Push Webhooks

The Push Status event is fired when a push API request has finished processing through Accounting Data as a Service™ and the accounting service provider.

Event Object

The webhook payload is sent in standard JSON format and contains an event object with the following information represented by key-value pairs (KVPs):

ElementTypeDescription
eventstringUnique event name for the webhook. Set to push.
connectionIdstringThe connection id associated with the webhook. Automatically assigned by Accounting Data as a Service™. See connections for more details.
businessNamestringThe business name associated with the webhook. See businesses for more details.
serviceNamestringThe name of the connected integration. See possible enum values.
pushCommunicationIdstringUnique push request ID. Automatically assigned by Accounting Data as a Service™.
sourceObjectIdsarrayAn array of strings representing the created object ids in the service providers.
dataTypestringThe data type associated with the webhook. See /data/dataTypes endpoint for all possible enum values.
requestedOnstringThe date and time at which the batch push was requested. See date format for more details.
completedOnstringThe date and time at which the batch push was completed. See date format for more details.
statusstringThe status of the batch push request. Possible values: success, failed.
responseCodeintegerStandard HTTP response code from the service provider. In general, 200 HTTP codes correspond to success, 40X codes are for developer- or user-related failures, and 50X codes are for Accounting Data as a Service™-related issues.
validationobjectAn object containing an array of errors. Returned if a specific batch push object failed.
serviceAccountRefobjectObject containing the account id and subsidiary or sub account id for the connection

Each object in the errors array may include the following elements:

ElementTypeDescription
fieldstringThe name of the element or property in the original request associated with the validation or error.
messagestringA user-friendly validation or error message sent by the service provider.

serviceAccountRef Object may include the following elements:

ElementTypeDescription
idstringAccount id for the connection
entityRef.idstringSub account or Subsidiary account id for the connection

Example Push Event Objects

{
  "data": {
    "event": "push",
    "connectionId": "CON-0a4e97aa-7a77-bbbb-00aa-b1b1001aa00",
    "businessName": "BIZ-d6b1c7d3-fe41-4447-ae72-3814b78b5142",
    "serviceName": "quickbooks",
    "dataType": "invoices",
    "pushCommunicationId": "60473b57f0cdd1683ca71f60",
    "sourceObjectIds": ["354"],
    "requestedOn": "2021-03-09T19:56:03.952Z",
    "completedOn": "2021-03-09T19:56:03.952Z",
    "status": "success",
    "responseCode": 200,
    "serviceAccountRef": {
      "id": "DEV",
      "entityRef": {
        "id": "100"
      }
    },
	},
	"requestId": "a3b4fc83-3e24-41aa-ba99-13cab09b0b7a"
}
{
  "data": {
    "event": "push",
    "connectionId": "CON-0a4e97aa-7a77-bbbb-00aa-b1b1001aa00",
    "businessName": "BIZ-d6b1c7d3-fe41-4447-ae72-3814b78b5142",
    "serviceName": "quickbooks",
    "dataType": "invoices",
    "pushCommunicationId": "60473b57f0cdd1683ca71f60",
    "sourceObjectId": ["354"],
    "requestedOn": "2021-03-09T19:56:03.952Z",
    "completedOn": "2021-03-09T19:56:03.952Z",
    "status": "failed",
    "responseCode": 400,
    "serviceAccountRef": {
      "id": "DEV",
      "entityRef": {
        "id": "100"
      }
    },
    "validation": {
      "errors": [
        {
          "field": "currencyRef",
          "message": "Business Validation Error: Multi Currency should be enabled to perform this operation."
        }
      ]
    }   
	},
	"requestId": "a3b4fc83-3e24-41aa-ba99-13cab09b0b7a"
}