Recharge for developers
Navigate our developer resources to quickly and successfully launch Recharge for your store.
Reference docs
Support docs
Resources
Fast & flexible developer tools
Build and deploy rapidly with our SDK, and take full control of every detail with our API.
JavaScript
// SDK in JavaScript
import { updateSubscriptionChargeDate } from ‘@rechargeapps/storefront-client‘;
await updateSubscriptionChargeDate (session, 27363808, ‘2022-10-18‘);
Python
# REST API in Python
import requests
import json
headers = {
“X-Recharge-Version”: “2021-11”,
“Content-Type”: “application/json”,
“X-Recharge-Access-Token”: “your_api_token”,
}
url = “https://api.rechargeapps.com/subscriptions/27363808/set_next_charge_date”
data = {“date”: “2022-10-18”}
result = requests.post(url, data=json.dumps(data), headers=headers)
print(json.dumps(json.loads(result.text), indent=2))
JavaScript
// SDK in JavaScript
import { mergeAddresses } from ‘@rechargeapps/storefront-client‘;
await mergeAddresses (session, {
target_address: { id: 42171447 },
source_addresses: [{ id: 42171446 }, { id: 42171445 }],
});
Python
# REST API in Python
import requests
import json
headers = {
“X-Recharge-Version”: “2021-11”,
“Content-Type”: “application/json”,
“X-Recharge-Access-Token”: “your_api_token”,
}
url = “https://api.rechargeapps.com/addresses/merge”
data = {“target_address”: {
“id”: 42171447},
“source_addresses”: [
{
“id”: 42171446
}, {
“id”: 42171445
}
]
}
result = requests.post(url, data=json.dumps(data), headers=headers)
print(json.dumps(json.loads(result.text), indent=2))
JavaScript
// SDK in JavaScript
import { applyDiscountToAddress } from ‘@rechargeapps/storefront-client‘;
await updateSubscriptionChargeDate (session, 123, ‘‘discount_code’‘);
Python
# REST API in Python
import requests
import json
headers = {
“X-Recharge-Version”: “2021-11”,
“Content-Type”: “application/json”,
“X-Recharge-Access-Token”: “your_api_token”,
}
url = “https://api.rechargeapps.com/addresses/38700614”
data = {“discount_id”: “1234567”}
result = requests.post(url, data=json.dumps(data), headers=headers)
print(json.dumps(json.loads(result.text), indent=2))
JavaScript
// SDK in JavaScript
// The Javascript SDK is designed for storefront customizations with built-in authentication to prevent access to sensitive data or administrative functions like creating a collection.
Python
# REST API in Python
import requests
import json
headers = {
“X-Recharge-Version”: “2021-11”,
“Content-Type”: “application/json”,
“X-Recharge-Access-Token”: “your_api_token”,
}
url = “https://api.rechargeapps.com/collections”
data = {
“description”: “cat products new release”,
“title”: “Cats Spring 2022”
}
result = requests.post(url, json.dumps(data), headers=headers)
print(json.dumps(json.loads(result.text), indent=2))
JavaScript
// SDK in JavaScript
// The Javascript SDK is designed for storefront customizations with built-in authentication to prevent access to sensitive data or administrative functions like creating a discount.
Python
# REST API in Python
import requests
import json
headers = {
“X-Recharge-Version”: “2021-11”,
“Content-Type”: “application/json”,
“X-Recharge-Access-Token”: “your_api_token”,
}
url = “https://api.rechargeapps.com/discounts”
data = {
“applies_to”: {
“purchase_item_type”: “ALL”
},
“channel_settings”: {
“api”: {
“can_apply”: true
},
“checkout_page”: {
“can_apply”: true
},
“customer_portal”: {
“can_apply”: true
},
“merchant_portal”: {
“can_apply”: true
}
},
“code”: “Discount1”,
“status”: “enabled”,
“usage_limits”: {
“first_time_customer_restriction”: false,
“one_application_per_customer”: false
},
“value”: “100.00”,
“value_type”: “percentage”
}
result = requests.post(url, json.dumps(data), headers=headers)
print(json.dumps(json.loads(result.text), indent=2))
Growing reach & impact
50M+
50M+
API requests per day
5K
5K
webhooks delivered per minute
6K
6K
stores using Recharge API
12K+
12K+
developers using Recharge API
Always up to date
We constantly enhance our features and tools. Subscribe to the Changelog to stay in the loop on new updates.
-
- Speed up subscription setup with our native Shopify and BigCommerce integrations or platform-independent API
- Power custom workflows and extend platform capabilities with a flexible API and limitless webhook architecture
- Build custom storefront experiences faster with our JavaScript SDK
-
- Subscribe to the changelog to track changes and upgrades to the Recharge API
- Access real-time status and uptime updates for all Recharge products
-
- Visit our roadmap to stay up to date on major product and feature releases
- Share feedback with our technical support team so we can continually improve your experience as a developer on Recharge
