List all payment requests

GET /v2/rtp

Returns a list of RTP requests created by the merchant, with support for filtering, sorting, and pagination.


Request

HTTP Method: GET Endpoint:

/v2/rtp

Headers

Authorization: Bearer {access_token}

Query Parameters

Parameter
Type
Required
Description

count

integer

Yes

Number of items to retrieve in the result set.

offset

integer

Yes

Starting point in the result set (for pagination).

sortBy

string(enum)

No

Sort results by field. Possible values: orderId, type, amount, status, createdAt, expiresAt. Default: createdAt.

order

string(enum)

No

Sorting order. Possible values: asc, desc. Default: asc.

rtpId

string(GUID)

No

Filter by RTP unique identifier.

orderId

string(100)

No

Filter by merchant-side order identifier.

amount

string(enum)

No

Filter by amount.

description

string(500)

No

Filter by description.

status

string(enum)

No

Filter by RTP status. Possible values: Created, Active, Cancelled, Accepted, Rejected, Expired.

createdAtFrom

datetime

No

Filter by RTP creation date (from, inclusive). Format: ISO 8601-1:2019.

createdAtTo

datetime

No

Filter by RTP creation date (to, inclusive). Format: ISO 8601-1:2019.

expiresAtFrom

datetime

No

Filter by RTP expiration date (from, inclusive). Format: ISO 8601-1:2019.

expiresAtTo

datetime

No

Filter by RTP expiration date (to, inclusive). Format: ISO 8601-1:2019.

terminalId

string(100)

No

Filter by terminal ID (provided by bank).


Example Request

curl -G "https://api.maibmerchants.md/v2/rtp" \
  -H "Authorization: Bearer {{access_token}}" \
  --data-urlencode "count=10" \
  --data-urlencode "offset=0" \
  --data-urlencode "amount=10.00" \
  --data-urlencode "sortBy=createdAt" \
  --data-urlencode "order=desc"

Response

Response Parameters

Field
Type
Description

result

object

Response result object.

result.totalCount

integer

Total number of items matching the filters.

result.items

array

Array of RTP detail objects.

result.items.rtpId

string (GUID)

RTP unique identifier.

result.items.orderId

string(100)

Merchant-side order identifier.

result.items.url

string(1000)

RTP URL (HTTPS).

result.items.amount

number (decimal)

RTP amount.

result.items.currency

string(enum)

RTP currency. Possible values: MDL.

result.items.description

string(500)

RTP description.

result.items.callbackUrl

string(1000)

Callback URL (HTTPS).

result.items.redirectUrl

string(1000)

Redirect URL (HTTPS).

result.items.status

string(enum)

RTP status. Possible values: Created, Active, Cancelled, Accepted, Rejected, Expired.

result.items.createdAt

datetime (ISO 8601)

Timestamp when RTP was created.

result.items.updatedAt

datetime (ISO 8601)

Timestamp of last status update.

result.items.expiresAt

datetime (ISO 8601)

Timestamp when RTP expires.

result.items.terminalId

string(100)

Terminal ID provided by bank.

ok

boolean

Request processing status (true on success).

errors

array

Present only if ok = false.

errors.errorCode

string

Error code.

errors.errorMessage

string

Error description.


Example Successful Response

{
  "result": {
    "totalCount": 42,
    "items": [
      {
        "rtpId": "123e4567-e89b-12d3-a456-426614174000",
        "url": "https://example.com/rtp/123e4567-e89b-12d3-a456-426614174000",
        "amount": 50.00,
        "currency": "MDL",
        "description": "Description",
        "status": "Accepted",
        "createdAt": "2024-08-05T10:32:28+03:00",
        "updatedAt": "2024-08-05T10:33:50+03:00",
        "expiresAt": "2024-08-05T10:34:28+03:00",
        "terminalId": "P011111"
      }
    ]
  },
  "ok": true
}

Notes & Best Practices

  • Use count and offset for efficient pagination.

  • Always filter by createdAtFrom / createdAtTo when doing reconciliation, to avoid unnecessarily large datasets.

  • url can be stored to provide direct links to RTPs in merchant back-office tools.

  • Status values are identical to those returned by the Get RTP Status endpoint.

Last updated