White Spirit API
API к ферме ККТ (кассовые аппараты)
Receipts ¶
Пробить чек ¶
Пробить чекPOST/v1/receipts
Метод, который синхронно пробивает чек на одной из касс в пуле.
Example URI
- group
string
(required)- wait4free
string
(required)- retry_count
string
(required)
Headers
Accept: application/json
Schema
{
"type": "object",
"description": "Запрос на создание чека",
"properties": {
"receipt_content": {
"type": "object",
"description": "Содержимое чека",
"required": [
"firm_inn",
"receipt_type",
"taxation_type",
"firm_reply_email",
"firm_url",
"agent_type",
"client_email_or_phone",
"rows",
"payments"
],
"properties": {
"firm_inn": {
"type": "string",
"description": "ИНН компании"
},
"receipt_type": {
"type": "string",
"enum": [
"income",
"return_income",
"charge",
"return_charge"
],
"description": "Тип чека (income - Приход, return_income - Возврат прихода, charge - Расход, return_charge - Возврат расхода)"
},
"taxation_type": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
],
"description": "Применяемая в чеке система налогообложения"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"client_email_or_phone": {
"type": "string",
"description": "Электронная почта или телефон клиента"
},
"supplier_phone": {
"type": "string",
"description": "Телефон поставщика"
},
"firm_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
},
"firm_url": {
"type": "string",
"description": "URL фирмы"
},
"additional_document_requisite": {
"type": "string",
"description": "Дополнительный реквизит документа (16 байт)"
},
"additional_user_requisite": {
"type": "object",
"description": "Дополнительный реквизит пользователя",
"properties": {
"name": {
"type": "string",
"description": "Наименование реквизита (64 байта)"
},
"value": {
"type": "string",
"description": "Значение реквизита (256 байт)"
}
}
},
"rows": {
"type": "array",
"items": {
"type": "object",
"description": "Описание позиции чека",
"required": [
"price",
"qty",
"tax_type",
"payment_type_type",
"text"
],
"properties": {
"price": {
"type": "string",
"description": "Цена"
},
"qty": {
"type": "string",
"description": "Количество"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"payment_type_type": {
"type": "string",
"enum": [
"prepayment",
"full_prepayment_wo_delivery",
"ip_payment",
"partial_prepayment_wo_delivery",
"full_payment_w_delivery",
"partial_payment_w_delivery",
"credit_w_delivery",
"credit_after_delivery"
],
"description": "Признак способа расчета"
},
"text": {
"type": "string",
"description": "Наименование"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"supplier_info": {
"type": "object",
"description": "Данные поставщика",
"required": [
"inn"
],
"properties": {
"inn": {
"type": "string",
"description": "ИНН поставщика"
},
"name": {
"type": "string",
"description": "Наименование поставщика"
},
"phone": {
"type": "string",
"description": "Телефон поставщика"
}
}
}
}
}
},
"payments": {
"type": "array",
"items": {
"type": "object",
"description": "Описание оплаты / Описание коррекции",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты. card -- электронным денежным средством, неденежные: prepayment -- предоплатой (зачетом аванса и (или) предыдущих платежей), credit -- постоплатой (в кредит), extension -- встречным представлением"
}
}
}
}
}
},
"conditional": {
"type": "object",
"description": "Условное выполнение",
"properties": {
"dialect": {
"type": "string",
"enum": [
"hy"
],
"description": "hy -- http://docs.hylang.org/en/stable/index.html"
},
"conditions": {
"type": "array",
"items": {
"type": "object",
"properties": {
"condition": {
"type": "string",
"enum": [
"accept_device",
"after",
"before",
"after_select_device"
],
"description": "accept_device -- фильтрация устройства, after -- выполняется сразу после пробития чека (для тестирования)"
},
"expression": {
"type": "string",
"description": "Условие на диалекте"
}
}
}
}
}
},
"trace": {
"type": "object",
"description": "Информация для отслежевания чека в логах"
}
},
"required": [
"receipt_content"
]
}
200
Пробитый чек
Headers
Content-Type: application/json
Body
{
"location": {
"address": "aliquip Ut commodo"
},
"document_index": 92053827
}
Schema
{
"type": "object",
"description": "Фискальный чек",
"properties": {
"id": {
"type": "number",
"format": "long",
"description": "Номер документа в ФН"
},
"dt": {
"type": "string",
"format": "date-time",
"description": "Дата и время сохранения (с точностью до минуты) документа в ФН"
},
"fp": {
"type": "number",
"format": "long",
"description": "Фискальный признак"
},
"shift_number": {
"type": "number",
"format": "long",
"description": "Номер смены"
},
"document_index": {
"type": "number",
"format": "long",
"description": "Номер чека за смену"
},
"ofd_ticket_received": {
"type": "boolean",
"description": "Отправлен ли документ в ОФД"
},
"check_url": {
"type": "string",
"description": "URL для просмотра чека пользователем"
},
"localzone": {
"type": "string",
"description": "Название часового пояса по месту расчета"
},
"origin": {
"type": "string",
"enum": [
"online",
"kkt_fn",
"fn"
],
"description": "Источник происхождения чека"
},
"receipt_extra_contnent": {
"type": "object"
},
"firm": {
"type": "object",
"description": "Компания пробившая чек",
"properties": {
"inn": {
"type": "string",
"description": "ИНН компании"
},
"name": {
"type": "string",
"description": "Наименование компании"
},
"reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
}
}
},
"fn": {
"type": "object",
"description": "Фискальный накопитель",
"properties": {
"sn": {
"type": "string",
"description": "заводской номер ФН. Глобальный уникальный идентификатор"
},
"model": {
"type": "string",
"description": "модель ФН"
}
}
},
"receipt_content": {
"type": "object",
"description": "Содержимое чека",
"required": [
"firm_inn",
"receipt_type",
"taxation_type",
"firm_reply_email",
"firm_url",
"agent_type",
"client_email_or_phone",
"rows",
"payments"
],
"properties": {
"firm_inn": {
"type": "string",
"description": "ИНН компании"
},
"receipt_type": {
"type": "string",
"enum": [
"income",
"return_income",
"charge",
"return_charge"
],
"description": "Тип чека (income - Приход, return_income - Возврат прихода, charge - Расход, return_charge - Возврат расхода)"
},
"taxation_type": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
],
"description": "Применяемая в чеке система налогообложения"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"client_email_or_phone": {
"type": "string",
"description": "Электронная почта или телефон клиента"
},
"supplier_phone": {
"type": "string",
"description": "Телефон поставщика"
},
"firm_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
},
"firm_url": {
"type": "string",
"description": "URL фирмы"
},
"additional_document_requisite": {
"type": "string",
"description": "Дополнительный реквизит документа (16 байт)"
},
"additional_user_requisite": {
"type": "object",
"description": "Дополнительный реквизит пользователя",
"properties": {
"name": {
"type": "string",
"description": "Наименование реквизита (64 байта)"
},
"value": {
"type": "string",
"description": "Значение реквизита (256 байт)"
}
}
},
"rows": {
"type": "array",
"items": {
"type": "object",
"description": "Описание позиции чека",
"required": [
"price",
"qty",
"tax_type",
"payment_type_type",
"text"
],
"properties": {
"price": {
"type": "string",
"description": "Цена"
},
"qty": {
"type": "string",
"description": "Количество"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"payment_type_type": {
"type": "string",
"enum": [
"prepayment",
"full_prepayment_wo_delivery",
"ip_payment",
"partial_prepayment_wo_delivery",
"full_payment_w_delivery",
"partial_payment_w_delivery",
"credit_w_delivery",
"credit_after_delivery"
],
"description": "Признак способа расчета"
},
"text": {
"type": "string",
"description": "Наименование"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"supplier_info": {
"type": "object",
"description": "Данные поставщика",
"required": [
"inn"
],
"properties": {
"inn": {
"type": "string",
"description": "ИНН поставщика"
},
"name": {
"type": "string",
"description": "Наименование поставщика"
},
"phone": {
"type": "string",
"description": "Телефон поставщика"
}
}
}
}
}
},
"payments": {
"type": "array",
"items": {
"type": "object",
"description": "Описание оплаты / Описание коррекции",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты. card -- электронным денежным средством, неденежные: prepayment -- предоплатой (зачетом аванса и (или) предыдущих платежей), credit -- постоплатой (в кредит), extension -- встречным представлением"
}
}
}
}
}
},
"receipt_calculated_content": {
"type": "object",
"description": "Посчитанные строки и итоги чека",
"required": [
"total",
"rows",
"tax_totals",
"totals"
],
"properties": {
"total": {
"type": "string",
"description": "Итог счета"
},
"money_received_total": {
"type": "string",
"description": "Полученное деньгами от клиента"
},
"firm_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
},
"firm_url": {
"type": "string",
"description": "URL фирмы"
},
"qr": {
"type": "string",
"description": "Значение для QR-кода"
},
"rows": {
"type": "array",
"items": {
"type": "object",
"description": "Посчитанная позиция чека",
"required": [
"price",
"qty",
"amount",
"tax_type",
"tax_pct",
"tax_amount",
"payment_type_type",
"text"
],
"properties": {
"price": {
"type": "string",
"description": "Цена"
},
"qty": {
"type": "string",
"description": "Количество"
},
"amount": {
"type": "string",
"description": "Сумма"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"tax_pct": {
"type": "string",
"description": "Процент налога"
},
"tax_amount": {
"type": "string",
"description": "Сумма налога"
},
"payment_type_type": {
"type": "string",
"enum": [
"prepayment",
"full_prepayment_wo_delivery",
"ip_payment",
"partial_prepayment_wo_delivery",
"full_payment_w_delivery",
"partial_payment_w_delivery",
"credit_w_delivery",
"credit_after_delivery"
],
"description": "Признак способа расчета"
},
"text": {
"type": "string",
"description": "Наименование"
}
}
}
},
"tax_totals": {
"type": "array",
"items": {
"type": "object",
"description": "Посчитанные налоги итогов",
"required": [
"tax_type",
"tax_pct",
"tax_amount"
],
"properties": {
"amount": {
"type": "string"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"tax_pct": {
"type": "string",
"description": "Процент налога"
},
"tax_amount": {
"type": "string",
"description": "Сумма налога"
}
}
}
},
"totals": {
"type": "array",
"items": {
"type": "object",
"description": "Описание посчитанного итога",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"emoney",
"emoney_other",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты (card - Картой, emoney - Электронным денежным средством, emoney_other)"
}
}
}
}
}
},
"ofd": {
"type": "object",
"description": "Оператор Фискальных Данных",
"properties": {
"inn": {
"type": "string",
"description": "ИНН Оператора фискальных данных"
},
"name": {
"type": "string",
"description": "Наименование оператора"
},
"check_url": {
"type": "string",
"description": "URL оператора фискальных данных"
}
}
},
"kkt": {
"type": "object",
"description": "Кассовый аппарат (ККТ)",
"properties": {
"sn": {
"type": "string",
"description": "Заводской номер ККТ. Глобальный уникальный номер кассы."
},
"rn": {
"type": "string",
"description": "Регистрационный номер ККТ."
},
"automatic_machine_number": {
"type": "string",
"description": "Номер автомата"
},
"version": {
"type": "string",
"description": "версия ККТ (тег 1188)"
}
}
},
"location": {
"type": "object",
"description": "Локация в которой находится касса",
"properties": {
"address": {
"type": "string",
"description": "Адрес места расположения ККТ"
},
"description": {
"type": "string",
"description": "Наименование места установки ККТ или адрес сайта, берется либо из чека, либо из параметров регистрации"
}
}
}
}
}
Выбить чек коррекции/коррекции БСО ¶
Выбить чек коррекции/коррекции БСОPOST/v1/cashmachines/{kkt_sn}/make_correction_receipt
Метод, который выбивает чек коррекции или чек коррекции БСО на конкретной кассе.
Example URI
- kkt_sn
string
(required)
Headers
Accept: application/json
Schema
{
"type": "object",
"description": "Запрос на создание чека коррекции/БСО",
"required": [
"correction_receipt_content"
],
"properties": {
"correction_receipt_content": {
"type": "object",
"description": "Содержимое чека коррекции",
"required": [
"payments",
"document_type",
"taxation_type",
"taxes",
"correction_type",
"reason"
],
"properties": {
"payments": {
"type": "array",
"items": {
"type": "object",
"description": "Описание оплаты / Описание коррекции",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты. card -- электронным денежным средством, неденежные: prepayment -- предоплатой (зачетом аванса и (или) предыдущих платежей), credit -- постоплатой (в кредит), extension -- встречным представлением"
}
}
}
},
"document_type": {
"type": "string",
"enum": [
"income_correction",
"charge_correction"
],
"description": "Тип документа коррекции (income_correction - коррекция прихода, charge_correction - коррекция расхода)"
},
"taxation_type": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
],
"description": "Применяемая в чеке система налогообложения"
},
"taxes": {
"type": "array",
"items": {
"type": "object",
"description": "Величина налога по соответвующей ставки. Для НДС 0% и Без налога нужно указывать суммы расчетов, а не сам налог.",
"required": [
"amount",
"tax_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма налога"
},
"tax_type": {
"type": "string",
"enum": [
"nds_18and20",
"nds_10",
"nds_0",
"nds_none",
"nds_18_118and20_120",
"nds_10_110"
],
"description": "Ставка налога"
}
}
},
"description": "Величины налогов по соответвующим ставкам. Не меньше одного значения и не более 6 значений."
},
"correction_type": {
"type": "string",
"enum": [
"independently",
"by_order"
],
"description": "Тип коррекции:\n * `independently` - Самостоятельно\n * `by_order` - По предписанию\n"
},
"reason": {
"type": "object",
"description": "Основание для коррекции",
"required": [
"dt"
],
"properties": {
"name": {
"type": "string",
"description": "Описание коррекции / Наименование документа"
},
"number": {
"type": "string",
"description": "Номер предписания налогового органа (указывается только если коррекция происходит по предписанию)"
},
"dt": {
"type": "string",
"format": "date",
"description": "Дата совершения корректируемого расчета / Дата документа, являющемся основанием для коррекции. В формате YYYY-MM-DD."
}
}
}
}
}
}
}
200
Пробитый чек коррекции
Headers
Content-Type: application/json
Body
{
"rnm": "consectetur Duis",
"receipt_type": "return_income"
}
Schema
{
"type": "object",
"description": "Фискальный документ",
"properties": {
"id": {
"type": "string",
"description": "Номер документа в ФН"
},
"document_type": {
"type": "string",
"enum": [
"RegistrationReport",
"ReRegistrationReport",
"ShiftOpenReport",
"ShiftCloseReport",
"Receipt",
"BSO",
"CorrectionReceipt",
"CorrectionBSO",
"CloseFNReport",
"CurrentReport"
],
"description": "Тип фискального документа"
},
"dt": {
"type": "string",
"format": "date-time",
"description": "Дата и время сохранения (с точностью до минуты) фискального документа"
},
"fp": {
"type": "string",
"description": "Фискальный признак"
},
"ofd_ticket_received": {
"type": "boolean",
"description": "Отправлен ли документ в ОФД"
},
"inn": {
"type": "string",
"description": "ИНН пользователя"
},
"rnm": {
"type": "string",
"description": "Регистрационный номер устройства"
},
"tax_mode": {
"type": "array",
"items": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
]
},
"description": "Режим налогооблажения"
},
"work_mode": {
"type": "array",
"items": {
"type": "string",
"enum": [
"crypt",
"autonomous",
"automatic",
"in_service_usage",
"BSO",
"internet_usage"
]
},
"description": "Режим работы"
},
"reregistration_code": {
"type": "integer",
"description": "Код причины перерегистрации"
},
"shift_number": {
"type": "integer",
"description": "Номер смены"
},
"receipt_type": {
"type": "string",
"enum": [
"income",
"charge",
"return_income",
"return_charge"
],
"description": "Тип чека"
},
"amount": {
"type": "string",
"description": "Сумма"
},
"number_unticketed_documents": {
"type": "string",
"description": "Количество неподтвержденных документов"
},
"first_unticketed_document_date": {
"type": "string",
"description": "Дата первого неподтвержденного документа"
},
"ofd_ticket_hex": {
"type": "string",
"description": "Фискальный признак ОФД"
},
"printform": {
"type": "array",
"items": {
"type": "string"
}
},
"rawform": {
"type": "object"
},
"fullform": {
"type": "object",
"description": "Фискальный чек",
"properties": {
"id": {
"type": "number",
"format": "long",
"description": "Номер документа в ФН"
},
"dt": {
"type": "string",
"format": "date-time",
"description": "Дата и время сохранения (с точностью до минуты) документа в ФН"
},
"fp": {
"type": "number",
"format": "long",
"description": "Фискальный признак"
},
"shift_number": {
"type": "number",
"format": "long",
"description": "Номер смены"
},
"document_index": {
"type": "number",
"format": "long",
"description": "Номер чека за смену"
},
"ofd_ticket_received": {
"type": "boolean",
"description": "Отправлен ли документ в ОФД"
},
"check_url": {
"type": "string",
"description": "URL для просмотра чека пользователем"
},
"localzone": {
"type": "string",
"description": "Название часового пояса по месту расчета"
},
"origin": {
"type": "string",
"enum": [
"online",
"kkt_fn",
"fn"
],
"description": "Источник происхождения чека"
},
"receipt_extra_contnent": {
"type": "object"
},
"firm": {
"type": "object",
"description": "Компания пробившая чек",
"properties": {
"inn": {
"type": "string",
"description": "ИНН компании"
},
"name": {
"type": "string",
"description": "Наименование компании"
},
"reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
}
}
},
"fn": {
"type": "object",
"description": "Фискальный накопитель",
"properties": {
"sn": {
"type": "string",
"description": "заводской номер ФН. Глобальный уникальный идентификатор"
},
"model": {
"type": "string",
"description": "модель ФН"
}
}
},
"receipt_content": {
"type": "object",
"description": "Содержимое чека",
"required": [
"firm_inn",
"receipt_type",
"taxation_type",
"firm_reply_email",
"firm_url",
"agent_type",
"client_email_or_phone",
"rows",
"payments"
],
"properties": {
"firm_inn": {
"type": "string",
"description": "ИНН компании"
},
"receipt_type": {
"type": "string",
"enum": [
"income",
"return_income",
"charge",
"return_charge"
],
"description": "Тип чека (income - Приход, return_income - Возврат прихода, charge - Расход, return_charge - Возврат расхода)"
},
"taxation_type": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
],
"description": "Применяемая в чеке система налогообложения"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"client_email_or_phone": {
"type": "string",
"description": "Электронная почта или телефон клиента"
},
"supplier_phone": {
"type": "string",
"description": "Телефон поставщика"
},
"firm_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
},
"firm_url": {
"type": "string",
"description": "URL фирмы"
},
"additional_document_requisite": {
"type": "string",
"description": "Дополнительный реквизит документа (16 байт)"
},
"additional_user_requisite": {
"type": "object",
"description": "Дополнительный реквизит пользователя",
"properties": {
"name": {
"type": "string",
"description": "Наименование реквизита (64 байта)"
},
"value": {
"type": "string",
"description": "Значение реквизита (256 байт)"
}
}
},
"rows": {
"type": "array",
"items": {
"type": "object",
"description": "Описание позиции чека",
"required": [
"price",
"qty",
"tax_type",
"payment_type_type",
"text"
],
"properties": {
"price": {
"type": "string",
"description": "Цена"
},
"qty": {
"type": "string",
"description": "Количество"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"payment_type_type": {
"type": "string",
"enum": [
"prepayment",
"full_prepayment_wo_delivery",
"ip_payment",
"partial_prepayment_wo_delivery",
"full_payment_w_delivery",
"partial_payment_w_delivery",
"credit_w_delivery",
"credit_after_delivery"
],
"description": "Признак способа расчета"
},
"text": {
"type": "string",
"description": "Наименование"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"supplier_info": {
"type": "object",
"description": "Данные поставщика",
"required": [
"inn"
],
"properties": {
"inn": {
"type": "string",
"description": "ИНН поставщика"
},
"name": {
"type": "string",
"description": "Наименование поставщика"
},
"phone": {
"type": "string",
"description": "Телефон поставщика"
}
}
}
}
}
},
"payments": {
"type": "array",
"items": {
"type": "object",
"description": "Описание оплаты / Описание коррекции",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты. card -- электронным денежным средством, неденежные: prepayment -- предоплатой (зачетом аванса и (или) предыдущих платежей), credit -- постоплатой (в кредит), extension -- встречным представлением"
}
}
}
}
}
},
"receipt_calculated_content": {
"type": "object",
"description": "Посчитанные строки и итоги чека",
"required": [
"total",
"rows",
"tax_totals",
"totals"
],
"properties": {
"total": {
"type": "string",
"description": "Итог счета"
},
"money_received_total": {
"type": "string",
"description": "Полученное деньгами от клиента"
},
"firm_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
},
"firm_url": {
"type": "string",
"description": "URL фирмы"
},
"qr": {
"type": "string",
"description": "Значение для QR-кода"
},
"rows": {
"type": "array",
"items": {
"type": "object",
"description": "Посчитанная позиция чека",
"required": [
"price",
"qty",
"amount",
"tax_type",
"tax_pct",
"tax_amount",
"payment_type_type",
"text"
],
"properties": {
"price": {
"type": "string",
"description": "Цена"
},
"qty": {
"type": "string",
"description": "Количество"
},
"amount": {
"type": "string",
"description": "Сумма"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"tax_pct": {
"type": "string",
"description": "Процент налога"
},
"tax_amount": {
"type": "string",
"description": "Сумма налога"
},
"payment_type_type": {
"type": "string",
"enum": [
"prepayment",
"full_prepayment_wo_delivery",
"ip_payment",
"partial_prepayment_wo_delivery",
"full_payment_w_delivery",
"partial_payment_w_delivery",
"credit_w_delivery",
"credit_after_delivery"
],
"description": "Признак способа расчета"
},
"text": {
"type": "string",
"description": "Наименование"
}
}
}
},
"tax_totals": {
"type": "array",
"items": {
"type": "object",
"description": "Посчитанные налоги итогов",
"required": [
"tax_type",
"tax_pct",
"tax_amount"
],
"properties": {
"amount": {
"type": "string"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"tax_pct": {
"type": "string",
"description": "Процент налога"
},
"tax_amount": {
"type": "string",
"description": "Сумма налога"
}
}
}
},
"totals": {
"type": "array",
"items": {
"type": "object",
"description": "Описание посчитанного итога",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"emoney",
"emoney_other",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты (card - Картой, emoney - Электронным денежным средством, emoney_other)"
}
}
}
}
}
},
"ofd": {
"type": "object",
"description": "Оператор Фискальных Данных",
"properties": {
"inn": {
"type": "string",
"description": "ИНН Оператора фискальных данных"
},
"name": {
"type": "string",
"description": "Наименование оператора"
},
"check_url": {
"type": "string",
"description": "URL оператора фискальных данных"
}
}
},
"kkt": {
"type": "object",
"description": "Кассовый аппарат (ККТ)",
"properties": {
"sn": {
"type": "string",
"description": "Заводской номер ККТ. Глобальный уникальный номер кассы."
},
"rn": {
"type": "string",
"description": "Регистрационный номер ККТ."
},
"automatic_machine_number": {
"type": "string",
"description": "Номер автомата"
},
"version": {
"type": "string",
"description": "версия ККТ (тег 1188)"
}
}
},
"location": {
"type": "object",
"description": "Локация в которой находится касса",
"properties": {
"address": {
"type": "string",
"description": "Адрес места расположения ККТ"
},
"description": {
"type": "string",
"description": "Наименование места установки ККТ или адрес сайта, берется либо из чека, либо из параметров регистрации"
}
}
}
}
}
}
}
Возвращает фискальный документ по номеруGET/v1/cashmachines/{kkt_sn}/document/{document_number}
Возвращает информацию по чеку пробитому на конкретной кассе.
Example URI
- kkt_sn
string
(required)- document_number
string
(required)- with_ofd_ticket
string
(required)- with_printform
string
(required)- with_rawform
string
(required)- with_fullform
string
(required)
Headers
Accept: application/json
200
Фискальный документ
Headers
Content-Type: application/json
Body
{
"reregistration_code": 51083996
}
Schema
{
"type": "object",
"description": "Фискальный документ",
"properties": {
"id": {
"type": "string",
"description": "Номер документа в ФН"
},
"document_type": {
"type": "string",
"enum": [
"RegistrationReport",
"ReRegistrationReport",
"ShiftOpenReport",
"ShiftCloseReport",
"Receipt",
"BSO",
"CorrectionReceipt",
"CorrectionBSO",
"CloseFNReport",
"CurrentReport"
],
"description": "Тип фискального документа"
},
"dt": {
"type": "string",
"format": "date-time",
"description": "Дата и время сохранения (с точностью до минуты) фискального документа"
},
"fp": {
"type": "string",
"description": "Фискальный признак"
},
"ofd_ticket_received": {
"type": "boolean",
"description": "Отправлен ли документ в ОФД"
},
"inn": {
"type": "string",
"description": "ИНН пользователя"
},
"rnm": {
"type": "string",
"description": "Регистрационный номер устройства"
},
"tax_mode": {
"type": "array",
"items": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
]
},
"description": "Режим налогооблажения"
},
"work_mode": {
"type": "array",
"items": {
"type": "string",
"enum": [
"crypt",
"autonomous",
"automatic",
"in_service_usage",
"BSO",
"internet_usage"
]
},
"description": "Режим работы"
},
"reregistration_code": {
"type": "integer",
"description": "Код причины перерегистрации"
},
"shift_number": {
"type": "integer",
"description": "Номер смены"
},
"receipt_type": {
"type": "string",
"enum": [
"income",
"charge",
"return_income",
"return_charge"
],
"description": "Тип чека"
},
"amount": {
"type": "string",
"description": "Сумма"
},
"number_unticketed_documents": {
"type": "string",
"description": "Количество неподтвержденных документов"
},
"first_unticketed_document_date": {
"type": "string",
"description": "Дата первого неподтвержденного документа"
},
"ofd_ticket_hex": {
"type": "string",
"description": "Фискальный признак ОФД"
},
"printform": {
"type": "array",
"items": {
"type": "string"
}
},
"rawform": {
"type": "object"
},
"fullform": {
"type": "object",
"description": "Фискальный чек",
"properties": {
"id": {
"type": "number",
"format": "long",
"description": "Номер документа в ФН"
},
"dt": {
"type": "string",
"format": "date-time",
"description": "Дата и время сохранения (с точностью до минуты) документа в ФН"
},
"fp": {
"type": "number",
"format": "long",
"description": "Фискальный признак"
},
"shift_number": {
"type": "number",
"format": "long",
"description": "Номер смены"
},
"document_index": {
"type": "number",
"format": "long",
"description": "Номер чека за смену"
},
"ofd_ticket_received": {
"type": "boolean",
"description": "Отправлен ли документ в ОФД"
},
"check_url": {
"type": "string",
"description": "URL для просмотра чека пользователем"
},
"localzone": {
"type": "string",
"description": "Название часового пояса по месту расчета"
},
"origin": {
"type": "string",
"enum": [
"online",
"kkt_fn",
"fn"
],
"description": "Источник происхождения чека"
},
"receipt_extra_contnent": {
"type": "object"
},
"firm": {
"type": "object",
"description": "Компания пробившая чек",
"properties": {
"inn": {
"type": "string",
"description": "ИНН компании"
},
"name": {
"type": "string",
"description": "Наименование компании"
},
"reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
}
}
},
"fn": {
"type": "object",
"description": "Фискальный накопитель",
"properties": {
"sn": {
"type": "string",
"description": "заводской номер ФН. Глобальный уникальный идентификатор"
},
"model": {
"type": "string",
"description": "модель ФН"
}
}
},
"receipt_content": {
"type": "object",
"description": "Содержимое чека",
"required": [
"firm_inn",
"receipt_type",
"taxation_type",
"firm_reply_email",
"firm_url",
"agent_type",
"client_email_or_phone",
"rows",
"payments"
],
"properties": {
"firm_inn": {
"type": "string",
"description": "ИНН компании"
},
"receipt_type": {
"type": "string",
"enum": [
"income",
"return_income",
"charge",
"return_charge"
],
"description": "Тип чека (income - Приход, return_income - Возврат прихода, charge - Расход, return_charge - Возврат расхода)"
},
"taxation_type": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
],
"description": "Применяемая в чеке система налогообложения"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"client_email_or_phone": {
"type": "string",
"description": "Электронная почта или телефон клиента"
},
"supplier_phone": {
"type": "string",
"description": "Телефон поставщика"
},
"firm_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
},
"firm_url": {
"type": "string",
"description": "URL фирмы"
},
"additional_document_requisite": {
"type": "string",
"description": "Дополнительный реквизит документа (16 байт)"
},
"additional_user_requisite": {
"type": "object",
"description": "Дополнительный реквизит пользователя",
"properties": {
"name": {
"type": "string",
"description": "Наименование реквизита (64 байта)"
},
"value": {
"type": "string",
"description": "Значение реквизита (256 байт)"
}
}
},
"rows": {
"type": "array",
"items": {
"type": "object",
"description": "Описание позиции чека",
"required": [
"price",
"qty",
"tax_type",
"payment_type_type",
"text"
],
"properties": {
"price": {
"type": "string",
"description": "Цена"
},
"qty": {
"type": "string",
"description": "Количество"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"payment_type_type": {
"type": "string",
"enum": [
"prepayment",
"full_prepayment_wo_delivery",
"ip_payment",
"partial_prepayment_wo_delivery",
"full_payment_w_delivery",
"partial_payment_w_delivery",
"credit_w_delivery",
"credit_after_delivery"
],
"description": "Признак способа расчета"
},
"text": {
"type": "string",
"description": "Наименование"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"supplier_info": {
"type": "object",
"description": "Данные поставщика",
"required": [
"inn"
],
"properties": {
"inn": {
"type": "string",
"description": "ИНН поставщика"
},
"name": {
"type": "string",
"description": "Наименование поставщика"
},
"phone": {
"type": "string",
"description": "Телефон поставщика"
}
}
}
}
}
},
"payments": {
"type": "array",
"items": {
"type": "object",
"description": "Описание оплаты / Описание коррекции",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты. card -- электронным денежным средством, неденежные: prepayment -- предоплатой (зачетом аванса и (или) предыдущих платежей), credit -- постоплатой (в кредит), extension -- встречным представлением"
}
}
}
}
}
},
"receipt_calculated_content": {
"type": "object",
"description": "Посчитанные строки и итоги чека",
"required": [
"total",
"rows",
"tax_totals",
"totals"
],
"properties": {
"total": {
"type": "string",
"description": "Итог счета"
},
"money_received_total": {
"type": "string",
"description": "Полученное деньгами от клиента"
},
"firm_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
},
"firm_url": {
"type": "string",
"description": "URL фирмы"
},
"qr": {
"type": "string",
"description": "Значение для QR-кода"
},
"rows": {
"type": "array",
"items": {
"type": "object",
"description": "Посчитанная позиция чека",
"required": [
"price",
"qty",
"amount",
"tax_type",
"tax_pct",
"tax_amount",
"payment_type_type",
"text"
],
"properties": {
"price": {
"type": "string",
"description": "Цена"
},
"qty": {
"type": "string",
"description": "Количество"
},
"amount": {
"type": "string",
"description": "Сумма"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"tax_pct": {
"type": "string",
"description": "Процент налога"
},
"tax_amount": {
"type": "string",
"description": "Сумма налога"
},
"payment_type_type": {
"type": "string",
"enum": [
"prepayment",
"full_prepayment_wo_delivery",
"ip_payment",
"partial_prepayment_wo_delivery",
"full_payment_w_delivery",
"partial_payment_w_delivery",
"credit_w_delivery",
"credit_after_delivery"
],
"description": "Признак способа расчета"
},
"text": {
"type": "string",
"description": "Наименование"
}
}
}
},
"tax_totals": {
"type": "array",
"items": {
"type": "object",
"description": "Посчитанные налоги итогов",
"required": [
"tax_type",
"tax_pct",
"tax_amount"
],
"properties": {
"amount": {
"type": "string"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"tax_pct": {
"type": "string",
"description": "Процент налога"
},
"tax_amount": {
"type": "string",
"description": "Сумма налога"
}
}
}
},
"totals": {
"type": "array",
"items": {
"type": "object",
"description": "Описание посчитанного итога",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"emoney",
"emoney_other",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты (card - Картой, emoney - Электронным денежным средством, emoney_other)"
}
}
}
}
}
},
"ofd": {
"type": "object",
"description": "Оператор Фискальных Данных",
"properties": {
"inn": {
"type": "string",
"description": "ИНН Оператора фискальных данных"
},
"name": {
"type": "string",
"description": "Наименование оператора"
},
"check_url": {
"type": "string",
"description": "URL оператора фискальных данных"
}
}
},
"kkt": {
"type": "object",
"description": "Кассовый аппарат (ККТ)",
"properties": {
"sn": {
"type": "string",
"description": "Заводской номер ККТ. Глобальный уникальный номер кассы."
},
"rn": {
"type": "string",
"description": "Регистрационный номер ККТ."
},
"automatic_machine_number": {
"type": "string",
"description": "Номер автомата"
},
"version": {
"type": "string",
"description": "версия ККТ (тег 1188)"
}
}
},
"location": {
"type": "object",
"description": "Локация в которой находится касса",
"properties": {
"address": {
"type": "string",
"description": "Адрес места расположения ККТ"
},
"description": {
"type": "string",
"description": "Наименование места установки ККТ или адрес сайта, берется либо из чека, либо из параметров регистрации"
}
}
}
}
}
}
}
Status ¶
Проверяет доступность серванта ¶
Проверяет доступность сервантаGET/v1/ping
Отвечает 200, если сервант жив и может пробить хоть один чек. В качестве опционального параметра может принимать ИНН чтобы проверить возможность пробить чек по конкретной фирме
Example URI
- firm_inn
string
(required)- group
string
(required)- backlog_ratio
string
(required)
Headers
Accept: application/json
200
Всё хорошо, можно бить чеки
Headers
Content-Type: application/json
Отдает минимальную информацию о свободных кассах по ИНН и группам ¶
Отдает минимальную информацию о свободных кассах по ИНН и группамGET/v1/info
Example URI
Headers
Accept: application/json
200
Минимальная информация
Headers
Content-Type: application/json
Выдает статус сервера, всех касс и очередейGET/v1/cashmachines
Выдает статус сервера, всех касс и очередей
Example URI
- include_offline
string
(required)
Headers
Accept: application/json
200
Статусы
Headers
Content-Type: application/json
Выдает статус кассы ¶
Выдает статус кассыGET/v1/cashmachines/{kkt_sn}/status
Метод, который возвращает статус конкретной кассы.
Example URI
- kkt_sn
string
(required)
Headers
Accept: application/json
200
Статус
Headers
Content-Type: application/json
Shifts ¶
Открыть смену ¶
Открыть сменуPOST/v1/cashmachines/{kkt_sn}/open_shift
Метод, который синхронно открывает смену на конкретной кассе.
Example URI
- kkt_sn
string
(required)
Headers
Accept: application/json
200
Успех
Headers
Content-Type: application/json
Body
{}
Schema
{
"type": "object",
"description": "Фискальный документ",
"properties": {
"id": {
"type": "string",
"description": "Номер документа в ФН"
},
"document_type": {
"type": "string",
"enum": [
"RegistrationReport",
"ReRegistrationReport",
"ShiftOpenReport",
"ShiftCloseReport",
"Receipt",
"BSO",
"CorrectionReceipt",
"CorrectionBSO",
"CloseFNReport",
"CurrentReport"
],
"description": "Тип фискального документа"
},
"dt": {
"type": "string",
"format": "date-time",
"description": "Дата и время сохранения (с точностью до минуты) фискального документа"
},
"fp": {
"type": "string",
"description": "Фискальный признак"
},
"ofd_ticket_received": {
"type": "boolean",
"description": "Отправлен ли документ в ОФД"
},
"inn": {
"type": "string",
"description": "ИНН пользователя"
},
"rnm": {
"type": "string",
"description": "Регистрационный номер устройства"
},
"tax_mode": {
"type": "array",
"items": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
]
},
"description": "Режим налогооблажения"
},
"work_mode": {
"type": "array",
"items": {
"type": "string",
"enum": [
"crypt",
"autonomous",
"automatic",
"in_service_usage",
"BSO",
"internet_usage"
]
},
"description": "Режим работы"
},
"reregistration_code": {
"type": "integer",
"description": "Код причины перерегистрации"
},
"shift_number": {
"type": "integer",
"description": "Номер смены"
},
"receipt_type": {
"type": "string",
"enum": [
"income",
"charge",
"return_income",
"return_charge"
],
"description": "Тип чека"
},
"amount": {
"type": "string",
"description": "Сумма"
},
"number_unticketed_documents": {
"type": "string",
"description": "Количество неподтвержденных документов"
},
"first_unticketed_document_date": {
"type": "string",
"description": "Дата первого неподтвержденного документа"
},
"ofd_ticket_hex": {
"type": "string",
"description": "Фискальный признак ОФД"
},
"printform": {
"type": "array",
"items": {
"type": "string"
}
},
"rawform": {
"type": "object"
},
"fullform": {
"type": "object",
"description": "Фискальный чек",
"properties": {
"id": {
"type": "number",
"format": "long",
"description": "Номер документа в ФН"
},
"dt": {
"type": "string",
"format": "date-time",
"description": "Дата и время сохранения (с точностью до минуты) документа в ФН"
},
"fp": {
"type": "number",
"format": "long",
"description": "Фискальный признак"
},
"shift_number": {
"type": "number",
"format": "long",
"description": "Номер смены"
},
"document_index": {
"type": "number",
"format": "long",
"description": "Номер чека за смену"
},
"ofd_ticket_received": {
"type": "boolean",
"description": "Отправлен ли документ в ОФД"
},
"check_url": {
"type": "string",
"description": "URL для просмотра чека пользователем"
},
"localzone": {
"type": "string",
"description": "Название часового пояса по месту расчета"
},
"origin": {
"type": "string",
"enum": [
"online",
"kkt_fn",
"fn"
],
"description": "Источник происхождения чека"
},
"receipt_extra_contnent": {
"type": "object"
},
"firm": {
"type": "object",
"description": "Компания пробившая чек",
"properties": {
"inn": {
"type": "string",
"description": "ИНН компании"
},
"name": {
"type": "string",
"description": "Наименование компании"
},
"reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
}
}
},
"fn": {
"type": "object",
"description": "Фискальный накопитель",
"properties": {
"sn": {
"type": "string",
"description": "заводской номер ФН. Глобальный уникальный идентификатор"
},
"model": {
"type": "string",
"description": "модель ФН"
}
}
},
"receipt_content": {
"type": "object",
"description": "Содержимое чека",
"required": [
"firm_inn",
"receipt_type",
"taxation_type",
"firm_reply_email",
"firm_url",
"agent_type",
"client_email_or_phone",
"rows",
"payments"
],
"properties": {
"firm_inn": {
"type": "string",
"description": "ИНН компании"
},
"receipt_type": {
"type": "string",
"enum": [
"income",
"return_income",
"charge",
"return_charge"
],
"description": "Тип чека (income - Приход, return_income - Возврат прихода, charge - Расход, return_charge - Возврат расхода)"
},
"taxation_type": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
],
"description": "Применяемая в чеке система налогообложения"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"client_email_or_phone": {
"type": "string",
"description": "Электронная почта или телефон клиента"
},
"supplier_phone": {
"type": "string",
"description": "Телефон поставщика"
},
"firm_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
},
"firm_url": {
"type": "string",
"description": "URL фирмы"
},
"additional_document_requisite": {
"type": "string",
"description": "Дополнительный реквизит документа (16 байт)"
},
"additional_user_requisite": {
"type": "object",
"description": "Дополнительный реквизит пользователя",
"properties": {
"name": {
"type": "string",
"description": "Наименование реквизита (64 байта)"
},
"value": {
"type": "string",
"description": "Значение реквизита (256 байт)"
}
}
},
"rows": {
"type": "array",
"items": {
"type": "object",
"description": "Описание позиции чека",
"required": [
"price",
"qty",
"tax_type",
"payment_type_type",
"text"
],
"properties": {
"price": {
"type": "string",
"description": "Цена"
},
"qty": {
"type": "string",
"description": "Количество"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"payment_type_type": {
"type": "string",
"enum": [
"prepayment",
"full_prepayment_wo_delivery",
"ip_payment",
"partial_prepayment_wo_delivery",
"full_payment_w_delivery",
"partial_payment_w_delivery",
"credit_w_delivery",
"credit_after_delivery"
],
"description": "Признак способа расчета"
},
"text": {
"type": "string",
"description": "Наименование"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"supplier_info": {
"type": "object",
"description": "Данные поставщика",
"required": [
"inn"
],
"properties": {
"inn": {
"type": "string",
"description": "ИНН поставщика"
},
"name": {
"type": "string",
"description": "Наименование поставщика"
},
"phone": {
"type": "string",
"description": "Телефон поставщика"
}
}
}
}
}
},
"payments": {
"type": "array",
"items": {
"type": "object",
"description": "Описание оплаты / Описание коррекции",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты. card -- электронным денежным средством, неденежные: prepayment -- предоплатой (зачетом аванса и (или) предыдущих платежей), credit -- постоплатой (в кредит), extension -- встречным представлением"
}
}
}
}
}
},
"receipt_calculated_content": {
"type": "object",
"description": "Посчитанные строки и итоги чека",
"required": [
"total",
"rows",
"tax_totals",
"totals"
],
"properties": {
"total": {
"type": "string",
"description": "Итог счета"
},
"money_received_total": {
"type": "string",
"description": "Полученное деньгами от клиента"
},
"firm_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
},
"firm_url": {
"type": "string",
"description": "URL фирмы"
},
"qr": {
"type": "string",
"description": "Значение для QR-кода"
},
"rows": {
"type": "array",
"items": {
"type": "object",
"description": "Посчитанная позиция чека",
"required": [
"price",
"qty",
"amount",
"tax_type",
"tax_pct",
"tax_amount",
"payment_type_type",
"text"
],
"properties": {
"price": {
"type": "string",
"description": "Цена"
},
"qty": {
"type": "string",
"description": "Количество"
},
"amount": {
"type": "string",
"description": "Сумма"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"tax_pct": {
"type": "string",
"description": "Процент налога"
},
"tax_amount": {
"type": "string",
"description": "Сумма налога"
},
"payment_type_type": {
"type": "string",
"enum": [
"prepayment",
"full_prepayment_wo_delivery",
"ip_payment",
"partial_prepayment_wo_delivery",
"full_payment_w_delivery",
"partial_payment_w_delivery",
"credit_w_delivery",
"credit_after_delivery"
],
"description": "Признак способа расчета"
},
"text": {
"type": "string",
"description": "Наименование"
}
}
}
},
"tax_totals": {
"type": "array",
"items": {
"type": "object",
"description": "Посчитанные налоги итогов",
"required": [
"tax_type",
"tax_pct",
"tax_amount"
],
"properties": {
"amount": {
"type": "string"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"tax_pct": {
"type": "string",
"description": "Процент налога"
},
"tax_amount": {
"type": "string",
"description": "Сумма налога"
}
}
}
},
"totals": {
"type": "array",
"items": {
"type": "object",
"description": "Описание посчитанного итога",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"emoney",
"emoney_other",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты (card - Картой, emoney - Электронным денежным средством, emoney_other)"
}
}
}
}
}
},
"ofd": {
"type": "object",
"description": "Оператор Фискальных Данных",
"properties": {
"inn": {
"type": "string",
"description": "ИНН Оператора фискальных данных"
},
"name": {
"type": "string",
"description": "Наименование оператора"
},
"check_url": {
"type": "string",
"description": "URL оператора фискальных данных"
}
}
},
"kkt": {
"type": "object",
"description": "Кассовый аппарат (ККТ)",
"properties": {
"sn": {
"type": "string",
"description": "Заводской номер ККТ. Глобальный уникальный номер кассы."
},
"rn": {
"type": "string",
"description": "Регистрационный номер ККТ."
},
"automatic_machine_number": {
"type": "string",
"description": "Номер автомата"
},
"version": {
"type": "string",
"description": "версия ККТ (тег 1188)"
}
}
},
"location": {
"type": "object",
"description": "Локация в которой находится касса",
"properties": {
"address": {
"type": "string",
"description": "Адрес места расположения ККТ"
},
"description": {
"type": "string",
"description": "Наименование места установки ККТ или адрес сайта, берется либо из чека, либо из параметров регистрации"
}
}
}
}
}
}
}
Закрыть (аварийно закрыть) сменуPOST/v1/cashmachines/{kkt_sn}/close_shift
Метод, который синхронно закрывает смену на конкретной кассе.
Example URI
- kkt_sn
string
(required)- emergency
string
(required)- mysecret
string
(required)
Headers
Accept: application/json
Schema
{
"type": "object",
"description": "Дополнительная информация для устройства"
}
200
Успех
Headers
Content-Type: application/json
Body
{}
Schema
{
"type": "object",
"description": "Фискальный документ",
"properties": {
"id": {
"type": "string",
"description": "Номер документа в ФН"
},
"document_type": {
"type": "string",
"enum": [
"RegistrationReport",
"ReRegistrationReport",
"ShiftOpenReport",
"ShiftCloseReport",
"Receipt",
"BSO",
"CorrectionReceipt",
"CorrectionBSO",
"CloseFNReport",
"CurrentReport"
],
"description": "Тип фискального документа"
},
"dt": {
"type": "string",
"format": "date-time",
"description": "Дата и время сохранения (с точностью до минуты) фискального документа"
},
"fp": {
"type": "string",
"description": "Фискальный признак"
},
"ofd_ticket_received": {
"type": "boolean",
"description": "Отправлен ли документ в ОФД"
},
"inn": {
"type": "string",
"description": "ИНН пользователя"
},
"rnm": {
"type": "string",
"description": "Регистрационный номер устройства"
},
"tax_mode": {
"type": "array",
"items": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
]
},
"description": "Режим налогооблажения"
},
"work_mode": {
"type": "array",
"items": {
"type": "string",
"enum": [
"crypt",
"autonomous",
"automatic",
"in_service_usage",
"BSO",
"internet_usage"
]
},
"description": "Режим работы"
},
"reregistration_code": {
"type": "integer",
"description": "Код причины перерегистрации"
},
"shift_number": {
"type": "integer",
"description": "Номер смены"
},
"receipt_type": {
"type": "string",
"enum": [
"income",
"charge",
"return_income",
"return_charge"
],
"description": "Тип чека"
},
"amount": {
"type": "string",
"description": "Сумма"
},
"number_unticketed_documents": {
"type": "string",
"description": "Количество неподтвержденных документов"
},
"first_unticketed_document_date": {
"type": "string",
"description": "Дата первого неподтвержденного документа"
},
"ofd_ticket_hex": {
"type": "string",
"description": "Фискальный признак ОФД"
},
"printform": {
"type": "array",
"items": {
"type": "string"
}
},
"rawform": {
"type": "object"
},
"fullform": {
"type": "object",
"description": "Фискальный чек",
"properties": {
"id": {
"type": "number",
"format": "long",
"description": "Номер документа в ФН"
},
"dt": {
"type": "string",
"format": "date-time",
"description": "Дата и время сохранения (с точностью до минуты) документа в ФН"
},
"fp": {
"type": "number",
"format": "long",
"description": "Фискальный признак"
},
"shift_number": {
"type": "number",
"format": "long",
"description": "Номер смены"
},
"document_index": {
"type": "number",
"format": "long",
"description": "Номер чека за смену"
},
"ofd_ticket_received": {
"type": "boolean",
"description": "Отправлен ли документ в ОФД"
},
"check_url": {
"type": "string",
"description": "URL для просмотра чека пользователем"
},
"localzone": {
"type": "string",
"description": "Название часового пояса по месту расчета"
},
"origin": {
"type": "string",
"enum": [
"online",
"kkt_fn",
"fn"
],
"description": "Источник происхождения чека"
},
"receipt_extra_contnent": {
"type": "object"
},
"firm": {
"type": "object",
"description": "Компания пробившая чек",
"properties": {
"inn": {
"type": "string",
"description": "ИНН компании"
},
"name": {
"type": "string",
"description": "Наименование компании"
},
"reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
}
}
},
"fn": {
"type": "object",
"description": "Фискальный накопитель",
"properties": {
"sn": {
"type": "string",
"description": "заводской номер ФН. Глобальный уникальный идентификатор"
},
"model": {
"type": "string",
"description": "модель ФН"
}
}
},
"receipt_content": {
"type": "object",
"description": "Содержимое чека",
"required": [
"firm_inn",
"receipt_type",
"taxation_type",
"firm_reply_email",
"firm_url",
"agent_type",
"client_email_or_phone",
"rows",
"payments"
],
"properties": {
"firm_inn": {
"type": "string",
"description": "ИНН компании"
},
"receipt_type": {
"type": "string",
"enum": [
"income",
"return_income",
"charge",
"return_charge"
],
"description": "Тип чека (income - Приход, return_income - Возврат прихода, charge - Расход, return_charge - Возврат расхода)"
},
"taxation_type": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
],
"description": "Применяемая в чеке система налогообложения"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"client_email_or_phone": {
"type": "string",
"description": "Электронная почта или телефон клиента"
},
"supplier_phone": {
"type": "string",
"description": "Телефон поставщика"
},
"firm_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
},
"firm_url": {
"type": "string",
"description": "URL фирмы"
},
"additional_document_requisite": {
"type": "string",
"description": "Дополнительный реквизит документа (16 байт)"
},
"additional_user_requisite": {
"type": "object",
"description": "Дополнительный реквизит пользователя",
"properties": {
"name": {
"type": "string",
"description": "Наименование реквизита (64 байта)"
},
"value": {
"type": "string",
"description": "Значение реквизита (256 байт)"
}
}
},
"rows": {
"type": "array",
"items": {
"type": "object",
"description": "Описание позиции чека",
"required": [
"price",
"qty",
"tax_type",
"payment_type_type",
"text"
],
"properties": {
"price": {
"type": "string",
"description": "Цена"
},
"qty": {
"type": "string",
"description": "Количество"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"payment_type_type": {
"type": "string",
"enum": [
"prepayment",
"full_prepayment_wo_delivery",
"ip_payment",
"partial_prepayment_wo_delivery",
"full_payment_w_delivery",
"partial_payment_w_delivery",
"credit_w_delivery",
"credit_after_delivery"
],
"description": "Признак способа расчета"
},
"text": {
"type": "string",
"description": "Наименование"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"supplier_info": {
"type": "object",
"description": "Данные поставщика",
"required": [
"inn"
],
"properties": {
"inn": {
"type": "string",
"description": "ИНН поставщика"
},
"name": {
"type": "string",
"description": "Наименование поставщика"
},
"phone": {
"type": "string",
"description": "Телефон поставщика"
}
}
}
}
}
},
"payments": {
"type": "array",
"items": {
"type": "object",
"description": "Описание оплаты / Описание коррекции",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты. card -- электронным денежным средством, неденежные: prepayment -- предоплатой (зачетом аванса и (или) предыдущих платежей), credit -- постоплатой (в кредит), extension -- встречным представлением"
}
}
}
}
}
},
"receipt_calculated_content": {
"type": "object",
"description": "Посчитанные строки и итоги чека",
"required": [
"total",
"rows",
"tax_totals",
"totals"
],
"properties": {
"total": {
"type": "string",
"description": "Итог счета"
},
"money_received_total": {
"type": "string",
"description": "Полученное деньгами от клиента"
},
"firm_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
},
"firm_url": {
"type": "string",
"description": "URL фирмы"
},
"qr": {
"type": "string",
"description": "Значение для QR-кода"
},
"rows": {
"type": "array",
"items": {
"type": "object",
"description": "Посчитанная позиция чека",
"required": [
"price",
"qty",
"amount",
"tax_type",
"tax_pct",
"tax_amount",
"payment_type_type",
"text"
],
"properties": {
"price": {
"type": "string",
"description": "Цена"
},
"qty": {
"type": "string",
"description": "Количество"
},
"amount": {
"type": "string",
"description": "Сумма"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"tax_pct": {
"type": "string",
"description": "Процент налога"
},
"tax_amount": {
"type": "string",
"description": "Сумма налога"
},
"payment_type_type": {
"type": "string",
"enum": [
"prepayment",
"full_prepayment_wo_delivery",
"ip_payment",
"partial_prepayment_wo_delivery",
"full_payment_w_delivery",
"partial_payment_w_delivery",
"credit_w_delivery",
"credit_after_delivery"
],
"description": "Признак способа расчета"
},
"text": {
"type": "string",
"description": "Наименование"
}
}
}
},
"tax_totals": {
"type": "array",
"items": {
"type": "object",
"description": "Посчитанные налоги итогов",
"required": [
"tax_type",
"tax_pct",
"tax_amount"
],
"properties": {
"amount": {
"type": "string"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"tax_pct": {
"type": "string",
"description": "Процент налога"
},
"tax_amount": {
"type": "string",
"description": "Сумма налога"
}
}
}
},
"totals": {
"type": "array",
"items": {
"type": "object",
"description": "Описание посчитанного итога",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"emoney",
"emoney_other",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты (card - Картой, emoney - Электронным денежным средством, emoney_other)"
}
}
}
}
}
},
"ofd": {
"type": "object",
"description": "Оператор Фискальных Данных",
"properties": {
"inn": {
"type": "string",
"description": "ИНН Оператора фискальных данных"
},
"name": {
"type": "string",
"description": "Наименование оператора"
},
"check_url": {
"type": "string",
"description": "URL оператора фискальных данных"
}
}
},
"kkt": {
"type": "object",
"description": "Кассовый аппарат (ККТ)",
"properties": {
"sn": {
"type": "string",
"description": "Заводской номер ККТ. Глобальный уникальный номер кассы."
},
"rn": {
"type": "string",
"description": "Регистрационный номер ККТ."
},
"automatic_machine_number": {
"type": "string",
"description": "Номер автомата"
},
"version": {
"type": "string",
"description": "версия ККТ (тег 1188)"
}
}
},
"location": {
"type": "object",
"description": "Локация в которой находится касса",
"properties": {
"address": {
"type": "string",
"description": "Адрес места расположения ККТ"
},
"description": {
"type": "string",
"description": "Наименование места установки ККТ или адрес сайта, берется либо из чека, либо из параметров регистрации"
}
}
}
}
}
}
}
Admin ¶
Перезагрузить кассу ¶
Перезагрузить кассуPOST/v1/cashmachines/{kkt_sn}/reboot
Перезазрузить кассу
Example URI
- kkt_sn
string
(required)- cold
string
(required)
Headers
Accept: application/json
200
Успех
Headers
Content-Type: application/json
Идентифицировать кассу ¶
Идентифицировать кассуPOST/v1/cashmachines/{kkt_sn}/ident
Идентифицировать кассу
Example URI
- kkt_sn
string
(required)- on_
string
(required)
Headers
Accept: application/json
200
Успех
Headers
Content-Type: application/json
Отконфигурировать кассу для регистрации ¶
Отконфигурировать кассу для регистрацииPOST/v1/cashmachines/{kkt_sn}/configure
Отконфигурировать кассу для регистрации
Example URI
- kkt_sn
string
(required)
Headers
Accept: application/json
Schema
{
"type": "object",
"description": "Конфигурационная информация",
"properties": {
"ofd_info": {
"type": "object",
"description": "ОФД информация",
"properties": {
"ofd_addr": {
"type": "string",
"description": "Сететевой адрес ОФД"
},
"check_url": {
"type": "string",
"description": "Адрес для проверки чека"
},
"transport": {
"type": "string",
"description": "Непонятный параметр, устанавливать в строку 0"
}
}
},
"reg_info": {
"type": "object",
"description": "Параметры регистрации",
"properties": {
"user_inn": {
"type": "string",
"description": "ИНН пользователя"
},
"rnm": {
"type": "string",
"description": "Регистрационный номер устройства"
},
"tax_mode": {
"type": "array",
"items": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
],
"minItems": 1
},
"description": "Режим налогообложения"
},
"work_mode": {
"type": "array",
"items": {
"type": "string",
"enum": [
"automatic",
"crypt",
"autonomous",
"in_service_usage",
"BSO",
"internet_usage"
]
},
"description": "Режим работы"
},
"user_name": {
"type": "string",
"description": "Наименование пользователя"
},
"account_address": {
"type": "string",
"description": "Адрес (место) расчётов"
},
"representative_for_registration": {
"type": "string",
"description": "Лицо, уполномоченное пользователем для проведение регистрации/перерегистрации"
},
"ofd_inn": {
"type": "string",
"description": "ИНН ОФД"
},
"representative_inn": {
"type": "string",
"description": "ИНН уполномоченного лица"
},
"account_address_name": {
"type": "string",
"description": "Место расчётов"
},
"ofd_name": {
"type": "string",
"description": "Название ОФД"
},
"agent_mode": {
"type": "array",
"items": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
]
},
"description": "Признак агента"
},
"terminal_number": {
"type": "string",
"description": "Номер терминала"
},
"user_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
}
}
},
"group_info": {
"type": "object",
"description": "Группы, в которые входит касса",
"properties": {
"groups": {
"type": "array",
"items": {
"type": "string",
"minItems": 0
},
"description": "Группы"
}
}
},
"device_payload": {
"type": "object",
"description": "Дополнительная информация для устройства"
},
"mysecret": {
"type": "string"
}
}
}
200
Успех
Headers
Content-Type: application/json
Зарегистрировать кассуPOST/v1/cashmachines/{kkt_sn}/register
Зарегистрировать кассу
Example URI
- kkt_sn
string
(required)- reregister
string
(required)- fn_changed
string
(required)- mysecret
string
(required)
Headers
Accept: application/json
Schema
{
"type": "object",
"description": "Дополнительная информация для устройства"
}
200
Успех
Headers
Content-Type: application/json
Body
{}
Schema
{
"type": "object",
"description": "Фискальный документ",
"properties": {
"id": {
"type": "string",
"description": "Номер документа в ФН"
},
"document_type": {
"type": "string",
"enum": [
"RegistrationReport",
"ReRegistrationReport",
"ShiftOpenReport",
"ShiftCloseReport",
"Receipt",
"BSO",
"CorrectionReceipt",
"CorrectionBSO",
"CloseFNReport",
"CurrentReport"
],
"description": "Тип фискального документа"
},
"dt": {
"type": "string",
"format": "date-time",
"description": "Дата и время сохранения (с точностью до минуты) фискального документа"
},
"fp": {
"type": "string",
"description": "Фискальный признак"
},
"ofd_ticket_received": {
"type": "boolean",
"description": "Отправлен ли документ в ОФД"
},
"inn": {
"type": "string",
"description": "ИНН пользователя"
},
"rnm": {
"type": "string",
"description": "Регистрационный номер устройства"
},
"tax_mode": {
"type": "array",
"items": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
]
},
"description": "Режим налогооблажения"
},
"work_mode": {
"type": "array",
"items": {
"type": "string",
"enum": [
"crypt",
"autonomous",
"automatic",
"in_service_usage",
"BSO",
"internet_usage"
]
},
"description": "Режим работы"
},
"reregistration_code": {
"type": "integer",
"description": "Код причины перерегистрации"
},
"shift_number": {
"type": "integer",
"description": "Номер смены"
},
"receipt_type": {
"type": "string",
"enum": [
"income",
"charge",
"return_income",
"return_charge"
],
"description": "Тип чека"
},
"amount": {
"type": "string",
"description": "Сумма"
},
"number_unticketed_documents": {
"type": "string",
"description": "Количество неподтвержденных документов"
},
"first_unticketed_document_date": {
"type": "string",
"description": "Дата первого неподтвержденного документа"
},
"ofd_ticket_hex": {
"type": "string",
"description": "Фискальный признак ОФД"
},
"printform": {
"type": "array",
"items": {
"type": "string"
}
},
"rawform": {
"type": "object"
},
"fullform": {
"type": "object",
"description": "Фискальный чек",
"properties": {
"id": {
"type": "number",
"format": "long",
"description": "Номер документа в ФН"
},
"dt": {
"type": "string",
"format": "date-time",
"description": "Дата и время сохранения (с точностью до минуты) документа в ФН"
},
"fp": {
"type": "number",
"format": "long",
"description": "Фискальный признак"
},
"shift_number": {
"type": "number",
"format": "long",
"description": "Номер смены"
},
"document_index": {
"type": "number",
"format": "long",
"description": "Номер чека за смену"
},
"ofd_ticket_received": {
"type": "boolean",
"description": "Отправлен ли документ в ОФД"
},
"check_url": {
"type": "string",
"description": "URL для просмотра чека пользователем"
},
"localzone": {
"type": "string",
"description": "Название часового пояса по месту расчета"
},
"origin": {
"type": "string",
"enum": [
"online",
"kkt_fn",
"fn"
],
"description": "Источник происхождения чека"
},
"receipt_extra_contnent": {
"type": "object"
},
"firm": {
"type": "object",
"description": "Компания пробившая чек",
"properties": {
"inn": {
"type": "string",
"description": "ИНН компании"
},
"name": {
"type": "string",
"description": "Наименование компании"
},
"reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
}
}
},
"fn": {
"type": "object",
"description": "Фискальный накопитель",
"properties": {
"sn": {
"type": "string",
"description": "заводской номер ФН. Глобальный уникальный идентификатор"
},
"model": {
"type": "string",
"description": "модель ФН"
}
}
},
"receipt_content": {
"type": "object",
"description": "Содержимое чека",
"required": [
"firm_inn",
"receipt_type",
"taxation_type",
"firm_reply_email",
"firm_url",
"agent_type",
"client_email_or_phone",
"rows",
"payments"
],
"properties": {
"firm_inn": {
"type": "string",
"description": "ИНН компании"
},
"receipt_type": {
"type": "string",
"enum": [
"income",
"return_income",
"charge",
"return_charge"
],
"description": "Тип чека (income - Приход, return_income - Возврат прихода, charge - Расход, return_charge - Возврат расхода)"
},
"taxation_type": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
],
"description": "Применяемая в чеке система налогообложения"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"client_email_or_phone": {
"type": "string",
"description": "Электронная почта или телефон клиента"
},
"supplier_phone": {
"type": "string",
"description": "Телефон поставщика"
},
"firm_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
},
"firm_url": {
"type": "string",
"description": "URL фирмы"
},
"additional_document_requisite": {
"type": "string",
"description": "Дополнительный реквизит документа (16 байт)"
},
"additional_user_requisite": {
"type": "object",
"description": "Дополнительный реквизит пользователя",
"properties": {
"name": {
"type": "string",
"description": "Наименование реквизита (64 байта)"
},
"value": {
"type": "string",
"description": "Значение реквизита (256 байт)"
}
}
},
"rows": {
"type": "array",
"items": {
"type": "object",
"description": "Описание позиции чека",
"required": [
"price",
"qty",
"tax_type",
"payment_type_type",
"text"
],
"properties": {
"price": {
"type": "string",
"description": "Цена"
},
"qty": {
"type": "string",
"description": "Количество"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"payment_type_type": {
"type": "string",
"enum": [
"prepayment",
"full_prepayment_wo_delivery",
"ip_payment",
"partial_prepayment_wo_delivery",
"full_payment_w_delivery",
"partial_payment_w_delivery",
"credit_w_delivery",
"credit_after_delivery"
],
"description": "Признак способа расчета"
},
"text": {
"type": "string",
"description": "Наименование"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"supplier_info": {
"type": "object",
"description": "Данные поставщика",
"required": [
"inn"
],
"properties": {
"inn": {
"type": "string",
"description": "ИНН поставщика"
},
"name": {
"type": "string",
"description": "Наименование поставщика"
},
"phone": {
"type": "string",
"description": "Телефон поставщика"
}
}
}
}
}
},
"payments": {
"type": "array",
"items": {
"type": "object",
"description": "Описание оплаты / Описание коррекции",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты. card -- электронным денежным средством, неденежные: prepayment -- предоплатой (зачетом аванса и (или) предыдущих платежей), credit -- постоплатой (в кредит), extension -- встречным представлением"
}
}
}
}
}
},
"receipt_calculated_content": {
"type": "object",
"description": "Посчитанные строки и итоги чека",
"required": [
"total",
"rows",
"tax_totals",
"totals"
],
"properties": {
"total": {
"type": "string",
"description": "Итог счета"
},
"money_received_total": {
"type": "string",
"description": "Полученное деньгами от клиента"
},
"firm_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
},
"firm_url": {
"type": "string",
"description": "URL фирмы"
},
"qr": {
"type": "string",
"description": "Значение для QR-кода"
},
"rows": {
"type": "array",
"items": {
"type": "object",
"description": "Посчитанная позиция чека",
"required": [
"price",
"qty",
"amount",
"tax_type",
"tax_pct",
"tax_amount",
"payment_type_type",
"text"
],
"properties": {
"price": {
"type": "string",
"description": "Цена"
},
"qty": {
"type": "string",
"description": "Количество"
},
"amount": {
"type": "string",
"description": "Сумма"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"tax_pct": {
"type": "string",
"description": "Процент налога"
},
"tax_amount": {
"type": "string",
"description": "Сумма налога"
},
"payment_type_type": {
"type": "string",
"enum": [
"prepayment",
"full_prepayment_wo_delivery",
"ip_payment",
"partial_prepayment_wo_delivery",
"full_payment_w_delivery",
"partial_payment_w_delivery",
"credit_w_delivery",
"credit_after_delivery"
],
"description": "Признак способа расчета"
},
"text": {
"type": "string",
"description": "Наименование"
}
}
}
},
"tax_totals": {
"type": "array",
"items": {
"type": "object",
"description": "Посчитанные налоги итогов",
"required": [
"tax_type",
"tax_pct",
"tax_amount"
],
"properties": {
"amount": {
"type": "string"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"tax_pct": {
"type": "string",
"description": "Процент налога"
},
"tax_amount": {
"type": "string",
"description": "Сумма налога"
}
}
}
},
"totals": {
"type": "array",
"items": {
"type": "object",
"description": "Описание посчитанного итога",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"emoney",
"emoney_other",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты (card - Картой, emoney - Электронным денежным средством, emoney_other)"
}
}
}
}
}
},
"ofd": {
"type": "object",
"description": "Оператор Фискальных Данных",
"properties": {
"inn": {
"type": "string",
"description": "ИНН Оператора фискальных данных"
},
"name": {
"type": "string",
"description": "Наименование оператора"
},
"check_url": {
"type": "string",
"description": "URL оператора фискальных данных"
}
}
},
"kkt": {
"type": "object",
"description": "Кассовый аппарат (ККТ)",
"properties": {
"sn": {
"type": "string",
"description": "Заводской номер ККТ. Глобальный уникальный номер кассы."
},
"rn": {
"type": "string",
"description": "Регистрационный номер ККТ."
},
"automatic_machine_number": {
"type": "string",
"description": "Номер автомата"
},
"version": {
"type": "string",
"description": "версия ККТ (тег 1188)"
}
}
},
"location": {
"type": "object",
"description": "Локация в которой находится касса",
"properties": {
"address": {
"type": "string",
"description": "Адрес места расположения ККТ"
},
"description": {
"type": "string",
"description": "Наименование места установки ККТ или адрес сайта, берется либо из чека, либо из параметров регистрации"
}
}
}
}
}
}
}
Закрытие фискального режимаPOST/v1/cashmachines/{kkt_sn}/close_fiscal_mode
Закрытие фискального режима
Example URI
- kkt_sn
string
(required)- mysecret
string
(required)
Headers
Accept: application/json
Schema
{
"type": "object",
"description": "Дополнительная информация для устройства"
}
200
Успех
Headers
Content-Type: application/json
Body
{}
Schema
{
"type": "object",
"description": "Фискальный документ",
"properties": {
"id": {
"type": "string",
"description": "Номер документа в ФН"
},
"document_type": {
"type": "string",
"enum": [
"RegistrationReport",
"ReRegistrationReport",
"ShiftOpenReport",
"ShiftCloseReport",
"Receipt",
"BSO",
"CorrectionReceipt",
"CorrectionBSO",
"CloseFNReport",
"CurrentReport"
],
"description": "Тип фискального документа"
},
"dt": {
"type": "string",
"format": "date-time",
"description": "Дата и время сохранения (с точностью до минуты) фискального документа"
},
"fp": {
"type": "string",
"description": "Фискальный признак"
},
"ofd_ticket_received": {
"type": "boolean",
"description": "Отправлен ли документ в ОФД"
},
"inn": {
"type": "string",
"description": "ИНН пользователя"
},
"rnm": {
"type": "string",
"description": "Регистрационный номер устройства"
},
"tax_mode": {
"type": "array",
"items": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
]
},
"description": "Режим налогооблажения"
},
"work_mode": {
"type": "array",
"items": {
"type": "string",
"enum": [
"crypt",
"autonomous",
"automatic",
"in_service_usage",
"BSO",
"internet_usage"
]
},
"description": "Режим работы"
},
"reregistration_code": {
"type": "integer",
"description": "Код причины перерегистрации"
},
"shift_number": {
"type": "integer",
"description": "Номер смены"
},
"receipt_type": {
"type": "string",
"enum": [
"income",
"charge",
"return_income",
"return_charge"
],
"description": "Тип чека"
},
"amount": {
"type": "string",
"description": "Сумма"
},
"number_unticketed_documents": {
"type": "string",
"description": "Количество неподтвержденных документов"
},
"first_unticketed_document_date": {
"type": "string",
"description": "Дата первого неподтвержденного документа"
},
"ofd_ticket_hex": {
"type": "string",
"description": "Фискальный признак ОФД"
},
"printform": {
"type": "array",
"items": {
"type": "string"
}
},
"rawform": {
"type": "object"
},
"fullform": {
"type": "object",
"description": "Фискальный чек",
"properties": {
"id": {
"type": "number",
"format": "long",
"description": "Номер документа в ФН"
},
"dt": {
"type": "string",
"format": "date-time",
"description": "Дата и время сохранения (с точностью до минуты) документа в ФН"
},
"fp": {
"type": "number",
"format": "long",
"description": "Фискальный признак"
},
"shift_number": {
"type": "number",
"format": "long",
"description": "Номер смены"
},
"document_index": {
"type": "number",
"format": "long",
"description": "Номер чека за смену"
},
"ofd_ticket_received": {
"type": "boolean",
"description": "Отправлен ли документ в ОФД"
},
"check_url": {
"type": "string",
"description": "URL для просмотра чека пользователем"
},
"localzone": {
"type": "string",
"description": "Название часового пояса по месту расчета"
},
"origin": {
"type": "string",
"enum": [
"online",
"kkt_fn",
"fn"
],
"description": "Источник происхождения чека"
},
"receipt_extra_contnent": {
"type": "object"
},
"firm": {
"type": "object",
"description": "Компания пробившая чек",
"properties": {
"inn": {
"type": "string",
"description": "ИНН компании"
},
"name": {
"type": "string",
"description": "Наименование компании"
},
"reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
}
}
},
"fn": {
"type": "object",
"description": "Фискальный накопитель",
"properties": {
"sn": {
"type": "string",
"description": "заводской номер ФН. Глобальный уникальный идентификатор"
},
"model": {
"type": "string",
"description": "модель ФН"
}
}
},
"receipt_content": {
"type": "object",
"description": "Содержимое чека",
"required": [
"firm_inn",
"receipt_type",
"taxation_type",
"firm_reply_email",
"firm_url",
"agent_type",
"client_email_or_phone",
"rows",
"payments"
],
"properties": {
"firm_inn": {
"type": "string",
"description": "ИНН компании"
},
"receipt_type": {
"type": "string",
"enum": [
"income",
"return_income",
"charge",
"return_charge"
],
"description": "Тип чека (income - Приход, return_income - Возврат прихода, charge - Расход, return_charge - Возврат расхода)"
},
"taxation_type": {
"type": "string",
"enum": [
"OSN",
"USN_income",
"USN_income_minus_charge",
"ESN_calc_income",
"ESN_agriculture",
"patent"
],
"description": "Применяемая в чеке система налогообложения"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"client_email_or_phone": {
"type": "string",
"description": "Электронная почта или телефон клиента"
},
"supplier_phone": {
"type": "string",
"description": "Телефон поставщика"
},
"firm_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
},
"firm_url": {
"type": "string",
"description": "URL фирмы"
},
"additional_document_requisite": {
"type": "string",
"description": "Дополнительный реквизит документа (16 байт)"
},
"additional_user_requisite": {
"type": "object",
"description": "Дополнительный реквизит пользователя",
"properties": {
"name": {
"type": "string",
"description": "Наименование реквизита (64 байта)"
},
"value": {
"type": "string",
"description": "Значение реквизита (256 байт)"
}
}
},
"rows": {
"type": "array",
"items": {
"type": "object",
"description": "Описание позиции чека",
"required": [
"price",
"qty",
"tax_type",
"payment_type_type",
"text"
],
"properties": {
"price": {
"type": "string",
"description": "Цена"
},
"qty": {
"type": "string",
"description": "Количество"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"payment_type_type": {
"type": "string",
"enum": [
"prepayment",
"full_prepayment_wo_delivery",
"ip_payment",
"partial_prepayment_wo_delivery",
"full_payment_w_delivery",
"partial_payment_w_delivery",
"credit_w_delivery",
"credit_after_delivery"
],
"description": "Признак способа расчета"
},
"text": {
"type": "string",
"description": "Наименование"
},
"agent_type": {
"type": "string",
"enum": [
"none_agent",
"payment_bank_agent",
"payment_bank_subagent",
"payment_agent",
"payment_subagent",
"confidant_agent",
"commission_agent",
"agent"
],
"description": "Признак агента"
},
"supplier_info": {
"type": "object",
"description": "Данные поставщика",
"required": [
"inn"
],
"properties": {
"inn": {
"type": "string",
"description": "ИНН поставщика"
},
"name": {
"type": "string",
"description": "Наименование поставщика"
},
"phone": {
"type": "string",
"description": "Телефон поставщика"
}
}
}
}
}
},
"payments": {
"type": "array",
"items": {
"type": "object",
"description": "Описание оплаты / Описание коррекции",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты. card -- электронным денежным средством, неденежные: prepayment -- предоплатой (зачетом аванса и (или) предыдущих платежей), credit -- постоплатой (в кредит), extension -- встречным представлением"
}
}
}
}
}
},
"receipt_calculated_content": {
"type": "object",
"description": "Посчитанные строки и итоги чека",
"required": [
"total",
"rows",
"tax_totals",
"totals"
],
"properties": {
"total": {
"type": "string",
"description": "Итог счета"
},
"money_received_total": {
"type": "string",
"description": "Полученное деньгами от клиента"
},
"firm_reply_email": {
"type": "string",
"description": "Адрес электронной почты отправителя чека"
},
"firm_url": {
"type": "string",
"description": "URL фирмы"
},
"qr": {
"type": "string",
"description": "Значение для QR-кода"
},
"rows": {
"type": "array",
"items": {
"type": "object",
"description": "Посчитанная позиция чека",
"required": [
"price",
"qty",
"amount",
"tax_type",
"tax_pct",
"tax_amount",
"payment_type_type",
"text"
],
"properties": {
"price": {
"type": "string",
"description": "Цена"
},
"qty": {
"type": "string",
"description": "Количество"
},
"amount": {
"type": "string",
"description": "Сумма"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"tax_pct": {
"type": "string",
"description": "Процент налога"
},
"tax_amount": {
"type": "string",
"description": "Сумма налога"
},
"payment_type_type": {
"type": "string",
"enum": [
"prepayment",
"full_prepayment_wo_delivery",
"ip_payment",
"partial_prepayment_wo_delivery",
"full_payment_w_delivery",
"partial_payment_w_delivery",
"credit_w_delivery",
"credit_after_delivery"
],
"description": "Признак способа расчета"
},
"text": {
"type": "string",
"description": "Наименование"
}
}
}
},
"tax_totals": {
"type": "array",
"items": {
"type": "object",
"description": "Посчитанные налоги итогов",
"required": [
"tax_type",
"tax_pct",
"tax_amount"
],
"properties": {
"amount": {
"type": "string"
},
"tax_type": {
"type": "string",
"enum": [
"nds_20",
"nds_18",
"nds_10",
"nds_0",
"nds_none",
"nds_20_120",
"nds_18_118",
"nds_10_110"
],
"description": "Ставка налога"
},
"tax_pct": {
"type": "string",
"description": "Процент налога"
},
"tax_amount": {
"type": "string",
"description": "Сумма налога"
}
}
}
},
"totals": {
"type": "array",
"items": {
"type": "object",
"description": "Описание посчитанного итога",
"required": [
"amount",
"payment_type"
],
"properties": {
"amount": {
"type": "string",
"description": "Сумма оплаты"
},
"payment_type": {
"type": "string",
"enum": [
"card",
"emoney",
"emoney_other",
"prepayment",
"credit",
"extension"
],
"description": "Тип оплаты (card - Картой, emoney - Электронным денежным средством, emoney_other)"
}
}
}
}
}
},
"ofd": {
"type": "object",
"description": "Оператор Фискальных Данных",
"properties": {
"inn": {
"type": "string",
"description": "ИНН Оператора фискальных данных"
},
"name": {
"type": "string",
"description": "Наименование оператора"
},
"check_url": {
"type": "string",
"description": "URL оператора фискальных данных"
}
}
},
"kkt": {
"type": "object",
"description": "Кассовый аппарат (ККТ)",
"properties": {
"sn": {
"type": "string",
"description": "Заводской номер ККТ. Глобальный уникальный номер кассы."
},
"rn": {
"type": "string",
"description": "Регистрационный номер ККТ."
},
"automatic_machine_number": {
"type": "string",
"description": "Номер автомата"
},
"version": {
"type": "string",
"description": "версия ККТ (тег 1188)"
}
}
},
"location": {
"type": "object",
"description": "Локация в которой находится касса",
"properties": {
"address": {
"type": "string",
"description": "Адрес места расположения ККТ"
},
"description": {
"type": "string",
"description": "Наименование места установки ККТ или адрес сайта, берется либо из чека, либо из параметров регистрации"
}
}
}
}
}
}
}
Установить дату и время на кассеPOST/v1/cashmachines/{kkt_sn}/set_datetime
Установить дату и время на кассе
Example URI
- kkt_sn
string
(required)- dt
string
(required)
Headers
Accept: application/json
200
Успех
Headers
Content-Type: application/json
Обновление кассыPOST/v1/cashmachines/{kkt_sn}/upgrade
Загрузка и обновление на кассы
Example URI
- kkt_sn
string
(required)- filename
string
(required)- mode
string
(required)
Headers
Accept: application/json
Schema
{
"type": "object",
"description": "Дополнительная информация для устройства"
}
200
Успех
Headers
Content-Type: application/json
Получить лог кассыGET/v1/cashmachines/{kkt_sn}/log
Получить лог кассы
Example URI
- kkt_sn
string
(required)- log_size
string
(required)
200
Успех
Schema
{
"type": "file"
}
Техническое обслуживание кассы ¶
Техническое обслуживание кассыPOST/v1/cashmachines/{kkt_sn}/maintenance
Техническое обслуживание кассы
Example URI
- kkt_sn
string
(required)
Headers
Accept: application/json
Schema
{
"type": "object",
"description": "Дополнительная информация для устройства"
}
200
Успех
Headers
Content-Type: application/json
Удаление данных из СУБД устройстваPOST/v1/cashmachines/{kkt_sn}/clear_device_data
Удаление данных из СУБД устройства
Example URI
- kkt_sn
string
(required)- mysecret
string
(required)
Headers
Accept: application/json
Schema
{
"type": "object",
"description": "Дополнительная информация для устройства"
}
200
Успех
Headers
Content-Type: application/json
Очистка отладочного ФНPOST/v1/cashmachines/{kkt_sn}/clear_debug_fn
Очистка отладочного ФН
Example URI
- kkt_sn
string
(required)- mysecret
string
(required)
Headers
Accept: application/json
Schema
{
"type": "object",
"description": "Дополнительная информация для устройства"
}
200
Успех
Headers
Content-Type: application/json