emqx_bridge_webhook_schema { config_enable { desc { en: """Enable or disable this bridge""" zh: """启用/禁用 Bridge""" } label: { en: "Enable Or Disable Bridge" zh: "启用/禁用 Bridge" } } config_direction { desc { en: """Deprecated, The direction of this bridge, MUST be 'egress'""" zh: """已废弃,Bridge 的方向,必须是 egress""" } label: { en: "Bridge Direction" zh: "Bridge 方向" } } config_url { desc { en: """The URL of the HTTP Bridge.
Template with variables is allowed in the path, but variables cannot be used in the scheme, host, or port part.
For example, http://localhost:9901/${topic} is allowed, but http://${host}:9901/message or http://localhost:${port}/message is not allowed.""" zh: """HTTP Bridge 的 URL。
路径中允许使用带变量的模板,但是 host, port 不允许使用变量模板。
例如, http://localhost:9901/${topic} 是允许的, 但是 http://${host}:9901/message http://localhost:${port}/message 不允许。""" } label: { en: "HTTP Bridge" zh: "HTTP Bridge" } } config_local_topic { desc { en: """The MQTT topic filter to be forwarded to the HTTP server. All MQTT 'PUBLISH' messages with the topic matching the local_topic will be forwarded.
NOTE: if this bridge is used as the action of a rule (EMQX rule engine), and also local_topic is configured, then both the data got from the rule and the MQTT messages that match local_topic will be forwarded.""" zh: """发送到 'local_topic' 的消息都会转发到 HTTP 服务器。
注意:如果这个 Bridge 被用作规则(EMQX 规则引擎)的输出,同时也配置了 'local_topic' ,那么这两部分的消息都会被转发到 HTTP 服务器。""" } label: { en: "Local Topic" zh: "本地 Topic" } } config_method { desc { en: """The method of the HTTP request. All the available methods are: post, put, get, delete.
Template with variables is allowed.""" zh: """HTTP 请求的方法。 所有可用的方法包括:post、put、get、delete。
允许使用带有变量的模板。""" } label: { en: "HTTP Method" zh: "HTTP 请求方法" } } config_headers { desc { en: """The headers of the HTTP request.
Template with variables is allowed.""" zh: """HTTP 请求的标头。
允许使用带有变量的模板。""" } label: { en: "HTTP Header" zh: "HTTP 请求标头" } } config_body { desc { en: """The body of the HTTP request.
If not provided, the body will be a JSON object of all the available fields.
There, 'all the available fields' means the context of a MQTT message when this webhook is triggered by receiving a MQTT message (the `local_topic` is set), or the context of the event when this webhook is triggered by a rule (i.e. this webhook is used as an action of a rule).
Template with variables is allowed.""" zh: """HTTP 请求的正文。
如果没有设置该字段,请求正文将是包含所有可用字段的 JSON object。
如果该 webhook 是由于收到 MQTT 消息触发的,'所有可用字段' 将是 MQTT 消息的 上下文信息;如果该 webhook 是由于规则触发的,'所有可用字段' 则为触发事件的上下文信息。
允许使用带有变量的模板。""" } label: { en: "HTTP Body" zh: "HTTP 请求正文" } } config_request_timeout { desc { en: """HTTP request timeout.""" zh: """HTTP 请求超时""" } label: { en: "HTTP Request Timeout" zh: "HTTP 请求超时" } } config_max_retries { desc { en: """HTTP request max retry times if failed.""" zh: """HTTP 请求失败最大重试次数""" } label: { en: "HTTP Request Max Retries" zh: "HTTP 请求重试次数" } } desc_type { desc { en: """The Bridge Type""" zh: """Bridge 类型""" } label: { en: "Bridge Type" zh: "Bridge 类型" } } desc_name { desc { en: """Bridge name, used as a human-readable description of the bridge.""" zh: """Bridge 名字,Bridge 的可读描述""" } label: { en: "Bridge Name" zh: "Bridge 名字" } } desc_config { desc { en: """Configuration for an HTTP bridge.""" zh: """HTTP Bridge 配置""" } label: { en: "HTTP Bridge Configuration" zh: "HTTP Bridge 配置" } } }