Expose session-owned chat automation metadata
This commit is contained in:
@@ -126,6 +126,10 @@ const (
|
||||
// carries ChatAttachmentImageContent. Only regular image files inside the
|
||||
// server's private chat attachment store are served.
|
||||
ChatAttachmentImage = "chat_attachment_image"
|
||||
// ChatAutomations reads provider-owned scheduled work for one operator chat.
|
||||
// It is deliberately read-only; providers that cannot authoritatively expose
|
||||
// this information return an unavailable status instead of an empty count.
|
||||
ChatAutomations = "chat_automations"
|
||||
// ChatEvent and ChatPermission are the server-pushed frames; they are the
|
||||
// only types the server sends without a matching request.
|
||||
ChatEvent = "chat_event"
|
||||
@@ -141,6 +145,22 @@ const (
|
||||
ChatPermission = "chat_permission"
|
||||
)
|
||||
|
||||
const (
|
||||
ChatAutomationSupported = "supported"
|
||||
ChatAutomationUnavailable = "unavailable"
|
||||
)
|
||||
|
||||
// ChatAutomationInfo is the bounded, per-session scheduled-work snapshot. A
|
||||
// nil ActiveCount means the provider could not authoritatively report a count;
|
||||
// zero is reserved for a supported provider with no active schedules.
|
||||
type ChatAutomationInfo struct {
|
||||
SessionID string `json:"session_id"`
|
||||
Provider string `json:"provider"`
|
||||
Status string `json:"status"`
|
||||
ActiveCount *int `json:"active_count,omitempty"`
|
||||
Reason string `json:"reason,omitempty"`
|
||||
}
|
||||
|
||||
// Content part types carried by ChatPart.Type and ChatEvent.Kind.
|
||||
const (
|
||||
ChatPartText = "text"
|
||||
|
||||
Reference in New Issue
Block a user