Deposit Notification
A server-initiated callback. Implement a receiving endpoint in your service.
The callback URL is provided by the initiator of the corresponding business request. See the callback_url parameter in the Generate Address API. This callback is initiated by Cregis and sent to the business side. There are two mutually exclusive callback outcomes, determined by the status value. A single transaction generates only one callback:
| status | Description |
|---|---|
| 1 | Deposit transaction successful callback |
| 2 | Deposit transaction failed callback |
After Cregis sends the callback, receiving a response body equal to the success string means the callback succeeded; otherwise, the callback failed. Failed callbacks can be pushed again. Log in to the Cregis client, select the corresponding project in the project menu, and push again from the callback records menu.
Different business types have different callback payloads. We strongly recommend using separate endpoints for different callback types to keep business logic clear.
Request
Callback Payload
application/jsonpidinteger<int64>Project ID.
cidinteger<int64>System serial number.
chain_idstringMain chain identifier.
token_idstringToken ID.
currencystringCurrency identifier.
addressstringAddress.
amountstringAmount.
statusstringenum: "1", "2"Status.
txidstringTransaction hash.
noncestring6-character random string.
timestampinteger<int64>Timestamp.
signstringSignature.
block_heightstringBlock height.
block_timestringBlock time.
memostringOn-chain memo/tag information. Supported only by TON and XRP.
Responses
200Your server must return HTTP 200 and a response body strictly equal to plain text `success` (`text/plain`).text/plainstring