Skip to main content
GET
/
payment
Get Payments
curl --request GET \
  --url https://api.royalti.io/payment/ \
  --header 'Authorization: Bearer <token>'
{
  "totalItems": "18,",
  "Payments": [
    {
      "id": "65f4b71d-ce3e-4458-ab6d-97d3c10d166c",
      "PaymentRequestId": "null,",
      "TenantUserId": "09de2d9b-a9eb-4b98-a15a-3b7f59f6161f",
      "title": "Payment Receipt updated",
      "transactionDate": "2023-04-21T00:00:00.000Z",
      "currency": "USD",
      "amount": 74000,
      "amountUSD": 100,
      "balanceCurrency": null,
      "balance": null,
      "conversionRate": 740,
      "externalId": null,
      "settings": null,
      "status": "completed",
      "memo": "Sale of album",
      "files": [
        "file3.pdf",
        "file2.pdf"
      ],
      "transactionId": "null,",
      "createdAt": "2024-11-18T15:40:45.843Z",
      "updatedAt": "2025-03-07T01:14:18.001Z",
      "TenantUser": {
        "id": "09de2d9b-a9eb-4b98-a15a-3b7f59f6161f",
        "firstName": "odiri",
        "lastName": "ighogboja",
        "role": "user",
        "User": {
          "email": "[email protected]",
          "profilePicture": null
        }
      }
    }
  ],
  "totalPages": "2,",
  "currentPage": "1,",
  "ilteredItems": 10
}
This endpoint requires authentication. Include your Bearer token in the Authorization header.

Description

Get Payments Description:
The /payment/ endpoint retrieves a list of payments with filtering and pagination options.
Method:
GET
Query Parameters:
ParameterTypeDescription
q (Optional)stringSearch query to filter payments
page (Optional)integerPage number for pagination. Default: 1
size (Optional)integerNumber of payments per page. Default: 10
sort (Optional)stringField to sort by. Default: ‘updatedAt’
order (Optional)stringSort order (‘asc’ or ‘desc’). Default: ‘desc’
user (Optional)stringFilter by user ID
status (Optional)stringFilter by status
startDate (Optional)stringFilter payments from this date
endDate (Optional)stringFilter payments to this date
include (Optional)stringSpecify ‘count’ to include the total count of items

Code Examples

const response = await fetch('https://api.royalti.io/payment/', {
  method: 'GET',
  headers: {
    'Authorization': `Bearer ${token}`,
  },
});

const data = await response.json();
console.log(data);

Authorizations

Authorization
string
header
required

JWT Authorization header using the Bearer scheme. Format: "Bearer {token}"

Query Parameters

q
string

Search query to filter payments

page
integer
default:1

Page number for pagination

size
integer
default:10

Number of payments per page

sort
string
default:updatedAt

Field to sort by

order
enum<string>
default:desc

Sort order ('asc' or 'desc')

Available options:
asc,
desc
user
string

Filter by user ID

startDate
string<date>

Filter payments from this date

endDate
string<date>

Filter payments to this date

include
string

Specify 'count' to include the total count of items

status
enum<string>

Filter payments by status

Available options:
PENDING,
COMPLETED,
FAILED

Response

Success

message
string
payments
object[]
total
integer
page
integer
size
integer