checkout

Create a payment session for one parcel label (MPP intent "session")

Prices the shipment live, anchors the amount to one service, and returns a handoff URL opening the SMKlog checkout prefilled with the shipment. The human confirms the contents certification and the carrier-adjustment consent there and pays on Stripe hosted checkout. This operation never charges: the agent prepares, the human pays. Pass the quote_id from getParcelQuote and the session reuses that quote instead of spending a second carrier call.

post/agent/checkout-session

Request

  • Base URL: https://quote-api.smklog.com
  • URL: https://quote-api.smklog.com/agent/checkout-session
  • Auth: one of:
    • none
    • OAuth 2 (client credentials, token URL https://quote-api.smklog.com/oauth/token, scopes: quote)

Request body

quote_idstring

The quote_id a getParcelQuote answer carries (the get_parcel_quote tool returns the same handle), valid 15 minutes. When given, the shipment comes from that quote and product, from_zip, to_zip, to_country and quantity are ignored; an expired handle prices the fields live.

productstring

Required unless quote_id is given.

from_zipstring

5-digit US ZIP. Required unless quote_id is given.

to_zipstring

5-digit US ZIP, or the destination country's own postal code. Required unless quote_id is given.

to_country'US' | 'CA' | 'GB' | 'DE' | 'AU'

Two-letter destination country

quantityinteger

How many of the item ship together. Default 1. Units that fit one box get a session for that box; more than one box, or a quantity above 1 sent with exact dimensions, returns no session — one label per box, so create one session per box.

servicestring

Optional service to anchor the amount, matched as a case-insensitive fragment of the display name; cheapest when omitted or unmatched.

Response

The session: intent, method, amount, currency, service, handoff_url, session_id, note. Keep session_id for getCheckoutStatus.

intent'session' required

Always "session" — this operation never charges

session_idstring nullable

Handle for getCheckoutStatus, shaped as_ plus a UUID, good for 30 days. Null only when the session record could not be stored.

methodstring[]

Payment rails behind the checkout, e.g. stripe, card

amountnumber required

Live-quoted checkout total for the anchored service, USD

currency'USD' required

ISO currency, USD

servicestring

The service the amount is anchored to

handoff_urlstring uri required

Opens the SMKlog checkout prefilled with this shipment

identified_product_titlestring

What the estimator understood the item to be

quote_reusedboolean

True when the amount came from a quote_id you supplied, so no carrier call was spent

notestring

Standing caveats: live quote, human confirms consents and pays

Changes

No recorded changes to this operation across all 1 revision of this API.