> For the complete documentation index, see [llms.txt](https://docs.ecwid.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ecwid.com/guides/payments/customize-payments/set-up-payment-fees.md).

# Set up payment fees

To add payment fees for your payment method, find it in REST API and update its details with a PUT request.

### Step 1. Find payment method ID with API call

Make a GET call to /profile/paymentOptions:

<mark style="color:green;">`GET`</mark> `https://app.ecwid.com/api/v3/{storeId}/profile/paymentOptions?responseFields=id,appClientId`

In response, you’ll see a JSON with payment options:

```json
[
    {
        "id": "13379-1606718590771",
        "appClientId": ""
    },
    {
        "id": "1272790545-1729232856479",
        "appClientId": "custom-app-15695068-1"
    }
]

```

Parse the response and find the one, where the `appClientId` value matches with your app’s client\_id.

### Step 2. Update fees for the payment method with API call

After getting the ID, use it in a second PUT call that adds a fee to the payment method. The fee has two settings: `type` that defines if the fee is added as a percent of the order total (`PERCENT`) or a flat value ( `ABSOLUTE`) and the value itself (`value` field).

Request example:

```json
PUT https://app.ecwid.com/api/v3/15695068/profile/paymentOptions/1272790545-1729232856479

{
    "paymentSurcharges": {
        "type": "PERCENT",
        "value": 10
    }
}
```

In response, you’ll see `200 OK` HTTP status with the response body:

```json
{
    "updateCount": 1
}
```

This means that you’ve successfully added a fee to the payment method.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.ecwid.com/guides/payments/customize-payments/set-up-payment-fees.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
