Skip to main content
GET
/
v1
/
payouts
curl -X GET "https://api.affonso.io/v1/payouts?limit=10&status=pending" \
  -H "Authorization: Bearer sk_live_your_api_key"
{
  "success": true,
  "data": [
    {
      "id": "pay_abc123",
      "affiliateId": "aff_456def",
      "invoiceNumber": 1001,
      "amount": 150.00,
      "status": "pending",
      "paymentMethod": "paypal",
      "paymentReference": null,
      "processedAt": null,
      "managedPayout": true,
      "affiliate": {
        "name": "John Doe",
        "email": "[email protected]"
      },
      "createdAt": "2024-01-25T10:00:00Z",
      "updatedAt": "2024-01-25T10:00:00Z"
    }
  ],
  "pagination": {
    "page": 1,
    "limit": 10,
    "total": 15,
    "totalPages": 2,
    "hasNextPage": true,
    "hasPrevPage": false
  }
}

Query Parameters

page
integer
default:"1"
Page number for pagination. Must be a positive integer.
limit
integer
default:"50"
Number of results per page. Maximum value is 200. Default is 50.
status
string
Filter payouts by status. Valid values: pending, processing, completed, failed, cancelled.
affiliateId
string
Filter payouts by affiliate ID. Only returns payouts for the specified affiliate.
sort
string
Sort field and direction in the format field:direction. Valid fields: createdAt, updatedAt, amount, processedAt. Valid directions: asc, desc. Example: createdAt:desc.
dateFrom
string
Filter payouts created on or after this date. ISO 8601 date format (e.g., 2024-01-01).
dateTo
string
Filter payouts created on or before this date. ISO 8601 date format (e.g., 2024-12-31).

Response

The response includes a paginated list of payouts and pagination metadata.
success
boolean
Always true for successful responses
data
array
Array of payout objects.
pagination
object
Pagination metadata object containing:
  • page (integer): Current page number
  • limit (integer): Number of results per page
  • total (integer): Total number of payouts matching the filters
  • totalPages (integer): Total number of pages
  • hasNextPage (boolean): Whether there is a next page
  • hasPrevPage (boolean): Whether there is a previous page
curl -X GET "https://api.affonso.io/v1/payouts?limit=10&status=pending" \
  -H "Authorization: Bearer sk_live_your_api_key"
{
  "success": true,
  "data": [
    {
      "id": "pay_abc123",
      "affiliateId": "aff_456def",
      "invoiceNumber": 1001,
      "amount": 150.00,
      "status": "pending",
      "paymentMethod": "paypal",
      "paymentReference": null,
      "processedAt": null,
      "managedPayout": true,
      "affiliate": {
        "name": "John Doe",
        "email": "[email protected]"
      },
      "createdAt": "2024-01-25T10:00:00Z",
      "updatedAt": "2024-01-25T10:00:00Z"
    }
  ],
  "pagination": {
    "page": 1,
    "limit": 10,
    "total": 15,
    "totalPages": 2,
    "hasNextPage": true,
    "hasPrevPage": false
  }
}