Universal List Elements: Overview of Methods

Each list element consists of fields. You can add new fields and configure them using the methods lists.field.*.

Quick navigation: all methods

User documentation: How to add list elements

Connection with Other Objects

Universal Lists. Elements are created within lists. To add an element to a list, specify the parameters IBLOCK_TYPE_ID, IBLOCK_ID, and IBLOCK_CODE. Values can be obtained using the method lists.get.

List Sections. An element can be placed in a section using the parameter IBLOCK_SECTION_ID. The section identifier can be obtained using the method lists.section.get.

Elements from Other Lists. The field type Link to elements connects elements from different lists. In such a field, you can select another list and specify its elements as values. The ID of the selected elements is stored within the field, while their names are displayed.

For example, if you already have a list called Sizes with elements: XS, S, M, L, then in the Products list, you create a field of type Link to elements and specify the Sizes list. Now, when you add a product, you don't enter sizes manually but select the required elements from the list — for instance, S and M.

To obtain the list identifier, use the method lists.get. The element identifier can be found using the method lists.element.get.

CRM Objects. The field type Link to CRM elements connects list elements with CRM objects: leads, deals, SPAs, contacts, and companies. In list elements, this field is displayed as a link to the CRM object, and in the CRM card itself, a tab with the list name appears.

The format of the field value depends on the settings.

  • If the field settings allow linking to only one object, fill the field value with the object identifier without a symbolic prefix. For example, 3 — contact. Otherwise, the field will be displayed but not exported to Excel.

  • If linking to multiple objects is allowed, fill the field value with the identifier with a prefix. For example, C_3 — contact.

Users. To work with users in list elements, fields of type Link to employee, Created by, and Modified by are used. The values in the Created by and Modified by fields are automatically filled by the system. For fields of type Link to employee, data must be provided manually.

The user identifier can be obtained using the method user.get.

Drive. The field type File (Drive) connects list elements with the Drive. To add a file to the element's field:

Overview of Methods

Scope: lists

Who can execute the method: depends on the method

Method

Description

lists.element.add

Creates a list element

lists.element.update

Updates a list element

lists.element.get

Returns an element or a list of elements

lists.element.delete

Deletes a list element

lists.element.get.file.url

Returns the file path