Configurable Activity Content Block

Choose a tool for developing with an AI agent:

  • use Alaio Vibecode to build an app for Bitrix24 from a task description without knowing any programming language. The agent writes the code and deploys the app to a server, with no manual hosting setup
  • use the MCP server to develop a REST API integration in your own project. The agent refers to the official REST documentation

Content blocks ContentBlockDto are the foundation of the content area of a timeline entry. The application builds the entry content from these blocks: text, links, name-value pairs, and a deadline.

The blocks are passed as an associative array in the blocks field: the key is the block identifier that the application sets itself, the value is the block object. The blocks array belongs to two objects:

Block types and their properties are the same in both cases. The blocks are displayed in the order they are listed in blocks.

General Block Structure

Each block has two fields: type — the block type, properties — its properties. Each type has its own set of properties, described below.

{
            "type": "text",
            "properties": {
                "value": "The customer confirmed the meeting"
            }
        }
        

How to Choose a Block Type

Type

What It Outputs

When to Use

text

A line of text with formatting

A short value, a label, a comment

largeText

Long text collapsed into a preview

An email, a call transcript, a description

link

A link with an action on click

Navigation to a CRM object, an external service, or an app

withTitle

A name-value pair

An entry with a set of fields

lineOfBlocks

Several blocks in one line

A name and a phone number side by side, text mixed with links

deadline

The current activity deadline with the option to change it

An activity with a deadline the user should see and edit

Restrictions and Errors

Only text, link, and deadline blocks can be nested inside withTitle and lineOfBlocks.

The remaining restrictions depend on where the blocks end up, and so do the calling permissions:

Content Block Types

Text

The type = text block outputs a formatted line of text in full, without collapsing. This is the basic block you start building an entry with.

Parameters

Required parameters are marked with *

Field

Description

value*
textWithTranslation

Text the user sees

multiline
boolean

Line break handling. With true, \n characters are replaced with <br>. Default is false

title
textWithTranslation

Tooltip text shown on hovering over the block

bold
boolean

Bold text. Default is false

size
string

Text size. Can take values xs, sm, md. Default is md

color
string

Text color. Can take values base_50, base_60, base_70, base_90. Any other value is rejected by the method with the ENUM_FIELD error

scope
string

Visibility scope, for example web

Example

Two lines of text, in bold, with a tooltip on hover:

{
            "type": "text",
            "properties": {
                "value": "The customer confirmed the meeting.\nThe meeting is at the office on Tiergartenstraße.",
                "multiline": true,
                "bold": true,
                "size": "md",
                "color": "base_90",
                "title": "Manager's comment"
            }
        }
        

This is how the text block looks in a timeline entry:

The text block in a timeline entry

Long Multiline Text

The type = largeText block outputs long multiline text and collapses it into a preview.

Parameters

Required parameters are marked with *

Field

Description

value*
textWithTranslation

Text the user sees

scope
string

Visibility scope, for example web

Example

{
            "type": "largeText",
            "properties": {
                "value": "Hello! My name is Klaus, I am calling about the request from the website. I checked the stock: both items are available, shipping is possible on Thursday. The customer asks for an invoice to a legal entity and delivery to the door. We agreed to call back once the budget is approved."
            }
        }
        

The user can expand the text with the "Show more" button:

The largeText block collapsed into a preview

Link

The type = link block outputs a link.

Parameters

Required parameters are marked with *

Field

Description

text*
textWithTranslation

Link text. HTML tags are not supported

action*
ActionDto

Action upon clicking the link

bold
boolean

Bold text. Default is false

scope
string

Visibility scope, for example web

Example

{
            "type": "link",
            "properties": {
             "text": "Open deal",
             "action": {
                "type": "redirect",
                "uri": "/crm/deal/details/123/"
             },
             "bold": true
            }
        }
        

The link block

Block with Heading

The type = withTitle block outputs a name-value pair. The value can be another content block.

Parameters

Required parameters are marked with *

Field

Description

title*
textWithTranslation

Title text

block*
ContentBlockDto

The content block displayed as the value. Blocks of types text, link, deadline are supported

inline
boolean

Display title and value in one line. Default is false

scope
string

Visibility scope, for example web

Examples

{
            "type": "withTitle",
            "properties": {
                "title": "Heading",
                "block": {
                    "type": "text",
                    "properties": {
                        "value": "Some value"
                    }
                }
            }
        }
        

The withTitle block with a text value

{
            "type": "withTitle",
            "properties": {
                "title": "Heading 2",
                "block": {
                    "type": "link",
                    "properties": {
                        "text": "Open deal",
                        "action": {
                            "type": "redirect",
                            "uri": "/crm/deal/details/123/"
                        }
                    }
                },
                "inline": true
            }
        }
        

The withTitle block with a link value in one line

Multiple Content Blocks in One Line

The type = lineOfBlocks block outputs several content blocks in a single line. This is how text with different formatting is combined with links in one line.

Parameters

Required parameters are marked with *

Field

Description

blocks*
object

Nested blocks: the key is the block identifier, the value is a ContentBlockDto object. No more than 20 blocks, types text, link, deadline are supported

scope
string

Visibility scope, for example web

Examples

{
            "type": "lineOfBlocks",
            "properties": {
                "blocks": {
                    "text": {
                        "type": "text",
                        "properties": {
                            "value": "Some text"
                        }
                    },
                    "link": {
                        "type": "link",
                        "properties": {
                            "text": "link",
                            "action": {
                                "type": "redirect",
                                "uri": "/crm/deal/details/123/"
                            }
                        }
                    },
                    "boldText": {
                        "type": "text",
                        "properties": {
                            "value": "bold text",
                            "bold": true
                        }
                    }
                }
            }
        }
        

Several blocks in one line

Deadline Selection

The type = deadline block shows the activity deadline and allows changing it right in the entry. The block is not displayed in an incoming activity or in an activity without a deadline.

Parameters

Required parameters are marked with *

Field

Description

readonly
boolean

Ban on changing the deadline. Default is false — the deadline can be changed right in the entry. Bitrix24 turns the ban on by itself if the activity is completed or the user has no edit access to the object the activity belongs to

scope
string

Visibility scope, for example web

Examples

{
            "type": "deadline",
            "properties": {
                "readonly": false
            }
        }
        

The deadline block

Continue Learning