接口详情
POST /v1/probe-dnspup/plugin/requests
插件发起一次拨测(目标 + 类型 + 选点),用平台 DNSPup 凭据与额度执行
- operationId
createProbeDNSPupPluginRequest- 认证
- API Key:请求头 Authorization: CdncaKey <key_id>.<secret>。有效权限是 Key 的范围与所有者当前权限的交集。
- 所需权限
全部需要:probes.dnspup.request
参数
createProbeDNSPupPluginRequest 参数| 名称 | 位置 | 类型 | 必填 | 说明 |
|---|
Idempotency-Key | header | string | 是 | — |
|---|
请求体
application/json · 必填:是
createProbeDNSPupPluginRequest 请求体| 名称 | 类型 | 必填 | 说明 |
|---|
type | string: tcping / ping / http / https / dns | 是 | — |
|---|
target | string | 是 | public IP / domain; http(s): URL with that scheme |
|---|
port | integer | 否 | tcping only |
|---|
method | string: GET / HEAD | 否 | — |
|---|
record | string: A / AAAA / CNAME / MX / NS / TXT | 否 | — |
|---|
expect | array<string> | 否 | dns: at least one answer must match |
|---|
ip_version | string: 4 / 6 | 否 | — |
|---|
selection | Selection | 否 | — |
|---|
响应
createProbeDNSPupPluginRequest 响应| 状态码 | 说明 |
|---|
202 | Started 字段:id: string(uuid) status: string: pending / completed / failed type: string target: string error_code?: string created_at: string(date-time) traces?: any results: array<object> |
|---|
400 | Error envelope |
|---|
401 | Error envelope |
|---|
403 | Error envelope |
|---|
409 | Error envelope |
|---|
422 | Error envelope |
|---|
429 | Error envelope |
|---|
503 | Error envelope |
|---|
失败时怎么办
400 按字段说明修正参数或请求体再发;不要原样重试。401 检查凭据格式、是否过期或被轮换。403 检查 Key 范围与所有者当前权限、当前租户作用域;不要换更高权限账号绕过。409 先回读资源当前状态;同一操作重试保持原 Idempotency-Key 和原请求内容。429 被限速:等待后再试,降低并发。503 依赖暂不可用:稍后用原 Idempotency-Key 重试。
↑ 回到列表
GET /v1/probe-dnspup/plugin/requests/{id}
读取本插件发起的拨测结果(运行中带 Retry-After;其他安装读不到)
- operationId
getProbeDNSPupPluginRequest- 认证
- API Key:请求头 Authorization: CdncaKey <key_id>.<secret>。有效权限是 Key 的范围与所有者当前权限的交集。
- 所需权限
全部需要:probes.dnspup.request
参数
getProbeDNSPupPluginRequest 参数| 名称 | 位置 | 类型 | 必填 | 说明 |
|---|
id | path | string(uuid) | 是 | — |
|---|
响应
getProbeDNSPupPluginRequest 响应| 状态码 | 说明 |
|---|
200 | Probe 字段:id: string(uuid) status: string: pending / completed / failed type: string target: string error_code?: string created_at: string(date-time) traces?: any results: array<object> |
|---|
401 | Error envelope |
|---|
403 | Error envelope |
|---|
404 | Error envelope |
|---|
失败时怎么办
401 检查凭据格式、是否过期或被轮换。403 检查 Key 范围与所有者当前权限、当前租户作用域;不要换更高权限账号绕过。404 资源不存在或不属于当前租户。
↑ 回到列表
GET /v1/probe-dnspup/plugin/status
插件能否发起拨测(未安装/未配置/暂停/额度),不计量
- operationId
getProbeDNSPupPluginStatus- 认证
- API Key:请求头 Authorization: CdncaKey <key_id>.<secret>。有效权限是 Key 的范围与所有者当前权限的交集。
- 所需权限
全部需要:probes.dnspup.request
响应
getProbeDNSPupPluginStatus 响应| 状态码 | 说明 |
|---|
200 | Status 字段:available: boolean reason?: string: probe_dnspup_not_installed / probe_dnspup_not_configured / probe_dnspup_paused / probe_dnspup_quota_exceeded paused_until?: string(date-time) per_minute: integer tenant_monthly: integer used_this_month: integer |
|---|
401 | Error envelope |
|---|
403 | Error envelope |
|---|
失败时怎么办
401 检查凭据格式、是否过期或被轮换。403 检查 Key 范围与所有者当前权限、当前租户作用域;不要换更高权限账号绕过。
↑ 回到列表