方法路径摘要认证
GET/v1/admin/notifications/channelsRead global notification channel settings登录会话
PUT/v1/admin/notifications/channelsUpdate global notification channel settings登录会话
GET/v1/admin/notifications/deliveriesList redacted notification delivery settlements登录会话
GET/v1/admin/notifications/deliveries/{outbox_id}/attemptsList redacted attempts for one notification delivery登录会话
GET/v1/admin/notifications/delivery-historyList redacted immutable notification delivery facts登录会话
GET/v1/admin/notifications/messagesList the compatibility message projection登录会话
GET/v1/admin/notifications/policyRead notification delivery window and event policies登录会话
PUT/v1/admin/notifications/policyUpdate notification delivery window and event policies登录会话
GET/v1/admin/notifications/templatesList immutable notification template versions登录会话
PUT/v1/admin/notifications/templates/{template_id}/versions/{version}/{channel}Create an immutable notification template version登录会话

契约文件:api/control-notifications.openapi.yaml api/control-notification-delivery-history.openapi.yaml

接口详情

GET /v1/admin/notifications/channels

Read global notification channel settings

operationId
getNotificationChannels
认证
  • 登录会话:主控登录后的 Bearer 会话,由客户本人在自己的主控里使用;插件不能要求客户交出会话。
所需权限

全部需要:system_configuration.read

响应

getNotificationChannels 响应
状态码说明
200Current global channel switches and capability facts.

字段:sms_enabled: boolean email_enabled: boolean sms_supported: boolean email_supported: boolean revision: integer(int64) changed: boolean

400Stable error envelope. Clients map code through locale resources and do not render message directly.
401Stable error envelope. Clients map code through locale resources and do not render message directly.
403Stable error envelope. Clients map code through locale resources and do not render message directly.
405Stable error envelope. Clients map code through locale resources and do not render message directly.
500Stable error envelope. Clients map code through locale resources and do not render message directly.

失败时怎么办

  • 400 按字段说明修正参数或请求体再发;不要原样重试。
  • 401 检查凭据格式、是否过期或被轮换。
  • 403 检查 Key 范围与所有者当前权限、当前租户作用域;不要换更高权限账号绕过。
  • 500 结果未知:先按资源 ID 或列表回读确认,再决定是否用原 Idempotency-Key 重试。

↑ 回到列表

PUT /v1/admin/notifications/channels

Update global notification channel settings

operationId
updateNotificationChannels
认证
  • 登录会话:主控登录后的 Bearer 会话,由客户本人在自己的主控里使用;插件不能要求客户交出会话。
所需权限

全部需要:system_configuration.manage

参数

updateNotificationChannels 参数
名称位置类型必填说明
If-Matchheaderstring是—
X-Request-IDheaderstring否Correlation identifier and retry key for this write. Reusing the same value for the same authenticated actor and operation requires the exact original path, revision, and body; an exact retry replays the original response, while changed semantics return 409.

请求体

application/json · 必填:是

updateNotificationChannels 请求体
名称类型必填说明
sms_enabledboolean是Enables the configured SMS provider for this channel or subscription.
email_enabledboolean是—

响应

updateNotificationChannels 响应
状态码说明
200Current global channel switches and capability facts.

字段:sms_enabled: boolean email_enabled: boolean sms_supported: boolean email_supported: boolean revision: integer(int64) changed: boolean

400Stable error envelope. Clients map code through locale resources and do not render message directly.
401Stable error envelope. Clients map code through locale resources and do not render message directly.
403Stable error envelope. Clients map code through locale resources and do not render message directly.
405Stable error envelope. Clients map code through locale resources and do not render message directly.
409Stable error envelope. Clients map code through locale resources and do not render message directly.
415Stable error envelope. Clients map code through locale resources and do not render message directly.
500Stable error envelope. Clients map code through locale resources and do not render message directly.

失败时怎么办

  • 400 按字段说明修正参数或请求体再发;不要原样重试。
  • 401 检查凭据格式、是否过期或被轮换。
  • 403 检查 Key 范围与所有者当前权限、当前租户作用域;不要换更高权限账号绕过。
  • 409 先回读资源当前状态;同一操作重试保持原 Idempotency-Key 和原请求内容。
  • 500 结果未知:先按资源 ID 或列表回读确认,再决定是否用原 Idempotency-Key 重试。

