Affirm incoming webhook setup guide
This article describes how to use the Affirm data source to create a webhook in your Affirm account and send actionable events to Tealium.
Prerequisites
- Affirm account
- Tealium EventStream or Tealium AudienceStream
How it works
Affirm offers a Webhook API that sends outgoing requests to an endpoint that you specify. These requests inform Tealium EventStream and AudienceStream about customer activity from your Affirm account.
- When you add the Affirm data source in your Tealium account a unique endpoint is generated.
- This endpoint is used to configure a webhook in your Affirm account.
- Once configured, you can create subscriptions based on topics and receive related push notifications to automate use cases, stay informed, and increase productivity.
Affirm data source
The Affirm data source generates a unique URL to use in your Affirm webhook configuration. The generated URL is in the format of:
https://collect.tealiumiq.com/integration/event/ACCOUNT/PROFILE/DATA_SOURCE_KEY
Add the Affirm data source before proceeding, then provide the generated endpoint to your Affirm Client Success Manager.
Related: How to Add a Data Source
Affirm setup
Once you have your data source endpoint, use the following steps to go to your Affirm account and create the webhook.
- Log in to your Affirm account.
- Create a webhook.
- Enable and save the webhook.
Events and attributes
All incoming Affirm event attributes are automatically prefixed with affirm_
. For example, Affirm will send the the smtp_id
attribute to Tealium and it will be converted to affirm_smtp_id
(all lowercase).
For a full list of webhook events and attributes generated by Affirm, see the Affirm Webhook Documentation.
Event Attribute | Type | Example |
---|---|---|
affirm_approved_amount |
Number | 50000.0 |
affirm_checkout_token |
String | “5I97HK0EREM38YHK3” |
affirm_created |
Date | 2019-02-27T22:50:52.601851 |
affirm_decision |
String | “approved”, “not_approved” |
affirm_email_address |
String | “Jeff.Testerson@affirm.com” |
affirm_event |
String | “opened”, “prequal_decision”, “approved”, “not_approved”, “more_information_needed”, “confirmed” |
affirm_event_timestamp |
Date | 2020-02-27T22:51:57.941799 |
affirm_expiration |
Date | 2020-02-27T22:42:08.092894 |
affirm_first_name |
String | “Jeff” |
affirm_last_name |
String | “Testerson” |
affirm_order_id |
String | “17.0” |
affirm_term_apr |
Array of Numbers | [19.55, 19.89, 20.12] |
affirm_term_created |
Array of Dates | [2019-02-27T22:42:08.092894, 2019-02-27T22:42:08.092894, 2019-02-27T22:42:08.092894] |
affirm_term_id |
Array of Strings | [“DX394TR2O0T6F3JM”, “D3QF1AOBN0SL6XXT”, “Z7XKQEWUW0FQOMJ2”] |
affirm_term_installment_amount |
Array of Numbers | [172127.0, 88236.0, 46348.0] |
affirm_term_installment_count |
Array of Numbers | [3.0, 6.0, 12.0] |
affirm_term_interest_amount |
Array of Numbers | [16381.0, 29415.0, 56176.0] |
affirm_term_prequal_amount |
Array of Numbers | [500000.0, 500000.0, 500000.0] |
affirm_total |
Number | 5000 |
affirm_webhook_session_id |
String | fal"A1b2C3" |
Vendor documentation
You must be logged into Affirm to view the following documentation, otherwise you will be redirected to the Affirm documentation main page.
This page was last updated: February 27, 2023