← Home
POST/hyax-api/v1/products

Create product

Creates a draft by default. Passing `isActive: true` only publishes when the product already passes publish readiness — otherwise it stays a draft and the response carries a `warning`. To sell variants, follow with **Update product options** then **Generate variants**. `WEBINAR` is not creatable via the API while it is platform-admin only.

Base URL: https://platform.hyax.com · Replace YOUR_API_KEY with your team API key.

Request body

FieldRequiredDescription
title Required
type Required `DIGITAL` | `PHYSICAL` | `COURSE` | `EVENT` | `MEMBERSHIP` | `MEETING`
pricingType Required `SINGLE` | `SUBSCRIPTION` | `PAY_WHAT_YOU_WANT` | `FREE`
slugNoDerived from the title when omitted; de-duplicated within the team
descriptionNo
priceNoRequired above zero for `SINGLE`/`SUBSCRIPTION` when publishing. Forced to null for `FREE`/`PAY_WHAT_YOU_WANT`
currencyNoISO 4217. Default `USD`
isActiveNoBoolean. Default `false`
hasVariantsNoBoolean. Required for a `DIGITAL` product to expose variants
unitsGrantedNoWallet units credited per purchase
membershipDurationNo`MONTH` | `YEAR` | `LIFETIME`. Defaults to `MONTH` for subscriptions
trialDaysNoNumber
meetingDurationNoMinutes, minimum 5. Default 60 for `MEETING`
meetingTypeNo`ONE_ON_ONE` | `GROUP`
categoryIdNoMust belong to the team

Request

curl -X POST 'https://platform.hyax.com/hyax-api/v1/products' \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{
    "title": "Studio Tee",
    "type": "PHYSICAL",
    "pricingType": "SINGLE",
    "price": 29,
    "currency": "USD",
    "hasVariants": true
  }'

Response

{
  "success": true,
  "data": {
    "id": "clx…",
    "title": "Studio Tee",
    "slug": "studio-tee",
    "type": "PHYSICAL",
    "pricingType": "SINGLE",
    "price": 29,
    "currency": "USD",
    "isActive": false,
    "hasVariants": true,
    "isArchived": false,
    "buyPath": "/buy/studio-tee",
    "buyUrl": "https://shop.example.com/buy/studio-tee",
    "createdAt": "2025-01-15T12:00:00.000Z",
    "updatedAt": "2025-01-15T12:00:00.000Z"
  }
}