↑ 回到列表

GET /v1/admin/notifications/deliveries

List redacted notification delivery settlements

operationId
listNotificationDeliveries
认证
  • 登录会话:主控登录后的 Bearer 会话,由客户本人在自己的主控里使用;插件不能要求客户交出会话。
所需权限

全部需要:system_configuration.read

说明(契约原文)

Lists durable delivery state without recipient contacts, subject, body, deduplication keys, lease tokens, provider response bodies, or credentials. The cursor is stable for the selected filters.

参数

listNotificationDeliveries 参数
名称位置类型必填说明
scope_idquerystring(uuid)否—
channelquerystring: email / sms否—
statequerystring: pending / dispatching / retry_wait / accepted / unknown / delivered / permanent_failed / exhausted / cancelled否—
limitqueryinteger否—
cursorquerystring(uuid)否—

响应

listNotificationDeliveries 响应
状态码说明
200Redacted delivery settlement page.

字段:items: array<DeliveryLog> next_cursor?: string(uuid)

400Stable error envelope. Clients map code through locale resources and do not render message directly.
401Stable error envelope. Clients map code through locale resources and do not render message directly.
403Stable error envelope. Clients map code through locale resources and do not render message directly.
405Stable error envelope. Clients map code through locale resources and do not render message directly.
500Stable error envelope. Clients map code through locale resources and do not render message directly.

失败时怎么办

  • 400 按字段说明修正参数或请求体再发;不要原样重试。
  • 401 检查凭据格式、是否过期或被轮换。
  • 403 检查 Key 范围与所有者当前权限、当前租户作用域;不要换更高权限账号绕过。
  • 500 结果未知:先按资源 ID 或列表回读确认,再决定是否用原 Idempotency-Key 重试。

↑ 回到列表

GET /v1/admin/notifications/deliveries/{outbox_id}/attempts

List redacted attempts for one notification delivery

operationId
listNotificationDeliveryAttempts
认证
  • 登录会话:主控登录后的 Bearer 会话,由客户本人在自己的主控里使用;插件不能要求客户交出会话。
所需权限

全部需要:system_configuration.read

参数

listNotificationDeliveryAttempts 参数
名称位置类型必填说明
outbox_idpathstring(uuid)是—

响应

listNotificationDeliveryAttempts 响应
状态码说明
200Redacted delivery attempt facts for one outbox item.

字段:outbox_id: string(uuid) items: array<DeliveryAttempt>

400Stable error envelope. Clients map code through locale resources and do not render message directly.
401Stable error envelope. Clients map code through locale resources and do not render message directly.
403Stable error envelope. Clients map code through locale resources and do not render message directly.
404Stable error envelope. Clients map code through locale resources and do not render message directly.
405Stable error envelope. Clients map code through locale resources and do not render message directly.
500Stable error envelope. Clients map code through locale resources and do not render message directly.

失败时怎么办

  • 400 按字段说明修正参数或请求体再发;不要原样重试。
  • 401 检查凭据格式、是否过期或被轮换。
  • 403 检查 Key 范围与所有者当前权限、当前租户作用域;不要换更高权限账号绕过。
  • 404 资源不存在或不属于当前租户。
  • 500 结果未知:先按资源 ID 或列表回读确认,再决定是否用原 Idempotency-Key 重试。

↑ 回到列表

GET /v1/admin/notifications/delivery-history

List redacted immutable notification delivery facts

operationId
listNotificationDeliveryHistory
认证
  • 登录会话:主控登录后的 Bearer 会话,由客户本人在自己的主控里使用;插件不能要求客户交出会话。
所需权限

任一即可:system_configuration.read platform.admin

说明(契约原文)

