Webhooks

Create a webhook endpoint.

post/webhooks

Request

  • Base URL
    https://sandbox.smileapi.io/v1
  • URL
    https://sandbox.smileapi.io/v1/webhooks
  • Auth
    HTTP basic

Request body

namestring required

Name of the webhook endpoint

urlstring required

URL of webhook, must begin with https://

eventTypesRefWebhookEventType[] required
activeboolean required

Whether to set this webhook active to received events

includePayloadboolean

Whether to put all datapoints' payload into the events(TASK_FINISHED, ACCOUNT_SNYC_TASK_FINISHED)

secretstring required

The key that will be used to generate HMAC-SHA512 hex digest value in the Smile-Signature header.

Example request

{
  "name": "Event Notification Postback",
  "url": "https://webhook.clienturl.xyz",
  "eventTypes": [
    "ACCOUNT_CONNECTED"
  ],
  "secret": "a little secret"
}

Response

OK

code'OK' | 'CREATED' | 'INVALID_CREDENTIALS' | 'INVALID_PARAMETERS' | 'INVALID_TOKEN' | 'UNAUTHORIZED_ACCESS' | 'MISSING_RESOURCE' | 'REQUEST_LIMIT_EXCEEDED' | 'SERVER_ERROR' | 'UNSUPPORTED_METHOD' | 'SERVER_UNAVAILABLE' | 'TIME_LIMIT_EXCEEDED'

Request status code

messagestring

Message response to the request

requestIdstring

Unique ID that is added to the body of every response for easy traceability of the request in our logs.

Example response

{
  "code": "OK",
  "message": "Success",
  "requestId": "5b79399a-6852-4234-bb0e-ad472648282d",
  "data": {
    "id": "17bbf36498de4d68a0d4f86c7b62f69f",
    "createdAt": "2021-04-14T09:30:24Z",
    "name": "Event Notification Postback",
    "url": "https://webhook.clienturl.xyz",
    "secret": "a little secret",
    "eventTypes": [
      "ACCOUNT_CONNECTED"
    ],
    "updatedAt": "2021-04-14T09:30:24Z"
  }
}

Changes

    • info

      removed the non-success response with the status

    • info

      removed the non-success response with the status

    • info

      removed the non-success response with the status

    • info

      removed the non-success response with the status

    • info

      removed the non-success response with the status

    • info

      removed the non-success response with the status

    • info

      removed the non-success response with the status

    • info

      removed the non-success response with the status

    • info

      removed the non-success response with the status

    • info

      removed the non-success response with the status

    • warning

      added the new USER_SESSION_COMPLETED enum value to the // response property for the response status

    • warning

      added the new USER_SESSION_RESET enum value to the // response property for the response status

    • info

      added the new USER_SESSION_COMPLETED enum value to the request property /

    • info

      added the new USER_SESSION_RESET enum value to the request property /