getAllSubscriptions
This method returns all subscriptions to products. 🔐 This method requires authorization.
Description
It returns a Promise that resolves to an ISubscriptions object.
Events.getAllSubscriptions(
offset,
limit
);
Parameters schema
Schema
offset: number
Pagination parameter, default is 0
example: 0
limit: number
Pagination parameter, default is 30
example: 30
By default, you can retrieve 10 objects. This is due to the record limit in the module's permissions settings.
For pagination to work correctly, you need to configure Module permissions according to your needs in the corresponding section.*
Examples
Minimal example
const response = await Events.getAllSubscriptions();
Example with attributes
const response = await Events.getAllSubscriptions(0, 30);
Example response
{
"total": 100,
"items": [
{
"eventMarker": "string",
"productId": 0
}
]
}
Response schema
Schema: ISubscriptions
total: number
Total number of records found
items: ISubscriptionItem[]
Event marker
items.eventMarker: string
Event marker
items.productId number
Product identifier