更新转发数据源
开发中
本地
http://127.0.0.1:9999
本地
http://127.0.0.1:9999
PUT
http://127.0.0.1:9999
请求参数
Header 参数
x-token
string
可选
默认值:
{{x-token}}
Body 参数application/json
id
string
必需
forwarding_rule_id
string
转发规则ID
source_type
string
数据源类型
source_id
string
数据源ID
message_type
string
消息类型
示例
{
"id": "string",
"forwarding_rule_id": "string",
"source_type": "string",
"source_id": "string",
"message_type": "string"
}
示例代码
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request PUT 'http://127.0.0.1:9999/api/v1/forwarding/source' \
--header 'x-token: {{x-token}}' \
--header 'Content-Type: application/json' \
--data-raw '{
"id": "string",
"forwarding_rule_id": "string",
"source_type": "string",
"source_id": "string",
"message_type": "string"
}'
返回响应
🟢200成功
application/json
Body
code
integer
必需
message
string
必需
data
object
必需
id
string
必需
forwarding_rule_id
string
必需
source_type
string
必需
source_id
string
必需
message_type
string
必需
created_at
string
必需
updated_at
string
必需
示例
{"code":200,"message":"转发数据源更新成功","data":{"id":"c6f91e7a-4f4a-7dd5-527c-eca973a9afe5","forwarding_rule_id":"9b9404fb-c1d5-645a-17f3-4bc83b580fbb","source_type":"device","source_id":"5af22b17-e977-bfaa-cecb-358cf1488182","message_type":"1,2,3","created_at":"2024-10-18T12:31:42.511106+08:00","updated_at":"2024-10-18T12:37:22.036089+08:00"}}