# GET /api/billing-runs/merchant-history

Billing Runs: Gets one merchant's billing history across every run that included it.

Returns the merchant's per-run results. The reseller scope is resolved server-side from the
merchant, so reseller users can only query merchants under their own reseller.

**Operation ID:** `GET_api_billing-runs_merchant-history`

## Authorization

Requires: MerchantBilling.BillingRuns, merchant scope.

Required permissions:
- `MerchantBilling.BillingRuns`

## Parameters

| Name | In | Required | Type | Description |
| --- | --- | --- | --- | --- |
| MerchantId | query | no | string(uuid) | The merchant whose billing history is requested. The owning reseller scope is  resolved server-side from this merchant — callers cannot supply a reseller. |
| PeriodKey | query | no | string | Filter by period key (yyyyMM). |
| ResultStatus | query | no | PhoeniXGateMerchantBillingMerchantBillingRunResultStatus | Filter by this merchant's per-run result status. |
| IncludeDryRuns | query | no | boolean | When `false` (default) dry (preview) runs are excluded — history shows real  billing only. Set `true` to include previews. |
| CreatedFrom | query | no | string(date-time) | Inclusive lower bound on the run's creation time. |
| CreatedTo | query | no | string(date-time) | Exclusive upper bound on the run's creation time (the date-range chip emits  next-day-exclusive bounds). |
| Filter.Logic | query | no | PhoenixAbpCoreDataFilteringFilterLogic |  |
| Filter.Rules | query | no | array<PhoenixAbpCoreDataFilteringFilterRule> |  |
| Filter.Groups | query | no | array<PhoenixAbpCoreDataFilteringFilterGroup> |  |
| MaxResultCount | query | no | integer(int32) |  |
| ContinuationToken | query | no | string |  |
| Sorting.Field | query | no | string |  |
| Sorting.Descending | query | no | boolean |  |
| IncludeDeleted | query | no | boolean |  |
| IncludeInactive | query | no | boolean |  |
| suppressNulls | query | no | boolean | If true, omit properties with null values. |

## Responses

### 200

The requested page of merchant billing history.

**Content type:** `text/plain`

Schema: `PhoenixAbpCoreApplicationContractsContinuationPagedResultDtoOfPhoeniXGateMerchantBillingBillingRunsMerchantBillingHistoryItemDto`

**Content type:** `application/json`

Schema: `PhoenixAbpCoreApplicationContractsContinuationPagedResultDtoOfPhoeniXGateMerchantBillingBillingRunsMerchantBillingHistoryItemDto`

**Content type:** `text/json`

Schema: `PhoenixAbpCoreApplicationContractsContinuationPagedResultDtoOfPhoeniXGateMerchantBillingBillingRunsMerchantBillingHistoryItemDto`

### 404

No merchant exists with the specified id (or it is outside the caller's reseller scope).

### 403

Forbidden

**Content type:** `text/plain`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

**Content type:** `application/json`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

**Content type:** `text/json`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

### 401

Unauthorized

**Content type:** `text/plain`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

**Content type:** `application/json`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

**Content type:** `text/json`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

### 400

Bad Request

**Content type:** `text/plain`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

**Content type:** `application/json`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

**Content type:** `text/json`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

### 501

Not Implemented

**Content type:** `text/plain`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

**Content type:** `application/json`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

**Content type:** `text/json`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

### 500

Internal Server Error

**Content type:** `text/plain`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

**Content type:** `application/json`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

**Content type:** `text/json`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

### default

The request failed. The body carries the standard error envelope: a machine-readable `error.code`, a human-readable `error.message`, and `error.validationErrors` when the failure was a validation rejection. See the error-code reference in this document's description for the values `error.code` can take.

**Content type:** `application/json`

Schema: `WinkPGHttpRemoteServiceErrorResponse`

## See also

- [All documentation](https://docs.winkpg.io/llms.txt): the machine-readable index of every public page on this site.
