# List Reports

**GET** `/reports`

Base URL: `https://api.uat.triple-a.io/api/fiat-payout/v1`

This endpoint allows API users to retrieve a paginated list of reports they requested.

## Authorization

- oauth2 (http, bearer)

## Query parameters

- `from` (string)
  Start date for filtering reports by the date each report was requested (its creation time, not the period the report covers), inclusive, in `YYYY-MM-DD` format.
- `to` (string)
  End date for filtering reports by the date each report was requested (its creation time, not the period the report covers), inclusive, in `YYYY-MM-DD` format.
- `page` (integer)
  Specify the page number.
- `limit` (integer)
  Specify the number of items per page.
- `sort_by` (string)
  Field to sort results by. Defaults to `created_at`.
- `sort_type` (string)
  Sort direction. Defaults to `DESC`.

## Responses

### 200

OK

- `id` (string<uuid>)
- `type` (string)
- `status` ("pending" | "error" | "completed")
- `delivery_channel` ("email" | "webhook")
- `sent_at` (string<date-time>)
  When the report was delivered via the chosen delivery_channel. Null until delivery has succeeded (a completed report may still have a null sent_at).
- `created_at` (string<date-time>)
- `updated_at` (string<date-time>)

Example:

```json
[
  {
    "id": "00000000-0000-0000-0000-000000000000",
    "type": "string",
    "status": "pending",
    "delivery_channel": "email",
    "sent_at": "1970-01-01T00:00:00.000Z",
    "created_at": "1970-01-01T00:00:00.000Z",
    "updated_at": "1970-01-01T00:00:00.000Z"
  }
]
```

### 400

Error defines errors may be returned from the system.

- `message` (string)
- `errors` (object[])
  - `errorCode` (string)
  - `message` (string)

Example:

```json
{
  "message": "string",
  "errors": [
    {
      "errorCode": "string",
      "message": "string"
    }
  ]
}
```

### 422

Error defines errors may be returned from the system.

- `message` (string)
- `errors` (object[])
  - `errorCode` (string)
  - `message` (string)

Example:

```json
{
  "message": "string",
  "errors": [
    {
      "errorCode": "string",
      "message": "string"
    }
  ]
}
```

### 500

Error defines errors may be returned from the system.

- `message` (string)
- `errors` (object[])
  - `errorCode` (string)
  - `message` (string)

Example:

```json
{
  "message": "string",
  "errors": [
    {
      "errorCode": "string",
      "message": "string"
    }
  ]
}
```