palbaseDocs

Palbase Commerce & Promotions · API

POST/commerce/carts/{cart_id}/checkout

Execute single-TX checkout with stock/promo holds and marketplace payment intent

Execute single-TX checkout with stock/promo holds and marketplace payment intent. payment_method is card (the default) or wallet, paid through a payment channel, or — with nothing paid yet — cod or bank_transfer, which a buyer picks only where the project's settings name them (offline_payment_methods; 403 payment_method_not_allowed otherwise), and net_terms, which the project's server (its secret key) alone checks out with. Any other name is refused (400 invalid_payment_method).

Called by your app, with the publishable key; or a signed-in user of your app, with their token and the publishable key; or your server, with the project's secret key.

Path

cart_idstring · requiredPath parameter cart_id.
curl
curl -X POST "https://<your-ref>.palbase.studio/commerce/carts/<cart_id>/checkout" \
  -H "apikey: $PALBASE_SECRET_KEY" \
  -H "content-type: application/json" \
  -d '{}'

Responses

201Execute single-TX checkout with stock/promo holds and marketplace payment intent

defaultStandard Palbase JSON error envelope (`error` and `error_description`).

Operation CheckoutCart of commerce's contract.