Webhook Setup Guide

Before setting up your webhook subscriptions, see our Webhook Integration Best Practices.

Summary

This guide walks you through setting up webhooks to receive real-time notifications of system events. You will learn how to prepare your endpoint, subscribe to a webhook, and manage your subscriptions.


Base URL

All webhook subscription API calls use the following base URL structure. Replace tenantslug with your organization's tenant slug.

https://backoffice.infinicept.com/api/{tenantslug}webhooks

Authentication

Webhooks support basic authentication and shared secret (plaintext) authentication methods to secure your endpoint.


Basic Authentication - Recommended as the industry standard with broad compatibility and universal tooling support.

{
  "Method": 0,
  "Username": "your-username",
  "Password": "your-password"
}

Shared Secret (Plaintext) - Offers simpler implementation and testing with a single credential to manage.

{
  "Method": 1,
  "SharedSecret": "your-shared-secret"
}

Prepare Your Endpoint

Before creating a subscription, ensure your webhook endpoint:

  • Is accessible via HTTPS
  • Can accept HTTP POST requests
  • Returns a 2xx HTTP status code for successful processing
  • Can accept the webhook's payload structure

Subscribe to a Webhook

Use this request to create a webhook subscription to receive notification of certain events (based on webhook type).


Request

POST https://backoffice.infinicept.com/api/{tenantslug}/webhooks

Request Body

Field NameTypeRequired/OptionalDescription
TypeintegerRequiredThe webhook type. Values include: 4 = Instructional Funding Submitted, 5 = Submerchant Deposit Rejected, 6 = Funding Deposit Funded, 7 = Funding Deposit Rejected, 8 = Funding Deposit Partially Rejected.
DestinationURLstringRequiredThe URL of your webhook endpoint
AuthenticationMethodobjectRequiredContains the authentication method and credentials used to secure your endpoint.
MethodintegerRequiredValues include: 0 = Basic authentication, 1 = Shared Secret (Plaintext)
UsernamestringRequired when Method = 0When using Basic authentication, this is the username used for authenticating your webhook endpoint.
PasswordstringRequired when Method = 0When using Basic authentication, this is the password used for authenticating your webhook endpoint.
SharedSecretstringRequired when Method = 1When using Shared Secret (Plaintext) authentication, this is the shared secret used for authenticating your webhook endpoint.

Example Request

{
  "Type": 6,
  "DestinationURL": "https://your-domain.com/webhooks/funding-deposit-funded",
  "AuthenticationMethod": {
    "Method": 1,
    "SharedSecret": "your-shared-secret-key"
  }
}

Authorization

Required HeadersDescription
x-AuthenticationKeyIdThe API key id used to authenticate and authorize your request to Infinicept. API keys are managed within your Backoffice tenant.
x-AuthenticationKeyValueThe API key value used to authenticate and authorize your request to Infinicept. API keys are managed within your Backoffice tenant.

Response

{
  "commandFingerprint": "123e4567-e89b-12d3-a456-426614174000",
  "status": 0,
  "createTime": "2024-01-15T10:30:00.000Z",
  "endTime": null,
  "error": null,
  "message": null
}

Command Status Values

StatusDescription
0 - ProcessingThe command is being executed
1 - CompletedThe command executed successfully
2 - FailedThe command failed (check error field for details)
3 - CanceledThe command was canceled before completion


Verify Your Subscription

Retrieve your subscription details to confirm it was created successfully.


Request

GET https://backoffice.infinicept.com/api/{tenantslug}/webhooks

Authorization

Required HeadersDescription
x-AuthenticationKeyIdThe API key id used to authenticate and authorize your request to Infinicept. API keys are managed within your Backoffice tenant.
x-AuthenticationKeyValueThe API key value used to authenticate and authorize your request to Infinicept. API keys are managed within your Backoffice tenant.

Response

[
  {
    "id": 4,
    "type": 6,
    "destinationURL": "https://your-domain.com/webhooks/funding-deposit-funded",
    "authenticationMethod": 1
  }
FieldDescription
idThe numeric value assigned to the subscription representing the order in which the subscription was created
typeThe integer value of the webhook type
destinationURLThe URL of your webhook endpoint
authenticationMethodThe authentication method used with your webhook subscription


Manage Your Subscriptions

Use these endpoints to create and manage webhook subscriptions.

Subscribe to a Webhook

Review Webhook Subscription Details

Update Webhook Subscription Details

List All Webhook Subscriptions