> ## Documentation Index
> Fetch the complete documentation index at: https://docs.glot.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Start a credit purchase

> Start a purchase of prepaid translation credit.

Returns a hosted payment page — redirect the browser to `checkout_url` to
complete the payment. Credit is added to the organization's balance only once
the payment has settled, so it may not be reflected the instant the browser
returns; abandoning checkout has no effect at all.

`amount_cents` must fall within the accepted top-up range, which
`GET /v1/billing/credit` reports as `min_topup_cents` / `max_topup_cents`.
Amounts outside it are rejected with 400.



## OpenAPI

````yaml https://api.staging.glot.com/openapi.json post /v1/billing/checkout
openapi: 3.1.0
info:
  title: glot-api
  version: 0.1.0
servers: []
security: []
tags:
  - name: rooms
    description: Create translation rooms and let participants join them.
  - name: usage
    description: Minutes and charges over time, for reporting and charts.
  - name: billing
    description: Buy prepaid credit and review the balance behind it.
  - name: api-keys
    description: Create and revoke keys used to authenticate requests.
  - name: supported-languages
    description: Languages available for translation.
  - name: users
    description: The authenticated user's own profile.
paths:
  /v1/billing/checkout:
    post:
      tags:
        - billing
      summary: Start a credit purchase
      description: >-
        Start a purchase of prepaid translation credit.


        Returns a hosted payment page — redirect the browser to `checkout_url`
        to

        complete the payment. Credit is added to the organization's balance only
        once

        the payment has settled, so it may not be reflected the instant the
        browser

        returns; abandoning checkout has no effect at all.


        `amount_cents` must fall within the accepted top-up range, which

        `GET /v1/billing/credit` reports as `min_topup_cents` /
        `max_topup_cents`.

        Amounts outside it are rejected with 400.
      operationId: create_checkout_v1_billing_checkout_post
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateCheckoutRequest'
        required: true
      responses:
        '201':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreateCheckoutResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    CreateCheckoutRequest:
      properties:
        amount_cents:
          type: integer
          exclusiveMinimum: 0
          title: Amount Cents
          examples:
            - 2500
      type: object
      required:
        - amount_cents
      title: CreateCheckoutRequest
      description: Request to buy prepaid translation credit.
    CreateCheckoutResponse:
      properties:
        checkout_id:
          type: string
          title: Checkout Id
        checkout_url:
          type: string
          title: Checkout Url
      type: object
      required:
        - checkout_id
        - checkout_url
      title: CreateCheckoutResponse
      description: >-
        Where to send the browser to complete the purchase.


        No quantity of credit is quoted: credit is money, so a settled payment
        of

        `amount_cents` adds exactly `amount_cents` to the balance.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````