S
docs.syncra.money
Профиль мерчанта
PATCH/api/v1/p2p/my-merchantСтейдж

Частичное обновление собственного профиля мерчанта: name, webhook_url, withdrawal_address, success_redirect_url, fail_redirect_url, checkout_brand_name, finance_chat_id, appeal_chat_id, ip_whitelist и три лимита сделок. Семантика указателей лимитов: отсутствует = без изменений, 0 = снят (NULL), >0 = задан (в минорных единицах). Пара min/max проверяется на согласованность. Статус, балансы и комиссии — только для админов. Аутентификация: JWT кабинета.

Authorization

bearerAuth
AuthorizationBearer <token>

JWT сессии кабинета (заголовок Authorization, схема Bearer) — используется эндпоинтом /api/v1/p2p/my-merchant.

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Частичное обновление — передавайте только изменённые поля. Указатели лимитов — отсутствует = без изменений, 0 = снят, >0 = задан.

Response Body

application/json

application/problem+json

application/problem+json

curl -X PATCH "https://example.com/api/v1/p2p/my-merchant" \  -H "X-Merchant-Token: <MERCHANT_TOKEN>" \  -H "X-Timestamp: <UNIX_TIMESTAMP>" \  -H "X-Signature: t=<UNIX_TIMESTAMP>,v1=<HEX_HMAC_SHA256>" \  -H "Content-Type: application/json" \  -d '{    "deal_min_amount": "100000",    "daily_deal_amount_limit": "10000000"  }'
{  "merchant": {    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",    "name": "string",    "email": "string",    "status": "string",    "kill_switch": true,    "kill_switch_reason": "string",    "balance_usdt": "string",    "escrow_usdt": "string",    "trc20_address": "string",    "project_url": "string",    "checkout_brand_name": "string",    "success_redirect_url": "string",    "fail_redirect_url": "string",    "finance_chat_id": "string",    "appeal_chat_id": "string",    "ip_whitelist": [      "string"    ],    "api_token": "string",    "withdrawal_address": "string",    "moderation_status": "string",    "api_version": "string",    "webhook_url": "string",    "created_at": "2019-08-24T14:15:22Z",    "updated_at": "2019-08-24T14:15:22Z",    "deal_min_amount": "string",    "deal_max_amount": "string",    "daily_deal_amount_limit": "string"  },  "auto_withdrawal_mode": "AUTO_UP_TO_LIMIT",  "auto_withdrawal_effective_limit_usdt_cents": "string"}
{  "type": "../dictionary",  "title": "string",  "status": 0,  "detail": "string",  "instance": "../dictionary",  "errors": [    {      "field": "amount",      "message": "must be greater than 0",      "code": "POSITIVE_REQUIRED"    }  ]}
{  "type": "../dictionary",  "title": "string",  "status": 0,  "detail": "string",  "instance": "../dictionary",  "errors": [    {      "field": "amount",      "message": "must be greater than 0",      "code": "POSITIVE_REQUIRED"    }  ]}