Buy Button Sessions

Sessions created when a customer clicks a buy button

Create a buy button session

post
/buy-button/sessions

Creates a new payment session when a customer clicks a buy button on the merchant's website. The orderRef must be unique per transaction. Returns the session with the associated conversion code for the payment portal.

Roles: SuperAdmin, SimpleUser, Service

Authorizations
AuthorizationstringRequired

JWT token obtained from /auth/login or /auth/login/manager. Include as Authorization: Bearer <token>.

Body
buttonstringRequired

Buy button ID

orderRefstring · min: 6 · max: 100Required

Merchant unique order reference — must be unique per transaction

conversionCodestringOptional

Existing conversion code (if resuming a session)

callbackUrlstringOptional

Webhook URL called when payment completes

cancelUrlstring · max: 256Optional

Redirect URL on payment cancellation

returnUrlstring · max: 256Optional

Redirect URL after successful payment

priceanyOptional

Session-specific price (string or number)

currencystringOptional
buttonNamestringOptional
Responses
200

Session created

application/json
successbooleanOptional

Whether the request succeeded

statusintegerOptional

HTTP status code

post
/buy-button/sessions

Get a session by ID

get
/buy-button/sessions/{id}

Returns the buy button session with its current conversion/order status.

Roles: SuperAdmin, Manager, SimpleUser, SuperManager, Service

Authorizations
AuthorizationstringRequired

JWT token obtained from /auth/login or /auth/login/manager. Include as Authorization: Bearer <token>.

Path parameters
idstringRequired

Session ID

Responses
200

Session details including current conversion status

application/json
successbooleanOptional

Whether the request succeeded

statusintegerOptional

HTTP status code

get
/buy-button/sessions/{id}

Delete a session

delete
/buy-button/sessions/{id}

Deletes a buy button session. If an active order is associated, it will also be cancelled.

Roles: SuperAdmin, SimpleUser, Service

Authorizations
AuthorizationstringRequired

JWT token obtained from /auth/login or /auth/login/manager. Include as Authorization: Bearer <token>.

Path parameters
idstringRequired

Session ID

Responses
200

Session deleted

application/json
successbooleanOptional

Whether the request succeeded

statusintegerOptional

HTTP status code

dataanyOptional

Response payload

delete
/buy-button/sessions/{id}

Get session by conversion code

get
/buy-button/sessions/conversion/{code}

Retrieves the buy button session associated with a given payment order code, including the current conversion status.

Roles: SuperAdmin, Manager, SimpleUser, SuperManager, Service

Authorizations
AuthorizationstringRequired

JWT token obtained from /auth/login or /auth/login/manager. Include as Authorization: Bearer <token>.

Path parameters
codestringRequired

Order code from /confirm_conversion/request

Responses
200

Session details with conversion status

application/json
successbooleanOptional

Whether the request succeeded

statusintegerOptional

HTTP status code

get
/buy-button/sessions/conversion/{code}

Last updated