This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.
HTTP Callbacks
Callbacks are used for session and transaction updates. Listen to the callbacks on deposits and withdrawals, by submitting the callback URL and the State ID in the callbacks
parameters. Respond with a HTTP 200 OK to let Brite know that the notifications has been received.
Please note that callback are not necessarily fired in order so please make sure to have logic in place to handle this.
Session callbacks
Brite backend supports the following callbacks for session states:
- STATE_AUTHENTICATION_COMPLETED = 2
- STATE_ABORTED = 10
- STATE_FAILED = 11
- STATE_COMPLETED = 12
To subscribe to callbacks. Populate the callbacks
with a URL which the callbacks should be sent to and the desired state. Same URL can be used for several states but every callback need to be populated separately in the request.
// example request parameters
"callbacks": [
{"url": "https://", "session_state": 2},
{"url": "https://", "session_state": 10},
{"url": "https://", "session_state": 11},
{"url": "https://", "session_state": 12},
]
The push notification is a JSON POST with the following body
// example request callbacks
{
"session_state": 2,
"session_id": "string",
"merchant_id": "string"
}
Transaction callbacks
Brite backend supports the following callbacks for transaction states:
- STATE_PENDING= 1 (For recurring deposit)
- STATE_ABORTED = 2
- STATE_FAILED = 3
- STATE_CREDIT = 5
- STATE_DEBIT = 7
To subscribe to callbacks. Populate the callbacks
with a URL which the callbacks should be sent to and the desired state. Same URL can be used for several states but every callback need to be populated separately in the request.
// example request - parameters
"callbacks": [
{"url": "some_url", "transaction_state": 2},
{"url": "some_url", "transaction_state": 3},
{"url": "some_url", "transaction_state": 5},
{"url": "some_url", "transaction_state": 7}
]
The push notification is a JSON POST with the following body
// example request callbacks
{
"transaction_state": "X",
"transaction_id": "Y",
"merchant_id": "Z"
}
Since the data is pushed in the open, the merchant is always required to verify the state on their end. This can be done by calling session.state
or transaction.state
endpoint.
It is important to note that subscribing to these callbacks, and particularly to STATE_CREDIT = 5, will enable you as a merchant to act on crediting the end user upon receiving the STATE_CREDIT
notification from Brite.
Retries
If a notifications has not received a 200 OK response Brite retries sending the state callbacks up to an hour. If the callback fails another attempt will be triggered after 10, 30 and then finally 60 minutes.
IP Whitlist
Please note that in order to use this service you must whitelist the following IP addresses:
Sandbox | Production |
---|---|
35.228.90.52 | 35.228.90.52 |
34.107.68.175 | 34.107.68.175 |
34.159.115.166 | 34.141.92.135 |
34.141.92.135 | 34.141.49.184 |
34.141.49.184 | 35.246.194.85 |
35.246.194.85 |