Important Note: The Customer Support Team at Cartfuel is unable to assist with Webhook implementation. If you need assistance, please contact a qualified developer.


Webhooks in Cartfuel

Webhooks are a way to communicate between two apps based on events. Real-time data can be sent from one application to another when an event occurs. Using this tool you can receive notifications whenever a prospective makes a purchase in your payment form.

Step 1: Access Your Cartfuel Webhook

  1. Click on the "Settings" link in the top right navigation

  2. Click on the "Webhooks" link in the left-side menu navigation

  3. Click on the blue "Add New Webhook" Button

  4. Enter a name for your new Webhook

  5. Enter the URL of your webhook endpoint

  6. Optional: Add additional headers to the webhook by clicking on "Add Header"

  7. Once complete click "Update"

Your new webhook should send information to your endpoint as sales happen on your Cartfuel payment form.

The payload will look something like this:

{
"payment_type": "upsell1",
"product": {
"product_id": "0540b8fe-3923-444b-a630-7d3ec4c2113d",
"product_name": "Product 1"
},
"customer": {
"id": "cus_AAAAAAAskQYyn",
"user_id": 1,
"gateway": "stripe",
"name": "John Doe",
"email": "[email protected]",
"purchase_date": 1605214896,
"additional_info": {
"payment_card": "visa",
"payment_card_last4": "4242",
"charge_id": "ch_1HmmvDDWaaaaaaaaaae",
"invoice_id": null,
"billing_details": {
"address": {
"city": "City Name",
"country": "US",
"line1": "Street no. 123",
"line2": null,
"postal_code": "42424",
"state": "Texas"
},
"email": "[email protected]",
"name": "Jane Doe",
"phone": null
}
},
"created_at": "2020-11-12T21:01:38.000000Z",
"updated_at": "2020-11-12T21:01:38.000000Z"
}
}


Don't have a Cartfuel account? Sign up for one here or log in.

Did this answer your question?