---
title: "Create Stripe checkout session"
method: POST
path: "/billing/me/checkout"
tags: ["Billing"]
---

# Create Stripe checkout session

`POST /billing/me/checkout`

## Request

- Base URL: `https://api.crawlora.net/api/v1`
- URL: `https://api.crawlora.net/api/v1/billing/me/checkout`
- Auth: API key in header `x-api-key`

Creates a Stripe Checkout session for the authenticated user's selected paid billing plan. The created subscription is tagged with the local user id and plan so Stripe webhooks can link the customer and activate the plan after payment.

## Request body

- BillingStripeCheckoutRequestDoc
  - `cancel_url` string
  - `plan` string
  - `success_url` string

## Response `200`

Stripe checkout session

- BillingStripeSessionResponseDoc
  - `code` integer
  - `data` BillingStripeSessionDoc
    - `id` string
    - `url` string
  - `msg` string

## Other responses

- `400`: Invalid request or plan
- `401`: Authentication required
- `500`: Internal server error

---

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