Integration & Automation-create and update session groups
1. Usage scenarios
Submit a form within YIDA to create a DingTalk conversation Group and change the name and members of the created group chat group.
2. Procedure
2.1 Step 1: Create a basic form
2.1.1 build and configure the create conversation group form
Create a form to enter the group name, Group owner, and group member data required to create a conversation group.
Procedure:
- Create a common form named create conversation group 」.
- Add a single-line text component named group chat name, which is required. (The operation is shown in Figure 2.1-1)
Figure 2.1-1 add and configure a single-line text component
- Add a member component named Select Group owner and set it to required. (The operation is shown in Figure 2.1-2)
Figure 2.1-2 add and configure member components
- Add another member component named select group member, set it to required, and enable multiple selection mode. (The operation is shown in Figure 2.1-3)
Figure 2.1-3 add and configure member components
- Click save in the upper-right corner of the page.
2.1.2 build and configure the session group data summary form
Create a form to record the group chat information created by the create conversation group form. The group name and group chat ID are included. The group chat ID must be obtained from the data returned by the connector that created the session group.
Procedure:
- Create a common form named session group data summary 」.
- Add two single-line text components named group chat name and group chat ID respectively 」. (The operation is shown in Figure 2.1-4)
Figure 2.1-4 add and configure a single-line text component
- Click the Save button in the upper-right corner.
2.1.3 build and configure the update session group form
Create a form to enter the data required to update a group chat created through a connector.
Procedure:
- Create a common form named update session group 」.
- Add a drop-down radio component named "select group chat" and set it as required. The options are associated with the "group chat name" component in the "session Group Data Summary" form. (The operation is shown in Figure 2.1-5)
Figure 2.1-5 add and configure the drop-down radio component
- Add a single-line text component named group chat ID, set data linkage, and associate the session group data summary form, when the value of the select group chat component is equal to the value of the group chat name component, the value of the group chat ID is equal to the value of the group chat ID component. (The operation is shown in Figure 2.1-6)
Figure 2.1-6 add a single-line text component and set data linkage
- Add two member components, named "add group member" and "delete group member" respectively, to enable multi-selection mode. (The operation is shown in Figure 2.1-7)
Figure 2.1-7 add and configure member components
- Add a single-line text component named "changed Group chat name 」. (The operation is shown in Figure 2.1-8)
Figure 2.1-8 add and configure a single-line text component
- Click save in the upper-right corner of the page.
2.2 Step 2: Add and configure connectors
For more information about YIDA connectors, seeIntegration & Automation
Through the preceding steps, the basic form required to call the connector has been completed. Next, the Create session group form and update session group form add and configure connectors to make logical preparations for implementing requirements.
2.2.1 Add and configure connectors to the create group session form
This connector is used to automatically create a session group on DingTalk when submitting the create session group form.
Procedure:
- Background management page> create session group> Integration & automation> create Integration & Automation (as shown in Figure 2.2-1)
Figure 2.2-1 connector configuration entry
- Enter the connector name as "create conversation group", select "form event trigger" and click "confirm.
(The operation is shown in Figure 2.2-2)
Figure 2.2-2 New connector
- Configure the form trigger event: the trigger event is "created successfully", select "all data" for data filtering, and click save.
(The operation is shown in Figure 2.2-3)
Figure 2.2-3 configure the connector form trigger event
- Select connector application: Select session group as the application and click next. (The operation is shown in Figure 2.2-4)
Figure 2.2-4 select connector application
- Select action: Select create session group and click next. (The operation is shown in Figure 2.2-5)
Figure 2.2-5 Select connector execution action
- Configure the execution action and click save. (Operation is shown in Figure 2.2-6)
Figure 2.2-6 configuration connector execution action
- Click save in the upper-right corner of the page and click Publish.
- Add a new data node under the connector node and configure it. Returns the group session ID to the group session data summary form. (The operation is shown in Figure 2.2-7)
Figure 2.2-7(1) add new data nodes
Figure 2.2-7(2) configure new data nodes
2.2.2 Add and configure connectors to the update group session form
This connector is used to automatically update the session group created by the connector on DingTalk when submitting the update session group form.
Procedure:
- Background management page> create session group> Settings> Page Settings> Integration & automation> create Integration & Automation (as shown in Figure 2.2-8)
Figure 2.2-8 connector configuration entry
- Enter the connector name as "create conversation group", select "form event trigger" and click "confirm.
(The operation is shown in Figure 2.2-9)
Figure 2.2-9 New connector
- Configure the form trigger event: the trigger event is "created successfully", select "all data" for data filtering, and click save.
(The operation is shown in Figure 2.2-10)
Figure 2.2-10 configure the connector form trigger event
- Select connector application: Select session group as the application and click next.
(The operation is shown in Figure 2.2-11)
Figure 2.2-11 select connector application
- Select action: Select create session group and click next.
(The operation is shown in Figure 2.2-12)
Figure 2.2-12 select connector execution action
- Configure the execution action and click save. (The operation is shown in Figure 2.2-13)
Figure 2.2-13 configuration connector execution action
- Click save in the upper-right corner of the page and click Publish.
2.3 Step 3: submit the form and trigger the connector
2.3.1 submit the create group session form to trigger the creation of a group chat connector
Figure 2.3-1 submit the create group session form
2.3.2 submit the update group session form to trigger the update group chat connector
Figure 2.3-2 submit an update group session form
3. Achieve results
Figure 3-1 shows the effect of creating group sessions
Figure 3-2 update group session effect display