Payroll approval
curl --request POST \ --url https://api.ztlpay.io/api/v2/payroll/approve \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --header 'PSU-IP-Address: 192.158.1.38' \ --header 'PSU-User-Agent: Mozilla/5.0 (Windows NT 10.0; …) Gecko/20100101 Firefox/63.0' \ --header 'consent-id: 3a797348-ef0c-4f52-b821-fdfcdb98c4d9' \ --data '{ "payrolls": [ "71a2e752-8b71-446f-b9e9-b19bfb70becb" ], "callbackUrl": "https://www.google.com" }'Start approval/signing process of a payroll
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Header Parameters
Section titled “Header Parameters”Example
3a797348-ef0c-4f52-b821-fdfcdb98c4d9A valid consentId
Example
192.158.1.38AAA IP Address of the end-user initiating the payment. DO NOT use any other IP address than what you can collect from the current user session that uses your system (don’t use something stored in your DB). This information is used by the banks to manage traffic and handle security.
The forwarded Agent header field of the HTTP request between PSU and TPP.
Example
Mozilla/5.0 (Windows NT 10.0; …) Gecko/20100101 Firefox/63.0Request Body
Section titled “Request Body”If both payrollId and payrolls are provided, payrolls will be used.
object
A list of payroll ids to be approved
Example
[ "71a2e752-8b71-446f-b9e9-b19bfb70becb"]Sca callback url for redirect authentication
Example
https://www.google.comIf both payrollId and payrolls are provided, payrolls will be used.
object
The id returned from the initiation process
Sca callback url for redirect authentication
Example
https://www.google.comResponses
Section titled “Responses”Approval initiated successfully
object
An ID that can be used to identify the approval and check for statuses
object
Redirect link to redirect authorization flow.
Url to start authorization redirect flow
Example
{ "id": "7c628b2e-9094-4bf8-af23-1d517c6fc4f5", "status": "STARTED", "sca": { "type": "redirect", "url": "https://api.ztlpay.io/api/v2/consents/sca/redirect/start/6212d401-1785-4739-8843-55fe4eb9dad4" }}Bad Request
object
INVALID_CONSENTConsent is invalidAUTHENTICATION_TEMPORARY_UNAVAILABLEAuthentication service is temporary unavailable, most likely due to user already has started another concurrent authentication processUNSUPPORTED_PRODUCT_BY_BANKProduct is not supported by bank
Unique RequestId, please provide this Id in case of support requests
The underlying reason for the error
Example
{ "failure": "INVALID_CONSENT", "ztlRequestId": "3a797348-ef0c-4f52-b821-fdfcdb98c4d9", "message": "Invalid Bban"}Forbidden
object
Unique RequestId, please provide this Id in case of support requests
The underlying reason for the error
Example
{ "ztlRequestId": "3a797348-ef0c-4f52-b821-fdfcdb98c4d9", "message": "Invalid account"}Headers
Section titled “Headers”Unique RequestId, please provide this Id in case of support requests
Example
3a797348-ef0c-4f52-b821-fdfcdb98c4d9Not found
object
Unique RequestId, please provide this Id in case of support requests
The underlying reason for the error
Example
{ "ztlRequestId": "3a797348-ef0c-4f52-b821-fdfcdb98c4d9", "message": "Invalid account"}Headers
Section titled “Headers”Unique RequestId, please provide this Id in case of support requests
Example
3a797348-ef0c-4f52-b821-fdfcdb98c4d9Conflict
object
Unique RequestId, please provide this Id in case of support requests
The underlying reason for the error
Example
{ "ztlRequestId": "3a797348-ef0c-4f52-b821-fdfcdb98c4d9", "message": "Invalid account"}Headers
Section titled “Headers”Unique RequestId, please provide this Id in case of support requests
Example
3a797348-ef0c-4f52-b821-fdfcdb98c4d9Internal server error
object
Unique RequestId, please provide this Id in case of support requests
The underlying reason for the error
Example
{ "ztlRequestId": "3a797348-ef0c-4f52-b821-fdfcdb98c4d9", "message": "Invalid account"}Headers
Section titled “Headers”Unique RequestId, please provide this Id in case of support requests
Example
3a797348-ef0c-4f52-b821-fdfcdb98c4d9Service unavailable
object
Unique RequestId, please provide this Id in case of support requests
The underlying reason for the error
Example
{ "ztlRequestId": "3a797348-ef0c-4f52-b821-fdfcdb98c4d9", "message": "Invalid account"}Headers
Section titled “Headers”Unique RequestId, please provide this Id in case of support requests
Example
3a797348-ef0c-4f52-b821-fdfcdb98c4d9