JSPM

  • Created
  • Published
  • Downloads 88
  • Score
    100M100P100Q80168F
  • License MIT

Commerce Layer CLI Token plugin

Package Exports

  • @commercelayer/cli-plugin-token
  • @commercelayer/cli-plugin-token/lib/index.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@commercelayer/cli-plugin-token) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

commercelayer-cli-plugin-token

oclif Version Downloads/week License

Usage

Commands

cl-token token:create

Create a new custom access token.

USAGE
  $ cl-token token:create

OPTIONS
  -m, --minutes=minutes            (required) minutes to token expiration [2, 120]
  -o, --organization=organization  (required) the slug of your organization
  -s, --shared=shared              (required) organization shared secret
  --info                           show access token info

EXAMPLES
  $ commercelayer token:create -s <sharedSecret> -m 30
  $ cl token:create -s <sharedSecret> -m 15 --info

See code: src/commands/token/create.ts

cl-token token:decode [TOKEN]

Decode a Commerce Layer access token.

USAGE
  $ cl-token token:decode [TOKEN]

ARGUMENTS
  TOKEN  the access token to decode

OPTIONS
  -o, --organization=organization  (required) the slug of your organization

ALIASES
  $ cl-token token:info

EXAMPLES
  $ commercelayer token:decode
  $ cl token:info -a <accessToken>

See code: src/commands/token/decode.ts

cl-token token:get

Get a new access token.

USAGE
  $ cl-token token:get

OPTIONS
  -S, --scope=scope                access token scope (market, stock location)
  -e, --email=email                customer email
  -i, --clientId=clientId          (required) application client_id
  -o, --organization=organization  (required) the slug of your organization
  -p, --password=password          customer secret password
  -s, --clientSecret=clientSecret  application client_secret
  --info                           show access token info

EXAMPLES
  $ commercelayer token:get
  $ cl token:get --info

See code: src/commands/token/get.ts

cl-token token:revoke [TOKEN]

Revoke a Commerce Layer access token.

USAGE
  $ cl-token token:revoke [TOKEN]

ARGUMENTS
  TOKEN  access token to revoke

OPTIONS
  -i, --clientId=clientId          (required) application client_id
  -o, --organization=organization  (required) the slug of your organization
  -s, --clientSecret=clientSecret  (required) application client_secret

EXAMPLES
  $ commercelayer token:revoke
  $ cl token:revoke -a <accessToken>

See code: src/commands/token/revoke.ts