---
title: "Get authoritative checkout state"
method: GET
path: "/credits/topups/{sessionId}"
tags: ["Top-ups"]
---

# Get authoritative checkout state

`GET /credits/topups/{sessionId}`

## Request

- Base URL: `https://api.paywithlocus.com/api`
- URL: `https://api.paywithlocus.com/api/credits/topups/{sessionId}`
- Auth: one of:
  - HTTP bearer
  - HTTP bearer

Returns the authoritative state of a workspace top-up checkout session. Poll it after Stripe Checkout instead of trusting the browser redirect.

## Path parameters

- `sessionId` string, required

## Response `200`

Checkout state

- TopupStatus
  - `success` unknown, required
  - `sessionId` string, required
  - `state` 'pending' | 'completed' | 'expired', required
  - `paymentStatus` string, required
  - `fulfillment` 'awaiting_payment' | 'processing' | 'ready' | 'expired' | 'failed': Ledger state. `completed` means Stripe was paid; credits are spendable once this is `ready`.

## Other responses

- `400`: Stable top-up validation, velocity, or ownership error

---

[API](https://skmtc.dev/paywithlocus/apis/locus-pro-api.md) - [All operations](https://skmtc.dev/paywithlocus/apis/locus-pro-api/llms.txt) - [OpenAPI document](https://skmtc.dev/paywithlocus/apis/locus-pro-api/revisions/aab8fa5d6cef?raw)
