Core Resources
Notifications
The Customer Notifications resource is used to dispatch email notifications to customers within Recharge. The endpoint uses your configured Recharge email templates, and will dispatch an email to the address associated with the indicated
customer_id. Some email templates require variable values, which are sent through the Customer Notifications resource via the template_vars attribute. See below examples for all available template types.#Send email notification
POST/customers/{id}/notifications
Sends a notification email to the customer with the
customer_id indicated in the route. To view the upcoming charge email template, visit the Notifications section in your Recharge Merchant Admin Portal.Scope
write_notificationsBody parameters
- Identifies the type of the notifications. Value can be email only.
- Identifies the type of the email notifications.Possible values
upcoming_chargeget_account_accessshopify_update_payment_information - template_varsobjectAn object containing the necessary template variables for this email template type.
Show child attributesHide child attributes2
- template_vars.address_idintegerIf needed by the
template_type, theaddress_idassociated with the indicatedCustomer, and the object of theNotification. - template_vars.charge_idbooleanIf needed by the
template_type, thecharge_idof theChargefor which the notification should be sent.
curl -X POST 'https://api.rechargeapps.com/customers/18819267/notifications' \
-H 'X-Recharge-Version: 2021-11' \
-H 'Content-Type: application/json' \
-H 'X-Recharge-Access-Token: your_api_token' \
-d '{
"type": "email",
"template_type": "upcoming_charge",
"template_vars": {
"address_id": 1234567890,
"charge_id": 9876543210
}
}'{}