mirror of
https://github.com/chriswritescode-dev/opencode-manager.git
synced 2026-12-05 20:34:18 +01:00
section 11: Phase 11: Internal session routes, ocm tool allow-list and
This commit is contained in:
1 parent
206113438c
commit
fc623fde96
10 files changed
+868
-2
No files matched your search
@@ -16,6 +16,11 @@ export const MANAGER_TOOL_ALLOWED_ROUTES = [
|
||||
'GET /repos',
|
||||
'GET /repos/*/git-info',
|
||||
'GET /opencode-workspaces',
|
||||
'GET /sessions',
|
||||
'POST /sessions',
|
||||
'POST /sessions/*/prompt',
|
||||
'GET /sessions/*/reply',
|
||||
'POST /sessions/*/fork',
|
||||
'GET /schedules/all',
|
||||
'GET /schedules/all/runs',
|
||||
'GET /repos/*/schedules',
|
||||
@@ -106,7 +111,7 @@ function buildManagerToolDescription(): string {
|
||||
'The action runs inside OpenCode Manager itself, so it needs no token and no network access from the agent shell, and it works in sandboxed sessions and scheduled runs.',
|
||||
'Actions:',
|
||||
'- send_notification: send a push notification to every device the user has registered.',
|
||||
'- request: call an allow-listed internal API route to read and manage settings, the OpenCode configuration file, repos, OpenCode workspaces, and schedules.',
|
||||
'- request: call an allow-listed internal API route to read and manage settings, the OpenCode configuration file, repos, OpenCode workspaces, sessions (list, create, follow up, read the latest reply, fork), and schedules.',
|
||||
'Allowed request routes:',
|
||||
]
|
||||
.concat(MANAGER_TOOL_ALLOWED_ROUTES.map((route) => `- ${route}`))
|
||||
|
||||
Reference in new issue
Block a user