Skip to Content
Docs
API referenceManagement API

Billing checkout sessions

POST
/billing/checkout-sessions

billing.contract.v1.CheckoutSessionService/CreateCheckoutSession (35-contracts.md, Checkout session and API Surface). The client's server creates a session for a Customer or a subject; the checkout element confirms it through /v1/me/billing. success_url and cancel_url must be on one of the instance's app origins (billing-svc docs/questions.md, P71).

Authorization

BearerAuth
headerAuthorization<token>

Access token as "Bearer "

Header Parameters

X-Idempotency-Key?string

Idempotency key

Response Body

A CheckoutSession object

application/json
  1. response
id?string

ID is its prefixed id.

object?string

Object names the kind: customer, invoice, contract, …

Example Request
curl -X POST 'https://api.us.pontive.com/v1/billing/checkout-sessions'
Example Response
{  "id": "string",  "object": "string"}
GET
/billing/checkout-sessions/{checkout_session_id}

billing.contract.v1.CheckoutSessionService/GetCheckoutSession (35-contracts.md, Checkout session and API Surface).

Authorization

BearerAuth
headerAuthorization<token>

Access token as "Bearer "

Path Parameters

checkout_session_id*string

id

Response Body

A CheckoutSession object

application/json
  1. response
id?string

ID is its prefixed id.

object?string

Object names the kind: customer, invoice, contract, …

Example Request
curl -X GET 'https://api.us.pontive.com/v1/billing/checkout-sessions/string'
Example Response
{  "id": "string",  "object": "string"}
POST
/billing/checkout-sessions/{checkout_session_id}/expire

billing.contract.v1.CheckoutSessionService/ExpireCheckoutSession (35-contracts.md, Checkout session and API Surface). An open session becomes expired.

Authorization

BearerAuth
headerAuthorization<token>

Access token as "Bearer "

Path Parameters

checkout_session_id*string

id

Header Parameters

X-Idempotency-Key?string

Idempotency key

Response Body

A CheckoutSession object

application/json
  1. response
id?string

ID is its prefixed id.

object?string

Object names the kind: customer, invoice, contract, …

Example Request
curl -X POST 'https://api.us.pontive.com/v1/billing/checkout-sessions/string/expire'
Example Response
{  "id": "string",  "object": "string"}