Documentation for version v73
Eventer
Description
Eventer The pipe registers a custom channel event. This pipe is also used to implement the moderation mechanism and stop the placement mailing on a channel with a configured Stop pipeline.
Structure
| Field | Type of value | Example | Required | Description |
|---|---|---|---|---|
| id | number | 10 | yes | Pipe's ID |
| type | string | "event" | yes | Type of a pipe |
| params | EventParamsObject | no | Type-specific parameters | |
| outs | OutsObject | no | Pipe's outputs |
| EventParamsObject | |||||
|---|---|---|---|---|---|
| Field | Type | Example | Reqiered | Default | Description |
| event_type | string | send | yes | - | Event type. The following options are possible:
|
| channel_id | int | 10001 | yes, beside event_type:
| - | Channel ID. |
| action_type | int | 100005 | yes, beside event_type:
| - | Channel ID. |
| event | EventObject | yes | - | Event Specific Parameters | |
| EventObject | |||||
|---|---|---|---|---|---|
| Field | Type | Example | Reqiered | Default | Description |
| send_message_id | string | $origin.send_message_id | yes | - | ID of the message in the platform. caution If we are talking about the Schedule pipeline, then the message identifier must additionally be transmitted using the Schedule pipe. In this case, it can be accessed will be received as follows: $origin.<name of the field with the identifier from the Schedule
pipe> |
Errors
Error processing template
params.event.send_message_id.params.event.send_message_id format is incorrect.
Example
{
"id": 100,
"type": "event",
"params": {
"event_type": "send",
"channel_id": 10001,
"action_type": 100021,
"event": {
"send_message_id": "$origin.send_message_id"
}
},
"outs": {
"error": 101
}
}{
"id": 150,
"type": "event",
"params": {
"event_type": "stop",
"event": {
"send_message_id": "$origin.send_message_id"
}
}
}{
"id": 18,
"type": "event",
"params": {
"event_type": "moderate_error",
"event": {
"send_message_id": "$origin.send_message_id"
}
},
"outs": {
"success": 19,
"error": 20
}
}