Skip to main content

Historical contract: Create Channel on Event Rule

Historical API contract. This page describes an earlier API contract. Methods, paths, and responses may differ from the current API.

Historical meaning​

Create Channel on Event Rule

Current API​

For new integrations, use the linked current API reference or guide.

View the current API reference

Parameters​

[
{
"name": "language",
"in": "path",
"schema": {
"type": "string",
"default": "en"
},
"required": true
},
{
"name": "project",
"in": "path",
"schema": {
"type": "string",
"default": "<redacted-personal>"
},
"required": true
},
{
"name": "api_version",
"in": "path",
"schema": {
"type": "string",
"default": "v400"
},
"required": true
},
{
"name": "event_rule_id",
"in": "path",
"schema": {
"type": "integer",
"format": "int32"
},
"required": true
}
]

Request body​

{
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"title",
"body",
"channel"
],
"properties": {
"title": {
"type": "string"
},
"body": {
"type": "string"
},
"enabled": {
"type": "boolean"
},
"channel": {
"type": "string"
}
}
}
}
}
}

Responses​

{
"200": {
"description": "200",
"content": {
"application/json": {
"examples": {
"Result": {
"value": "{\n \"error\": false,\n \"result\": {\n \"title\": \"Channel Event rule\",\n \"body\": \"This is a test1\",\n \"enabled\": \"1\",\n \"channel\": \"sms\",\n \"event_rule_id\": \"3\",\n \"updated_at\": \"2022-05-18 17:57:06\",\n \"created_at\": \"2022-05-18 17:57:06\",\n \"id\": 5\n }\n}"
}
},
"schema": {
"type": "object",
"properties": {
"error": {
"type": "boolean",
"example": false,
"default": true
},
"result": {
"type": "object",
"properties": {
"title": {
"type": "string",
"example": "Channel Event rule"
},
"body": {
"type": "string",
"example": "This is a test1"
},
"enabled": {
"type": "string",
"example": "1"
},
"channel": {
"type": "string",
"example": "sms"
},
"event_rule_id": {
"type": "string",
"example": "3"
},
"updated_at": {
"type": "string",
"example": "2022-05-18 17:57:06"
},
"created_at": {
"type": "string",
"example": "2022-05-18 17:57:06"
},
"id": {
"type": "integer",
"example": 5,
"default": 0
}
}
}
}
}
}
}
},
"400": {
"description": "400",
"content": {
"application/json": {
"examples": {
"Result": {
"value": "{}"
}
},
"schema": {
"type": "object",
"properties": {}
}
}
}
}
}