Platform administrators with system_configuration.read or platform.admin may query all scopes or one exact scope. Session, membership and current permissions are revalidated before query validation and lookup. One row identifies one immutable outbox sequence, including anonymous recipients and replay generations. Filters combine with AND. Without from/to the complete history is queried. Each optional bound is inclusive; when both are supplied, to must be greater than from and the window at most 31 days. The current request uses one consistent database view for cursor validation, total_count and rows. Pages are ordered by observed_at, outbox_id and sequence descending. Cursors identify persisted facts and are validated against the current filters; they do not promise a snapshot across requests. Delivery history never includes message titles, bodies, full recipient contacts, provider response bodies, deduplication keys, lease tokens or credentials. New transport calls record only a masked recipient address and provider_call_started_at. A row sees only an observation in the same attempt through its own sequence; dispatch_started never reads a future settlement observation. Historical rows without observations remain null and are never backfilled from current user contacts. Message content retains its separate administrator message-query contract.

参数

listNotificationDeliveryHistory 参数
名称位置类型必填说明
scope_idquerystring(uuid)否Optional exact scope; omitted means all scopes for an authorized platform administrator.
channelquerystring: email / sms否—
statequerystring: pending / dispatching / retry_wait / accepted / unknown / delivered / permanent_failed / exhausted / cancelled否—
resultquerystring: success / failure否success means only delivered; failure means retry_wait, permanent_failed or exhausted. accepted, unknown, lease_unknown and cancelled are neither success nor failure. When state is also supplied, both filters must match; a contradiction returns an empty page.
event_typequerystring否Exact persisted notification event type, not a legacy UI alias.
user_idquerystring否Canonical lowercase nonzero UUID or positive decimal display ID, at most signed int64 maximum; filters recipients, not actors.
message_idquerystring(uuid)否Exact immutable notification_events.id, shared by original and replay outboxes.
fromquerystring(date-time)否Inclusive observed_at lower bound, RFC3339 with optional fractional seconds.
toquerystring(date-time)否Inclusive observed_at upper bound, RFC3339 with optional fractional seconds.
limitqueryinteger否—
cursorquerystring否Returned outbox UUID and positive int32 fact sequence; must identify a fact satisfying the current filters.

响应

listNotificationDeliveryHistory 响应
状态码说明
200A consistent current-request page and filtered total, with no cross-request snapshot guarantee.

字段:schema: string items: array<DeliveryHistoryFact> total_count: integer(int64) next_cursor?: string

400Stable error envelope. Clients map code through locale resources and do not render message directly.
401Stable error envelope. Clients map code through locale resources and do not render message directly.
403Stable error envelope. Clients map code through locale resources and do not render message directly.
405Stable error envelope. Clients map code through locale resources and do not render message directly.
500Stable error envelope. Clients map code through locale resources and do not render message directly.

失败时怎么办

  • 400 按字段说明修正参数或请求体再发;不要原样重试。
  • 401 检查凭据格式、是否过期或被轮换。
  • 403 检查 Key 范围与所有者当前权限、当前租户作用域;不要换更高权限账号绕过。
  • 500 结果未知:先按资源 ID 或列表回读确认,再决定是否用原 Idempotency-Key 重试。

↑ 回到列表

GET /v1/admin/notifications/messages

List the compatibility message projection

operationId
listNotificationMessages
认证
  • 登录会话:主控登录后的 Bearer 会话,由客户本人在自己的主控里使用;插件不能要求客户交出会话。
所需权限

全部需要:system_configuration.read

说明(契约原文)

Event-centric administrator view of member notification facts. Fields that are not backed by durable facts are returned as null. Site and package use the subject recorded when the event was raised; older package-monitor rows fall back to the monitor transition's exact subscription. Events raised without a site subject never match a site filter, and ownership is never inferred from current bindings. Titles, channel bodies and email_state/sms_state come from original generation-1 outbox facts (null = that channel was not generated); delivery replay does not duplicate message rows.

参数

listNotificationMessages 参数
名称位置类型必填说明
scope_idquerystring(uuid)否—
typequerystring否—
user_idquerystring(uuid)否—
package_idquerystring否Exact user subscription ID from a monitor transition; product IDs do not match. Unknown IDs return an empty page.
site_idquerystring否Site recorded when the event was raised (notification_events.subject_site_id); events without a site subject never match.
userquerystring否Recipient user by exact display ID or case-insensitive substring of username / display name (current values).
packagequerystring否User subscription by exact display ID or case-insensitive substring of the package name; events whose subscription no longer exists never match.
sitequerystring否Event-time site by exact display ID or case-insensitive substring of its current domain; events whose site no longer exists never match.
limitqueryinteger否—
cursorquerystring(uuid)否—

