# Lists merchants

<span class="api-endpoint">GET {{<a href="#urlbases">baseURL</a>}}/pay-api/v1/merchants</span>
This endpoint lists merchants associated with the authenticated partner (ISV).
The following query parameters are search filters used to specify the retuurned results.

Endpoint: GET /pay-api/v1/merchants
Version: V1
Security: Bearer

## Query parameters:

  - `page` (integer)
    Specifies the page number of the returned search results.

A page is considered each set of the `pageSize` value.

The maximum page value is the `pageSize` divided by the `total` count rounded up.
The count is zero-based.
For example, if `pageSize` is 50 and the `total` is 130, there are three pages.
The maximum `page` value is 2.

Values above the maximum page value will complete successfully but not return any items.

Example: 0

  - `pageSize` (integer)
    Specifies the number of items for each page of the returned search results.

A page is considered each set of the `pageSize` value.

The maximum page value is the `pageSize` divided by the `total` count rounded up.
The count is zero-based.
For example, if `pageSize` is 50 and the `total` is 130, there are three pages.
The maximum `page` value is 2.

Example: 50

  - `orderBy` (string)
    Specifies the field the results get ordered by.

The sort order is specified by the `asc` value.

Example: contactName

  - `asc` (boolean)
    Specifies the sort order is ascending.

The sort field is specified by the `orderBy` value.

If `true`, the sort order is ascending.<br>
If `false`, the sort order is descending.

Example: true

  - `search` (string)
    Specifies the search string.

This performs a case insensitive, matching, or partially matching search.

Fields does not have to be specified.
If the results are to be sorted, the field `orderby` to specify the sort field.

  - `mccCodeId` (integer)
    Specifies the <a href="#mcc-codes">MCC (merchant category code)</a>.

Example: 28

  - `statusId` (integer)
    Merchant status filter.

  - `createdFrom` (string)
    Specifies the earliest inclusive created date (in an ISO 8601 date-time UTC format).

This value may be paired with the field `createdTo` to form an inclusive range.

  - `createdTo` (string)
    Specifies the latest inclusive created date (in an ISO 8601 date-time UTC format).

This value may be paired with the field `createdFrom` to form an inclusive range.

  - `modifiedFrom` (string)
    Specifies the earliest inclusive modified date (in an ISO 8601 date-time UTC format).

This value may be paired with the field `modifiedTo` to form an inclusive range.

  - `modifiedTo` (string)
    Specifies the latest inclusive modified date (in an ISO 8601 date-time UTC format).

This value may be paired with the field `modifiedFrom` to form an inclusive range.

  - `lastTransactionDateFrom` (string)
    Specifies the earliest inclusive transaction date (in an ISO 8601 date-time UTC format).

This value may be paired with the field `lastTransactionDateTo` to form an inclusive range.

  - `lastTransactionDateTo` (string)
    Specifies the latest inclusive transaction date (in an ISO 8601 date-time UTC format).

This value may be paired with the field `lastTransactionDateFrom` to form an inclusive range.

## Response 200 fields (application/json):

  - `items` (array, required)
    Indicates an object array for the returned merchant list.

  - `items.companyName` (string, required)
    Indicates the name of the customer's company or organization.

Example: Peppared Street Cafe
    Example: Peppared Street Cafe

  - `items.merchantId` (string, required)
    Indicates the merchant Identifies.

Example: 3fa85f64-5717-4562-b3fc-2c963f66afa6
    Example: 3fa85f64-5717-4562-b3fc-2c963f66afa6

  - `total` (integer, required)
    Indicates the total number of merchants found.

Example: 4
    Example: 4

## Response 400 fields (application/json):

  - `details` (string)
    Indicates details about the error.

Example: Validation failed: -- Email: 'Email' is not a valid email address. Severity: Error
    Example: Validation failed: -- Email: 'Email' is not a valid email address. Severity: Error

  - `statusCode` (integer)
    Specifies the HTTP response status code.
This is the HTTP status code returned by the attempted delivery.
The following is a list of HTTP response status codes that include but are not limited to:
| HTTP Status | Meaning |
|  --- | --- |
| 200 | Delivery succeeded |
| 400 | Bad request |
| 401 | Unauthorized |
| 404 | Endpoint not found |
| 429 | Rate limited |

Example: 401
    Example: 401

  - `source` (string)
    Indicates the source of the error.
Example: <Service>
    Example: <Service>

  - `exceptionType` (string)
    Indicates the error's exception type.

Example: FluentValidation.ValidationException
    Example: FluentValidation.ValidationException

  - `correlationId` (string)
    Indicates the correlation identifier.

Example: aa6cfcd0-0295-4a4c-b074-8c901f114fef
    Example: aa6cfcd0-0295-4a4c-b074-8c901f114fef

  - `entityId` (string)
    Indicates the entity identifier.
Example:
null

  - `errorCode` (string)
    Indicates the error code.
Example:
null

## Response 404 fields (application/json):

  - `details` (string)

  - `statusCode` (integer)
    Specifies the HTTP response status code.
This is the HTTP status code returned by the attempted delivery.
The following is a list of HTTP response status codes that include but are not limited to:
| HTTP Status | Meaning |
|  --- | --- |
| 200 | Delivery succeeded |
| 400 | Bad request |
| 401 | Unauthorized |
| 404 | Endpoint not found |
| 429 | Rate limited |

Example: 401
    Example: 401

  - `source` (string)

  - `exceptionType` (string)

  - `correlationId` (string)

  - `entityId` (string)

  - `errorCode` (string)

## Response 500 fields (application/json):

  - `details` (string)

  - `statusCode` (integer)
    Specifies the HTTP response status code.
This is the HTTP status code returned by the attempted delivery.
The following is a list of HTTP response status codes that include but are not limited to:
| HTTP Status | Meaning |
|  --- | --- |
| 200 | Delivery succeeded |
| 400 | Bad request |
| 401 | Unauthorized |
| 404 | Endpoint not found |
| 429 | Rate limited |

Example: 401
    Example: 401

  - `source` (string)

  - `exceptionType` (string)

  - `correlationId` (string)

  - `entityId` (string)

  - `errorCode` (string)

