3.1.1-Robot Chatflow
1. Overview
Interface Name: Robot Dialog Stream
Version number: v1.0.0
2. Information
WebSocket: wss://DOMAIN/openapi/v2/ws/dialog/
Domain: Refer to "Service address description"
3. Request parameters
Request body field:
cybertron-robot-key
string
Yes
Robot key
cybertron-robot-token
string
Yes
Robot token
username
string
Yes
User account
segment_code
string
No
Session encoding, the dialog history can be divided through this parameter. This parameter obtain can be called to obtain session information, interface creation, or session history. If this field is not passed, the system will query the latest session through the user id and robot id. If it cannot be found, it will be automatically created
question
string
No
Input question
open_flow_trigger
string
No
autoThe model is compatible with normal dialog and intent recognition;directThe mode needs to specify the specific flow_uuid to call directly
open_flow_uuid
string
No
Specify the specific flow to run;open_flow_triggerfordirectIt is required
open_flow_node_uuid
string
No
Specify a specific node in the flow to run
open_flow_node_inputs
object
No
Specify the entry parameter of a specific node in the flow
open_flow_debug
int
No
1 Yes, 0 No; default 0, run flow in non-debug mode (only print node reply and some important information)
4. Response field description
Response field description:
code
string
6-digit string;000000It is normal;400The beginning is an error
message
string
Status description
type
string
message type;stringWhen data is a string;jsonWhen data is a json object;flowWhen data is flow output json object
index
int
Reference v1 interface
flow_name
string
currently running conversation flow name
node_type
string
Current running node type
node_title
string
currently running node name
node_waiting_input
int
1 is waiting for user output; 0 is not waiting.
data
object
message body
data.history
array
dialog history, array form, human-computer interaction in which each element in the array is a node
data.output
object
flow output of the current node
data.answer
string
current node output (currently only string output is provided)
data.content_type
string
When it is text, it means that answer is a string output (currently only text type is provided)
data.flow_stage
string
current flow state (corresponding to code)
data.code
string
data information output by flow (debug mode or normal output)
data.node_stream
int
1 or 0; 1 is a streaming type, and the answer needs to be spliced into the final
data.node_answer_index
int
When it is a stream, it indicates the current splicing number of the answer
data.node_answer_finish
string
y or n; when it is y, it means the end of the output of the current node
data.cur_node_id
string
id of the current node
data.parent_node_id
string
parent node id of the current node
Description of code code in response message body:
000000
Normal output
400000
An error occurred
002000
flow entry
002001
flow exit
002002
node entry
002003
node debug information output (debug mode only)
002004
flow waits for user input before continuing to run
002005
The current running round of the flow engine ends
5. Example
The first round
【Client → Server】The user executes the specified flow through flow_uuid
{
"question": "",
"username": "me",
"cybertron-robot-key": "PL1qFV************ lhkA0NSPo=",
"cybertron-robot-token": "MTcwMjg***************************************ZdWJ3ckd1ODQ9",
"segment_code": "cd0f14c3-801c-4b2d-8882-395e4ee7b9f5",
"open_flow_trigger": "direct",
"open_flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"open_flow_node_uuid": "",
"open_flow_node_inputs": {},
"open_flow_debug": 1
}【Server → Client】Task received successfully
{
"code": "000000",
"message": "task send success,",
"type": "json",
"index": -2,
"data": {
"task_id": "7e912afca57b11ef8652004238b4a21d"
}
}[Server → Client] The problem was sent successfully, and a unique dialog id was generated (see the function of v1 version interface)
{
"code": "000000",
"message": "send question success",
"index": -1,
"type": "json",
"data": {
"question": "",
"dialog_id": "1858406156273270784"
}
}[Server → Client] Server performs flow execution
{
"code": "000000",
"message": "success",
"dialog_id": 1858406156273270784,
"type": "flow",
"index": 0,
"data": {
"final": true,
"id": null,
"response_create_time": "2024-11-18 15:05",
"response_create_time_timestamp": "1731913529981",
"response_update_time": "2024-11-18 15:05",
"response_update_time_timestamp": "1731913529981",
"flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"history": [],
"output": {},
"answer": "flow_enter",
"content_type": "text",
"session_id": "7edd9595-a57b-11ef-bce8-004238b4a21d",
"flow_stage": "flow_enter",
"code": "002000",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0,
"target_node_id": "start0000000000000000000000",
"source_node_id": "start0000000000000000000000",
"cur_node_id": "start0000000000000000000000",
"parent_node_id": "start000000000000000000000000"
},
"finish": "y",
"cur_node_id": "start0000000000000000000000",
"node_id": "start000000000000000000000",
"debug": 1,
"node_developer": 0,
"flow_name": "Customer Information Collection Assistant",
"node_type": "start",
"node_title": "Customer Information Collection Assistant",
"parent_node_id": "start0000000000000000000000",
"node_waiting_input": 0
}[Server → Client] Node jump information during flow execution, jump from start node to node 1
{
"code": "000000",
"message": "success",
"dialog_id": 1858406156273270784,
"type": "flow",
"index": 0,
"data": {
"final": true,
"id": null,
"response_create_time": "2024-11-18 15:05",
"response_create_time_timestamp": "1731913529981",
"response_update_time": "2024-11-18 15:05",
"response_update_time_timestamp": "1731913529981",
"flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"history": [],
"output": {
"inputs": {},
"variables": {},
"entities": {},
"robot_user_asking": "",
"user_robot_replying": "",
"robot_user_replying": ""
},
"answer": "node_id: a93311b9-7e1b-40d3-a0e5-94e26e2d9748 enter by prev_node_id: start000000000000000000000000000000000000000000000",
"content_type": "text",
"session_id": "7edd9595-a57b-11ef-bce8-004238b4a21d",
"flow_stage": "flow_running",
"code": "002002",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0,
"target_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"source_node_id": "start0000000000000000000000",
"cur_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"parent_node_id": "start000000000000000000000000"
},
"finish": "y",
"cur_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"node_id": "start000000000000000000000",
"debug": 1,
"node_developer": 0,
"flow_name": "Customer Information Collection Assistant",
"node_type": "answer",
"node_title": null,
"node_waiting": false,
"parent_node_id": "start0000000000000000000000",
"node_waiting_input": 0
}[Server → Client] Node 1 executes, see data.answer for replying to client content.
{
"code": "000000",
"message": "success",
"dialog_id": 1858406156273270784,
"type": "flow",
"index": 0,
"data": {
"final": true,
"id": null,
"response_create_time": "2024-11-18 15:05",
"response_create_time_timestamp": "1731913529981",
"response_update_time": "2024-11-18 15:05",
"response_update_time_timestamp": "1731913529981",
"flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"history": [
{
"timestamp": 1731913531091,
"time_date": "20241118150531091582",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"robot_user_replying": "Hello, welcome to our company to handle business! Your name and contact information will be collected now. We will keep it confidential. Please rest assured.",
"robot_user_asking": "",
"user_robot_replying": ""
}
],
"output": {
"inputs": {},
"variables": {},
"entities": {},
"robot_user_asking": "",
"user_robot_replying": "",
"robot_user_replying": "Hello, welcome to our company to handle business! Your name and contact information will be collected now. We will keep it confidential. Please rest assured."
},
"Answer": "Hello, welcome to our company to handle business! Your name and contact information will be collected now. We will keep it confidential. Please rest assured.",
"content_type": "text",
"session_id": "7edd9595-a57b-11ef-bce8-004238b4a21d",
"flow_stage": "flow_running",
"code": "000000",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0,
"target_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"source_node_id": "start0000000000000000000000",
"cur_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"parent_node_id": "start000000000000000000000000"
},
"finish": "y",
"cur_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"node_id": "start000000000000000000000",
"debug": 1,
"node_developer": 0,
"flow_name": "Customer Information Collection Assistant",
"node_type": "answer",
"node_title": null,
"node_waiting": false,
"parent_node_id": "start0000000000000000000000",
"node_waiting_input": 0
}[Server → Client] Flow execution process, node jumps information, this is node 1 jumps to node 2
{
"code": "000000",
"message": "success",
"dialog_id": 1858406156273270784,
"type": "flow",
"index": 0,
"data": {
"final": true,
"id": null,
"response_create_time": "2024-11-18 15:05",
"response_create_time_timestamp": "1731913529981",
"response_update_time": "2024-11-18 15:05",
"response_update_time_timestamp": "1731913529981",
"flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"history": [
{
"timestamp": 1731913531091,
"time_date": "20241118150531091582",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"robot_user_replying": "Hello, welcome to our company to handle business! Your name and contact information will be collected now. We will keep it confidential. Please rest assured.",
"robot_user_asking": "",
"user_robot_replying": ""
}
],
"output": {
"inputs": {},
"variables": {},
"entities": {},
"robot_user_asking": "",
"user_robot_replying": "",
"robot_user_replying": ""
},
"answer": "node_id: 67a4219c-963d-4e9d-8af9-81e6d3af6095 enter by prev_node_id: a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"content_type": "text",
"session_id": "7edd9595-a57b-11ef-bce8-004238b4a21d",
"flow_stage": "flow_running",
"code": "002002",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0,
"target_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"source_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"cur_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"parent_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748"
},
"finish": "y",
"cur_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"debug": 1,
"node_developer": 0,
"flow_name": "Customer Information Collection Assistant",
"node_type": "parameter_extractor",
"node_title": null,
"node_waiting": false,
"parent_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"node_waiting_input": 0
}[Server → Client] Node 2 executes, prompting the user to enter a name
{
"code": "000000",
"message": "success",
"dialog_id": 1858406156273270784,
"type": "flow",
"index": 0,
"data": {
"final": true,
"id": null,
"response_create_time": "2024-11-18 15:05",
"response_create_time_timestamp": "1731913529981",
"response_update_time": "2024-11-18 15:05",
"response_update_time_timestamp": "1731913529981",
"flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"history": [
{
"timestamp": 1731913531091,
"time_date": "20241118150531091582",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"robot_user_replying": "Hello, welcome to our company to handle business! Your name and contact information will be collected now. We will keep it confidential. Please rest assured.",
"robot_user_asking": "",
"user_robot_replying": ""
}
],
"output": {
"inputs": {},
"variables": {},
"entities": {},
"robot_user_asking": "Please provide your name",
"user_robot_replying": "",
"robot_user_replying": ""
},
"Answer": "Please provide your name",
"content_type": "text",
"session_id": "7edd9595-a57b-11ef-bce8-004238b4a21d",
"flow_stage": "flow_running",
"code": "000000",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0,
"target_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"source_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"cur_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"parent_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748"
},
"finish": "y",
"cur_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"debug": 1,
"node_developer": 0,
"flow_name": "Customer Information Collection Assistant",
"node_type": "parameter_extractor",
"node_title": null,
"node_waiting": false,
"parent_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"node_waiting_input": 0
}[Server → Client] Server output client notification client input
{
"code": "000000",
"message": "success",
"dialog_id": 1858406156273270784,
"type": "flow",
"index": 0,
"data": {
"final": true,
"id": null,
"response_create_time": "2024-11-18 15:05",
"response_create_time_timestamp": "1731913529981",
"response_update_time": "2024-11-18 15:05",
"response_update_time_timestamp": "1731913529981",
"flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"history": [
{
"timestamp": 1731913531091,
"time_date": "20241118150531091582",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"robot_user_replying": "Hello, welcome to our company to handle business! Your name and contact information will be collected now. We will keep it confidential. Please rest assured.",
"robot_user_asking": "",
"user_robot_replying": ""
}
],
"output": {
"inputs": {},
"variables": {},
"entities": {},
"robot_user_asking": "Please provide your name",
"user_robot_replying": "",
"robot_user_replying": ""
},
"answer": "node_waiting_input",
"content_type": "text",
"session_id": "7edd9595-a57b-11ef-bce8-004238b4a21d",
"flow_stage": "flow_running",
"code": "002004",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0,
"target_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"source_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"cur_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"parent_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748"
},
"finish": "y",
"cur_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"debug": 1,
"node_developer": 0,
"flow_name": "Customer Information Collection Assistant",
"node_type": "parameter_extractor",
"node_title": null,
"node_waiting": true,
"parent_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"node_waiting_input": 1
}[Server→Client] The type is flow and finish is y means that the current round of flow interaction is completed
{
"code": "000000",
"message": "success",
"dialog_id": 1858406156273270784,
"type": "flow",
"index": 0,
"data": {
"code": "002005",
"answer": "current_communication_complete",
"content_type": "text",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0
},
"finish": "y"
}Round 2
[Client → Server] question is called Zhang San for my name, providing the information that flow needs to collect
{
"question": "My name is Zhang San",
"username": "me",
"cybertron-robot-key": "PL1qFV************ lhkA0NSPo=",
"cybertron-robot-token": "MTcwMjg***************************************ZdWJ3ckd1ODQ9",
"segment_code": "cd0f14c3-801c-4b2d-8882-395e4ee7b9f5",
"open_flow_trigger": "direct",
"open_flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"open_flow_node_uuid": "",
"open_flow_node_inputs": {},
"open_flow_debug": 1
}[Server → Client] The server received the message
{
"code": "000000",
"message": "task send success,",
"type": "json",
"index": -2,
"data": {
"task_id": "f15a5e0ba57b11efb0b4004238b4a21d"
}
}
{
"code": "000000",
"message": "send question success",
"index": -1,
"type": "json",
"data": {
"question": "My name is Zhang San",
"dialog_id": "1858406963072811008"
}
}[Server → Client] The server responds to client information and collects information about entity slots and values
{
"code": "000000",
"message": "success",
"dialog_id": 1858406963072811008,
"type": "flow",
"index": 0,
"data": {
"final": true,
"id": null,
"response_create_time": "2024-11-18 15:08",
"response_create_time_timestamp": "1731913722548",
"response_update_time": "2024-11-18 15:08",
"response_update_time_timestamp": "1731913722548",
"flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"history": [
{
"timestamp": 1731913531091,
"time_date": "20241118150531091582",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"robot_user_replying": "Hello, welcome to our company to handle business! Your name and contact information will be collected now. We will keep it confidential. Please rest assured.",
"robot_user_asking": "",
"user_robot_replying": ""
},
{
"timestamp": 1731913725910,
"time_date": "20241118150845910619",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My name is Zhang San"
},
{
"timestamp": 1731913725910,
"time_date": "20241118150845910619",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My name is Zhang San"
}
],
"output": {
"inputs": {},
"variables": {},
"entities": {
"customerName": "Zhang San"
},
"robot_user_asking": "",
"user_robot_replying": "My name is Zhang San",
"robot_user_replying": ""
},
"answer": "entity: customerName, value: Zhang San",
"content_type": "text",
"session_id": "7edd9595-a57b-11ef-bce8-004238b4a21d",
"flow_stage": "flow_running",
"code": "002003",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0,
"target_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"source_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"cur_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"parent_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748"
},
"finish": "y",
"cur_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"debug": 1,
"node_developer": 0,
"flow_name": "Customer Information Collection Assistant",
"node_type": "parameter_extractor",
"node_title": null,
"node_waiting": false,
"parent_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"node_waiting_input": 0
}[Server → Client] Node 2 executes, prompting the user to enter the mobile phone number
{
"code": "000000",
"message": "success",
"dialog_id": 1858406963072811008,
"type": "flow",
"index": 0,
"data": {
"final": true,
"id": null,
"response_create_time": "2024-11-18 15:08",
"response_create_time_timestamp": "1731913722548",
"response_update_time": "2024-11-18 15:08",
"response_update_time_timestamp": "1731913722548",
"flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"history": [
{
"timestamp": 1731913531091,
"time_date": "20241118150531091582",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"robot_user_replying": "Hello, welcome to our company to handle business! Your name and contact information will be collected now. We will keep it confidential. Please rest assured.",
"robot_user_asking": "",
"user_robot_replying": ""
},
{
"timestamp": 1731913725910,
"time_date": "20241118150845910619",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My name is Zhang San"
},
{
"timestamp": 1731913725910,
"time_date": "20241118150845910619",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My name is Zhang San"
}
],
"output": {
"inputs": {},
"variables": {},
"entities": {
"customerName": "Zhang San"
},
"robot_user_asking": "Please provide your mobile phone number",
"user_robot_replying": "",
"robot_user_replying": ""
},
"Answer": "Please provide your mobile phone number",
"content_type": "text",
"session_id": "7edd9595-a57b-11ef-bce8-004238b4a21d",
"flow_stage": "flow_running",
"code": "000000",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0,
"target_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"source_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"cur_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"parent_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748"
},
"finish": "y",
"cur_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"debug": 1,
"node_developer": 0,
"flow_name": "Customer Information Collection Assistant",
"node_type": "parameter_extractor",
"node_title": null,
"node_waiting": false,
"parent_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"node_waiting_input": 0
}[Server → Client] Server output client notification client input
{
"code": "000000",
"message": "success",
"dialog_id": 1858406963072811008,
"type": "flow",
"index": 0,
"data": {
"final": true,
"id": null,
"response_create_time": "2024-11-18 15:08",
"response_create_time_timestamp": "1731913722548",
"response_update_time": "2024-11-18 15:08",
"response_update_time_timestamp": "1731913722548",
"flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"history": [
{
"timestamp": 1731913531091,
"time_date": "20241118150531091582",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"robot_user_replying": "Hello, welcome to our company to handle business! Your name and contact information will be collected now. We will keep it confidential. Please rest assured.",
"robot_user_asking": "",
"user_robot_replying": ""
},
{
"timestamp": 1731913725910,
"time_date": "20241118150845910619",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My name is Zhang San"
},
{
"timestamp": 1731913725910,
"time_date": "20241118150845910619",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My name is Zhang San"
}
],
"output": {
"inputs": {},
"variables": {},
"entities": {
"customerName": "Zhang San"
},
"robot_user_asking": "Please provide your mobile phone number",
"user_robot_replying": "",
"robot_user_replying": ""
},
"answer": "node_waiting_input",
"content_type": "text",
"session_id": "7edd9595-a57b-11ef-bce8-004238b4a21d",
"flow_stage": "flow_running",
"code": "002004",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0,
"target_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"source_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"cur_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"parent_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748"
},
"finish": "y",
"cur_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"debug": 1,
"node_developer": 0,
"flow_name": "Customer Information Collection Assistant",
"node_type": "parameter_extractor",
"node_title": null,
"node_waiting": true,
"parent_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"node_waiting_input": 1
}[Server→Client] The type is flow and finish is y means that the current round of flow interaction is completed
{
"code": "000000",
"message": "success",
"dialog_id": 1858406156273270784,
"type": "flow",
"index": 0,
"data": {
"code": "002005",
"answer": "current_communication_complete",
"content_type": "text",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0
},
"finish": "y"
}The third round
[Client → Server] question provides users with mobile phone number information and provides information that flow needs to collect
{
"question": "My mobile phone number is 133103335027",
"username": "me",
"cybertron-robot-key": "PL1qFV************ lhkA0NSPo=",
"cybertron-robot-token": "MTcwMjg***************************************ZdWJ3ckd1ODQ9",
"segment_code": "cd0f14c3-801c-4b2d-8882-395e4ee7b9f5",
"open_flow_trigger": "direct",
"open_flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"open_flow_node_uuid": "",
"open_flow_node_inputs": {},
"open_flow_debug": 1
}[Server → Client] The server received the message
{
"code": "000000",
"message": "task send success,",
"type": "json",
"index": -2,
"data": {
"task_id": "266cf5eea57c11efa06a004238b4a21d"
}
}
{
"code": "000000",
"message": "send question success",
"index": -1,
"type": "json",
"data": {
"question": "My mobile phone number is 133103335027",
"dialog_id": "1858407336739160064"
}
}[Server → Client] Mobile phone number entity information collected by the server
{
"code": "000000",
"message": "success",
"dialog_id": 1858407336739160064,
"type": "flow",
"index": 0,
"data": {
"final": true,
"id": null,
"response_create_time": "2024-11-18 15:10",
"response_create_time_timestamp": "1731913811598",
"response_update_time": "2024-11-18 15:10",
"response_update_time_timestamp": "1731913811598",
"flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"history": [
{
"timestamp": 1731913531091,
"time_date": "20241118150531091582",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"robot_user_replying": "Hello, welcome to our company to handle business! Your name and contact information will be collected now. We will keep it confidential. Please rest assured.",
"robot_user_asking": "",
"user_robot_replying": ""
},
{
"timestamp": 1731913725910,
"time_date": "20241118150845910619",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My name is Zhang San"
},
{
"timestamp": 1731913728170,
"time_date": "20241118150848170189",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "Please provide your mobile phone number",
"user_robot_replying": ""
},
{
"timestamp": 1731913814087,
"time_date": "20241118151014087544",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My mobile phone number is 133103335027"
},
{
"timestamp": 1731913814087,
"time_date": "20241118151014087544",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My mobile phone number is 133103335027"
}
],
"output": {
"inputs": {},
"variables": {},
"entities": {
"customerName": "Zhang San",
"customerPhoneNumber": "133103335027"
},
"robot_user_asking": "",
"user_robot_replying": "My mobile phone number is 133103335027",
"robot_user_replying": ""
},
"answer": "entity: customerPhoneNumber, value: 133103335027",
"content_type": "text",
"session_id": "7edd9595-a57b-11ef-bce8-004238b4a21d",
"flow_stage": "flow_running",
"code": "002003",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0,
"target_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"source_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"cur_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"parent_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748"
},
"finish": "y",
"cur_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"debug": 1,
"node_developer": 0,
"flow_name": "Customer Information Collection Assistant",
"node_type": "parameter_extractor",
"node_title": null,
"node_waiting": false,
"parent_node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"node_waiting_input": 0
}[Server → Client] Node transfer information, jump from Node 2 to Node 4 to execute code node
{
"code": "000000",
"message": "success",
"dialog_id": 1858407336739160064,
"type": "flow",
"index": 0,
"data": {
"final": true,
"id": null,
"response_create_time": "2024-11-18 15:10",
"response_create_time_timestamp": "1731913811598",
"response_update_time": "2024-11-18 15:10",
"response_update_time_timestamp": "1731913811598",
"flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"history": [
{
"timestamp": 1731913531091,
"time_date": "20241118150531091582",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"robot_user_replying": "Hello, welcome to our company to handle business! Your name and contact information will be collected now. We will keep it confidential. Please rest assured.",
"robot_user_asking": "",
"user_robot_replying": ""
},
{
"timestamp": 1731913725910,
"time_date": "20241118150845910619",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My name is Zhang San"
},
{
"timestamp": 1731913728170,
"time_date": "20241118150848170189",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "Please provide your mobile phone number",
"user_robot_replying": ""
},
{
"timestamp": 1731913814087,
"time_date": "20241118151014087544",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My mobile phone number is 133103335027"
},
{
"timestamp": 1731913814087,
"time_date": "20241118151014087544",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My mobile phone number is 133103335027"
}
],
"output": {
"inputs": {},
"variables": {},
"entities": {
"customerName": "Zhang San",
"customerPhoneNumber": "133103335027"
},
"robot_user_asking": "",
"user_robot_replying": "",
"robot_user_replying": ""
},
"answer": "node_id: 658d5db7-2460-4ed9-9842-59398e0b894a enter by prev_node_id: 67a4219c-963d-4e9d-8af9-81e6d3af6095",
"content_type": "text",
"session_id": "7edd9595-a57b-11ef-bce8-004238b4a21d",
"flow_stage": "flow_running",
"code": "002002",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0,
"target_node_id": "658d5db7-2460-4ed9-9842-59398e0b894a",
"source_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"cur_node_id": "658d5db7-2460-4ed9-9842-59398e0b894a",
"parent_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095"
},
"finish": "y",
"cur_node_id": "658d5db7-2460-4ed9-9842-59398e0b894a",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"debug": 1,
"node_developer": 0,
"flow_name": "Customer Information Collection Assistant",
"node_type": "flow_code",
"node_title": "",
"node_waiting": false,
"parent_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"node_waiting_input": 0
}[Server → Client] Code code node outputs debugging information
{
"code": "000000",
"message": "success",
"dialog_id": 1858407336739160064,
"type": "flow",
"index": 0,
"data": {
"final": true,
"id": null,
"response_create_time": "2024-11-18 15:10",
"response_create_time_timestamp": "1731913811598",
"response_update_time": "2024-11-18 15:10",
"response_update_time_timestamp": "1731913811598",
"flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"history": [
{
"timestamp": 1731913531091,
"time_date": "20241118150531091582",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"robot_user_replying": "Hello, welcome to our company to handle business! Your name and contact information will be collected now. We will keep it confidential. Please rest assured.",
"robot_user_asking": "",
"user_robot_replying": ""
},
{
"timestamp": 1731913725910,
"time_date": "20241118150845910619",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My name is Zhang San"
},
{
"timestamp": 1731913728170,
"time_date": "20241118150848170189",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "Please provide your mobile phone number",
"user_robot_replying": ""
},
{
"timestamp": 1731913814087,
"time_date": "20241118151014087544",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My mobile phone number is 133103335027"
},
{
"timestamp": 1731913814087,
"time_date": "20241118151014087544",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My mobile phone number is 133103335027"
}
],
"output": {
"inputs": {},
"variables": {},
"entities": {
"customerName": "Zhang San",
"customerPhoneNumber": "133103335027"
},
"robot_user_asking": "",
"user_robot_replying": "",
"robot_user_replying": ""
},
"answer": "{\"my_var\": \"Mr. Zhang, your last number is: 5027. \", \"last_code_time_cost\": 0.6902499198913574, \"last_code_error\": \"\"}",
"content_type": "text",
"session_id": "7edd9595-a57b-11ef-bce8-004238b4a21d",
"flow_stage": "flow_running",
"code": "002003",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0,
"target_node_id": "658d5db7-2460-4ed9-9842-59398e0b894a",
"source_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"cur_node_id": "658d5db7-2460-4ed9-9842-59398e0b894a",
"parent_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095"
},
"finish": "y",
"cur_node_id": "658d5db7-2460-4ed9-9842-59398e0b894a",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"debug": 1,
"node_developer": 0,
"flow_name": "Customer Information Collection Assistant",
"node_type": "flow_code",
"node_title": "",
"node_waiting": false,
"parent_node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"node_waiting_input": 0
}[Server → Client] Flow node jump information, jump from code node to text reply node
{
"code": "000000",
"message": "success",
"dialog_id": 1858407336739160064,
"type": "flow",
"index": 0,
"data": {
"final": true,
"id": null,
"response_create_time": "2024-11-18 15:10",
"response_create_time_timestamp": "1731913811598",
"response_update_time": "2024-11-18 15:10",
"response_update_time_timestamp": "1731913811598",
"flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"history": [
{
"timestamp": 1731913531091,
"time_date": "20241118150531091582",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"robot_user_replying": "Hello, welcome to our company to handle business! Your name and contact information will be collected now. We will keep it confidential. Please rest assured.",
"robot_user_asking": "",
"user_robot_replying": ""
},
{
"timestamp": 1731913725910,
"time_date": "20241118150845910619",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My name is Zhang San"
},
{
"timestamp": 1731913728170,
"time_date": "20241118150848170189",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "Please provide your mobile phone number",
"user_robot_replying": ""
},
{
"timestamp": 1731913814087,
"time_date": "20241118151014087544",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My mobile phone number is 133103335027"
},
{
"timestamp": 1731913814087,
"time_date": "20241118151014087544",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My mobile phone number is 133103335027"
}
],
"output": {
"inputs": {},
"variables": {
"last_code_response": {
"desc": "Mr. Zhang, your last number is: 5027."
},
"my_var": "Mr. Zhang, your last number is: 5027.",
"last_code_time_cost": 0.6902499198913574,
"last_code_error": ""
},
"entities": {
"customerName": "Zhang San",
"customerPhoneNumber": "133103335027"
},
"robot_user_asking": "",
"user_robot_replying": "",
"robot_user_replying": ""
},
"answer": "node_id: 8893d45d-64a4-4854-8f51-0c4c18842839 enter by prev_node_id: 658d5db7-2460-4ed9-9842-59398e0b894a",
"content_type": "text",
"session_id": "7edd9595-a57b-11ef-bce8-004238b4a21d",
"flow_stage": "flow_running",
"code": "002002",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0,
"target_node_id": "8893d45d-64a4-4854-8f51-0c4c18842839",
"source_node_id": "658d5db7-2460-4ed9-9842-59398e0b894a",
"cur_node_id": "8893d45d-64a4-4854-8f51-0c4c18842839",
"parent_node_id": "658d5db7-2460-4ed9-9842-59398e0b894a"
},
"finish": "y",
"cur_node_id": "8893d45d-64a4-4854-8f51-0c4c18842839",
"node_id": "658d5db7-2460-4ed9-9842-59398e0b894a",
"debug": 1,
"node_developer": 0,
"flow_name": "Customer Information Collection Assistant",
"node_type": "answer",
"node_title": null,
"node_waiting": false,
"parent_node_id": "658d5db7-2460-4ed9-9842-59398e0b894a",
"node_waiting_input": 0
}[Server → Client] Flow text reply node output information, see data.answer
{
"code": "000000",
"message": "success",
"dialog_id": 1858407336739160064,
"type": "flow",
"index": 0,
"data": {
"final": true,
"id": null,
"response_create_time": "2024-11-18 15:10",
"response_create_time_timestamp": "1731913811598",
"response_update_time": "2024-11-18 15:10",
"response_update_time_timestamp": "1731913811598",
"flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"history": [
{
"timestamp": 1731913531091,
"time_date": "20241118150531091582",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"robot_user_replying": "Hello, welcome to our company to handle business! Your name and contact information will be collected now. We will keep it confidential. Please rest assured.",
"robot_user_asking": "",
"user_robot_replying": ""
},
{
"timestamp": 1731913725910,
"time_date": "20241118150845910619",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My name is Zhang San"
},
{
"timestamp": 1731913728170,
"time_date": "20241118150848170189",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "Please provide your mobile phone number",
"user_robot_replying": ""
},
{
"timestamp": 1731913814087,
"time_date": "20241118151014087544",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My mobile phone number is 133103335027"
},
{
"timestamp": 1731913814087,
"time_date": "20241118151014087544",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My mobile phone number is 133103335027"
},
{
"timestamp": 1731913814943,
"time_date": "20241118151014943252",
"node_id": "8893d45d-64a4-4854-8f51-0c4c18842839",
"robot_user_replying": "Mr. Zhang, your last number is: 5027. The information collection is completed. Thank you for your cooperation.",
"robot_user_asking": "",
"user_robot_replying": ""
}
],
"output": {
"inputs": {},
"variables": {
"last_code_response": {
"desc": "Mr. Zhang, your last number is: 5027."
},
"my_var": "Mr. Zhang, your last number is: 5027.",
"last_code_time_cost": 0.6902499198913574,
"last_code_error": ""
},
"entities": {
"customerName": "Zhang San",
"customerPhoneNumber": "133103335027"
},
"robot_user_asking": "",
"user_robot_replying": "",
"robot_user_replying": "Mr. Zhang, your last number is: 5027. The information collection is completed. Thank you for your cooperation."
},
"Answer": "Mr. Zhang, your last number is: 5027. The information collection is completed. Thank you for your cooperation.",
"content_type": "text",
"session_id": "7edd9595-a57b-11ef-bce8-004238b4a21d",
"flow_stage": "flow_running",
"code": "000000",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0,
"target_node_id": "8893d45d-64a4-4854-8f51-0c4c18842839",
"source_node_id": "658d5db7-2460-4ed9-9842-59398e0b894a",
"cur_node_id": "8893d45d-64a4-4854-8f51-0c4c18842839",
"parent_node_id": "658d5db7-2460-4ed9-9842-59398e0b894a"
},
"finish": "y",
"cur_node_id": "8893d45d-64a4-4854-8f51-0c4c18842839",
"node_id": "658d5db7-2460-4ed9-9842-59398e0b894a",
"debug": 1,
"node_developer": 0,
"flow_name": "Customer Information Collection Assistant",
"node_type": "answer",
"node_title": null,
"node_waiting": false,
"parent_node_id": "658d5db7-2460-4ed9-9842-59398e0b894a",
"node_waiting_input": 0
}[Server → Client] flow execution exit information
{
"code": "000000",
"message": "success",
"dialog_id": 1858407336739160064,
"type": "flow",
"index": 0,
"data": {
"final": true,
"id": null,
"response_create_time": "2024-11-18 15:10",
"response_create_time_timestamp": "1731913811598",
"response_update_time": "2024-11-18 15:10",
"response_update_time_timestamp": "1731913811598",
"flow_uuid": "3c61d330-a577-11ef-ad83-e4434b3011a0",
"history": [
{
"timestamp": 1731913531091,
"time_date": "20241118150531091582",
"node_id": "a93311b9-7e1b-40d3-a0e5-94e26e2d9748",
"robot_user_replying": "Hello, welcome to our company to handle business! Your name and contact information will be collected now. We will keep it confidential. Please rest assured.",
"robot_user_asking": "",
"user_robot_replying": ""
},
{
"timestamp": 1731913725910,
"time_date": "20241118150845910619",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My name is Zhang San"
},
{
"timestamp": 1731913728170,
"time_date": "20241118150848170189",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "Please provide your mobile phone number",
"user_robot_replying": ""
},
{
"timestamp": 1731913814087,
"time_date": "20241118151014087544",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My mobile phone number is 133103335027"
},
{
"timestamp": 1731913814087,
"time_date": "20241118151014087544",
"node_id": "67a4219c-963d-4e9d-8af9-81e6d3af6095",
"robot_user_replying": "",
"robot_user_asking": "",
"user_robot_replying": "My mobile phone number is 133103335027"
},
{
"timestamp": 1731913814943,
"time_date": "20241118151014943252",
"node_id": "8893d45d-64a4-4854-8f51-0c4c18842839",
"robot_user_replying": "Mr. Zhang, your last number is: 5027. The information collection is completed. Thank you for your cooperation.",
"robot_user_asking": "",
"user_robot_replying": ""
}
],
"output": {
"inputs": {},
"variables": {
"last_code_response": {
"desc": "Mr. Zhang, your last number is: 5027."
},
"my_var": "Mr. Zhang, your last number is: 5027.",
"last_code_time_cost": 0.6902499198913574,
"last_code_error": ""
},
"entities": {
"customerName": "Zhang San",
"customerPhoneNumber": "133103335027"
}
},
"answer": "flow_exit",
"content_type": "text",
"session_id": "7edd9595-a57b-11ef-bce8-004238b4a21d",
"flow_stage": "flow_exit",
"code": "002001",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0,
"target_node_id": "8893d45d-64a4-4854-8f51-0c4c18842839",
"source_node_id": "8893d45d-64a4-4854-8f51-0c4c18842839",
"cur_node_id": "8893d45d-64a4-4854-8f51-0c4c18842839",
"parent_node_id": "8893d45d-64a4-4854-8f51-0c4c18842839"
},
"finish": "y",
"cur_node_id": "8893d45d-64a4-4854-8f51-0c4c18842839",
"node_id": "8893d45d-64a4-4854-8f51-0c4c18842839",
"debug": 1,
"node_developer": 0,
"flow_name": "Customer Information Collection Assistant",
"node_type": "answer",
"node_title": null,
"parent_node_id": "8893d45d-64a4-4854-8f51-0c4c18842839",
"node_waiting_input": 0
}[Server → Client] The current flow execution completed and exited
{
"code": "000000",
"message": "success",
"dialog_id": 1858406156273270784,
"type": "flow",
"index": 0,
"data": {
"code": "002005",
"answer": "current_communication_complete",
"content_type": "text",
"node_stream": 0,
"node_answer_finish": "y",
"node_answer_index": 0
},
"finish": "y"
}Last updated