> 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/changelog/may-2025/may-16/updated-encryption-mode-for-payment-api-requests.md).

# Updated encryption mode for payment API requests

#### What's new

Backend processing of any online payment in Ecwid store starts with receiving a <mark style="color:blue;">`POST`</mark> request from Ecwid API to your `paymentUrl` endpoint. The incoming request contains an encrypted JSON with the order data.

From now on, the order data is encrypted with the `aes-128-gcm` mechanism instead of `aes-128-cbc`, and the encrypted data is stored in the `enc_data` JSON object instead of the `data`.

{% hint style="warning" %}
**Breaking changes!**

This change will become backwards incompatible in the future. It's best to update payment applications now to ensure they continue working without any issues.&#x20;
{% endhint %}

#### Changes in API

<mark style="color:blue;">`POST`</mark> requests coming to the `paymentUrl` endpoint now have two JSON objects with the order data:

* The new `enc_data` object encrypted with the `aes-128-gcm` mechanism.&#x20;

Documentation now includes parse examples for this method: [Broken mention](broken://spaces/bMnrDOrph8biE23TpY18/pages/LhHI1LK21XqlqOudlTFV)<br>

* Old `data` object that uses `aes-128-cbc` for encryption.&#x20;

{% hint style="danger" %}
The `data` object that uses `aes-128-cbc` encryption will become deprecated in the future.\
You can still find code example using the [Sample payment app](/guides/payments/sample-payment-app.md).
{% endhint %}

#### Documentation links

{% content-ref url="/spaces/bMnrDOrph8biE23TpY18/pages/fkhtJxsOdYxW2SuJGLTJ" %}
[Broken mention](broken://spaces/bMnrDOrph8biE23TpY18/pages/fkhtJxsOdYxW2SuJGLTJ)
{% endcontent-ref %}


---

# 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 dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.ecwid.com/changelog/may-2025/may-16/updated-encryption-mode-for-payment-api-requests.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
