CREEM API Reference
Complete API reference with all endpoints, request/response schemas, and field descriptions.Base Configuration
Authentication
All requests require thex-api-key header:
Checkouts API
Create Checkout Session
Creates a new checkout session and returns a URL to redirect the customer.| Field | Type | Required | Description |
|---|---|---|---|
product_id | string | Yes | Product ID to purchase (e.g., prod_abc123) |
request_id | string | No | Your tracking ID for this checkout |
units | number | No | Number of units/seats (default: 1) |
discount_code | string | No | Pre-fill discount code |
customer | object | No | Pre-fill customer data |
customer.email | string | No | Customer’s email address |
customer.id | string | No | Existing customer ID |
success_url | string | No | Redirect URL after payment |
metadata | object | No | Key-value pairs for tracking |
custom_fields | array | No | Additional fields to collect (max 3) |
Retrieve Checkout
| Field | Type | Required | Description |
|---|---|---|---|
checkout_id | string | Yes | Checkout session ID |
CheckoutEntity with expanded product, customer, order, subscription, and feature objects if checkout is completed.
Products API
Create Product
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Yes | Product name |
description | string | No | Product description |
image_url | string | No | Product image URL (PNG/JPG) |
price | integer | Yes | Price in cents (min: 100) |
currency | string | Yes | ISO currency code (USD, EUR, etc.) |
billing_type | string | Yes | recurring or onetime |
billing_period | string | If recurring | every-month, every-year, etc. |
tax_mode | string | No | inclusive or exclusive |
tax_category | string | No | saas, digital-goods-service, ebooks |
default_success_url | string | No | Default redirect after payment |
custom_fields | array | No | Fields to collect at checkout |
abandoned_cart_recovery_enabled | boolean | No | Enable cart recovery emails |
Retrieve Product
List Products
| Field | Type | Required | Description |
|---|---|---|---|
page_number | number | No | Page number (default: 1) |
page_size | number | No | Items per page |
Customers API
Retrieve Customer
List Customers
Generate Customer Portal Link
Subscriptions API
Retrieve Subscription
active- Currently active and paidtrialing- In trial periodpaused- Temporarily pausedcanceled- Canceled (terminal)unpaid- Payment failedscheduled_cancel- Will cancel at period end
Update Subscription
proration-charge-immediately- Charge prorated amount now, new billing cycle startsproration-charge- Credit added to next invoice, same billing cycleproration-none- No proration, change at next cycle
Upgrade Subscription
Cancel Subscription
mode:immediate(cancel now) orscheduled(at period end)onExecute:cancelorpause(only for scheduled mode)
Pause Subscription
Resume Subscription
Licenses API
Activate License
active- Valid and usableinactive- No activations yetexpired- Past expiration datedisabled- Manually disabled
Validate License
Deactivate License
Discounts API
Create Discount
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Yes | Display name |
code | string | No | Discount code (auto-generated if empty) |
type | string | Yes | percentage or fixed |
percentage | number | If type=percentage | Discount percentage (e.g., 20 for 20%) |
amount | number | If type=fixed | Fixed amount in cents |
currency | string | If type=fixed | Currency for fixed discount |
duration | string | Yes | forever, once, or repeating |
duration_in_months | number | If duration=repeating | Months to apply |
max_redemptions | number | No | Usage limit |
expiry_date | string | No | ISO date when code expires |
applies_to_products | array | Yes | Product IDs this applies to |
Retrieve Discount
Delete Discount
Transactions API
Get Transaction
payment- One-time paymentinvoice- Subscription payment
paid- Successfully paidrefunded- Fully refundedpartially_refunded- Partially refundedchargeback- Disputed
List Transactions
| Field | Type | Required | Description |
|---|---|---|---|
customer_id | string | No | Filter by customer |
order_id | string | No | Filter by order |
product_id | string | No | Filter by product |
page_number | number | No | Page number |
page_size | number | No | Items per page |
Common Entities
OrderEntity
PaginationEntity
EnvironmentMode
Values:test, prod, sandbox
HTTP Response Codes
| Code | Description |
|---|---|
| 200 | Success |
| 400 | Bad Request - Invalid parameters |
| 401 | Unauthorized - Missing API key |
| 403 | Forbidden - Invalid API key or limit reached |
| 404 | Not Found - Resource doesn’t exist |
| 429 | Rate Limited |
| 500 | Server Error |
Rate Limits
Contact support for specific rate limits. Implement exponential backoff for 429 responses.Idempotency
Userequest_id for checkout sessions to prevent duplicate payments if retrying failed requests.