Reference
Interface
interface CartChildItemCreate {
quantity: number;
sku: string;
subscription: boolean;
subscription_duration: number | null;
subscription_end: string | null;
subscription_interval: number;
subscription_period: "daily" | "weekly" | "monthly" | "yearly" | null;
subscription_start: string | null;
subscription_type: "normal" | "consumable" | null;
}
interface CartItemCreate {
children: CartChildItemCreate | null;
quantity: number;
sku: string;
subscription: boolean;
subscription_duration: number | null;
subscription_end: string | null;
subscription_interval: number;
subscription_period: "daily" | "weekly" | "monthly" | "yearly" | null;
subscription_start: string | null;
subscription_type: "normal" | "consumable" | null;
}
Keys
children
- Type:
array
- Default:
null
Manually add child items to a parent.
quantity
- Type:
number
- Default:
1
Amount of products added.
sku
- Type:
boolean
- Default:
false
Stock keeping unit.
subscription
- Type:
boolean
- Default:
false
User to determine if the added product is a subscription or not.
subscription_duration
- Type:
number|null
- Default:
null
Specifies the subscription length.
subscription_end
- Type:
string|Date|null
- Default:
null
Subscription end date.
subscription_interval
- Type:
number
- Default:
1
Specifies the prepaid length of a subscription.
subscription_period
- Type:
string
- Default:
null
Specifies the instalment frequency.
daily | weekly | monthly | yearly;
subscription_start
- Type:
string|Date|null
- Default:
null
Subscription start date.
subscription_type
- Type:
string|null
- Default:
null
Specifies the type of the subscription as normal or consumable.
normal | consumable;