К содержанию
TelegaFirst

Для AI-агентов: markdown этой страницы — /docs/api-op-createorder.mdиндекс документации — /llms.txt

createOrder

Обновлено

POST /api/v1/orders

createOrder

Авторизация и права

Scopes: ALL. Auth alternatives: OR; scopes внутри альтернативы: ALL.

ПолеЗначение
security.0.hubApiKey[]
security.1.hubBearer[]
securitySchemes.hubApiKey.in"header"
securitySchemes.hubApiKey.name"X-Api-Key"
securitySchemes.hubApiKey.type"apiKey"
securitySchemes.hubBearer.scheme"bearer"
securitySchemes.hubBearer.type"http"
x-required-scopes["orders"]

Параметры запроса

ПолеЗначение
0.description"Required for nonempty POST bodies; optional for an empty refresh body."
0.in"header"
0.name"Idempotency-Key"
0.requiredtrue
0.schema0.schema

Тело запроса

ПолеЗначение
content.application/json.schemaCreateOrderRequest
requiredtrue

Ответы

ПолеЗначение
201.content.application/json.schemaCreateOrderResponse
201.description"Create external order"

Ошибки

ПолеЗначение
400.content.application/problem+json.schemaProblemDetails
400.description"The accepted pricing quote is malformed, forged, or bound to a different tenant, subject, surface, zone, or basket"
401.content.application/problem+json.schemaProblemDetails
401.description"Missing or invalid authentication"
403.content.application/problem+json.schemaProblemDetails
403.description"The caller lacks the orders scope or tenant access"
404.content.application/problem+json.schemaProblemDetails
404.description"A product or requested user was not found for this tenant"
409.content.application/problem+json.schema409.content.application/problem+json.schema
409.description"The accepted quote is stale. `details.freshQuote` contains the sole new six-field signed quote; retry with a new Idempotency-Key."
422.content.application/problem+json.schemaProblemDetails
422.description"The basket is invalid or a RU fiscal route requires a valid buyer email or phone (YooKassa requires email)"
428.content.application/problem+json.schemaProblemDetails
428.description"An accepted six-field pricing quote is required"

Дополнительные условия

ПолеЗначение
operationId"createOrder"
tags["orders"]
x-idempotency"http-cache"