# 2. List (ByConnection)

<mark style="color:green;">`POST`</mark> `{{Base Address}}/api/terminal/`<mark style="color:red;">`{ConnectionId}`</mark>`/list`

It will be sufficient to send a request to the address provided above. You can use the 'Base Address' as you wish for both the test environment and the live environment.

{% hint style="info" %}
Important: To use the **Connection List** service, you need to send the 'apikeyprivate' and '**apiclientprivate**' **parameters** in the 'Header' field.

\
[<mark style="color:green;">**PhysicalAPI Ad**</mark>](/payment-orchestration-integration-document/environment.md)<mark style="color:green;">**dress**</mark>
{% endhint %}

**The header information that needs to be sent to the service is as follows:**

<table><thead><tr><th width="243">Parameter</th><th width="106.33333333333331">Type</th><th width="144">Compulsory</th><th>Description</th></tr></thead><tbody><tr><td>apikeyprivate</td><td>string</td><td>Yes</td><td>The Private Key obtained from the member merchant panel.</td></tr><tr><td>apiclientprivate</td><td>string</td><td>Yes</td><td>The Private Client obtained from the member merchant panel.</td></tr></tbody></table>

**The body information that needs to be sent to the service is as follows:**

{% tabs %}
{% tab title="JSON" %}

```json
{
  "pageIndex": 0,
  "pageSize": 10
}
```

{% endtab %}
{% endtabs %}

**The response returned from the service:**

<table><thead><tr><th width="182">Parameter</th><th width="107.33333333333331">Type</th><th>Description</th></tr></thead><tbody><tr><td>Result</td><td>object</td><td>It returns the details of the service.</td></tr><tr><td>ErrorCode</td><td>int</td><td>Error code. If the transaction is successful, it returns a value of '0'.</td></tr><tr><td>Succeeded</td><td>bool</td><td>It returns a true or false value. If the transaction is <mark style="color:green;">successful</mark>, it returns the value 'true'.</td></tr><tr><td>Failed</td><td>bool</td><td>Returns a true or false value. <mark style="color:red;">Returns</mark> “true” if the operation fails.</td></tr><tr><td>Message</td><td>string</td><td>If the transaction is faulty, this is the error message specified, which provides language support according to the locale parameter.</td></tr><tr><td>ClientMessage</td><td>string</td><td>It returns the fixed values of Paywall error codes. You can map them accordingly.</td></tr></tbody></table>

{% tabs %}
{% tab title="JSON" %}
{% code overflow="wrap" lineNumbers="true" %}

```json5
{
    "Result": {
        "Items": [
            {
                "Id": "c5e049d4-626f-4e0e-81a9-18a4e9da0e32",
                "ConnectionId": "70b2190b-e47b-455f-b05e-8c132a05534c",
                "BrandId": 10,
                "ProviderId": 10,
                "RegionId": 1,
                "ConnectionName": "Varsayılan 1",
                "SourceId": null,
                "TerminalId": "10177",
                "SerialNo": "PAV960000015-passive",
                "SourceCreatedDate": null,
                "SourceUpdateDate": null,
                "MerchantId": "1308"
            },
            {
                "Id": "3332d81c-e047-4bef-8385-6f8eba337fac",
                "ConnectionId": "1b63d83f-d8ba-4476-9886-4b2f1d103e74",
                "BrandId": 10,
                "ProviderId": 30,
                "RegionId": 1,
                "ConnectionName": "Varsayılan 2",
                "SourceId": null,
                "TerminalId": "10040",
                "SerialNo": "PAV860027766",
                "SourceCreatedDate": null,
                "SourceUpdateDate": null,
                "MerchantId": "1308"
            },
            {
                "Id": "ead51e59-33ea-49e3-bd47-19673794dce9",
                "ConnectionId": "1b63d83f-d8ba-4476-9886-4b2f1d103e74",
                "BrandId": 10,
                "ProviderId": 30,
                "RegionId": 1,
                "ConnectionName": "Varsayılan 2",
                "SourceId": null,
                "TerminalId": "10177",
                "SerialNo": "PAV960000015-passive",
                "SourceCreatedDate": null,
                "SourceUpdateDate": null,
                "MerchantId": "1308"
            },
            {
                "Id": "38e895c3-1a9a-4b73-8816-8557d1d031d6",
                "ConnectionId": "70b2190b-e47b-455f-b05e-8c132a05534c",
                "BrandId": 10,
                "ProviderId": 10,
                "RegionId": 1,
                "ConnectionName": "Varsayılan 1",
                "SourceId": null,
                "TerminalId": "10040",
                "SerialNo": "PAV860027766",
                "SourceCreatedDate": null,
                "SourceUpdateDate": null,
                "MerchantId": "1308"
            }
        ],
        "Pagination": {
            "CurrentPage": 0,
            "PageCount": 1,
            "PageSize": 10,
            "TotalCount": 4
        }
    },
    "Failed": false,
    "Message": null,
    "ClientMessage": null,
    "Succeeded": true
}
```

{% endcode %}
{% endtab %}
{% endtabs %}


---

# 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://developer.paywall.one/payment-orchestration-integration-document/physical-pos/3.-terminal/2.-list-byconnection.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.
