Skip to main content
The Crevio API lets you programmatically manage your account’s products, orders, customers, checkouts, and more. Use it to build custom storefronts, sync data with external systems, or automate workflows.

What you can do with the API

  • Products — Create, update, list, and retrieve products and price variants.
  • Orders — List and retrieve order details.
  • Customers — List, retrieve, and manage customer records.
  • Checkouts — Create checkout sessions and retrieve checkout details.
  • Checkout links — Create and manage shareable checkout links.
  • Experiences — List and retrieve experiences and their content.
  • Discounts — Create and manage discount codes.
  • Blog posts — Create and manage blog content.

Authentication

All API requests are authenticated using Bearer tokens. Include your API token in the Authorization header of every request:
curl https://api.crevio.co/v1/products \
  -H "Authorization: Bearer YOUR_API_TOKEN"
Requests without a valid token receive a 401 Unauthorized response.

Base URL

All API endpoints use the following base URL:
https://api.crevio.co/v1

Creating API tokens

1

Go to Developer settings

In your dashboard, navigate to Settings > Developer.
2

Create a new token

Click New API token and give it a descriptive name (e.g., “My integration” or “Storefront sync”).
3

Copy the token

Your token is displayed once. Copy it and store it securely. You will not be able to view it again.
Treat API tokens like passwords. Do not commit them to version control, share them in public channels, or include them in client-side code. Store them in environment variables or a secrets manager.
API tokens are scoped to your account. Any request made with a token acts on behalf of the user who created it, within the context of that account.

Token management

  • Tokens display their last used timestamp so you can identify stale tokens.
  • You can delete a token at any time to revoke access immediately.
  • Each account can have multiple active tokens.

Rate limiting

The API enforces rate limits to ensure fair usage and platform stability. If you exceed the rate limit, the API responds with a 429 Too Many Requests status code. Wait for the period indicated in the response headers before retrying.
Implement exponential backoff in your API client to handle rate limits gracefully. The @crevio/sdk handles this automatically.

Pagination

List endpoints return paginated results. The response includes an items array and a pagination object:
{
  "items": [
    { "id": "prod_abc123", "name": "My Course" },
    { "id": "prod_def456", "name": "Templates Pack" }
  ],
  "pagination": {
    "page": 1,
    "pages": 5,
    "count": 47,
    "limit": 10,
    "offset": 0,
    "from": 1,
    "to": 10,
    "in": 10,
    "last": 5,
    "next": 2,
    "previous": null
  }
}
FieldDescription
pageCurrent page number
pagesTotal number of pages
countTotal number of items across all pages
limitNumber of items per page
offsetNumber of items skipped
fromPosition of the first item on this page
toPosition of the last item on this page
inNumber of items on this page
lastLast page number
nextNext page number, or null if on the last page
previousPrevious page number, or null if on the first page
Use the page query parameter to navigate between pages:
curl https://api.crevio.co/v1/products?page=2 \
  -H "Authorization: Bearer YOUR_API_TOKEN"

Error format

When a request fails, the API returns a JSON error response:
{
  "error": {
    "type": "validation_error",
    "message": "Name can't be blank",
    "details": {
      "name": ["can't be blank"]
    }
  }
}
FieldDescription
typeThe error category (e.g., validation_error, not_found, parameter_missing, error)
messageA human-readable description of what went wrong
detailsField-level validation errors (included for validation errors only)

Common error types

TypeHTTP statusDescription
validation_error422The request body contains invalid data
not_found404The requested resource does not exist
parameter_missing400A required parameter is missing
error500An unexpected server error occurred

Full API reference

For detailed documentation of every endpoint, request parameters, and response schemas, see the API Reference tab.

Available SDKs

@crevio/sdk (TypeScript)

The official TypeScript SDK provides a type-safe client for the Crevio API with Zod validation, automatic retries, and support for multiple runtimes (Node.js, browsers, Cloudflare Workers, and Deno). Install it with your preferred package manager:
npm install @crevio/sdk
Basic usage:
import { Crevio } from "@crevio/sdk";

const crevio = new Crevio({
  bearerAuth: "YOUR_API_TOKEN",
});

// List products
const { items, pagination } = await crevio.products.list();

// Get a specific product
const product = await crevio.products.get("prod_abc123");

// Create a checkout
const checkout = await crevio.checkouts.create({
  priceVariantId: "pv_xyz789",
});
The SDK handles authentication, pagination, error handling, and retries automatically.