Skip to content

Commit 08c83c9

Browse files
authored
Merge pull request #221 from flashcatcloud/fix/datasource-masking-and-statuspage-schemas
fix(api-reference): correct datasource masking claim and add status-page update/delete schemas
2 parents 8a38845 + 96ff8f9 commit 08c83c9

6 files changed

Lines changed: 460 additions & 24 deletions

File tree

‎api-reference/monitors.openapi.en.json‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@
201201
"Monitors/Data sources"
202202
],
203203
"x-mint": {
204-
"content": "## Restrictions\n\n| Aspect | Value |\n| ------ | ----- |\n| Rate limits | **1,000 requests/minute**; **50 requests/second** per account |\n| Permissions | **Datasources Manage** (`monit`) |\n\n## Usage\n\n- `type_ident` must be one of: `prometheus`, `loki`, `mysql`, `oracle`, `postgres`, `clickhouse`, `elasticsearch`, `sls`, `victorialogs`.\n- `edge_cluster_name` specifies which Monitors edge cluster evaluates rules using this datasource.\n- For `elasticsearch`, set `payload.elasticsearch.deployment` to `cloud` or `self-managed`.\n- Every call is recorded in the account audit log. Don't put secrets in request fields.\n\n## Credential fields\n\nThe `info` / `create` / `update` responses never return credentials in cleartext. `password`, `basic_auth_password`, `api_key`, `service_token`, `access_key_secret`, `tls_key`, `tls_key_pwd` and their siblings come back as the placeholder `******`; a field that was never configured still comes back as an empty string. `sls.access_key_id` is an identifier rather than a credential and is returned as-is.\n\nOn update, submitting `******` unchanged means **keep the stored value**, and an empty string is treated the same way. To rotate a credential, submit the new value directly.\n\nOn create there is no stored value to keep — submitting a `******` copied from another response stores the literal string `******`, and the data source will fail to connect.",
204+
"content": "## Restrictions\n\n| Aspect | Value |\n| ------ | ----- |\n| Rate limits | **1,000 requests/minute**; **50 requests/second** per account |\n| Permissions | **Datasources Manage** (`monit`) |\n\n## Usage\n\n- `type_ident` must be one of: `prometheus`, `loki`, `mysql`, `oracle`, `postgres`, `clickhouse`, `elasticsearch`, `sls`, `victorialogs`.\n- `edge_cluster_name` specifies which Monitors edge cluster evaluates rules using this datasource.\n- For `elasticsearch`, set `payload.elasticsearch.deployment` to `cloud` or `self-managed`.\n- Every call is recorded in the account audit log. Don't put secrets in request fields.\n\n## Credential fields\n\nThe `info` / `create` / `update` responses include the `payload` configuration exactly as stored — `password`, `basic_auth_password`, `api_key`, `service_token`, `access_key_secret`, `tls_key`, `tls_key_pwd` and similar fields are returned as-is, not masked. Treat these responses as sensitive: avoid logging them or forwarding them to third parties.",
205205
"href": "/en/api-reference/monitors/data-sources/monit-datasource-write-create",
206206
"metadata": {
207207
"sidebarTitle": "Create datasource"
@@ -287,7 +287,7 @@
287287
"Monitors/Data sources"
288288
],
289289
"x-mint": {
290-
"content": "## Restrictions\n\n| Aspect | Value |\n| ------ | ----- |\n| Rate limits | **1,000 requests/minute**; **50 requests/second** per account |\n| Permissions | **Datasources Manage** (`monit`) |\n\n## Usage\n\n- Every call is recorded in the account audit log. Don't put secrets in request fields.\n\n## Credential fields\n\nThe `info` / `create` / `update` responses never return credentials in cleartext. `password`, `basic_auth_password`, `api_key`, `service_token`, `access_key_secret`, `tls_key`, `tls_key_pwd` and their siblings come back as the placeholder `******`; a field that was never configured still comes back as an empty string. `sls.access_key_id` is an identifier rather than a credential and is returned as-is.\n\nOn update, submitting `******` unchanged means **keep the stored value**, and an empty string is treated the same way. To rotate a credential, submit the new value directly.\n\nOn create there is no stored value to keep — submitting a `******` copied from another response stores the literal string `******`, and the data source will fail to connect.",
290+
"content": "## Restrictions\n\n| Aspect | Value |\n| ------ | ----- |\n| Rate limits | **1,000 requests/minute**; **50 requests/second** per account |\n| Permissions | **Datasources Manage** (`monit`) |\n\n## Usage\n\n- Every call is recorded in the account audit log. Don't put secrets in request fields.\n\n## Credential fields\n\nThe `info` / `create` / `update` responses include the `payload` configuration exactly as stored — `password`, `basic_auth_password`, `api_key`, `service_token`, `access_key_secret`, `tls_key`, `tls_key_pwd` and similar fields are returned as-is, not masked. Treat these responses as sensitive: avoid logging them or forwarding them to third parties.",
291291
"href": "/en/api-reference/monitors/data-sources/monit-datasource-write-update",
292292
"metadata": {
293293
"sidebarTitle": "Update datasource"
@@ -1052,12 +1052,12 @@
10521052
"post": {
10531053
"operationId": "monit-datasource-read-info",
10541054
"summary": "Get datasource detail",
1055-
"description": "Retrieve full details of a single data source by its ID, including the `payload` configuration, with credential fields masked as `******`.",
1055+
"description": "Retrieve full details of a single data source by its ID, including the `payload` configuration with its configured connection and authentication settings; treat the response as sensitive and avoid logging or forwarding it.",
10561056
"tags": [
10571057
"Monitors/Data sources"
10581058
],
10591059
"x-mint": {
1060-
"content": "## Restrictions\n\n| Aspect | Value |\n| ------ | ----- |\n| Rate limits | **1,000 requests/minute**; **50 requests/second** per account |\n| Permissions | **Datasources Read** (`monit`) |\n\n## Credential fields\n\nThe `info` / `create` / `update` responses never return credentials in cleartext. `password`, `basic_auth_password`, `api_key`, `service_token`, `access_key_secret`, `tls_key`, `tls_key_pwd` and their siblings come back as the placeholder `******`; a field that was never configured still comes back as an empty string. `sls.access_key_id` is an identifier rather than a credential and is returned as-is.\n\nOn update, submitting `******` unchanged means **keep the stored value**, and an empty string is treated the same way. To rotate a credential, submit the new value directly.\n\nOn create there is no stored value to keep — submitting a `******` copied from another response stores the literal string `******`, and the data source will fail to connect.",
1060+
"content": "## Restrictions\n\n| Aspect | Value |\n| ------ | ----- |\n| Rate limits | **1,000 requests/minute**; **50 requests/second** per account |\n| Permissions | **Datasources Read** (`monit`) |\n\n## Credential fields\n\nThe `info` / `create` / `update` responses include the `payload` configuration exactly as stored — `password`, `basic_auth_password`, `api_key`, `service_token`, `access_key_secret`, `tls_key`, `tls_key_pwd` and similar fields are returned as-is, not masked. Treat these responses as sensitive: avoid logging them or forwarding them to third parties.",
10611061
"href": "/en/api-reference/monitors/data-sources/monit-datasource-read-info",
10621062
"metadata": {
10631063
"sidebarTitle": "Get datasource detail"

‎api-reference/monitors.openapi.zh.json‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@
201201
"Monitors/告警数据源"
202202
],
203203
"x-mint": {
204-
"content": "## 限制说明\n\n| 项目 | 说明 |\n| ---- | ---- |\n| 速率限制 | 每个账户 **1,000 次/分钟**;**50 次/秒** |\n| 权限要求 | **数据源管理**(`monit`) |\n\n## 使用说明\n\n- `type_ident` 必须为以下之一:`prometheus`、`loki`、`mysql`、`oracle`、`postgres`、`clickhouse`、`elasticsearch`、`sls`、`victorialogs`。\n- `edge_cluster_name` 指定使用该数据源进行规则评估的 Monitors Edge 集群。\n- 对于 `elasticsearch`,`payload.elasticsearch.deployment` 须设为 `cloud` 或 `self-managed`。\n- 每次调用都会记录到账户审计日志,请不要把敏感信息放在请求字段中。\n\n## 凭据字段\n\n`info` / `create` / `update` 的响应不返回凭据明文。`password`、`basic_auth_password`、`api_key`、`service_token`、`access_key_secret`、`tls_key`、`tls_key_pwd` 等字段一律以 `******` 占位返回;原本就没配置的字段仍返回空字符串。`sls.access_key_id` 是标识而非凭据,照常返回真实值。\n\n更新时把 `******` 原样提交表示**沿用已存值**,留空同样按沿用处理;要轮换凭据就直接提交新值。\n\n创建时没有可沿用的旧值——若把从别处读来的 `******` 当作真实口令提交,存下来的就是字面量 `******`,数据源会连不上。",
204+
"content": "## 限制说明\n\n| 项目 | 说明 |\n| ---- | ---- |\n| 速率限制 | 每个账户 **1,000 次/分钟**;**50 次/秒** |\n| 权限要求 | **数据源管理**(`monit`) |\n\n## 使用说明\n\n- `type_ident` 必须为以下之一:`prometheus`、`loki`、`mysql`、`oracle`、`postgres`、`clickhouse`、`elasticsearch`、`sls`、`victorialogs`。\n- `edge_cluster_name` 指定使用该数据源进行规则评估的 Monitors Edge 集群。\n- 对于 `elasticsearch`,`payload.elasticsearch.deployment` 须设为 `cloud` 或 `self-managed`。\n- 每次调用都会记录到账户审计日志,请不要把敏感信息放在请求字段中。\n\n## 凭据字段\n\n`info` / `create` / `update` 的响应会按原样返回 `payload` 配置——`password`、`basic_auth_password`、`api_key`、`service_token`、`access_key_secret`、`tls_key`、`tls_key_pwd` 等字段均如实返回,不做脱敏。请将这些响应视为敏感信息:避免记录日志或转发给第三方。",
205205
"href": "/zh/api-reference/monitors/data-sources/monit-datasource-write-create",
206206
"metadata": {
207207
"sidebarTitle": "创建数据源"
@@ -287,7 +287,7 @@
287287
"Monitors/告警数据源"
288288
],
289289
"x-mint": {
290-
"content": "## 限制说明\n\n| 项目 | 说明 |\n| ---- | ---- |\n| 速率限制 | 每个账户 **1,000 次/分钟**;**50 次/秒** |\n| 权限要求 | **数据源管理**(`monit`) |\n\n## 使用说明\n\n- 每次调用都会记录到账户审计日志,请不要把敏感信息放在请求字段中。\n\n## 凭据字段\n\n`info` / `create` / `update` 的响应不返回凭据明文。`password`、`basic_auth_password`、`api_key`、`service_token`、`access_key_secret`、`tls_key`、`tls_key_pwd` 等字段一律以 `******` 占位返回;原本就没配置的字段仍返回空字符串。`sls.access_key_id` 是标识而非凭据,照常返回真实值。\n\n更新时把 `******` 原样提交表示**沿用已存值**,留空同样按沿用处理;要轮换凭据就直接提交新值。\n\n创建时没有可沿用的旧值——若把从别处读来的 `******` 当作真实口令提交,存下来的就是字面量 `******`,数据源会连不上。",
290+
"content": "## 限制说明\n\n| 项目 | 说明 |\n| ---- | ---- |\n| 速率限制 | 每个账户 **1,000 次/分钟**;**50 次/秒** |\n| 权限要求 | **数据源管理**(`monit`) |\n\n## 使用说明\n\n- 每次调用都会记录到账户审计日志,请不要把敏感信息放在请求字段中。\n\n## 凭据字段\n\n`info` / `create` / `update` 的响应会按原样返回 `payload` 配置——`password`、`basic_auth_password`、`api_key`、`service_token`、`access_key_secret`、`tls_key`、`tls_key_pwd` 等字段均如实返回,不做脱敏。请将这些响应视为敏感信息:避免记录日志或转发给第三方。",
291291
"href": "/zh/api-reference/monitors/data-sources/monit-datasource-write-update",
292292
"metadata": {
293293
"sidebarTitle": "更新数据源"
@@ -1052,12 +1052,12 @@
10521052
"post": {
10531053
"operationId": "monit-datasource-read-info",
10541054
"summary": "查看数据源详情",
1055-
"description": "通过 ID 获取单个数据源的完整信息,包括 `payload` 配置(凭据字段以 `******` 脱敏返回)。",
1055+
"description": "通过 ID 获取单个数据源的完整信息,包括 `payload` 配置及其中配置的连接与鉴权信息;请将该响应视为敏感信息,避免记录或转发。",
10561056
"tags": [
10571057
"Monitors/告警数据源"
10581058
],
10591059
"x-mint": {
1060-
"content": "## 限制说明\n\n| 项目 | 说明 |\n| ---- | ---- |\n| 速率限制 | 每个账户 **1,000 次/分钟**;**50 次/秒** |\n| 权限要求 | **数据源查看**(`monit`) |\n\n## 凭据字段\n\n`info` / `create` / `update` 的响应不返回凭据明文。`password`、`basic_auth_password`、`api_key`、`service_token`、`access_key_secret`、`tls_key`、`tls_key_pwd` 等字段一律以 `******` 占位返回;原本就没配置的字段仍返回空字符串。`sls.access_key_id` 是标识而非凭据,照常返回真实值。\n\n更新时把 `******` 原样提交表示**沿用已存值**,留空同样按沿用处理;要轮换凭据就直接提交新值。\n\n创建时没有可沿用的旧值——若把从别处读来的 `******` 当作真实口令提交,存下来的就是字面量 `******`,数据源会连不上。",
1060+
"content": "## 限制说明\n\n| 项目 | 说明 |\n| ---- | ---- |\n| 速率限制 | 每个账户 **1,000 次/分钟**;**50 次/秒** |\n| 权限要求 | **数据源查看**(`monit`) |\n\n## 凭据字段\n\n`info` / `create` / `update` 的响应会按原样返回 `payload` 配置——`password`、`basic_auth_password`、`api_key`、`service_token`、`access_key_secret`、`tls_key`、`tls_key_pwd` 等字段均如实返回,不做脱敏。请将这些响应视为敏感信息:避免记录日志或转发给第三方。",
10611061
"href": "/zh/api-reference/monitors/data-sources/monit-datasource-read-info",
10621062
"metadata": {
10631063
"sidebarTitle": "查看数据源详情"

‎api-reference/on-call.openapi.en.json‎

Lines changed: 111 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15322,7 +15322,7 @@
1532215322
"content": {
1532315323
"application/json": {
1532415324
"schema": {
15325-
"$ref": "#/components/schemas/EmptyRequest"
15325+
"$ref": "#/components/schemas/UpdateStatusPageRequest"
1532615326
},
1532715327
"example": {
1532815328
"page_id": 5750613685214,
@@ -15395,7 +15395,7 @@
1539515395
"content": {
1539615396
"application/json": {
1539715397
"schema": {
15398-
"$ref": "#/components/schemas/EmptyRequest"
15398+
"$ref": "#/components/schemas/DeleteStatusPageRequest"
1539915399
},
1540015400
"example": {
1540115401
"page_id": 5750613685214
@@ -29567,6 +29567,115 @@
2956729567
"page_url_name"
2956829568
]
2956929569
},
29570+
"UpdateStatusPageRequest": {
29571+
"type": "object",
29572+
"description": "Parameters for updating an existing status page. All fields except `page_id` are optional; omit a field to keep its existing value.",
29573+
"required": [
29574+
"page_id"
29575+
],
29576+
"properties": {
29577+
"page_id": {
29578+
"type": "integer",
29579+
"format": "int64",
29580+
"description": "Status page ID."
29581+
},
29582+
"name": {
29583+
"type": "string",
29584+
"description": "Display name of the status page. Omit to keep the existing value.",
29585+
"maxLength": 255
29586+
},
29587+
"url_name": {
29588+
"type": "string",
29589+
"description": "URL-safe slug, unique per account and page type. Omit to keep the existing value.",
29590+
"maxLength": 255
29591+
},
29592+
"custom_domain": {
29593+
"type": "string",
29594+
"description": "Custom domain for a public status page. Omit to keep the existing value.",
29595+
"maxLength": 255
29596+
},
29597+
"page_title": {
29598+
"type": "string",
29599+
"description": "Browser title shown for the status page. Omit to keep the existing value."
29600+
},
29601+
"logo": {
29602+
"type": "string",
29603+
"description": "Logo image of the status page. Omit to keep the existing value."
29604+
},
29605+
"dark_logo": {
29606+
"type": "string",
29607+
"description": "Dark-mode logo image of the status page. Omit to keep the existing value."
29608+
},
29609+
"logo_url": {
29610+
"type": "string",
29611+
"description": "URL opened when the logo is clicked. Omit to keep the existing value."
29612+
},
29613+
"favicon": {
29614+
"type": "string",
29615+
"description": "Favicon of the status page. Omit to keep the existing value."
29616+
},
29617+
"page_header": {
29618+
"type": "string",
29619+
"description": "Header content shown on the status page. Omit to keep the existing value."
29620+
},
29621+
"page_footer": {
29622+
"type": "string",
29623+
"description": "Footer content shown on the status page. Omit to keep the existing value."
29624+
},
29625+
"date_view": {
29626+
"type": "string",
29627+
"description": "How event dates are displayed. Omit to keep the existing value.",
29628+
"enum": [
29629+
"calendar",
29630+
"list"
29631+
]
29632+
},
29633+
"display_uptime_mode": {
29634+
"type": "string",
29635+
"description": "How uptime is displayed. Omit to keep the existing value.",
29636+
"enum": [
29637+
"chart_and_percentage",
29638+
"chart",
29639+
"none"
29640+
]
29641+
},
29642+
"custom_links": {
29643+
"type": "array",
29644+
"description": "Custom navigation links shown on the status page. Omit to keep the existing value.",
29645+
"items": {
29646+
"type": "object",
29647+
"additionalProperties": {
29648+
"type": "string"
29649+
}
29650+
}
29651+
},
29652+
"contact_info": {
29653+
"type": "string",
29654+
"description": "Get-in-touch contact, such as a mailto or website URL. Omit to keep the existing value."
29655+
},
29656+
"subscription": {
29657+
"$ref": "#/components/schemas/StatusPageSubscriptionItem"
29658+
},
29659+
"template_preference": {
29660+
"type": "string",
29661+
"description": "Preferred change-event template type. Omit to keep the existing value."
29662+
}
29663+
}
29664+
},
29665+
"DeleteStatusPageRequest": {
29666+
"type": "object",
29667+
"description": "Parameters for deleting a status page.",
29668+
"required": [
29669+
"page_id"
29670+
],
29671+
"properties": {
29672+
"page_id": {
29673+
"type": "integer",
29674+
"format": "int64",
29675+
"description": "Status page ID."
29676+
}
29677+
}
29678+
},
2957029679
"CustomFieldValues": {
2957129680
"type": "object",
2957229681
"description": "Values keyed by account custom field name. The active form determines the allowed keys, types, and required fields.",

0 commit comments

Comments
 (0)