响应

listNotificationMessages 响应
状态码说明
200Versioned, event-centric compatibility projection of member notification facts.

字段:schema: string items: array<Message> next_cursor?: string(uuid) total: integer

400Stable error envelope. Clients map code through locale resources and do not render message directly.
401Stable error envelope. Clients map code through locale resources and do not render message directly.
403Stable error envelope. Clients map code through locale resources and do not render message directly.
405Stable error envelope. Clients map code through locale resources and do not render message directly.
500Stable error envelope. Clients map code through locale resources and do not render message directly.

失败时怎么办

  • 400 按字段说明修正参数或请求体再发;不要原样重试。
  • 401 检查凭据格式、是否过期或被轮换。
  • 403 检查 Key 范围与所有者当前权限、当前租户作用域;不要换更高权限账号绕过。
  • 500 结果未知:先按资源 ID 或列表回读确认,再决定是否用原 Idempotency-Key 重试。

↑ 回到列表

GET /v1/admin/notifications/policy

Read notification delivery window and event policies

operationId
getNotificationDeliveryPolicy
认证
  • 登录会话:主控登录后的 Bearer 会话,由客户本人在自己的主控里使用;插件不能要求客户交出会话。
所需权限

全部需要:system_configuration.read

响应

getNotificationDeliveryPolicy 响应
状态码说明
200Versioned global delivery window and per-event execution policy. System-required identity messages bypass these timing and subscription controls.

字段:window_mode: string: all_day / custom window_start: string window_end: string timezone: string events: array<DeliveryPolicyEvent> schema: string revision: integer(int64) changed: boolean

400Stable error envelope. Clients map code through locale resources and do not render message directly.
401Stable error envelope. Clients map code through locale resources and do not render message directly.
403Stable error envelope. Clients map code through locale resources and do not render message directly.
405Stable error envelope. Clients map code through locale resources and do not render message directly.
500Stable error envelope. Clients map code through locale resources and do not render message directly.

失败时怎么办

  • 400 按字段说明修正参数或请求体再发;不要原样重试。
  • 401 检查凭据格式、是否过期或被轮换。
  • 403 检查 Key 范围与所有者当前权限、当前租户作用域;不要换更高权限账号绕过。
  • 500 结果未知:先按资源 ID 或列表回读确认,再决定是否用原 Idempotency-Key 重试。

↑ 回到列表

PUT /v1/admin/notifications/policy

Update notification delivery window and event policies

operationId
updateNotificationDeliveryPolicy
认证
  • 登录会话:主控登录后的 Bearer 会话,由客户本人在自己的主控里使用;插件不能要求客户交出会话。
所需权限

全部需要:system_configuration.manage

参数

updateNotificationDeliveryPolicy 参数
名称位置类型必填说明
If-Matchheaderstring是—
X-Request-IDheaderstring否Correlation identifier and retry key for this write. Reusing the same value for the same authenticated actor and operation requires the exact original path, revision, and body; an exact retry replays the original response, while changed semantics return 409.

请求体

application/json · 必填:是

updateNotificationDeliveryPolicy 请求体
名称类型必填说明
window_modestring: all_day / custom是—
window_startstring是—
window_endstring是—
timezonestring是—
eventsarray<DeliveryPolicyEvent>是—

响应

updateNotificationDeliveryPolicy 响应
状态码说明
200Versioned global delivery window and per-event execution policy. System-required identity messages bypass these timing and subscription controls.

字段:window_mode: string: all_day / custom window_start: string window_end: string timezone: string events: array<DeliveryPolicyEvent> schema: string revision: integer(int64) changed: boolean

400Stable error envelope. Clients map code through locale resources and do not render message directly.
401Stable error envelope. Clients map code through locale resources and do not render message directly.
403Stable error envelope. Clients map code through locale resources and do not render message directly.
405Stable error envelope. Clients map code through locale resources and do not render message directly.
409Stable error envelope. Clients map code through locale resources and do not render message directly.
415Stable error envelope. Clients map code through locale resources and do not render message directly.
500Stable error envelope. Clients map code through locale resources and do not render message directly.

