Skip to content

handle plugin and resource command conflict#1480

Merged
etsai2-stripe merged 6 commits intomasterfrom
handleAppsResourceCommands
Mar 17, 2026
Merged

handle plugin and resource command conflict#1480
etsai2-stripe merged 6 commits intomasterfrom
handleAppsResourceCommands

Conversation

@etsai2-stripe
Copy link
Copy Markdown
Contributor

Reviewers

r? @
cc @stripe/developer-products

Summary

resource sub-command returns resource help menu

% stripe apps secrets
Usage:
  stripe apps secrets <operation> [parameters...]

Available Operations:
  create
  delete_where
  find
  list

Flags:
  -h, --help   help for secrets

Global Flags:
      --api-key string        Your API key to use for the command
      --color string          turn on/off color output (on, off, auto)
      --config string         config file (default is $HOME/.config/stripe/config.toml)
      --device-name string    device name
      --log-level string      log level (debug, info, trace, warn, error) (default "info")
  -p, --project-name string   the project name to read from for config (default "default")

Use "stripe apps secrets [command] --help" for more information about a command.

plugin subcommand returns plugin help menu

% stripe apps create
Create a new Stripe app

Usage:
  stripe apps create <app> [destination] [flags]

Examples:
stripe apps create ticket-manager

Flags:
  -h, --help                  help for create
      --id string             ID for the app (ie. com.example.<app_id>)
      --name string           Name for the app to be displayed in the UI
      --npm-registry string   npm registry to use
      --skip-git              Flag to determine to initialize git or not
  -T, --template string       Create a Stripe App from an existing template (default "hello-world")

Global Flags:
      --api-key string        Your API key to use for the command
      --color string          turn on/off color output (on, off, auto)
      --config string         config file (default is $HOME/.config/stripe/config.toml)
      --device-name string    device name
      --log-level string      log level (debug, info, trace, warn, error) (default "info")
  -p, --project-name string   the project name to read from for config (default "default")

top level conflict command that is available for both plugin and resource shows a combine help menu

% stripe apps --help
Usage:
  stripe apps <resource> <operation> [parameters...]

Available Resources:
  secrets

Flags:
  -h, --help   help for apps

Global Flags:
      --api-key string        Your API key to use for the command
      --color string          turn on/off color output (on, off, auto)
      --config string         config file (default is $HOME/.config/stripe/config.toml)
      --device-name string    device name
      --log-level string      log level (debug, info, trace, warn, error) (default "info")
  -p, --project-name string   the project name to read from for config (default "default")

Use "stripe apps [command] --help" for more information about a command.

---
Additional commands from the apps plugin:

Commands for building Stripe apps

Usage:
  stripe apps [command]

Available Commands:
  add               Add a building block for developing your app
  create            Create a new Stripe app
  grant             Grant configuration access to your app
  help              Help about any command
  remove            Remove a building block from your stripe-app json
  revoke            Revoke configuration access to your app
  set               Update App Manifest
  start             Start a development server for viewing your app in the Stripe dashboard
  upload            Upload your app to be submitted for review

Flags:
      --api-key string        Your API key to use for the command
      --color string          turn on/off color output (on, off, auto)
      --config string         config file (default is $HOME/.config/stripe/config.toml)
      --device-name string    device name
  -h, --help                  help for apps
      --log-level string      log level (debug, info, trace, warn, error) (default "info")
  -p, --project-name string   the project name to read from for config (default "default")

Use "stripe apps [command] --help" for more information about a command.

invalid command returns error

% stripe apps randomcmd
Unknown command "randomcmd" for "stripe apps".
See "stripe apps --help" for a list of available commands.
exit status 1

@etsai2-stripe etsai2-stripe merged commit 83084ac into master Mar 17, 2026
13 checks passed
vcheung-stripe added a commit that referenced this pull request Mar 18, 2026
vcheung-stripe added a commit that referenced this pull request Mar 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants