POST /api/v3/private/exchange/routes/{route}/fields/{group}/{field}/files HTTP/1.1
Host: your-exchange
Accept: application/json
Authorization: Bearer <token>
X-Api-Signature-Version: v2
X-Api-Timestamp: <unix_timestamp>
X-Api-Nonce: <nonce>
X-Api-Signature: sha256=<hex_digest>
Idempotency-Key: <idempotency_key>
Content-Type: multipart/form-data; boundary=example-boundary
--example-boundary
Content-Disposition: form-data; name="file"; filename="<filename>"
Content-Type: <file_content_type>
<байты файла>
--example-boundary--
{
"state": 0,
"message": "<string>",
"result": {
"file": {
"token": "<string>",
"public_id": "<string>",
"name": "<string>",
"extension": "<string>",
"mime_type": "<string>",
"size_bytes": 123,
"expires_at": "2023-11-07T05:31:56Z"
}
},
"meta": {
"request_id": "<string>",
"correlation_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"pagination": {
"mode": "page",
"current_page": 2,
"per_page": 2,
"total": 1,
"last_page": 2,
"from": 123,
"to": 123,
"has_more": true
},
"filters": {},
"sort": [
"<string>"
],
"summary": {
"total": 123,
"bonus_sum": "<string>",
"currency": "<string>",
"confirmed_accruals": 123,
"by_currency": [
{
"currency": "<string>",
"bonus_sum": "<string>",
"confirmed_accruals": 123
}
]
}
}
}Файлы
Загрузить файл для поля заявки
Возвращает одноразовый токен, привязанный к авторизованной интеграции, направлению и полю. Для группы user передайте массив токенов в user_fields[field_key] до истечения срока.
POST
/
private
/
exchange
/
routes
/
{route}
/
fields
/
{group}
/
{field}
/
files
POST /api/v3/private/exchange/routes/{route}/fields/{group}/{field}/files HTTP/1.1
Host: your-exchange
Accept: application/json
Authorization: Bearer <token>
X-Api-Signature-Version: v2
X-Api-Timestamp: <unix_timestamp>
X-Api-Nonce: <nonce>
X-Api-Signature: sha256=<hex_digest>
Idempotency-Key: <idempotency_key>
Content-Type: multipart/form-data; boundary=example-boundary
--example-boundary
Content-Disposition: form-data; name="file"; filename="<filename>"
Content-Type: <file_content_type>
<байты файла>
--example-boundary--
{
"state": 0,
"message": "<string>",
"result": {
"file": {
"token": "<string>",
"public_id": "<string>",
"name": "<string>",
"extension": "<string>",
"mime_type": "<string>",
"size_bytes": 123,
"expires_at": "2023-11-07T05:31:56Z"
}
},
"meta": {
"request_id": "<string>",
"correlation_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"pagination": {
"mode": "page",
"current_page": 2,
"per_page": 2,
"total": 1,
"last_page": 2,
"from": 123,
"to": 123,
"has_more": true
},
"filters": {},
"sort": [
"<string>"
],
"summary": {
"total": 123,
"bonus_sum": "<string>",
"currency": "<string>",
"confirmed_accruals": 123,
"by_currency": [
{
"currency": "<string>",
"bonus_sum": "<string>",
"confirmed_accruals": 123
}
]
}
}
}English version
Подпишите запрос HMAC v2. Требуется право
public-api:files:write. Принимает заголовок Idempotency-Key.
Связанные методы
POST /api/v3/private/exchange/routes/{route}/fields/{group}/{field}/files HTTP/1.1
Host: your-exchange
Accept: application/json
Authorization: Bearer <token>
X-Api-Signature-Version: v2
X-Api-Timestamp: <unix_timestamp>
X-Api-Nonce: <nonce>
X-Api-Signature: sha256=<hex_digest>
Idempotency-Key: <idempotency_key>
Content-Type: multipart/form-data; boundary=example-boundary
--example-boundary
Content-Disposition: form-data; name="file"; filename="<filename>"
Content-Type: <file_content_type>
<байты файла>
--example-boundary--
Авторизации
Заголовки
Обязательная версия подписи запроса. Укажите v2 первой строкой канонического представления. Восьмой строкой добавьте Idempotency-Key без крайних пробелов или пустую строку при отсутствии ключа. Подписывайте исходные значения разобранного query.
Allowed value:
"v2"