Webhooks

Allows clients to manage webhooks.

The Peach webhook system will issue POST requests with the event data as JSON payload.

Create webhook subscription

Creates a new webhook subscription.

Securityoauth2 or bearerAuth or apiKeyHeader
Request
Request Body schema: application/json
required
webhookType
required
string

Peach supports two ways of receiving webhooks:

  • direct - events will be provided directly to the url nominated by the lender, and the event data will match Peach's data format.
  • proxyGalileo - events will trigger Peach to make specific API calls to Galileo, so Galileo's sub-ledger remains in sync with Peach's ledger.

Note: when setting webhookType as proxyGalileo, please work with the Peach team to ensure the API calls you require are configured.

Enum: "direct" "proxyGalileo"
eventTypes
Array of strings

The list of events for which the caller will receive webhooks. For any proxy webhookType, this field should be left empty, and we will automatically send the events associated with that specific proxy.

Items Enum: "autopay.schedule.cancel" "autopay.schedule.created" "autopay.payment.rescheduled" "autopay.payment.canceled" "card.created" "card.replacement.requested" "card.status.changed" "case.association.added" "case.association.removed" "case.donotinteract.created" "case.donotinteract.deleted" "case.donotinteract.updated" "case.donotinteract.changed" "case.donotinteract.expired" "case.escalation.changed" "case.created" "case.updated" "case.deleted" "communication.send" "indexrate.created" "indexrate.updated" "loan.created" "loan.current" "loan.fee.capitalized" "loan.credit.limit.changed" "draw.credit.limit.changed" "draw.fee.booked" "loan.balance.changed" "loan.foreigntransactionfee.booked" "loan.overdue" "loan.overdue.update" "loan.interestaccrued.min" "loan.interest.capitalized" "loan.statuschanged" "loan.latefee.booked" "loan.modificationfee.booked" "loan.nsffee.booked" "loan.fee.booked" "loan.promoprogram.activated" "loan.promoprogram.canceled" "loan.promoprogram.created" "loan.promoprogram.exercised" "loan.promoprogram.reactivated" "loan.promoprogram.updated" "loan.paymentplan.setup" "loan.promiseplan.created" "loan.promiseplan.statuschanged" "loan.promiseplan.due.today" "loan.promiseplan.overdue" "loan.promiseplan.current" "loan.purchasefee.booked" "loan.duedate.defer" "loan.schedule.defer" "loan.ownerchanged" "loan.rate.created" "loan.rate.updated" "loan.refunded" "loan.reimbursement.initiated" "loan.reimbursement.processed" "loan.period.started" "loan.obligation.statuschanged" "loan.servicefee.booked" "statement.created" "paymentplan.created" "paymentplan.statuschanged" "person.created" "person.consent.updated" "person.monitoring.scra.started" "person.monitoring.bankruptcy.started" "contact.created" "contact.deleted" "contact.updated" "payment.instrument.created" "payment.instrument.updated" "payment.instrument.deactivated" "interaction.blocked" "payment.applied" "payment.chargeback" "payment.chargeback.reversed" "payment.failed" "payment.initiated" "payment.pending" "payment.succeeded" "payment.reversed" "payment.scheduled" "payment.rescheduled" "payment.due.today" "payment.hold.days.expired" "purchase.authorized" "purchase.settled" "purchase.applied" "purchase.changed" "purchase.created" "purchase.dispute.created" "purchase.dispute.updated" "loan.creditreporting.created" "loan.creditreporting.stopped" "ach.file.created" "ach.file.upload.attempted" "ach.file.upload.failed" "ach.file.upload.succeeded" "reconciliation.payment.failed" "supercase.changed"
id
string
createdAt
string <date-time>
updatedAt
string or null <date-time>
deletedAt
string or null <date-time>
enabled
boolean
Default: true

If true events will be sent to this webhook, if false no events will be sent to it.

hydrateData
boolean
Default: false

Indicates the amount of information the receiver of webhooks will get. Only applicable if webhookType=direct.

  • false - Peach will provide a minimum amount of data. For example: event identifier, event name, timestamp and identifier(s) of associated object(s) (e.g. loan ID, borrower ID, transaction ID, etc.)
  • true - in addition to the data provided in the false option, Peach will provide full details of the object(s) associated with the event.

