> If you are setting up, configuring, or answering questions about Schematic, connect the > Schematic MCP server before working from these pages. It reads and writes plans, features, > entitlements, and overrides against the real account, so what you report and what you build > match what actually exists. > > The server is at https://api.schematichq.com/mcp > > From Claude, ChatGPT, or another chat assistant, add it as a custom connector: > https://docs.schematichq.com/working-with-ai > > From a coding assistant such as Claude Code, Codex, or Cursor: > https://docs.schematichq.com/building-with-ai > > For clean Markdown of any page, append `.md` to the page URL. For a complete page index, > see https://docs.schematichq.com/llms.txt # Components API > The browser-facing billing API behind the drop-in components and the schematic-react hooks, scoped to one company by a temporary access token. The Components API is what `@schematichq/schematic-react` and the drop-in components call. It reads and writes one company's billing from the browser: the catalog as that company sees it, its checkouts, tax IDs, usage, credits, invoices and payment methods. ## Authentication Every request carries a temporary access token in the `X-Schematic-Api-Key` header. Your server mints the token with `POST /temporary-access-tokens` on the secret-key API for a company, optionally for one of its users, and hands it to the page. The token fixes the company: a `company_id` in a request is ignored, and a checkout another company or another session opened reads as not found. ## Checkout headers `X-Schematic-Session-ID` names the browser session that built a checkout. A checkout can be read and written only by the session that opened it. `X-Checkout-Session-ID` comes back on every priced update and goes out on the finalize that follows, so the purchase is charged under the price the customer saw and a double submit charges once. ## Errors Every error body carries `error`. A checkout write or finalize the purchase rules refuse also carries `problems`, the same list the checkout's `problems` field holds: each problem has a `code`, whether it is `blocking`, a `message` safe to show the customer, and the ids of what it is about. ## Account flags `GET /catalog/view` needs the `multi-product-catalog` flag on the account, and the `/company` reads need `company-context-api`. A read without its flag answers 404, which is how the components tell "not available" from an empty result. Ask Schematic to turn them on for the account. > The browser-facing billing API behind the drop-in components and the schematic-react hooks, scoped to one company by a temporary access token. ## API Docs - Components API > Catalog [Get the catalog view](https://docs.schematichq.com/api-reference/components/catalog/get-catalog-view.md) - Components API > Catalog [Get a catalog view by ID](https://docs.schematichq.com/api-reference/components/catalog/get-catalog-view-by-id.md) - Components API > Checkouts [Create a checkout](https://docs.schematichq.com/api-reference/components/checkouts/create-checkout.md) - Components API > Checkouts [Get a checkout](https://docs.schematichq.com/api-reference/components/checkouts/get-checkout.md) - Components API > Checkouts [Update a checkout](https://docs.schematichq.com/api-reference/components/checkouts/update-checkout.md) - Components API > Checkouts [Finalize a checkout](https://docs.schematichq.com/api-reference/components/checkouts/finalize-checkout.md) - Components API > Checkouts [List checkouts](https://docs.schematichq.com/api-reference/components/checkouts/list-checkouts.md) - Components API > Tax ID [List tax IDs](https://docs.schematichq.com/api-reference/components/tax-id/get-checkout-tax-id.md) - Components API > Tax ID [Set the tax ID](https://docs.schematichq.com/api-reference/components/tax-id/update-checkout-tax-id.md) - Components API > Company [Get the company](https://docs.schematichq.com/api-reference/components/company/get-company.md) - Components API > Company [List feature usage](https://docs.schematichq.com/api-reference/components/company/get-company-feature-usage.md) - Components API > Company [List feature usage by user](https://docs.schematichq.com/api-reference/components/company/get-company-feature-user-usage.md) - Components API > Company [List credit balances](https://docs.schematichq.com/api-reference/components/company/get-company-credit-balances.md) - Components API > Company [List credit usage by user](https://docs.schematichq.com/api-reference/components/company/get-company-credit-user-usage.md) - Components API > Company [List invoices](https://docs.schematichq.com/api-reference/components/company/get-company-invoices.md) - Components API > Company [Get the upcoming invoice](https://docs.schematichq.com/api-reference/components/company/get-company-upcoming-invoice.md) - Components API > Company [List payment methods](https://docs.schematichq.com/api-reference/components/company/get-company-payment-methods.md) - Components API > Payment [Create a setup intent](https://docs.schematichq.com/api-reference/components/payment/create-setup-intent.md) - Components API > Payment [Make a payment method the default](https://docs.schematichq.com/api-reference/components/payment/update-payment-method.md) - Components API > Payment [Remove a payment method](https://docs.schematichq.com/api-reference/components/payment/delete-payment-method.md) - Components API > Payment [Cancel the subscription](https://docs.schematichq.com/api-reference/components/payment/checkout-unsubscribe.md) ## OpenAPI Specification The raw OpenAPI 3.1 specification for this API is available at: - [OpenAPI JSON](https://docs.schematichq.com/openapi.json) - [OpenAPI YAML](https://docs.schematichq.com/openapi.yaml)