Documentation

crm.externalchannel.connector.register

crm.externalchannel.connector.register

Registers an external channel connector.

Parameters

See. method parameters.

Call example for registration of connector

BX24.callMethod(
   "crm.externalchannel.connector.register",
   {
    fields:{
        "NAME":"Connector 1C",
        "ORIGINATOR_ID":"1C",
        "EXTERNAL_SERVER_HOST":"localhost:9090\/"
        }
   },
   function(result) 
   {
        if(result.error())
            console.error(result.error());
        else
            console.dir(result.data());
    }
);

Depending on whether counter agent is a Contact or a Company, external service calls the following commands:

crm.externalchannel.company
crm.externalchannel.contact
crm.externalchannel.activity.company
crm.externalchannel.activity.contact

Error codes

Code StatusText by default Description
ERROR_IMPORT_BATCH400 Bad RequestBatch is not defined.Data package is missing in the request.
ERROR_CONNECTOR_NOT_FOUND404 Not FoundConnector not found!Connector is not registered.
ERROR_CONNECTOR_CREATE500 Internal Server ErrorConnector not created.Error during the creation.
ERROR_CONNECTOR_REGISTRATION400 Bad Request Error in data transmission.
ERROR_CONNECTOR_INVALID403 ForbiddenConnector is invalid!Error during connector loading.
ERROR_PRESET_NOT_FOUND403 ForbiddenPreset is not defined.Preset is not found.


© «Bitrix24», 2001-2024
Up