mirror of
https://github.com/memohai/Memoh.git
synced 2026-04-27 07:16:19 +09:00
feat(access): add guest chat ACL (#235)
This commit is contained in:
+17
-18
@@ -19,7 +19,6 @@ type Bot struct {
|
||||
MaxContextLoadTime int32 `json:"max_context_load_time"`
|
||||
MaxContextTokens int32 `json:"max_context_tokens"`
|
||||
Language string `json:"language"`
|
||||
AllowGuest bool `json:"allow_guest"`
|
||||
ReasoningEnabled bool `json:"reasoning_enabled"`
|
||||
ReasoningEffort string `json:"reasoning_effort"`
|
||||
MaxInboxItems int32 `json:"max_inbox_items"`
|
||||
@@ -37,6 +36,23 @@ type Bot struct {
|
||||
UpdatedAt pgtype.Timestamptz `json:"updated_at"`
|
||||
}
|
||||
|
||||
type BotAclRule struct {
|
||||
ID pgtype.UUID `json:"id"`
|
||||
BotID pgtype.UUID `json:"bot_id"`
|
||||
Action string `json:"action"`
|
||||
Effect string `json:"effect"`
|
||||
SubjectKind string `json:"subject_kind"`
|
||||
UserID pgtype.UUID `json:"user_id"`
|
||||
ChannelIdentityID pgtype.UUID `json:"channel_identity_id"`
|
||||
SourceChannel pgtype.Text `json:"source_channel"`
|
||||
SourceConversationType pgtype.Text `json:"source_conversation_type"`
|
||||
SourceConversationID pgtype.Text `json:"source_conversation_id"`
|
||||
SourceThreadID pgtype.Text `json:"source_thread_id"`
|
||||
CreatedByUserID pgtype.UUID `json:"created_by_user_id"`
|
||||
CreatedAt pgtype.Timestamptz `json:"created_at"`
|
||||
UpdatedAt pgtype.Timestamptz `json:"updated_at"`
|
||||
}
|
||||
|
||||
type BotChannelConfig struct {
|
||||
ID pgtype.UUID `json:"id"`
|
||||
BotID pgtype.UUID `json:"bot_id"`
|
||||
@@ -129,23 +145,6 @@ type BotInbox struct {
|
||||
ReadAt pgtype.Timestamptz `json:"read_at"`
|
||||
}
|
||||
|
||||
type BotMember struct {
|
||||
BotID pgtype.UUID `json:"bot_id"`
|
||||
UserID pgtype.UUID `json:"user_id"`
|
||||
Role string `json:"role"`
|
||||
CreatedAt pgtype.Timestamptz `json:"created_at"`
|
||||
}
|
||||
|
||||
type BotPreauthKey struct {
|
||||
ID pgtype.UUID `json:"id"`
|
||||
BotID pgtype.UUID `json:"bot_id"`
|
||||
Token string `json:"token"`
|
||||
IssuedByUserID pgtype.UUID `json:"issued_by_user_id"`
|
||||
ExpiresAt pgtype.Timestamptz `json:"expires_at"`
|
||||
UsedAt pgtype.Timestamptz `json:"used_at"`
|
||||
CreatedAt pgtype.Timestamptz `json:"created_at"`
|
||||
}
|
||||
|
||||
type BotStorageBinding struct {
|
||||
ID pgtype.UUID `json:"id"`
|
||||
BotID pgtype.UUID `json:"bot_id"`
|
||||
|
||||
Reference in New Issue
Block a user