SHOPSTACK

Checkout with the CLI

Give Shopstack a product and a spending limit. Follow the checkout in your terminal.

  1. Select your user

    Terminal
    shopstack profiles list
    shopstack profiles use NAME

    Use a personal or end-user profile. A developer management profile must create an end user first.

  2. Save the request

    Put the product URL, customer details, currency, and spending limit in checkout.json.

    JSON example & field reference →
  3. Run the checkout

    Terminal
    shopstack checkout run --file checkout.json

    The CLI shows status and activity as they change. If Shopstack needs a size, address detail, or other information, answer the terminal prompt.

    With no payment provider selected, card entry uses a hidden terminal prompt. For an active Link connection, add "payment_provider": "link" to the request.

  4. Review the exact total

    The CLI displays subtotal, shipping, tax, and total. Missing values appear as unavailable.

    CLI prompt
    Approve this exact payment? [y/N]

    Enter y or yes to approve. Any other answer declines. Your spending limit and card entry do not approve payment.

  5. Read the result

    Progress goes to stderr. The final checkout object goes to stdout as JSON. Check status, then result or failure.

    Result fields & failure handling →
Create, inspect, or cancel separately
Terminal
shopstack checkout create --file checkout.json
shopstack checkout get CHECKOUT_ID
shopstack checkout cancel CHECKOUT_ID

create returns immediately. Save its checkout ID. get reads current state; cancel requests cancellation before submission.

run starts a new checkout. It does not resume an existing ID. If monitoring stops, inspect the saved ID before you create another checkout.