Get subscription by ID
Retrieves a subscription by its unique identifier. Returns the full subscription object including status, billing period, and dates.
Authorization<token>
Bearer token authentication for client-side SDK operations. Format: 'Authorization: Bearer '
In: header
Path Parameters
idstring
Response Body
curl -X GET "https://test-api.stash.gg/sdk/subscriptions/string"{
"id": "string",
"externalAccountId": "string",
"planId": "string",
"status": "string",
"period": {
"value": 0,
"unit": "string"
},
"trialEnd": "2019-08-24T14:15:22Z",
"accessEndDate": "2019-08-24T14:15:22Z",
"currentPeriodEnd": "2019-08-24T14:15:22Z",
"nextBillingDate": "2019-08-24T14:15:22Z",
"cancelAtPeriodEnd": true,
"canceledAt": "2019-08-24T14:15:22Z",
"createdAt": "2019-08-24T14:15:22Z",
"checkoutLinkMetadata": {
"property1": "string",
"property2": "string"
}
}{
"code": 0,
"message": "string",
"details": [
{
"@type": "string",
"property1": null,
"property2": null
}
]
}How is this guide?
Get payments by subscription ID GET
Retrieves payments associated with a subscription with pagination support. Returns a list of payment objects including payment ID, amount, currency, a succeeded indicator, and timestamps. Use the `next_page_token` from the response to fetch the next page.
List subscriptions GET
Query subscriptions by player and optionally filter by status. Returns all matching subscriptions for the specified external_account_id.