Search docs

Webhook API Reference

Webhook API traffic. Add monitoring to every API call with the Proxy API.

Introduction

Welcome to the Webhook API.

Authentication

apiKey

To use API you have to sign up and get your own API key. Unify API accounts have sandbox mode and live mode API keys. To change modes just use the appropriate key to get a live or test object. You can find your API keys on the unify settings of your Apideck app. Your Apideck application_id can also be found on the same page.

Authenticate your API requests by including your test or live secret API key in the request header.

  • Bearer authorization header: Authorization: Bearer <your-apideck-api-key>
  • Application id header: x-apideck-app-id: <your-apideck-app-id>

You should use the public keys on the SDKs and the secret keys to authenticate API requests.

Do not share or include your secret API keys on client side code. Your API keys carry significant privileges. Please ensure to keep them 100% secure and be sure to not share your secret API keys in areas that are publicly accessible like GitHub.

Learn how to set the Authorization header inside Postman https://learning.postman.com/docs/postman/sending-api-requests/authorization/#api-key

Go to Unify to grab your API KEY https://app.apideck.com/unify/api-keys

Security Scheme Type API Key
Header parameter name Authorization

Webhooks

The Webhooks model

idstring
descriptionstring
unified_apistring
required
Enum:vaultleadcrmaccounting

Name of Apideck Unified API

statusstring
required
Enum:enableddisabled

The status of the webhook.

delivery_urlstring
required

The delivery url of the webhook endpoint.

execute_base_urlstring
required

The Unify Base URL events from connectors will be sent to after service id is appended.

Webhooks example
{}

List webhooks

get/webhook/webhooks

List webhooks

Authorizations:

Header parameters

x-apideck-app-idstring
required

The ID of your Unify application

Query parameters

cursorstring

Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response.

limitinteger[ 1 .. 200 ]
Default:20

Number of records to return

Responses

200Webhooks
400Bad Request
401Unauthorized
402Payment Required
404The specified resource was not found
422Unprocessable

Mapping coverage per connector

Request example

Node
import { Apideck } from '@apideck/node'

const apideck = new Apideck({
  apiKey: 'REPLACE_WITH_API_KEY',
  appId: 'REPLACE_WITH_APP_ID'
})

try {
  const { data } = await apideck.webhook.webhooksAll({})
  console.log('API called successfully', data)
} catch (error) {
  console.error(error)
}

Response example

{
  "status_code": 200,
  "status": "OK",
  "data": [
    {
      "id": "1234",
      "description": "A description",
      "unified_api": "crm",
      "status": "enabled",
      "delivery_url": "https://example.com/my/webhook/endpoint",
      "execute_base_url": "https://unify.apideck.com/webhook/webhooks/1234/execute",
      "events": [
        "vault.connection.created",
        "vault.connection.updated"
      ],
      "updated_at": "2020-09-30T07:43:32.000Z",
      "created_at": "2020-09-30T07:43:32.000Z"
    }
  ],
  "meta": {
    "items_on_page": 50,
    "cursors": {
      "previous": "em9oby1jcm06OnBhZ2U6OjE=",
      "current": "em9oby1jcm06OnBhZ2U6OjI=",
      "next": "em9oby1jcm06OnBhZ2U6OjM="
    }
  },
  "links": {
    "previous": "https://unify.apideck.com/crm/companies?cursor=em9oby1jcm06OnBhZ2U6OjE%3D",
    "current": "https://unify.apideck.com/crm/companies",
    "next": "https://unify.apideck.com/crm/companies?cursor=em9oby1jcm06OnBhZ2U6OjM"
  }
}

Create webhook

post/webhook/webhooks

Create webhook

Authorizations:

Header parameters

x-apideck-app-idstring
required

The ID of your Unify application

Request body schema

application/json
unified_apistring
required
Enum:vaultleadcrmaccounting

Name of Apideck Unified API

statusstring
required
Enum:enableddisabled

The status of the webhook.

delivery_urlstring
required

The delivery url of the webhook endpoint.

eventsstrings
required
Enum:*crm.activity.createdcrm.activity.updatedcrm.activity.deleted

The list of subscribed events for this webhook. [*] indicates that all events are enabled.

descriptionstring

Responses

201Webhooks
400Bad Request
401Unauthorized
402Payment Required
404The specified resource was not found
422Unprocessable

Mapping coverage per connector

Request example

{
  "description": "A description",
  "unified_api": "crm",
  "status": "enabled",
  "delivery_url": "https://example.com/my/webhook/endpoint",
  "events": [
    "vault.connection.created",
    "vault.connection.updated"
  ]
}

