Documentation

sale.cashbox.add

Description and example

Methods adds a cash register.

Example

BX.rest.callMethod(
    "sale.cashbox.add",
    {
        "NAME": 'Rest cash register',
        "REST_CODE": 'restcashbox01',
        "EMAIL": "user@example.com",
        "NUMBER_KKM": "123",
        "ACTIVE": "Y",
        "OFD": "bx_ofdruofd",
        "OFD_SETTINGS":
        {
            "OFD_MODE":
            {
                "IS_TEST": "N"
            }
        },
        "SETTINGS":
        {
            "AUTH":
            {
                "KEYWORD": "top_secret!",
                "PREFERENCE": "SECOND"
            },
            "INTERACTION":
            {
                "MODE": "ACTIVE"
            }
        }
    },
    function(result)
    {
        if(result.error())
            console.error(result.error());
        else
            console.dir(result.data());
    }
);

Parameters

Parameter Description Available from version
NAME Required. Cash register name.
REST_CODE Required. Cash register REST handler code.
EMAIL Required. Specifies an email to receive notifications in case of errors when printing receipts.
OFD OFD handler code (without OFD by default). Available OFD handlers:
  • bx_firstofd
  • bx_platformaofd
  • bx_yarusofd
  • bx_taxcomofd
  • bx_ofdruofd
  • bx_tenzorofd
  • bx_conturofd
OFD_SETTINGS OFD settings (empty array by default).
NUMBER_KKM Cash register external ID (empty by default).
KKM_ID Cash register ID (empty by default).
OFD_SETTINGS OFD settings (empty array by default).
ACTIVE Cash register activity (N by default).
SORT Sorting (100 by default).
USE_OFFLINE Cash register offline use (N by default).
SETTINGS Cash register settings according to settings structure (empty by default).


© «Bitrix24», 2001-2022
Up