The Subscription Plan Detail object
Attributes
Unique identifier for the object.
{
"id": "subscription-plan-detail_abc123",
"idx": 1,
"parent_id": null,
"parent_type": "parent_type_example",
"qty": 0,
"plan": "plan_example"
} /api/accounts/subscription-plan-detail?parent_id={id} List subscription plan details by parent
Returns all subscription plan details belonging to the specified parent.
Query parameters
The ID of the parent to list children for.
Returns
A list of subscription plan detail objects belonging to the parent.
curl https://api.overplane.dev/api/accounts/subscription-plan-detail?parent_id=parent_abc123 \
-H "Authorization: Bearer sk_test_..." {
"data": [
{
"id": "subscription-plan-detail_abc123",
"idx": 1,
"parent_id": null,
"parent_type": "parent_type_example",
"qty": 0,
"plan": "plan_example"
}
],
"has_more": false,
"total": 1
} /api/accounts/subscription-plan-detail Create a subscription plan detail
Creates a new subscription plan detail object.
Body parameters
Returns
Returns the newly created subscription plan detail object if the call succeeded.
curl https://api.overplane.dev/api/accounts/subscription-plan-detail \
-H "Authorization: Bearer sk_test_..." \
-X POST \
-H "Content-Type: application/json" \
-d '{"parent_id":null,"parent_type":"parent_type_example","qty":0,"plan":"plan_example"}' {
"id": "subscription-plan-detail_abc123",
"idx": 1,
"parent_id": null,
"parent_type": "parent_type_example",
"qty": 0,
"plan": "plan_example"
} /api/accounts/subscription-plan-detail/{id} Update a subscription plan detail
Updates the specified subscription plan detail by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
Path parameters
The identifier of the subscription plan detail to update.
Body parameters
Returns
Returns the updated subscription plan detail object.
curl https://api.overplane.dev/api/accounts/subscription-plan-detail/subscription-plan-detail_abc123 \
-H "Authorization: Bearer sk_test_..." \
-X PATCH \
-H "Content-Type: application/json" \
-d '{"idx":1,"parent_id":null}' {
"id": "subscription-plan-detail_abc123",
"idx": 1,
"parent_id": null,
"parent_type": "parent_type_example",
"qty": 0,
"plan": "plan_example"
} /api/accounts/subscription-plan-detail/{id} Delete a subscription plan detail
Permanently deletes a subscription plan detail. This cannot be undone.
Path parameters
The identifier of the subscription plan detail to delete.
Returns
Returns a confirmation that the subscription plan detail has been deleted.
curl https://api.overplane.dev/api/accounts/subscription-plan-detail/subscription-plan-detail_abc123 \
-H "Authorization: Bearer sk_test_..." \
-X DELETE {
"id": "subscription-plan-detail_abc123",
"deleted": true
} /api/accounts/subscription-plan-detail/reorder Reorder subscription plan details
Updates the sort order of subscription plan details within their parent by setting new index values.
Returns
Returns the reordered list.
curl https://api.overplane.dev/api/accounts/subscription-plan-detail/reorder \
-H "Authorization: Bearer sk_test_..." \
-X POST {
"id": "subscription-plan-detail_abc123",
"idx": 1,
"parent_id": null,
"parent_type": "parent_type_example",
"qty": 0,
"plan": "plan_example"
}