v1

latestOpenAPI 3.0.32026-07-26120117318.1 KB
Offerings

Create an offering

Creates a new offering for the authenticated project. If the project has no offerings yet, the new one is auto-promoted to main (tag will be 1 in the response even if it was omitted in the request). Prefer POST /v4/offerings/{offering_id}/set-main over passing tag=1 here when switching the main of an existing project.

post/offerings

Headers

Idempotency-Keystring

Request body

idstring required

1–64 chars of [a-zA-Z0-9._:- ]. Spaces and colons are accepted for parity with dashboard-created offerings. Immutable after create.

tag0 | null nullable

Only 0 and null (or omitting the field) are accepted on create. tag=1 is rejected with 400 cannot_set_main_directly — promote via POST /v4/offerings/{offering_id}/set-main (atomic). The very first offering in a project is auto-promoted to main even if tag is omitted.

product_idsstring[]

Product UIDs in display order. Each must already exist in this project, otherwise the request fails with 400 product_not_in_project. Up to 100 entries per request (maxItems).

Example request

{
  "id": "premium_monthly"
}

Response

Offering created.

object'offering' required
idstring required
urlstring required
taginteger nullable required

Offering role within the project. 1 = main offering (TAG_MAIN) — exactly one offering per project has tag=1 at any time; promote via POST /v4/offerings/{offering_id}/set-main. 0 = regular offering that was demoted from main. null = regular offering that has never been tagged. Treat 0 and null as equivalent on read. The Offerings endpoints filter out experiment-variant offerings, but legacy rows could carry historical values other than 0, 1, or null, so the response field is intentionally not enum-restricted. Write schemas restrict accepted values server-side.

product_idsstring[] required

Product UIDs that belong to this offering, in display order.

created_atstring date-time required
updated_atstring date-time required

Example response

{
  "id": "premium_monthly",
  "url": "/v4/offerings/premium_monthly",
  "created_at": "2025-09-15T12:30:00Z",
  "updated_at": "2025-11-03T10:26:40Z"
}