Skip to content

Create one or more subscriptions

POST
/api/subscriptions

Creates new subscriptions for a profile. Lines split across entities will produce multiple subscription records; the response returns the IDs of every subscription created.

object
profile_id
required
string
shopify_payment_method_id
required
string
next_delivery_date
required
string
delivery_slot_id
string
nullable
delivery_address_id
string
nullable
note
string
nullable
notify_customer
boolean
lines
required
Array<object>
object
shopify_product_id
required
string
shopify_variant_id
required
string
product_title
required
string
variant_title
string
nullable
sku
string
nullable
price
required
number
quantity
required
number
>= 1
selling_plan_id
required
string
subscription_variant_id
string
nullable
selection_items
Array<object>
nullable
object
slot_id
required
string
shopify_product_id
required
string
shopify_variant_id
required
string
product_title
required
string
variant_title
string
nullable
quantity
required
number
>= 1
price
required
number

Subscriptions created

object
ids
required

IDs of the created subscriptions

Array<string>

Invalid request — see error message for details

Example
{
"error": "Failed to create subscription"
}