feat: add UMO config overrides

This commit is contained in:
Soulter
2026-07-05 14:47:58 +08:00
parent 25cbd41e08
commit 31e7af82d7
56 changed files with 2813 additions and 1447 deletions

View File

@@ -3896,6 +3896,69 @@ paths:
"200":
$ref: "#/components/responses/Ok"
/api/v1/sessions/config-overrides:
get:
tags: [Sessions]
summary: List UMO config overrides
operationId: listSessionConfigOverrides
x-astrbot-scope: data
parameters:
- $ref: "#/components/parameters/Page"
- $ref: "#/components/parameters/PageSize"
- name: search
in: query
schema:
type: string
responses:
"200":
$ref: "#/components/responses/Ok"
post:
tags: [Sessions]
summary: Update or create a UMO config override
operationId: upsertSessionConfigOverride
x-astrbot-scope: data
requestBody:
required: true
content:
application/json:
schema:
$ref: "#/components/schemas/SessionConfigOverrideRequest"
responses:
"200":
$ref: "#/components/responses/Ok"
/api/v1/sessions/config-overrides/delete:
post:
tags: [Sessions]
summary: Delete one or more UMO config overrides
operationId: deleteSessionConfigOverride
x-astrbot-scope: data
requestBody:
required: true
content:
application/json:
schema:
$ref: "#/components/schemas/SessionConfigOverrideDeleteRequest"
responses:
"200":
$ref: "#/components/responses/Ok"
/api/v1/sessions/aliases:
post:
tags: [Sessions]
summary: Update UMO aliases used as session remarks
operationId: upsertSessionAlias
x-astrbot-scope: data
requestBody:
required: true
content:
application/json:
schema:
$ref: "#/components/schemas/SessionAliasRequest"
responses:
"200":
$ref: "#/components/responses/Ok"
/api/v1/sessions/provider:
patch:
tags: [Sessions]
@@ -5863,6 +5926,58 @@ components:
$ref: "#/components/schemas/DynamicConfig"
additionalProperties: true
SessionConfigOverrideRequest:
type: object
required: [umo, path, value]
properties:
umo:
type: string
path:
type: string
value: {}
additionalProperties: true
SessionConfigOverrideDeleteRequest:
type: object
properties:
umo:
type: string
umos:
type: array
items:
type: string
scope:
type: string
enum: [all, group, private, custom_group]
group_id:
type: string
path:
type: string
paths:
type: array
items:
type: string
additionalProperties: true
SessionAliasRequest:
type: object
required: [custom_name]
properties:
umo:
type: string
umos:
type: array
items:
type: string
scope:
type: string
enum: [all, group, private, custom_group]
group_id:
type: string
custom_name:
type: string
additionalProperties: true
UmoListRequest:
type: object
properties: