# Search historical payouts

Use the **searchPayouts** method to extract information on the historical payouts issued by 2Checkout for your account.

You can retrieve information on the payment for a specific invoice, or search based on numerous filters such as payment status, transfer date, or payout method.

## Search filters <a href="#search-filters" id="search-filters"></a>

| Parameter           | Type / Description                                                                                                                                                                                                                                                                           |
| ------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `Reference`         | <p><strong>Optional (string)</strong></p><p>InvoicePrefix (PREFIX) + InvoiceNo (00000) will search for transfers containing an invoice with prefix + number.</p><p>The invoice reference is generated by 2Checkout and can be found in the Accounting area from your Control Panel.</p>      |
| `Status`            | <p><strong>Optional (array of strings)</strong></p><p>Possible payout statuses:</p><ul><li>PAID  - 2Checkout transfers successfully paid.</li><li>PARTIALLY\_PAID  - 2Checkout transfers that partially covered invoice amounts.</li><li>CANCELED  - 2Checkout canceled transfers.</li></ul> |
| `Currency`          | <p><strong>Optional (string)</strong></p><p>3 letter ISO currency code.</p>                                                                                                                                                                                                                  |
| `StartDate`         | <p><strong>Optional (string)</strong></p><p>Start payment date. Format: Yyyy-mm-dd.</p>                                                                                                                                                                                                      |
| `EndDate`           | <p><strong>Optional (string)</strong></p><p>End payment date. Format: Yyyy-mm-dd.</p>                                                                                                                                                                                                        |
| `PaymentType`       | <p><strong>Optional (string)</strong></p><p>Possible payout methods:</p><ul><li>WIRE</li><li>PAYPAL</li><li>CHECK</li><li>PAYONEER</li><li>WEBMONEY</li></ul>                                                                                                                                |
| `OrderBy`           | <p><strong>Optional (array of objects)</strong></p><p>Details below</p>                                                                                                                                                                                                                      |
| `OrderBy.Field`     | <p><strong>String</strong></p><p>Variable used for ordering the returned data. Possible values:</p><ul><li><code>TransferCompletionDate</code> - payment remittance date.</li></ul>                                                                                                          |
| `OrderBy.Direction` | <p><strong>String</strong></p><p>Order direction. Possible values:</p><ul><li>ASC - for ascending order.</li><li>DESC - for descending order.</li></ul>                                                                                                                                      |
| `Pagination`        | <p><strong>Optional (object)</strong></p><p>Use this object for paginating the results.</p><p>Default behavior is to display 10 results per page.</p>                                                                                                                                        |
| `Pagination.Page`   | <p><strong>Integer</strong></p><p>Number of pages used for displaying results.</p>                                                                                                                                                                                                           |
| `Pagination.Limit`  | <p><strong>Integer</strong></p><p>Limit the number of results.</p>                                                                                                                                                                                                                           |

### Request sample <a href="#request" id="request"></a>

```php
<?php

require('PATH_TO_AUTH');

$SearchOptions = new stdClass();
//$SearchOptions->Reference = 'FBV8572'; // search for a specific invoice
$SearchOptions->Status = ['PAID', 'CANCELED'];
$SearchOptions->Currency = 'USD';
$SearchOptions->StartDate = '2018-05-01';
$SearchOptions->EndDate = '2018-06-01';
$SearchOptions->PaymentType = 'WIRE';
$SearchOptions->OrderBy = [];
$orderBy = new stdClass();
$orderBy->Field = 'TransferCompletionDate';
$orderBy->Direction = 'DESC';
$SearchOptions->OrderBy[] = $orderBy;
$SearchOptions->Pagination = new stdClass();
//$SearchOptions->Pagination->Page = 1;
//$SearchOptions->Pagination->Limit = 200;

try {
    $subscriptionInfo = $client->searchPayouts($sessionID, $SearchOptions);
}
catch (SoapFault $e) {
    echo "AccountPayouts: " . $e->getMessage();
    exit;
}
var_dump("Payouts", $subscriptionInfo);

```

## Response parameters <a href="#response" id="response"></a>

### Historical payout object <a href="#historical-payout-object" id="historical-payout-object"></a>

