---
title: "Checkout"
method: POST
path: "/api/billing/checkout"
tags: ["billing"]
---

# Checkout

`POST /api/billing/checkout`

## Request

- Base URL: `https://api.heymetra.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.heymetra.com/api/billing/checkout`
- Auth: none declared

Open a hosted checkout for the caller's workspace on the chosen plan.

``tier=enterprise`` pays the offer an admin staged on this workspace; any
other tier on an Enterprise workspace is refused.

## Headers

- `authorization` string, nullable
- `x-workspace-id` string, nullable

## Request body

- CheckoutIn
  - `tier` 'starter' | 'pro' | 'superior' | 'enterprise', required
  - `interval` 'monthly' | 'annual'

## Response `200`

Successful Response

- CheckoutOut
  - `checkout_url` string, required
  - `mode` string, required
  - `session_id` string, required

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/heymetra/apis/heymetra-api.md) · [All operations](https://skmtc.dev/heymetra/apis/heymetra-api/llms.txt) · [OpenAPI document](https://skmtc.dev/heymetra/apis/heymetra-api/revisions/877b0f87d6d0?raw)
