# Collect Payment

<mark style="color:orange;">`POST`</mark> /v3/customers/me/agreements/<mark style="color:orange;">{agreementId}</mark>/transactions/payment

## Request

The details below help you form your HTTP requests to this endpoint.

### Headers

You may need to provide specific headers.

<table><thead><tr><th>Name</th><th>Type</th><th data-type="checkbox">Required</th><th>Description</th></tr></thead><tbody><tr><td>customer-token</td><td>string</td><td>true</td><td>Customer's authentication token</td></tr><tr><td>x-version-override</td><td>string</td><td>false</td><td>N/A</td></tr></tbody></table>

### Path Parameters

The endpoint path expects parameters.

<table><thead><tr><th>Name</th><th>Type</th><th data-type="checkbox">Required</th><th>Description</th></tr></thead><tbody><tr><td>agreementId</td><td>string</td><td>true</td><td>Agreement Id</td></tr></tbody></table>

### Body

You must provide a JSON payload.

<table><thead><tr><th>Name</th><th>Type</th><th data-type="checkbox">Required</th><th>Description</th></tr></thead><tbody><tr><td>paymentMethodId</td><td>string</td><td>true</td><td>Payment Method Id</td></tr><tr><td>amount</td><td>number</td><td>true</td><td>Amount</td></tr></tbody></table>

## Response

The details below help you understand the responses you could get from this endpoint.

### Samples

Below are samples of responses, with tabs corresponding to returned status code.

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

```javascript
[
    {
        "paymentId": "682799b08737e7663dc31f32",
        "amount": 2,
        "failureReason": "DECLINE CHECK CHECK LIMIT EXCEEDED",
        "failureCode": "123"
    }
]
```

{% endtab %}
{% endtabs %}

### Schema

The response's schema is outlined below.

<table><thead><tr><th>Name</th><th>Type</th><th data-type="checkbox">Required</th><th>Description</th></tr></thead><tbody><tr><td>data</td><td>array</td><td>false</td><td>N/A</td></tr><tr><td>data[].paymentId</td><td>string</td><td>true</td><td>Payment ID</td></tr><tr><td>data[].amount</td><td>number</td><td>true</td><td>Amount</td></tr><tr><td>data[].outcome</td><td>string</td><td>true</td><td>Outcome</td></tr><tr><td>data[].failureReason</td><td>string</td><td>false</td><td>Failure Reason</td></tr><tr><td>data[].failureCode</td><td>string</td><td>false</td><td>Failure Code</td></tr></tbody></table>
