Webhook Solutions
Overview
Our webhook solution ensures that your system receives real-time notifications regarding specific events triggered within the NI system, based on your subscription to the different webhooks.
Integration
Our Webhooks solution relies on consumer defining a single API endpoint to receive all the notification types. Each message contains a common structure with:
- id: Unique message id
- type: type of notification. This is the key field to differentiate processing of the details payload
- timestamp: timestamp of the message from NI systems
- details: notification payload. Every message type will have its own payload specification and should be parsed and acted accordingly.
Security
The webhook endpoint is expected to be hosted through TLS/HTTPS to ensure secured data exchange. In addition to this, our webhook solution supports API authentication.
The preferred authentication strategy is oAuth2 where the consumer should provide NI with:
- Authentication/Token management URL endpoint
- client_id
- client_secret
Pre-requisites
Our webhook API request will be using the POST verb.
To register a Webhook endpoint with us, please contact your relationship manager with:
- Webhook URL Endpoint
- Authentication mode
- Security requirements
To support different authentication method or integration strategy with us, please contact your relationship manager
SMS Webhook
Status:
Production
Version:
V2
Product:
Webhook Solutions
SMS Webhook....
Overview
The SMS Webhook serves to inform your system when an SMS needs to be dispatched to the cardholder.
SMS text generation
This functionality is employed when NI handles SMS text generation, but the message sending is managed by your system.
Predefined templates
Message text generation relies on predefined templates set up at NI for each event.
Contact details
Alongside message text generation, we'll provide the contact details necessary to send the notification back to the cardholder from your side.
How It Works
First the template needs to be defined at NI side, and delivery channel will be defined as your system.
Once SMS is triggered, the SMS Webhook will initiate a request containing relevant information about the event to a predefined URL endpoint.
SMS Webhook
Status:
Production
Version:
V2
Product:
Webhook Solutions
Node | Child Node | Type | Length | Description |
---|---|---|---|---|
Authorization | Bearer xxxx | string | Authorization Header (Bearer Token) | |
Content-Type | application/json | string | Content Type |
Node Type | Type | Length | Description | |||||||
---|---|---|---|---|---|---|---|---|---|---|
id | string | 20 | Unique identifer for the request | |||||||
type | string | 32 | Type of the webhook | |||||||
timestamp | string | 30 | Timestamp of the request - Format YYYY-MM-DDtHH:MM:SS.SSS+04:00 | |||||||
details | sms | recipient | card | id | value | string | 32 | Card Identifier | ||
type | string | 20 | externalCardId - when this is used,cardNumber - when clear card number is used | |||||||
maskedCardNumber | string | 19 | Masked PAN number | |||||||
clientId | string | 21 | Client ID | |||||||
mobilePhone | string | 32 | Mobile Number to which the SMS should be triggered | |||||||
string | 255 | Email ID | ||||||||
language | string | 3 | Language ISO code | |||||||
textMessage | string | 255 | The content of the SMS |
{
"id": "b876d568-8411-4638-bdef-a1a188a4773b",
"type": "SMS",
"timestamp": "2020-07-20T06:49:02.366Z",
"details": {
"sms": {
"recipient": {
"card": {
"id": {
"value": "99984100133767425304",
"type": "externalCardId"
}
},
"maskedCardNumber": "999841XXXXXX7408",
"clientId": "112233677339066180",
"mobilePhone": "112211223322",
"email": "James.Robert@network.global",
"language": "ENG"
},
"textMessage": "Thank you for your NI Issuing Core DEMO Visa Gold credit card application. Your NI Issuing Core DEMO credit card ending 0796 was activated with 0.00 AED."
}
}
}
Node | Child Node | Type | Length | Description | |||
---|---|---|---|---|---|---|---|
Content-Type | application/json | string | Content Type |
Node Type | Type | Length | Description | |||||||
---|---|---|---|---|---|---|---|---|---|---|
id | string | 12 | Unique identifer ID | |||||||
type | string | 10 | Type of the webhook | |||||||
timestamp | string | 30 | Timestamp of the response - Format YYYY-MM-DDtHH:MM:SS.SSS+04:00 | |||||||
response | status | code | string | 5 | Status code of the response | |||||
description | string | 30 | Response Description |
{
"id": "b876d568-8411-4638-bdef-a1a188a4773b",
"type": "SMS",
"timestamp": "2020-07-20T06:49:02.366Z",
"response": {
"status": {
"code": "00",
"description": "successful"
}
}
}
Code | Description |
---|---|
200 | Bank Fin Profiles Successfully retrieved |
400 | Bad request (Refer to the Bussiness Error Table) |
401 | Indicates that the request requires user authentication information. The client MAY repeat the request with a suitable Authorization header field |
404 | The server can not find the requested resource. |
500 | Internal Server Error |
502 | The server got an invalid response while working as a gateway to get the response needed to handle the request |
503 | The server is not ready to handle the request. |
504 | The server is acting as a gateway and cannot get a response in time for a request. |
596 | Service Not Found |