Retrieving subscriptions list from the product catalog
This method allows retrieving a list of subscriptions available in your app — including payment conditions for those subscriptions.
tip
If you are in doubt read the instruction in the usage scenarios.
Interaction parameters
GET
https://public-api.rustore.ru/public/applications/{appId}/catalog/subscriptions
Attribute | Type | Description | Mandatory | Location | Example |
---|---|---|---|---|---|
Public-Token | string | Jwe token to Public API Rustore. How to get an authorization token. | Yes | header | N/A |
appId | int | App ID | Yes | path | 385727 |
productId | string | Product ID form the RuStore Console. If specified, only the information about the product with the specified ID is returned. | No | query | full_access_1_month |
status | array | Product publication status:
| No | query | active |
continuationToken | string | Token to retrieve the next part of the result. | No | query | MSxiYTBmZDA...4ZDMyOWNlOTY= |
limit | int | Number of elements on a page. Maximum value is 500 . | No | query | 20 |
Response parameters
Attribute | Type | Description | Mandatory | Example |
---|---|---|---|---|
code | string | Yes | Response code | • OK ;• ERROR ;• BAD_REQUEST ;• NOT_FOUND . |
message | string | No | Decoded response code | N/A |
body{} | object | Yes | Response body | N/A |
timestamp | string | Yes | Response time | 2024-11-01T11:10:54.994306Z |
body{}
Attribute | Type | Description | Mandatory | Example |
---|---|---|---|---|
totalElementsCount | int | Total number of elements. If there are no elements, 0 will be returned. | No | 500 |
elementsCount | int | Number of returned elements. | No | 20 |
continuationToken | string | Token to retrieve the next part of the result. | No, nullable | null |
elements[] | array | Response contents | No | N/A |
elements[]
Attribute | Type | Description | Mandatory | Example |
---|---|---|---|---|
productId | string | Product code. | No, if there are no returned elements | full_access_1_month |
productType | string | Product type: subscription . | No, if there are no returned elements | subscription |
image | string | Link to product picture | No, if there are no returned elements | https://platform...c8e1b74.png |
name | string | Product name. | No, if there are no returned elements | Full access to all app functions |
description | string | Product description. | No, if there are no returned elements | Full access to all app functions, no ads |
status | string | Product publication status:
| No, if there are no returned elements | active |
tariffs[] | array | Tariffs. | No, if there are no returned elements | N/A |
tariffs[]
Attribute | Type | Description | Mandatory | Example |
---|---|---|---|---|
tariffCode | string | Tariff code. Available values:
For more details see here. | No | promo |
priceCurrency | string | ISO 4217 currency code. | No | RUB |
priceValue | string | Price in minor currency units. | No | 15000 |
periodType | string |
| No | day |
duration | int | Number of periodType in the specified subscription period. | No | 1 |
Successful response
{
"code": "OK",
"message": null,
"body": {
"totalElementsCount": 1,
"elementsCount": 1,
"continuationToken": null,
"elements": [
{
"productId": "full_access_1_month",
"productType": "subscription",
"image": "",
"name": "Full access to all app functions",
"description": "Full access to all app functions, no ads",
"status": "active",
"tariffs": [
{
"tariffCode": "grace",
"priceCurrency": "RUB",
"priceValue": 0,
"periodType": "day",
"duration": 14
},
{
"tariffCode": "hold",
"priceCurrency": "RUB",
"priceValue": 0,
"periodType": "day",
"duration": 14
},
{
"tariffCode": "start",
"priceCurrency": "RUB",
"priceValue": 1000,
"periodType": "month",
"duration": 1
},
{
"tariffCode": "standard",
"priceCurrency": "RUB",
"priceValue": 10000,
"periodType": "month",
"duration": 1
},
{
"tariffCode": "promo",
"priceCurrency": "RUB",
"priceValue": 0,
"periodType": "month",
"duration": 1
}
]
}
]
},
"timestamp": "2024-11-07T09:49:28.476738105Z"
}
Error response example
{
"code": "ERROR",
"message": "Invalid type specified for request parameter 'status'. Required type 'Set'",
"body": null,
"timestamp": "2024-11-07T09:49:59.787412185Z"
}