Documentation

imconnector.connector.data.set

The method sets data for REST connector.

Parameters

Method Description Available from version
CONNECTOR Connector ID
LINE Line ID to which connector is attached.
DATA Array with data to be saved:
  • id - ID of the account connected to this connector.
  • url and url_im - links to chat. Parameter url_im is used in widget. When not specified, just url will be used.
  • name - channel name to be displayed in widget.

Example

	//imconnector.connector.data.set
	function connectorDataSet()
	{
		var params = {
			CONNECTOR: 'myrestconnector',
			LINE: 1,
			DATA: {
				id: 123,
				url: 'http://localhost',
				url_im: 'http://localhost',
				name: 'My rest connector name'
			}
		};
		BX24.callMethod(
			'imconnector.connector.data.set',
			params,
			function (result) {
				if (result.error())
					alert("Error: " + result.error());
				else
					alert("True: " + result.data());
			}
		);
	}


User Comments

User comments are not part of official documentation. Use information provided by other users in the comments at your own risk.

The User Comments section is not to be used as a feature discussion board. Only registered users can post comments. Your comment will be visible once it has been approved by the moderator.
© «Bitrix Inc.», 2001-2021, «Bitrix Inc.», 2021