Create Package

View as Markdown
Create a new package with items. A package groups products for checkout with billing cycle toggles. At least one item is required, and at least one billing cycle must be enabled.

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Path parameters

account_idstringRequired

Request

This endpoint expects an object.
namestringRequired>=1 character
Package name
descriptionstring or nullOptional
Package description
is_activebooleanOptionalDefaults to true
Whether the package is active
allow_monthlybooleanOptionalDefaults to true
Allow monthly billing cycle
allow_annualbooleanOptionalDefaults to true
Allow annual billing cycle
default_billing_cycleenumOptionalDefaults to monthly
Default billing cycle when both are allowed
itemslist of objectsOptional

Package items (can be added after creation)

metadatamap from strings to any or nullOptional
Optional metadata

Response

Successful Response
idstring
account_idstring
namestring
created_atdatetime
updated_atdatetime
descriptionstring or nullOptional
is_activebooleanOptionalDefaults to true
allow_monthlybooleanOptionalDefaults to true
allow_annualbooleanOptionalDefaults to true
default_billing_cyclestringOptionalDefaults to monthly
itemslist of objectsOptional
deleted_atdatetime or nullOptional

Errors

422
Unprocessable Entity Error