Перейти к основному содержимому

Envelope[ItemLookupResponse]

data object
anyOf
items object[]required
  • Array [
  • error object
    anyOf
    string

    Possible values: [service_not_found, item_not_found, upstream_error]

    foundFoundrequired
    item object
    anyOf
    amountIsQuantityAmountisquantity

    true when the item is a quantity-mode DTU (e.g. Telegram Stars, TON). The amount value sent in POST /orders and POST /dtu/validation must then be an integer count of units.

    Default value: false
    currencyCurrencyrequired
    idIdrequired
    inStockInstockrequired
    isLongOrder object

    Whether long orders are supported for this item. When true, you may set isLongOrder=true in POST /orders (shop orders only).

    anyOf
    boolean
    maxQuantity object

    Maximum allowed quantity. Present only when amountIsQuantity=true.

    anyOf
    integer
    minQtyToLongOrder object

    Minimum quantity for which a long order is allowed. Present only when isLongOrder=true.

    anyOf
    integer
    minQuantity object

    Minimum allowed quantity. Present only when amountIsQuantity=true.

    anyOf
    integer
    name object
    anyOf
    string
    pricePricerequired
    stepQuantity object

    Allowed step between quantities. Present only when amountIsQuantity=true.

    anyOf
    integer
    unitPrice object

    Per-unit base price in USD. Present only when amountIsQuantity=true; final price is computed as quantity × unitPrice (plus any tariff markup).

    anyOf
    string
    itemIdItemidrequired
    serviceIdServiceidrequired
  • ]
  • errorCode object
    anyOf
    string
    errors object
    anyOf
  • Array [
  • codeFieldErrorCoderequired

    Possible values: [MISSING, OUT_OF_RANGE, INVALID_FORMAT, INVALID_VALUE, NOT_ALLOWED, TOO_LONG, TOO_SHORT]

    fieldFieldrequired
    messageMessagerequired
  • ]
  • statusTransactionStatusrequired

    Possible values: [SUCCESS, IN_PROGRESS, PARTIALLY_COMPLETED, CANCELLED]

    statusCodeStatusCoderequired

    Possible values: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]

    statusMessageStatusmessagerequired
    traceIdTraceidrequired
    Envelope[ItemLookupResponse]
    {
    "data": {
    "items": [
    {
    "error": "service_not_found",
    "found": true,
    "item": {
    "amountIsQuantity": false,
    "currency": "string",
    "id": "string",
    "inStock": 0,
    "isLongOrder": true,
    "maxQuantity": 0,
    "minQtyToLongOrder": 0,
    "minQuantity": 0,
    "name": "string",
    "price": 0,
    "stepQuantity": 0,
    "unitPrice": "string"
    },
    "itemId": "string",
    "serviceId": "string"
    }
    ]
    },
    "errorCode": "string",
    "errors": [
    {
    "code": "MISSING",
    "field": "string",
    "message": "string"
    }
    ],
    "status": "SUCCESS",
    "statusCode": 0,
    "statusMessage": "string",
    "traceId": "string"
    }