POST /v1/transactions/custody-bank/deposit/initiatePOST /v1/transactions/custody-bank/deposit/completehttps://api.dev.pynil.com/v1.Authorization: Basic <BASE64(username:password)>X-Signature: <HMAC_SHA256_UPPERCASE_HEX>X-Timestamp: <UNIX_TIMESTAMP_SECONDS>Content-Type: application/jsonHTTP_METHOD + "\n" + REQUEST_PATH + "\n" + UNIX_TIMESTAMP/v1/transactions/custody-bank/deposit/initiatePOST /v1/transactions/custody-bank/deposit/initiate{
"walletNumber": "101000030",
"amount": 500.0,
"timestamp": "2025-08-03",
"notes": "Layla deposits money"
}walletNumber, amount, timestamp are required.{
"success": true,
"message": "Success.",
"statusCode": 200,
"data": {
"account": {
"branchCode": "MAIN",
"bban": "12000010000101000030",
"currencyCode": "SDG",
"walletName": "Layla ismaeil",
"status": "Active"
},
"charges": [
{
"name": "Custody Deposit",
"amount": 20.0
}
],
"totalFees": 20.0
}
}400 validation response envelope (success/message/statusCode/data)401 RFC 7807 ProblemDetails (e.g., missing signature, invalid timestamp, invalid signature)404 envelope error (wallet/depositor/shadow not found)500 envelope errorPOST /v1/transactions/custody-bank/deposit/complete{
"walletNumber": "101000030",
"currency": "SDG",
"amount": 500.0,
"depositor": {
"fullName": "Layla ismaeil",
"mobile": "0918003874",
"idNumber": "1001-1090-180",
"address": "Khartoum - sudan"
},
"BankTranID": "41128",
"timestamp": "2025-08-03",
"notes": "Layla deposits money"
}depositor object is optional.BankTranID is required and used for idempotency.BankTranID was already processed successfully, API returns the existing nilpayTranRef.{
"success": true,
"message": "Success.",
"statusCode": 200,
"data": {
"nilpayTranRef": 6
}
}{
"type": "about:blank",
"title": "Unauthorized",
"status": 401,
"detail": "Invalid signature"
}| HTTP Code | Error Type | Description | Action Required |
|---|---|---|---|
| 400 | Validation Error | Invalid request parameters | Fix request payload and retry |
| 401 | Authentication Failed | Basic Auth, signature, timestamp, or replay validation failure | Verify credentials, signature payload, and timestamp |
| 404 | Account Not Found | Wallet/depositor/shadow account not found or inactive | Verify wallet and configuration |
| 500 | Internal Server Error | Unrecoverable server error | Retry later, contact support if persistent |