Overview of the Transaction Webhook

Understanding the utility of the transaction object.

Every transaction conducted through iDonate creates a Transaction Webhook in the iDonate database.  It contains all the information of the transaction, such as donor name, gift amount, campaign and designation, etc.

This can be especially useful for interacting with external API's.  Webhooks can be configured to send a Transaction Event JSON object to an external URL, so that when a transaction happens through iDonate, a record can automatically be created in another external service.

A Sample Transaction Webhook

This is a sample of the JSON object that is created when a transaction occurs.  In this case, a transaction_set.created object.

{
"id": "8c5a0930-acb2-4b9f-ad7b-29ca6c4d60d3",
"created": "2022-06-23T08:21:11.631992+00:00",
"transactions": [
  {
    "id": "8c5a0930-acb2-4b9f-ad7b-29ca6c4d60d3",
    "utm": {
      "term": "",
      "medium": "",
      "source": "",
      "content": "",
      "campaign": ""
    },
    "gift": null,
    "type": "cash",
    "embed": null,
    "status": "complete",
    "address": {
      "zip": "75023",
      "city": "Plano",
      "state": "TX",
       "title": null,
      "street": "69878 Council Dr",
      "country": "US",
      "street2": "",
      "country_code": "US",
      "country_name": "United States"
    },
    "contact": {
      "email": "cdeteau@idonate.com",
      "phone": "+19729897187",
      "title": "",
      "address": {
        "zip": "75023",
        "city": "Plano",
        "state": "TX",
        "title": null,
        "street": "697265 Council Dr",
         "country": "US",
        "street2": "",
        "country_code": "US",
        "country_name": "United States"
      },
      "created": "2019-11-21T20:49:06.094745+00:00",
      "updated": "2022-01-03T20:06:14.476301+00:00",
      "lastname": "Deteau",
      "timezone": "America/Chicago",
      "firstname": "Chad",
      "middlename": ""
    },
    "created": "2022-06-23T08:21:11.631992+00:00",
    "subtype": "credit",
    "tribute": null,
    "advocate": null,
    "donor_id": "b9ba2292-7e37-4b7c-a985-b57dc39ec260",
    "card_type": "visa",
    "frequency": "Monthly",
    "hide_name": false,
    "vendor_id": null,
    "final_date": null,
    "gift_extra": "",
    "sale_price": null,
    "advocate_id": null,
    "campaign_id": null,
    "description": "Cash Donation: $256.78",
    "designation": {
      "id": "cdf6d2b9-c4c0-4e6b-b6d7-2e8949cd25b1",
      "code": "1",
      "title": "School Lunch Assistance Program",
      "fund_id": "1"
    },
    "p2p_team_id": null,
    "schedule_id": "4a160565-c282-4490-81c5-4d441b5e9f59",
    "sms_keyword": null,
    "check_number": null,
    "company_name": "",
    "email_opt_in": false,
    "net_proceeds": 256.78,
    "advocate_name": null,
    "custom_note_1": "May we contact you about volunteer opportunities? = No",
    "custom_note_2": null,
    "custom_note_3": null,
    "custom_note_4": null,
    "custom_note_5": null,
    "customer_meta": {},
    "p2p_team_name": null,
    "campaign_title": null,
    "donor_paid_fee": 6.78,
    "p2p_program_id": null,
    "reference_code": null,
    "additional_info": null,
    "client_proceeds": 256.78,
    "expiration_year": 2023,
    "organization_id": "92ba4986-553d-4e5b-a40d-c92d8c6138e5",
    "recurring_count": 21,
    "advocacy_team_id": null,
    "designation_note": "",
    "expiration_month": 4,
    "last_four_digits": "1111",
    "p2p_program_name": null,
    "p2p_fundraiser_id": null,
    "advocacy_team_name": null,
    "payment_gateway_id": "cb76276c-b794-4aac-8b51-115571bb65f0",
    "transaction_set_id": "8c5a0930-acb2-4b9f-ad7b-29ca6c4d60d3",
    "advocacy_program_id": null,
    "p2p_fundraiser_name": null,
    "external_tracking_id": "49",
    "p2p_fundraiser_title": null,
    "payment_gateway_name": "Spreedly: Test",
    "advocacy_program_name": null,
    "organization_event_id": null,
    "payment_transaction_id": "8c5a0930-acb2-4b9f-ad7b-29ca6c4d60d3",
    "corporate_matching_record": null
  }
],
"organization_id": "92ba4986-553d-4e5b-a40d-c92d8c6138e5"
}