Response example

{
  "status_code": 200,
  "status": "OK",
  "data": {
    "id": "1234",
    "description": "A description",
    "unified_api": "crm",
    "status": "enabled",
    "delivery_url": "https://example.com/my/webhook/endpoint",
    "execute_base_url": "https://unify.apideck.com/webhook/webhooks/1234/execute",
    "events": [
      "vault.connection.created",
      "vault.connection.updated"
    ],
    "updated_at": "2020-09-30T07:43:32.000Z",
    "created_at": "2020-09-30T07:43:32.000Z"
  }
}

Get webhook

get/webhook/webhooks/{id}

Get webhook

Authorizations:

Path parameters

idstring
required

JWT Webhook token that represents the unifiedApi and applicationId associated to the event source.

Header parameters

x-apideck-app-idstring
required

The ID of your Unify application

Responses

200Webhooks
400Bad Request
401Unauthorized
402Payment Required
404The specified resource was not found
422Unprocessable

Mapping coverage per connector

Request example

Node
import { Apideck } from '@apideck/node'

const apideck = new Apideck({
  apiKey: 'REPLACE_WITH_API_KEY',
  appId: 'REPLACE_WITH_APP_ID'
})

try {
  const { data } = await apideck.webhook.webhooksOne({
    id: 'id_example'
  })
  console.log('API called successfully', data)
} catch (error) {
  console.error(error)
}

Response example

{
  "status_code": 200,
  "status": "OK",
  "data": {
    "id": "1234",
    "description": "A description",
    "unified_api": "crm",
    "status": "enabled",
    "delivery_url": "https://example.com/my/webhook/endpoint",
    "execute_base_url": "https://unify.apideck.com/webhook/webhooks/1234/execute",
    "events": [
      "vault.connection.created",
      "vault.connection.updated"
    ],
    "updated_at": "2020-09-30T07:43:32.000Z",
    "created_at": "2020-09-30T07:43:32.000Z"
  }
}

Update webhook

patch/webhook/webhooks/{id}

Update webhook

Authorizations:

Path parameters

idstring
required

JWT Webhook token that represents the unifiedApi and applicationId associated to the event source.

Header parameters

x-apideck-app-idstring
required

The ID of your Unify application

Request body schema

application/json
descriptionstring
statusstring
Enum:enableddisabled

The status of the webhook.

delivery_urlstring

The delivery url of the webhook endpoint.

eventsstrings
Enum:*crm.activity.createdcrm.activity.updatedcrm.activity.deleted

The list of subscribed events for this webhook. [*] indicates that all events are enabled.

Responses

200Webhooks
400Bad Request
401Unauthorized
402Payment Required
404The specified resource was not found
422Unprocessable

Mapping coverage per connector

Request example

{
  "description": "A description",
  "status": "enabled",
  "delivery_url": "https://example.com/my/webhook/endpoint",
  "events": [
    "vault.connection.created",
    "vault.connection.updated"
  ]
}

Response example

{
  "status_code": 200,
  "status": "OK",
  "data": {
    "id": "1234",
    "description": "A description",
    "unified_api": "crm",
    "status": "enabled",
    "delivery_url": "https://example.com/my/webhook/endpoint",
    "execute_base_url": "https://unify.apideck.com/webhook/webhooks/1234/execute",
    "events": [
      "vault.connection.created",
      "vault.connection.updated"
    ],
    "updated_at": "2020-09-30T07:43:32.000Z",
    "created_at": "2020-09-30T07:43:32.000Z"
  }
}

Delete webhook

delete/webhook/webhooks/{id}

Delete webhook

Authorizations:

Path parameters

idstring
required

JWT Webhook token that represents the unifiedApi and applicationId associated to the event source.

Header parameters

x-apideck-app-idstring
required

The ID of your Unify application

Responses

200Webhooks
400Bad Request
401Unauthorized
402Payment Required
404The specified resource was not found
422Unprocessable

Mapping coverage per connector

Request example

Node
import { Apideck } from '@apideck/node'

const apideck = new Apideck({
  apiKey: 'REPLACE_WITH_API_KEY',
  appId: 'REPLACE_WITH_APP_ID'
})

try {
  const { data } = await apideck.webhook.webhooksDelete({
    id: 'id_example'
  })
  console.log('API called successfully', data)
} catch (error) {
  console.error(error)
}

Response example

