About RecurringApplicationCharge ​
Access scope
Multiple access scopes needed — refer to each endpoint for access scope requirements.
The Billing API provides a set of RESTful endpoints for managing app billing information, including creating, canceling, retrieving bills, and reporting usage charges. This API is designed to support merchants on the Genstore platform in subscribing to and using apps.
Core Features:
- Create recurring app charges: Allows merchants to create recurring subscription fees for apps.
- Cancel recurring charges: Allows merchants to cancel their subscription fees for apps.
- Retrieve a single charge: Allows merchants to query charge details using the subscription charge ID.
- Create usage-based charges: Allows merchants to create charges based on actual usage.
Notes
When using the Billing API, please note the following:
- Data consistency: To avoid duplicate usage charges, ensure that the
extUniqueId
in each usage report request is unique.
Use Cases
Here are some common use cases to help developers better understand the practical value of the Billing API:
- Create recurring application charges: Merchants can use the API to create recurring billing plans for apps, supporting time-based, usage-based, or hybrid billing models.
- Cancel recurring charges: Merchants can cancel their current subscription fees through the API.
- Retrieve a single charge: Merchants can retrieve details of an individual subscription to view its full billing information.
- Create usage-based charges: Once a merchant subscribes to a usage-based plan, they can report usage via the API to generate corresponding usage charges.
Endpoints
POST
/api/202412/recurring_application_charges: Create recurring app charge
DELETE
/api/202412/recurring_application_charges/{chargeId}: Cancel recurring app charge
GET
/api/202412/recurring_application_charges/{chargeId}: Retrieve single app charge
Recurring application charge Object ​
The recurring application charge object.
Properties ​
* pending;
* active;
* declined;
* expired;
* froze;
* cancelled.
{
"recurringApplicationCharge": {
"trialEndsTime": "2025-04-01T15:46:46-04:00",
"trialDays": "5",
"test": "false",
"confirmationUrl": "https://jsmith.blaze.com/admin/charges/755357713/1029266966/RecurringApplicationCharge/confirm_recurring_application_charge?signature=BAh7BzoHaWRpBBZeWT06EmF1dG9fYWN0aXZhdGVU--98ef575ea1fff24621e47eaa65e42758f13a3ae5",
"billingTime": "2025-04-01T15:46:46-04:00",
"updateTime": "2025-04-01T15:46:46-04:00",
"createTime": "2025-04-01T15:46:46-04:00",
"activatedTime": "2025-04-01T15:46:46-04:00",
"price": "20.0",
"cancelledTime": "2025-04-01T15:46:46-04:00",
"name": "Super Duper Plan",
"currency": "USD",
"id": "1029266966",
"returnUrl": "http://super-duper.blaze.com/",
"status": "pending"
}
}
POST
Create recurring app charge ​
Creates a recurring charge for an app subscription. Supports time-based, usage-based, and hybrid billing models.
Access scope
Requires ANY of the following access scopes: write_billing
Endpoint
POST
/api/202412/recurring_application_charges
Request Params
Response Data
* pending;
* active;
* declined;
* expired;
* froze;
* cancelled.
curl -X POST \
https://{shop}.genmystore.com/api/202412/recurring_application_charges" \
-H "X-Genstore-Access-Token: {access_token}" \
-H "Content-Type: application/json" \
-d '{
"recurringApplicationCharge":{
"trialDays":"7",
"cappedAmount":"100",
"terms":"$1 for 1000 emails",
"price":"100.00",
"name":"Super Duper Expensive action",
"returnUrl":"http://super-duper.blaze.com"
}
}'
HTTP/1.1 200 OK
{
"recurringApplicationCharge": {
"trialEndsTime": "2025-04-01T15:46:46-04:00",
"trialDays": "5",
"test": "false",
"confirmationUrl": "https://jsmith.blaze.com/admin/charges/755357713/1029266966/RecurringApplicationCharge/confirm_recurring_application_charge?signature=BAh7BzoHaWRpBBZeWT06EmF1dG9fYWN0aXZhdGVU--98ef575ea1fff24621e47eaa65e42758f13a3ae5",
"billingTime": "2025-04-01T15:46:46-04:00",
"updateTime": "2025-04-01T15:46:46-04:00",
"createTime": "2025-04-01T15:46:46-04:00",
"activatedTime": "2025-04-01T15:46:46-04:00",
"price": "20.0",
"cancelledTime": "2025-04-01T15:46:46-04:00",
"name": "Super Duper Plan",
"currency": "USD",
"id": "1029266966",
"returnUrl": "http://super-duper.blaze.com/",
"status": "pending"
}
}
DELETE
Cancel recurring app charge ​
Cancels the current recurring charge for a shop.
Access scope
Requires ANY of the following access scopes: write_billing
Endpoint
DELETE
/api/202412/recurring_application_charges/{chargeId}
Request Params
Response Data
curl -X DELETE \
https://{shop}.genmystore.com/api/202412/recurring_application_charges/{chargeId}" \
-H "X-Genstore-Access-Token: {access_token}" \
HTTP/1.1 200 OK
{}
GET
Retrieve single app charge ​
Retrieve detailed information about a single charge based on the charge ID.
Access scope
Requires ANY of the following access scopes: write_billing
read_billing
Endpoint
GET
/api/202412/recurring_application_charges/{chargeId}
Request Params
Response Data
* pending;
* active;
* declined;
* expired;
* froze;
* cancelled.
curl -X GET \
https://{shop}.genmystore.com/api/202412/recurring_application_charges/{chargeId}" \
-H "X-Genstore-Access-Token: {access_token}" \
HTTP/1.1 200 OK
{
"recurringApplicationCharge": {
"trialEndsTime": "2025-04-01T15:46:46-04:00",
"trialDays": "5",
"test": "false",
"confirmationUrl": "https://jsmith.blaze.com/admin/charges/755357713/1029266966/RecurringApplicationCharge/confirm_recurring_application_charge?signature=BAh7BzoHaWRpBBZeWT06EmF1dG9fYWN0aXZhdGVU--98ef575ea1fff24621e47eaa65e42758f13a3ae5",
"billingTime": "2025-04-01T15:46:46-04:00",
"updateTime": "2025-04-01T15:46:46-04:00",
"createTime": "2025-04-01T15:46:46-04:00",
"activatedTime": "2025-04-01T15:46:46-04:00",
"price": "20.0",
"cancelledTime": "2025-04-01T15:46:46-04:00",
"name": "Super Duper Plan",
"currency": "USD",
"id": "1029266966",
"returnUrl": "http://super-duper.blaze.com/",
"status": "pending"
}
}
About RecurringApplicationCharge
Access scope
Multiple access scopes needed — refer to each endpoint for access scope requirements.
The Billing API provides a set of RESTful endpoints for managing app billing information, including creating, canceling, retrieving bills, and reporting usage charges. This API is designed to support merchants on the Genstore platform in subscribing to and using apps.
Core Features:
- Create recurring app charges: Allows merchants to create recurring subscription fees for apps.
- Cancel recurring charges: Allows merchants to cancel their subscription fees for apps.
- Retrieve a single charge: Allows merchants to query charge details using the subscription charge ID.
- Create usage-based charges: Allows merchants to create charges based on actual usage.
Notes
When using the Billing API, please note the following:
- Data consistency: To avoid duplicate usage charges, ensure that the
extUniqueId
in each usage report request is unique.
Use Cases
Here are some common use cases to help developers better understand the practical value of the Billing API:
- Create recurring application charges: Merchants can use the API to create recurring billing plans for apps, supporting time-based, usage-based, or hybrid billing models.
- Cancel recurring charges: Merchants can cancel their current subscription fees through the API.
- Retrieve a single charge: Merchants can retrieve details of an individual subscription to view its full billing information.
- Create usage-based charges: Once a merchant subscribes to a usage-based plan, they can report usage via the API to generate corresponding usage charges.
Recurring application charge Object
The recurring application charge object.
Properties
POST
Create recurring app charge
Creates a recurring charge for an app subscription. Supports time-based, usage-based, and hybrid billing models.
Access scope
Requires ANY of the following access scopes: write_billing
Endpoint
POST
/api/202412/recurring_application_charges
DELETE
Cancel recurring app charge
Cancels the current recurring charge for a shop.
Access scope
Requires ANY of the following access scopes: write_billing
Endpoint
DELETE
/api/202412/recurring_application_charges/{chargeId}
GET
Retrieve single app charge
Retrieve detailed information about a single charge based on the charge ID.
Access scope
Requires ANY of the following access scopes: write_billing
read_billing
Endpoint
GET
/api/202412/recurring_application_charges/{chargeId}