# Display List of QR Codes with Filtering Options

**GET**`/v2/mia/qr`

This endpoint allows retrieving a list of QR codes created in the MIA platform, with the ability to apply various filtering, sorting, and pagination parameters.

***

#### Request parameters (query)

| Name          | Type              | Required | Description                                                                                                                         |
| ------------- | ----------------- | -------- | ----------------------------------------------------------------------------------------------------------------------------------- |
| count         | integer           | Yes      | Number of returned results.                                                                                                         |
| offset        | integer           | Yes      | Starting index for the result set.                                                                                                  |
| sortBy        | string (enum)     | No       | Field used for sorting. Possible values: `orderId`, `type`, `amountType`, `status`, `createdAt`, `expiresAt`. Default: `createdAt`. |
| order         | string (enum)     | No       | Sorting order. Possible values: `asc`, `desc`. Default: `asc`.                                                                      |
| qrId          | string (GUID)     | No       | Filter by QR ID.                                                                                                                    |
| extensionId   | string (GUID)     | No       | Filter by QR extension ID.                                                                                                          |
| orderId       | string (max. 100) | No       | Filter by merchant order ID.                                                                                                        |
| type          | string (enum)     | No       | QR type. Possible values: `Static`, `Dynamic`, `Hybrid`.                                                                            |
| amountType    | string (enum)     | No       | Amount type. Possible values: `Fixed`, `Controlled`, `Free`.                                                                        |
| amountFrom    | number (decimal)  | No       | Minimum amount value.                                                                                                               |
| amountTo      | number (decimal)  | No       | Maximum amount value.                                                                                                               |
| description   | string (max. 500) | No       | Filter by description.                                                                                                              |
| status        | string (enum)     | No       | QR status. Possible values: `Active`, `Inactive`, `Expired`, `Paid`, `Cancelled`.                                                   |
| createdAtFrom | string (datetime) | No       | Creation date — from. ISO 8601 format.                                                                                              |
| createdAtTo   | string (datetime) | No       | Creation date — to. ISO 8601 format.                                                                                                |
| expiresAtFrom | string (datetime) | No       | Expiration date — from. ISO 8601 format.                                                                                            |
| expiresAtTo   | string (datetime) | No       | Expiration date — to. ISO 8601 format.                                                                                              |
| terminalId    | string (max. 100) | No       | Terminal ID, provided by the bank.                                                                                                  |

***

#### Request example

```bash
curl -G "https://api.example.com/v2/mia/qr" \
  -H "Authorization: Bearer {{access_token}}" \
  --data-urlencode "count=10" \
  --data-urlencode "offset=0" \
  --data-urlencode "amountFrom=10.00" \
  --data-urlencode "amountTo=100.00" \
  --data-urlencode "sortBy=createdAt" \
  --data-urlencode "order=desc"
```

***

#### Response parameters

**Object `result`**

| Name       | Type    | Description                                          |
| ---------- | ------- | ---------------------------------------------------- |
| totalCount | integer | Total number of QR codes found based on the filters. |
| items      | array   | List of QR objects.                                  |

**Objects in `items`**

| Field       | Type               | Description                                                      |
| ----------- | ------------------ | ---------------------------------------------------------------- |
| qrId        | string (GUID)      | Unique identifier of the QR code.                                |
| extensionId | string (GUID)      | QR extension ID.                                                 |
| orderId     | string (max. 100)  | Merchant's order ID.                                             |
| type        | string (enum)      | QR type: `Static`, `Dynamic`, `Hybrid`.                          |
| url         | string (max. 1000) | QR URL. Format: HTTPS.                                           |
| amountType  | string (enum)      | Amount type: `Fixed`, `Controlled`, `Free`.                      |
| amount      | number (decimal)   | Fixed amount (if applicable).                                    |
| amountMin   | number (decimal)   | Minimum amount (for controlled amounts).                         |
| amountMax   | number (decimal)   | Maximum amount (for controlled amounts).                         |
| currency    | string (enum)      | Currency. ISO 4217 format.                                       |
| description | string (max. 500)  | QR description.                                                  |
| callbackUrl | string (max. 1000) | Callback URL.                                                    |
| status      | string (enum)      | QR status: `Active`, `Inactive`, `Expired`, `Paid`, `Cancelled`. |
| createdAt   | string (datetime)  | QR creation date. ISO 8601 format.                               |
| updatedAt   | string (datetime)  | Last update. ISO 8601 format.                                    |
| expiresAt   | string (datetime)  | QR expiration date. ISO 8601 format.                             |
| terminalId  | string (max. 100)  | Bank terminal ID.                                                |

**Other fields**

| Field               | Type    | Description                                       |
| ------------------- | ------- | ------------------------------------------------- |
| ok                  | boolean | `true` if the request was successfully processed. |
| errors              | object  | Error details, if any.                            |
| errors.errorCode    | string  | Error code.                                       |
| errors.errorMessage | string  | Error description.                                |

***

#### Exemplu răspuns

```json
{
  "result": {
    "totalCount": 42,
    "items": [
      {
        "qrId": "123e4567-e89b-12d3-a456-426614174000",
        "extensionId": "40e6ba44-7dff-48cc-91ec-386a38318c68",
        "type": "Dynamic",
        "url": "https://example.com/qr/123e4567-e89b-12d3-a456-426614174000",
        "amountType": "Fixed",
        "amount": 50.00,
        "currency": "MDL",
        "description": "Description",
        "status": "Paid",
        "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
}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.maibmerchants.md/mia-qr-api/en/endpoints/information-retrieval-get/display-list-of-qr-codes-with-filtering-options.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