{
  "status_code": 200,
  "status": "OK",
  "data": {
    "id": "1234",
    "description": "A description",
    "unified_api": "crm",
    "status": "enabled",
    "delivery_url": "https://example.com/my/webhook/endpoint",
    "execute_base_url": "https://unify.apideck.com/webhook/webhooks/1234/execute",
    "events": [
      "vault.connection.created",
      "vault.connection.updated"
    ],
    "updated_at": "2020-09-30T07:43:32.000Z",
    "created_at": "2020-09-30T07:43:32.000Z"
  }
}

Execute a webhook

post/webhook/webhooks/{id}/execute/{serv...

Execute a webhook

Authorizations:

Path parameters

idstring
required

JWT Webhook token that represents the unifiedApi and applicationId associated to the event source.

serviceIdstring
required

Service provider ID.

Responses

200Execute Webhook
400Bad Request
401Unauthorized
402Payment Required
404The specified resource was not found
422Unprocessable

Mapping coverage per connector

Request example

Response example

{
  "status_code": 200,
  "status": "OK",
  "request_id": "c6af9ac6-7b61-11e6-9a41-93e8deadbeef",
  "timestamp": "2021-10-01T08:26:28.039Z"
}

List event logs

get/webhook/logs

List event logs

Authorizations:

Header parameters

x-apideck-app-idstring
required

The ID of your Unify application

Query parameters

cursorstring

Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response.

limitinteger[ 1 .. 200 ]
Default:20

Number of records to return

filterobjectfilter[exclude_apis]=vault,proxy

Filter results

Responses

200EventLogs
400Bad Request
401Unauthorized
402Payment Required
404The specified resource was not found
422Unprocessable

Mapping coverage per connector

Request example

Node
import { Apideck } from '@apideck/node'

const apideck = new Apideck({
  apiKey: 'REPLACE_WITH_API_KEY',
  appId: 'REPLACE_WITH_APP_ID'
})

try {
  const { data } = await apideck.webhook.eventLogsAll({})
  console.log('API called successfully', data)
} catch (error) {
  console.error(error)
}

Response example

{
  "status_code": 200,
  "status": "OK",
  "data": [
    {
      "id": "1d174c4d-fe9e-4377-a76c-6da22fe9cd87",
      "status_code": 200,
      "success": true,
      "application_id": "1111",
      "consumer_id": "test_consumer_id",
      "unified_api": "crm",
      "service": {
        "id": "101-data-solution",
        "name": "101 Data Solution"
      },
      "endpoint": "https://example.com/my/webhook/endpoint",
      "event_type": "vault.connection.updated",
      "execution_attempt": 3,
      "http_method": "GET",
      "timestamp": "2021-07-12T14:26:17.420Z",
      "entity_type": "Connection",
      "request_body": "{\"entity\":{\"id\":\"2222+test_user_id\",\"application_id\":\"2222\",\"consumer_id\":\"test_user_id\",\"name\":\"ActiveCampaign\",\"icon\":\"https://res.cloudinary.com/apideck/image/upload/v1529455970/catalog/activecampaign/icon128x128.png\",\"logo\":\"https://www.activecampaign.com/site/assets/social-2x.png\",\"unified_api\":\"crm\",\"service_id\":\"activecampaign\",\"auth_type\":\"apiKey\",\"enabled\":true,\"tag_line\":\"Integrated email marketing, marketing automation, and small business CRM. Save time while growing your business with sales automation.\",\"website\":\"https://www.activecampaign.com/\",\"settings\":{\"instance_url\":\"https://eu28.salesforce.com\",\"base_url\":\"https://updated.api-us1.com\"},\"metadata\":{\"plan\":\"enterprise\",\"account\":{\"name\":\"My Company\"}},\"state\":\"callable\",\"created_at\":\"2021-09-10T10:39:49.628Z\",\"updated_at\":\"2021-09-10T10:39:52.715Z\"},\"entityType\":\"Connection\"}",
      "response_body": "{\"status\":\"OK\"}",
      "retry_scheduled": true,
      "attempts": [
        {
          "timestamp": "2021-07-12T14:26:17.420Z",
          "execution_attempt": 3,
          "status_code": 200,
          "success": true
        }
      ]
    }
  ],
  "meta": {
    "items_on_page": 50,
    "cursors": {
      "previous": "em9oby1jcm06OnBhZ2U6OjE=",
      "current": "em9oby1jcm06OnBhZ2U6OjI=",
      "next": "em9oby1jcm06OnBhZ2U6OjM="
    }
  },
  "links": {
    "previous": "https://unify.apideck.com/crm/companies?cursor=em9oby1jcm06OnBhZ2U6OjE%3D",
    "current": "https://unify.apideck.com/crm/companies",
    "next": "https://unify.apideck.com/crm/companies?cursor=em9oby1jcm06OnBhZ2U6OjM"
  }
}