Document Needed for Customer Verification Event


(Colton Milbrandt) #1

As you know Dwolla may ask for additional documentation to verify an account. When using Dwolla as White label service the only way to send this information to the external application is through a webhook. I was wondering if you can send me a sample JSON object for this event so I know how to parse the information I need in order to send detail information to our customer.

As of now, i am handling this kind of event But what I want is detail information so my customer will know what information they need to submit to dwolla and hoping this JSON objec will contain all the information I need.

Also, when sending an event for “customer_verification_document_failed” I would like to see the JSON for this event as well. Does this event has the information as of why it failed? Again, so I can send a detail email to our customer instead of telling it failed without any explanation.


(Spencer Hunter) #2

Hey @coltonmilbrandt, When an event occurs on a Customer (or Account), Dwolla will deliver this event via a webhook to your subscribed endpoint. Each webhook sent by the Dwolla API contains an Event with _links to: the associated resource that triggered the event or changed state, Account associated with the event, and the Customer associated with the event (if applicable). The Event also contains a topic, which gives your app information at a high level on what the event was. If you want to access specific information on the resource then you’ll want to follow the resource link to see the reason for the document failure (for example).

{
  "id": "d4b3dc36-0d60-4c96-8a7e-14c3d51926d2",
  "resourceId": "96d2ed8f-73a1-49a4-86a1-8dd2feadc048",
  "topic": "customer_verification_document_failed",
  "timestamp": "2016-12-20T15:47:25.739Z",
  "_links": {
    "self": {
      "href": "https://api-uat.dwolla.com/events/d4b3dc36-0d60-4c96-8a7e-14c3d51926d2"
    },
    "account": {
      "href": "https://api-uat.dwolla.com/accounts/ad5f2162-404a-4c4c-994e-6ab6c3a13254"
    },
    "resource": {
      "href": "https://api-uat.dwolla.com/documents/96d2ed8f-73a1-49a4-86a1-8dd2feadc048"
    },
    "customer": {
      "href": "https://api-uat.dwolla.com/customers/9bc9c1be-3546-46d7-b883-49be0a9b0df3"
    }
  },
  "created": "2016-12-20T15:47:25.739Z"
}

Looking up the reason for the document upload failure
Calling this endpoint, you can retrieve the document failure reason.

GET https://api-uat.dwolla.com/documents/96d2ed8f-73a1-49a4-86a1-8dd2feadc048
Accept: application/vnd.dwolla.v1.hal+json
Authorization: Bearer {your access token}

{
  "_links": {
    "self": {
      "href": "https://api-uat.dwolla.com/documents/96d2ed8f-73a1-49a4-86a1-8dd2feadc048",
      "type": "application/vnd.dwolla.v1.hal+json",
      "resource-type": "document"
    }
  },
  "id": "96d2ed8f-73a1-49a4-86a1-8dd2feadc048",
  "status": "reviewed",
  "type": "license",
  "created": "2016-12-20T15:46:40.000Z",
  "failureReason": "ScanNotReadable"
}