查询集成列表
curl --request POST \
--url 'https://api.flashcat.cloud/integration/list?app_key=' \
--header 'Content-Type: application/json' \
--data '
{
"p": 1,
"limit": 20,
"status": "enabled"
}
'import requests
url = "https://api.flashcat.cloud/integration/list?app_key="
payload = {
"p": 1,
"limit": 20,
"status": "enabled"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({p: 1, limit: 20, status: 'enabled'})
};
fetch('https://api.flashcat.cloud/integration/list?app_key=', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.flashcat.cloud/integration/list?app_key=",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'p' => 1,
'limit' => 20,
'status' => 'enabled'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.flashcat.cloud/integration/list?app_key="
payload := strings.NewReader("{\n \"p\": 1,\n \"limit\": 20,\n \"status\": \"enabled\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.flashcat.cloud/integration/list?app_key=")
.header("Content-Type", "application/json")
.body("{\n \"p\": 1,\n \"limit\": 20,\n \"status\": \"enabled\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.flashcat.cloud/integration/list?app_key=")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"p\": 1,\n \"limit\": 20,\n \"status\": \"enabled\"\n}"
response = http.request(request)
puts response.read_body{
"request_id": "01HK8XQE3Z7JM2NTFQ5YJ8P9R4",
"data": {
"p": 1,
"limit": 20,
"total": 1,
"items": [
{
"integration_id": 6113996590131,
"team_id": 1467226103121,
"plugin_type": "standard.alert",
"plugin_type_name": "Standard Alert",
"category": "event.alert",
"name": "Prod metrics alerts",
"description": "Alerts pushed by the production Prometheus stack",
"status": "enabled",
"ref_id": "a_6612f0c9e1b7a4d3508f2c6b",
"created_at": 1775116800,
"updated_at": 1775203200,
"last_time": 1775298600
}
]
}
}{
"request_id": "01HK8XQE3Z7JM2NTFQ5YJ8P9R4",
"error": {
"code": "InvalidParameter",
"message": "The specified parameter is not valid."
}
}{
"request_id": "01HK8XQE3Z7JM2NTFQ5YJ8P9R4",
"error": {
"code": "Unauthorized",
"message": "You are unauthorized."
}
}{
"request_id": "01HK8XQE3Z7JM2NTFQ5YJ8P9R4",
"error": {
"code": "RequestTooFrequently",
"message": "Request too frequently."
}
}{
"request_id": "01HK8XQE3Z7JM2NTFQ5YJ8P9R4",
"error": {
"code": "InternalError",
"message": "We encountered an internal error, and it has been reported. Please try again later."
}
}集成中心
查询集成列表
查询当前账户的告警源与变更源集成列表。
POST
/
integration
/
list
查询集成列表
curl --request POST \
--url 'https://api.flashcat.cloud/integration/list?app_key=' \
--header 'Content-Type: application/json' \
--data '
{
"p": 1,
"limit": 20,
"status": "enabled"
}
'import requests
url = "https://api.flashcat.cloud/integration/list?app_key="
payload = {
"p": 1,
"limit": 20,
"status": "enabled"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({p: 1, limit: 20, status: 'enabled'})
};
fetch('https://api.flashcat.cloud/integration/list?app_key=', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.flashcat.cloud/integration/list?app_key=",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'p' => 1,
'limit' => 20,
'status' => 'enabled'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.flashcat.cloud/integration/list?app_key="
payload := strings.NewReader("{\n \"p\": 1,\n \"limit\": 20,\n \"status\": \"enabled\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.flashcat.cloud/integration/list?app_key=")
.header("Content-Type", "application/json")
.body("{\n \"p\": 1,\n \"limit\": 20,\n \"status\": \"enabled\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.flashcat.cloud/integration/list?app_key=")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"p\": 1,\n \"limit\": 20,\n \"status\": \"enabled\"\n}"
response = http.request(request)
puts response.read_body{
"request_id": "01HK8XQE3Z7JM2NTFQ5YJ8P9R4",
"data": {
"p": 1,
"limit": 20,
"total": 1,
"items": [
{
"integration_id": 6113996590131,
"team_id": 1467226103121,
"plugin_type": "standard.alert",
"plugin_type_name": "Standard Alert",
"category": "event.alert",
"name": "Prod metrics alerts",
"description": "Alerts pushed by the production Prometheus stack",
"status": "enabled",
"ref_id": "a_6612f0c9e1b7a4d3508f2c6b",
"created_at": 1775116800,
"updated_at": 1775203200,
"last_time": 1775298600
}
]
}
}{
"request_id": "01HK8XQE3Z7JM2NTFQ5YJ8P9R4",
"error": {
"code": "InvalidParameter",
"message": "The specified parameter is not valid."
}
}{
"request_id": "01HK8XQE3Z7JM2NTFQ5YJ8P9R4",
"error": {
"code": "Unauthorized",
"message": "You are unauthorized."
}
}{
"request_id": "01HK8XQE3Z7JM2NTFQ5YJ8P9R4",
"error": {
"code": "RequestTooFrequently",
"message": "Request too frequently."
}
}{
"request_id": "01HK8XQE3Z7JM2NTFQ5YJ8P9R4",
"error": {
"code": "InternalError",
"message": "We encountered an internal error, and it has been reported. Please try again later."
}
}授权
在 Flashduty 控制台 账户 → APP Key 中签发的 app_key。调用任何公开 API 时都必须携带。它等同于所属账户的身份凭证,请妥善保管。
请求体
application/json
查询集成列表的过滤参数。
页码,从 1 开始。
必填范围:
x >= 1每页条数,默认 100,最大 100。
必填范围:
1 <= x <= 100排序字段,默认 created_at;plugin_type 按底层插件排序。
可用选项:
created_at, updated_at, name, plugin_type, status 按分类过滤,支持逗号分隔多个值。
已废弃;与 plugin_type 同时传入时会合并生效。
按集成类型过滤,支持逗号分隔多个值。
按状态过滤,支持逗号分隔多个值。
按集成名称过滤。
按来源引用 ID 过滤;每个值必须以 c_(协作空间)、a_(账户)或 w_ 开头。
true 升序,false 降序。
仅返回你所在团队拥有的集成。
按团队 ID 过滤;与 is_my_team 同时使用时在其结果内进一步收窄。
此页面对您有帮助吗?