失败时怎么办

  • 400 按字段说明修正参数或请求体再发;不要原样重试。
  • 401 检查凭据格式、是否过期或被轮换。
  • 403 检查 Key 范围与所有者当前权限、当前租户作用域;不要换更高权限账号绕过。
  • 409 先回读资源当前状态;同一操作重试保持原 Idempotency-Key 和原请求内容。
  • 500 结果未知:先按资源 ID 或列表回读确认,再决定是否用原 Idempotency-Key 重试。

↑ 回到列表

GET /v1/admin/notifications/templates

List immutable notification template versions

operationId
listNotificationTemplates
认证
  • 登录会话:主控登录后的 Bearer 会话,由客户本人在自己的主控里使用;插件不能要求客户交出会话。
所需权限

全部需要:system_configuration.read

响应

listNotificationTemplates 响应
状态码说明
200Immutable notification template versions.

字段:items: array<Template>

400Stable error envelope. Clients map code through locale resources and do not render message directly.
401Stable error envelope. Clients map code through locale resources and do not render message directly.
403Stable error envelope. Clients map code through locale resources and do not render message directly.
405Stable error envelope. Clients map code through locale resources and do not render message directly.
500Stable error envelope. Clients map code through locale resources and do not render message directly.

失败时怎么办

  • 400 按字段说明修正参数或请求体再发;不要原样重试。
  • 401 检查凭据格式、是否过期或被轮换。
  • 403 检查 Key 范围与所有者当前权限、当前租户作用域;不要换更高权限账号绕过。
  • 500 结果未知:先按资源 ID 或列表回读确认,再决定是否用原 Idempotency-Key 重试。

↑ 回到列表

PUT /v1/admin/notifications/templates/{template_id}/versions/{version}/{channel}

Create an immutable notification template version

operationId
putNotificationTemplateVersion
认证
  • 登录会话:主控登录后的 Bearer 会话,由客户本人在自己的主控里使用;插件不能要求客户交出会话。
所需权限

全部需要:system_configuration.manage

参数

putNotificationTemplateVersion 参数
名称位置类型必填说明
template_idpathstring是—
versionpathinteger(int64)是—
channelpathstring: email / sms是—
X-Request-IDheaderstring否Correlation identifier and retry key for this write. Reusing the same value for the same authenticated actor and operation requires the exact original path, revision, and body; an exact retry replays the original response, while changed semantics return 409.

请求体

application/json · 必填:是

putNotificationTemplateVersion 请求体
名称类型必填说明
subjectstring是Required and non-empty for email; must be empty for SMS. Maximum source size is 2048 UTF-8 bytes.
bodystring是Maximum source size is 131072 UTF-8 bytes for email and 8192 UTF-8 bytes for SMS.
variablesarray<string>是—

响应

putNotificationTemplateVersion 响应
状态码说明
200Created template version or an identical natural replay.

字段:template_id: string version: integer(int64) channel: string: email / sms subject: string body: string variables: array<string> created_at: string(date-time) changed: boolean

400Stable error envelope. Clients map code through locale resources and do not render message directly.
401Stable error envelope. Clients map code through locale resources and do not render message directly.
403Stable error envelope. Clients map code through locale resources and do not render message directly.
405Stable error envelope. Clients map code through locale resources and do not render message directly.
409Stable error envelope. Clients map code through locale resources and do not render message directly.
415Stable error envelope. Clients map code through locale resources and do not render message directly.
500Stable error envelope. Clients map code through locale resources and do not render message directly.

失败时怎么办

  • 400 按字段说明修正参数或请求体再发;不要原样重试。
  • 401 检查凭据格式、是否过期或被轮换。
  • 403 检查 Key 范围与所有者当前权限、当前租户作用域;不要换更高权限账号绕过。
  • 409 先回读资源当前状态;同一操作重试保持原 Idempotency-Key 和原请求内容。
  • 500 结果未知:先按资源 ID 或列表回读确认,再决定是否用原 Idempotency-Key 重试。

↑ 回到列表