Skip to content

Catalog Product — Create (step 1)

Creates a new catalog product — mirrors the Bagisto admin Create-Product wizard step 1. Only the bare-minimum fields are accepted at this step; everything else (name, description, price, inventories, images, variants, booking slots, etc.) is added through the Update endpoint.

Single-step configurable create

This endpoint accepts super_attributes in the same request as the create. The store then generates the full cartesian product of variants from the option ids you pass.

Endpoint

EndpointMethod
/api/admin/catalog/productsPOST

Request body

FieldTypeRequiredNotes
skustringyesUnique product SKU. Slug-validated.
attribute_family_idintegeryesExisting attribute family ID.
typestringyesOne of simple, virtual, downloadable, grouped, bundle, configurable, booking.
super_attributesobjectconditionalRequired when type=configurable. Map of attribute code (or id) → non-empty list of option ids. e.g. { "color": [1, 2], "size": [6, 7] }.

For every type except configurable, the body is just sku + attribute_family_id + type. Configurable additionally requires super_attributes.

Booking products

type=booking creates the parent booking product. The 5 sub-types (default / appointment / event / rental / table) and their slots or tickets are configured during the Update call.

Response

201 Created returning the full product detail payload — most fields will be null because only sku, type, and attribute_family_id are populated at this point. For configurable, the generated variants are included so you can reference each variant id when you fill in per-variant pricing via Update.

Errors

HTTPCause
401 UnauthorizedMissing or invalid admin Bearer token.
403 ForbiddenAdmin role lacks catalog.products.create.
422 Unprocessable EntityValidation failed — missing sku/family, unsupported type, duplicate SKU, invalid slug, unknown family, missing/invalid super_attributes for configurable.

Notes

  • The next call is typically PUT /api/admin/catalog/products/{id} to populate the rest of the fields.
  • See Update for the per-type structure payloads (variants, bundle options, links, booking slots/tickets).

Released under the MIT License.