| Parameter                                             | Type / Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| ----------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `Items`                                               | <p><strong>Array  of objects</strong></p><p>Details below</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |
| `PaymentInstance`                                     | <p><strong>Object</strong></p><p>Details below</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| `PaymentInstance.TransferCompletionDate`              | <p><strong>String</strong><br>Payment date. Format: Yyyy-mm-dd.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| `PaymentInstance.PaymentType`                         | <p><strong>String</strong></p><p>Payout method used for the transfer. Possible values:</p><ul><li>WIRE</li><li>PAYPAL</li><li>CHECK</li><li>PAYONEER</li><li>WEBMONEY</li></ul>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| `PaymentInstance.Amount`                              | <p><strong>Float</strong><br>Amount transferred. Can be negative, for invoices deducted from your payment.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| `PaymentInstance.Currency`                            | <p><strong>String</strong><br>Currency in which the amount was transferred. Three letters ISO currency code.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| `PaymentInstance.Status`                              | <p><strong>String</strong></p><p>Payment status. Possible values:</p><ul><li>PAID  - 2Checkout transfers successfully paid.</li><li>NOT\_PAID  - 2Checkout unpaid balance amounts.</li><li>PARTIALLY\_PAID  - 2Checkout transfers that partially covered invoice amounts.</li><li>CANCELED  - 2Checkout canceled transfers.</li></ul>                                                                                                                                                                                                                                                                                                                                                 |
| `PaymentInstance.Invoices`                            | <p><strong>Array of objects</strong></p><p>An object is created for each invoice part of the payment.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
| `PaymentInstance.Invoices.Reference`                  | <p><strong>String</strong><br>System generated invoice reference. Formed by InvoicePrefix (PREFIX) + InvoiceNo (00000).</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| `PaymentInstance.Invoices.Amount`                     | <p><strong>Float</strong><br>Invoice amount.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| `PaymentInstance.Invoices.Description`                | <p><strong>String</strong><br>Comments submitted on the invoice.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| `PaymentInstance.Invoices.Type`                       | <p><strong>String</strong></p><p>Invoice type. Possible values:</p><ul><li>Period net sales</li><li>Retain chargebacks</li><li>Release chargeback</li><li>Services</li></ul>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| `PaymentInstance.Invoices.Code`                       | <p><strong>String</strong></p><p>Code used for identifying the invoice type. Possible values:</p><ul><li>PERIOD\_NET\_SALES</li><li>DISPUTES\_BALANCE\_HOLD</li><li>DISPUTES\_BALANCE\_RELEASE</li><li>AFFILIATE\_BONUSES</li><li>AFFILIATE\_BONUS\_COMMISSION</li><li>CANCELED\_PO</li><li>ROLLING\_RESERVE\_HOLD</li><li>ROLLING\_RESERVE\_RELEASE</li><li>CLOSED\_CHARGEBACK\_FEES</li><li>OPEN\_CHARGEBACK\_FEES</li><li>CUSTOM\_FEE</li><li>CHARGEBACK\_FUND</li><li>CHANNEL\_MANAGER\_SALES</li><li>MONTHLY\_FEE</li><li>COMMITMENT\_FEE</li><li>OVERDUE\_PO\_PAYMENTS</li><li>PENDING\_PO\_PAYMENTS</li><li>RRT\_FEES</li><li>TRANSFER\_FEE</li><li>UNILOC\_DISCOUNT</li></ul> |
| `PaymentInstance.Invoices.Date`                       | <p><strong>String</strong><br>Date the invoice was generated.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| `PaymentInstance.Invoices.PaidAmount`                 | <p><strong>Float</strong><br>Invoice amount paid on this transfer.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| `PaymentInstance.Invoices.PaidDate`                   | <p><strong>String</strong><br>Transfer date.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| `PaymentInstance.Invoices.PaidCurrency`               | <p><strong>String</strong><br>Currency of the transfer.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| `PaymentInstance.Summary`                             | <p><strong>Object</strong></p><p>A summary of all the invoices included in this transfer.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |
| `PaymentInstance.Summary.ServicesAmount`              | <p><strong>Float</strong><br>Amount paid or retained for 2Checkout service invoices.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| `PaymentInstance.PurchaseOrdersAmount`                | <p><strong>Float</strong><br>Amount paid for purchase orders.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| `PaymentInstance.ChargeBacksAmount`                   | <p><strong>Float</strong><br>Amount paid for chargebacks retained and released.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| `PaymentInstance.RollingReserveAmount`                | <p><strong>Float</strong><br>Amount paid for rolling reserves.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| `PaymentInstance.RollingReserveAmount.PeriodNetSales` | <p><strong>Float</strong><br>Amount paid for period net sales.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| `PaymentInstance.RollingReserveAmount.VendorToVendor` | <p><strong>Float</strong><br>Amount paid for vendor 2 vendor invoices.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| `PaymentInstance.RollingReserveAmount.ChargeBackFund` | <p><strong>Float</strong><br>Amount paid for the chargeback fund.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| `PaymentInstance.Pagination`                          | <p><strong>Object</strong></p><p>Details below</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| `PaymentInstance.Pagination.Page`                     | <p><strong>Integer</strong><br>Number of pages used for displaying the results.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| `PaymentInstance.Pagination.Limit`                    | <p><strong>Integer</strong><br>Limitation of the result numbers.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| `PaymentInstance.Pagination.Count`                    | <p><strong>Integer</strong><br>Total number of results.</p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |


---

# 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.2checkout.com/soap-api-reference/soap-api-6.0/api-requests/account-payouts/search-historical-payouts.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.
