Stubs

Modules

Pushing modules

Name a module

A module's name is Stubs's host, an owner (a user or an organisation) and the module's name, in stubs.yaml:

version: v2
modules:
  - path: .
    name: stubs.dev/acme/payments

Create and push

Create the module first, or let the push create it:

stubs registry module create stubs.dev/acme/payments --visibility public
stubs push
stubs push --create --create-visibility private

Each push makes a commit, unless nothing changed. Private modules are visible only to the owner's members; how many you can have depends on your team's plan (see Billing & types).

Read a module

stubs build stubs.dev/acme/payments -o payments.binpb
stubs export stubs.dev/acme/payments -o exported

stubs build makes an image of the module and its dependencies; stubs export writes out its .proto files.