Currently we support hydrating the following objects:

  • borrower
  • loan
  • transaction
  • case
object (WebhookDirectDetails)

The details required for Peach to pass the events via webhook. Required only if webhookType=direct.

object (WebhookProxyDetails)

The details required for Peach to make an API call to the third party identified in the webhookType. Required only if webhookType=proxyXXX.

Responses
200

Success

post/webhooks
Request samples
application/json
{
  • "webhookType": "direct",
  • "eventTypes": [
    ],
  • "id": "string",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "updatedAt": "2019-08-24T14:15:22Z",
  • "deletedAt": "2019-08-24T14:15:22Z",
  • "enabled": true,
  • "hydrateData": false,
  • "webhookDirectDetails": {
    },
  • "webhookProxyDetails": {
    }
}
Response samples
application/json
{
  • "status": 0,
  • "message": "string",
  • "data": {
    }
}

Get webhooks

Securityoauth2 or bearerAuth or apiKeyHeader
Request
query Parameters
limit
integer [ 1 .. 100 ]
Default: 25

The maximum count of results to retrieve.

startingAfter
string

Return results starting after the provided object identifier.

endingBefore
string

Return results ending before the provided object identifier.

Responses
200

Success

get/webhooks
Response samples
application/json
{
  • "status": 0,
  • "count": 0,
  • "data": [
    ]
}

Get webhook subscription by ID

Securityoauth2 or bearerAuth or apiKeyHeader
Request
path Parameters
webhookSubscriptionId
required
string

The ID of the webhook subscription

Responses
200

Success

get/webhooks/{webhookSubscriptionId}
Response samples
application/json
{
  • "status": 0,
  • "message": "string",
  • "data": {
    }
}

Update webhook subscription

Securityoauth2 or bearerAuth or apiKeyHeader
Request
path Parameters
webhookSubscriptionId
required
string

The ID of the webhook subscription

Request Body schema: application/json
required
id
string
createdAt
string <date-time>
updatedAt
string or null <date-time>
deletedAt
string or null <date-time>
enabled
boolean
Default: true

If true events will be sent to this webhook, if false no events will be sent to it.

hydrateData
boolean
Default: false

Indicates the amount of information the receiver of webhooks will get. Only applicable if webhookType=direct.

  • false - Peach will provide a minimum amount of data. For example: event identifier, event name, timestamp and identifier(s) of associated object(s) (e.g. loan ID, borrower ID, transaction ID, etc.)
  • true - in addition to the data provided in the false option, Peach will provide full details of the object(s) associated with the event.

Currently we support hydrating the following objects:

  • borrower
  • loan
  • transaction
  • case
object (WebhookDirectDetails)

The details required for Peach to pass the events via webhook. Required only if webhookType=direct.

object (WebhookProxyDetails)

The details required for Peach to make an API call to the third party identified in the webhookType. Required only if webhookType=proxyXXX.

Responses
200

Success

put/webhooks/{webhookSubscriptionId}
Request samples
application/json
{
  • "id": "string",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "updatedAt": "2019-08-24T14:15:22Z",
  • "deletedAt": "2019-08-24T14:15:22Z",
  • "enabled": true,
  • "hydrateData": false,
  • "webhookDirectDetails": {
    },
  • "webhookProxyDetails": {
    }
}
Response samples
application/json
{
  • "status": 0,
  • "message": "string",
  • "data": {
    }
}

Delete webhook subscription

Securityoauth2 or bearerAuth or apiKeyHeader
Request
path Parameters
webhookSubscriptionId
required
string

The ID of the webhook subscription

Responses
204

Success

delete/webhooks/{webhookSubscriptionId}

Test a webhook with static payload.

Securityoauth2 or bearerAuth or apiKeyHeader
Request
path Parameters
webhookSubscriptionId
required
string

The ID of the webhook subscription

Responses
204

Success

post/webhooks/{webhookSubscriptionId}/ping

Request sandbox access