Payment Documentation
Integration guides for endpoints to manage and retrieve documents associated with Lync payments.
These documents are often required for international transactions and may include proofs of completion, receipts, and other supporting files.
1. List Payment Documents
Overview
This endpoint retrieves all documents related to a specific payment. The documents may be text-based or files (e.g., PDFs).
Path Parameter
Parameter | Type | Required | Description |
---|---|---|---|
paymentId | string | ✅ Yes | The unique identifier of the payment whose documents you want to retrieve. |
Example Request
GET http://api.sandbox.waza.co/lync/banking/v2/payments/018fc990-1496-7c68-b268-46b1267cc015/docs
Example Response
{
"data": [
{
"id": "01927112-381d-76b5-9de8-e58cea1b4613",
"state": "ACTIVE",
"created_date": "2024-10-09T11:37:52.413Z",
"updated_date": "2024-10-09T11:37:52.413Z",
"version": 0,
"value": "93962476-39ea-4bb9-9e28-ad748d1d8aae",
"description": "swift uetr",
"type": "PROOF_OF_COMPLETION",
"file_info": {
"type": "application/pdf",
"name": null,
"size": 18810,
"url": "/payments/docs/01927112-381d-76b5-9de8-e58cea1b4613/download"
},
"payment_id": "019270f5-d692-7a97-bf52-93fb4f0b962f"
}
]
}
Response Fields
Field | Type | Description |
---|---|---|
id | string | The unique identifier of the document. |
state | string | The status of the document (ACTIVE , INACTIVE ). |
created_date | string | The date when the document was created. |
updated_date | string | The date when the document was last updated. |
version | integer | The version number of the document. |
value | string | The internal reference value of the document. |
description | string | A short description of the document (e.g., "swift uetr"). |
type | string | The type of document (e.g., PROOF_OF_COMPLETION ). |
file_info.type | string | The MIME type of the document (e.g., application/pdf ). |
file_info.name | string | The name of the document file (if available). |
file_info.size | integer | The file size in bytes. |
file_info.url | string | The URL to download the document. |
payment_id | string | The payment ID associated with the document. |
2. Download a Payment Document
Overview
This endpoint downloads a specific document associated with a payment. The response is a buffer file, meaning it will be handled as a file download rather than JSON.
Path Parameter
Parameter | Type | Required | Description |
---|---|---|---|
docId | string | ✅ Yes | The unique identifier of the document to be downloaded. |
Example Request
GET http://api.sandbox.waza.co/lync/banking/v2/payments/docs/018fdd86-fa7c-73a6-a11d-7f392e450d29/download
Response
- The response will contain the document file as a binary buffer.
- The
Content-Type
in the response headers will indicate the file format (e.g.,application/pdf
). - Ensure your system correctly handles file downloads based on the response format.
Example Error Response (Invalid Payment ID):
If the request fails, the API will return an error response with relevant details.
{
"error": {
"message": "Payment not found",
"code": "404",
"description": "No documents found for the given payment ID"
}
}
Updated 2 months ago