Documentation
¶
Index ¶
- func ApiRoutes(router *http.ServeMux)
- func HandleAuthorization(w http.ResponseWriter, r *http.Request)
- func HandleCallMethod(w http.ResponseWriter, r *http.Request)
- func HandleClearAuthBlocks(w http.ResponseWriter, r *http.Request)
- func HandleCreateCommand(w http.ResponseWriter, r *http.Request)
- func HandleCreateEventSink(w http.ResponseWriter, r *http.Request)
- func HandleCreateGroup(w http.ResponseWriter, r *http.Request)
- func HandleCreateMCPServer(w http.ResponseWriter, r *http.Request)
- func HandleCreatePool(w http.ResponseWriter, r *http.Request)
- func HandleCreateRole(w http.ResponseWriter, r *http.Request)
- func HandleCreateScript(w http.ResponseWriter, r *http.Request)
- func HandleCreateSkill(w http.ResponseWriter, r *http.Request)
- func HandleCreateSpace(w http.ResponseWriter, r *http.Request)
- func HandleCreateStackDefinition(w http.ResponseWriter, r *http.Request)
- func HandleCreateTemplate(w http.ResponseWriter, r *http.Request)
- func HandleCreateTemplateVar(w http.ResponseWriter, r *http.Request)
- func HandleCreateToken(w http.ResponseWriter, r *http.Request)
- func HandleCreateUser(w http.ResponseWriter, r *http.Request)
- func HandleCreateVolume(w http.ResponseWriter, r *http.Request)
- func HandleDeleteCommand(w http.ResponseWriter, r *http.Request)
- func HandleDeleteEventSink(w http.ResponseWriter, r *http.Request)
- func HandleDeleteGroup(w http.ResponseWriter, r *http.Request)
- func HandleDeleteMCPServer(w http.ResponseWriter, r *http.Request)
- func HandleDeletePool(w http.ResponseWriter, r *http.Request)
- func HandleDeleteRole(w http.ResponseWriter, r *http.Request)
- func HandleDeleteScript(w http.ResponseWriter, r *http.Request)
- func HandleDeleteSessions(w http.ResponseWriter, r *http.Request)
- func HandleDeleteSkill(w http.ResponseWriter, r *http.Request)
- func HandleDeleteSpace(w http.ResponseWriter, r *http.Request)
- func HandleDeleteSpaceFile(w http.ResponseWriter, r *http.Request)
- func HandleDeleteStackDefinition(w http.ResponseWriter, r *http.Request)
- func HandleDeleteTemplate(w http.ResponseWriter, r *http.Request)
- func HandleDeleteTemplateVar(w http.ResponseWriter, r *http.Request)
- func HandleDeleteToken(w http.ResponseWriter, r *http.Request)
- func HandleDeleteTunnel(w http.ResponseWriter, r *http.Request)
- func HandleDeleteUser(w http.ResponseWriter, r *http.Request)
- func HandleDeleteVolume(w http.ResponseWriter, r *http.Request)
- func HandleEditFile(w http.ResponseWriter, r *http.Request)
- func HandleEmitEvent(w http.ResponseWriter, r *http.Request)
- func HandleEmitUserEvent(w http.ResponseWriter, r *http.Request)
- func HandleExecuteScript(w http.ResponseWriter, r *http.Request)
- func HandleExecuteScriptStream(w http.ResponseWriter, r *http.Request)
- func HandleExportAuditLogs(w http.ResponseWriter, r *http.Request)
- func HandleExportTemplate(w http.ResponseWriter, r *http.Request)
- func HandleFind(w http.ResponseWriter, r *http.Request)
- func HandleGetAuditLogs(w http.ResponseWriter, r *http.Request)
- func HandleGetBaseImages(w http.ResponseWriter, r *http.Request)
- func HandleGetCapabilities(w http.ResponseWriter, r *http.Request)
- func HandleGetClusterInfo(w http.ResponseWriter, r *http.Request)
- func HandleGetClusterNode(w http.ResponseWriter, r *http.Request)
- func HandleGetCommand(w http.ResponseWriter, r *http.Request)
- func HandleGetCommands(w http.ResponseWriter, r *http.Request)
- func HandleGetEventSink(w http.ResponseWriter, r *http.Request)
- func HandleGetEventSinks(w http.ResponseWriter, r *http.Request)
- func HandleGetGlobalScripts(w http.ResponseWriter, r *http.Request)
- func HandleGetGroup(w http.ResponseWriter, r *http.Request)
- func HandleGetGroups(w http.ResponseWriter, r *http.Request)
- func HandleGetIcons(w http.ResponseWriter, r *http.Request)
- func HandleGetMCPServer(w http.ResponseWriter, r *http.Request)
- func HandleGetMCPServers(w http.ResponseWriter, r *http.Request)
- func HandleGetMethods(w http.ResponseWriter, r *http.Request)
- func HandleGetOwnNavPreferences(w http.ResponseWriter, r *http.Request)
- func HandleGetPermissions(w http.ResponseWriter, r *http.Request)
- func HandleGetPool(w http.ResponseWriter, r *http.Request)
- func HandleGetPools(w http.ResponseWriter, r *http.Request)
- func HandleGetRole(w http.ResponseWriter, r *http.Request)
- func HandleGetRoles(w http.ResponseWriter, r *http.Request)
- func HandleGetScript(w http.ResponseWriter, r *http.Request)
- func HandleGetScriptByName(w http.ResponseWriter, r *http.Request)
- func HandleGetScriptDetailsByName(w http.ResponseWriter, r *http.Request)
- func HandleGetScriptLibsZip(w http.ResponseWriter, r *http.Request)
- func HandleGetScripts(w http.ResponseWriter, r *http.Request)
- func HandleGetServerInfo(w http.ResponseWriter, r *http.Request)
- func HandleGetSessions(w http.ResponseWriter, r *http.Request)
- func HandleGetSkill(w http.ResponseWriter, r *http.Request)
- func HandleGetSkills(w http.ResponseWriter, r *http.Request)
- func HandleGetSpace(w http.ResponseWriter, r *http.Request)
- func HandleGetSpaceCustomField(w http.ResponseWriter, r *http.Request)
- func HandleGetSpaceJobs(w http.ResponseWriter, r *http.Request)
- func HandleGetSpaceUsageCurrent(w http.ResponseWriter, r *http.Request)
- func HandleGetSpaceUsageHistory(w http.ResponseWriter, r *http.Request)
- func HandleGetSpaces(w http.ResponseWriter, r *http.Request)
- func HandleGetStackDefinition(w http.ResponseWriter, r *http.Request)
- func HandleGetStackDefinitions(w http.ResponseWriter, r *http.Request)
- func HandleGetTemplate(w http.ResponseWriter, r *http.Request)
- func HandleGetTemplateNodes(w http.ResponseWriter, r *http.Request)
- func HandleGetTemplateVar(w http.ResponseWriter, r *http.Request)
- func HandleGetTemplateVars(w http.ResponseWriter, r *http.Request)
- func HandleGetTemplates(w http.ResponseWriter, r *http.Request)
- func HandleGetTokens(w http.ResponseWriter, r *http.Request)
- func HandleGetTunnelServerInfo(w http.ResponseWriter, r *http.Request)
- func HandleGetTunnels(w http.ResponseWriter, r *http.Request)
- func HandleGetUser(w http.ResponseWriter, r *http.Request)
- func HandleGetUserHasPermission(w http.ResponseWriter, r *http.Request)
- func HandleGetUserPermissions(w http.ResponseWriter, r *http.Request)
- func HandleGetUserQuota(w http.ResponseWriter, r *http.Request)
- func HandleGetUsers(w http.ResponseWriter, r *http.Request)
- func HandleGetVolume(w http.ResponseWriter, r *http.Request)
- func HandleGetVolumeNodes(w http.ResponseWriter, r *http.Request)
- func HandleGetVolumes(w http.ResponseWriter, r *http.Request)
- func HandleGrep(w http.ResponseWriter, r *http.Request)
- func HandleImportTemplate(w http.ResponseWriter, r *http.Request)
- func HandleListMCPServerTools(w http.ResponseWriter, r *http.Request)
- func HandleLogout(w http.ResponseWriter, r *http.Request)
- func HandlePing(w http.ResponseWriter, r *http.Request)
- func HandlePoolStart(w http.ResponseWriter, r *http.Request)
- func HandlePoolStop(w http.ResponseWriter, r *http.Request)
- func HandleReadSpaceFile(w http.ResponseWriter, r *http.Request)
- func HandleRefreshBaseImages(w http.ResponseWriter, r *http.Request)
- func HandleRunCommand(w http.ResponseWriter, r *http.Request)
- func HandleSSE(w http.ResponseWriter, r *http.Request)
- func HandleSearch(w http.ResponseWriter, r *http.Request)
- func HandleSearchSkills(w http.ResponseWriter, r *http.Request)
- func HandleSed(w http.ResponseWriter, r *http.Request)
- func HandleSetPoolSize(w http.ResponseWriter, r *http.Request)
- func HandleSetSpaceCustomField(w http.ResponseWriter, r *http.Request)
- func HandleSpaceAddShare(w http.ResponseWriter, r *http.Request)
- func HandleSpaceRemoveShare(w http.ResponseWriter, r *http.Request)
- func HandleSpaceRestart(w http.ResponseWriter, r *http.Request)
- func HandleSpaceStart(w http.ResponseWriter, r *http.Request)
- func HandleSpaceStop(w http.ResponseWriter, r *http.Request)
- func HandleSpaceStopUsersSpaces(w http.ResponseWriter, r *http.Request)
- func HandleSpaceTransfer(w http.ResponseWriter, r *http.Request)
- func HandleSpecBuild(w http.ResponseWriter, r *http.Request)
- func HandleSpecParse(w http.ResponseWriter, r *http.Request)
- func HandleStackDelete(w http.ResponseWriter, r *http.Request)
- func HandleStackExists(w http.ResponseWriter, r *http.Request)
- func HandleStackRestart(w http.ResponseWriter, r *http.Request)
- func HandleStackStart(w http.ResponseWriter, r *http.Request)
- func HandleStackStop(w http.ResponseWriter, r *http.Request)
- func HandleToggleMCPServerTool(w http.ResponseWriter, r *http.Request)
- func HandleUpdateCommand(w http.ResponseWriter, r *http.Request)
- func HandleUpdateEventSink(w http.ResponseWriter, r *http.Request)
- func HandleUpdateGroup(w http.ResponseWriter, r *http.Request)
- func HandleUpdateMCPServer(w http.ResponseWriter, r *http.Request)
- func HandleUpdateOwnNavPreferences(w http.ResponseWriter, r *http.Request)
- func HandleUpdateOwnSSHPrivateKey(w http.ResponseWriter, r *http.Request)
- func HandleUpdateOwnSSHPublicKey(w http.ResponseWriter, r *http.Request)
- func HandleUpdatePool(w http.ResponseWriter, r *http.Request)
- func HandleUpdateRole(w http.ResponseWriter, r *http.Request)
- func HandleUpdateScript(w http.ResponseWriter, r *http.Request)
- func HandleUpdateSkill(w http.ResponseWriter, r *http.Request)
- func HandleUpdateSpace(w http.ResponseWriter, r *http.Request)
- func HandleUpdateSpaceJobs(w http.ResponseWriter, r *http.Request)
- func HandleUpdateStackDefinition(w http.ResponseWriter, r *http.Request)
- func HandleUpdateTemplate(w http.ResponseWriter, r *http.Request)
- func HandleUpdateTemplateVar(w http.ResponseWriter, r *http.Request)
- func HandleUpdateToken(w http.ResponseWriter, r *http.Request)
- func HandleUpdateUser(w http.ResponseWriter, r *http.Request)
- func HandleUpdateVolume(w http.ResponseWriter, r *http.Request)
- func HandleUsingTotp(w http.ResponseWriter, r *http.Request)
- func HandleValidateStackDefinition(w http.ResponseWriter, r *http.Request)
- func HandleValidateTemplate(w http.ResponseWriter, r *http.Request)
- func HandleValidateVolume(w http.ResponseWriter, r *http.Request)
- func HandleVolumeStart(w http.ResponseWriter, r *http.Request)
- func HandleVolumeStop(w http.ResponseWriter, r *http.Request)
- func HandleWhoAmI(w http.ResponseWriter, r *http.Request)
- func HandleWriteSpaceFile(w http.ResponseWriter, r *http.Request)
- type AvailableNode
- type ErrorResponse
- type JobsErrorResponse
- type MethodListResponse
- type ReadFileRequest
- type ReadFileResponse
- type RunCommandRequest
- type RunCommandResponse
- type UnifiedScriptExecuteRequest
- type WriteFileRequest
- type WriteFileResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func HandleAuthorization ¶
func HandleAuthorization(w http.ResponseWriter, r *http.Request)
func HandleCallMethod ¶ added in v0.28.0
func HandleCallMethod(w http.ResponseWriter, r *http.Request)
HandleCallMethod accepts JSON-RPC 2.0 requests in three forms:
- Single request: {"jsonrpc":"2.0","method":"...","params":{},"id":1}
- Batch: [{"jsonrpc":"2.0","method":"...","id":1},{...}]
- Notification: {"jsonrpc":"2.0","method":"...","params":{}} (no id)
Single requests return a single JSON-RPC response object. Batch requests return a JSON array of responses. Notifications produce no response entry. If all items in a batch are notifications the HTTP response is 204.
func HandleClearAuthBlocks ¶ added in v0.33.0
func HandleClearAuthBlocks(w http.ResponseWriter, r *http.Request)
HandleClearAuthBlocks flushes all auth rate-limit state (failed-login counters and active blocks) so blocked IPs can log in again immediately. Clearing is gossiped so the whole cluster flushes together.
func HandleCreateCommand ¶ added in v0.29.0
func HandleCreateCommand(w http.ResponseWriter, r *http.Request)
func HandleCreateEventSink ¶ added in v0.28.0
func HandleCreateEventSink(w http.ResponseWriter, r *http.Request)
func HandleCreateGroup ¶
func HandleCreateGroup(w http.ResponseWriter, r *http.Request)
func HandleCreateMCPServer ¶ added in v0.29.0
func HandleCreateMCPServer(w http.ResponseWriter, r *http.Request)
func HandleCreatePool ¶ added in v0.28.0
func HandleCreatePool(w http.ResponseWriter, r *http.Request)
func HandleCreateRole ¶
func HandleCreateRole(w http.ResponseWriter, r *http.Request)
func HandleCreateScript ¶ added in v0.23.0
func HandleCreateScript(w http.ResponseWriter, r *http.Request)
func HandleCreateSkill ¶ added in v0.23.0
func HandleCreateSkill(w http.ResponseWriter, r *http.Request)
func HandleCreateSpace ¶
func HandleCreateSpace(w http.ResponseWriter, r *http.Request)
func HandleCreateStackDefinition ¶ added in v0.24.0
func HandleCreateStackDefinition(w http.ResponseWriter, r *http.Request)
func HandleCreateTemplate ¶
func HandleCreateTemplate(w http.ResponseWriter, r *http.Request)
func HandleCreateTemplateVar ¶
func HandleCreateTemplateVar(w http.ResponseWriter, r *http.Request)
func HandleCreateToken ¶
func HandleCreateToken(w http.ResponseWriter, r *http.Request)
func HandleCreateUser ¶
func HandleCreateUser(w http.ResponseWriter, r *http.Request)
func HandleCreateVolume ¶
func HandleCreateVolume(w http.ResponseWriter, r *http.Request)
func HandleDeleteCommand ¶ added in v0.29.0
func HandleDeleteCommand(w http.ResponseWriter, r *http.Request)
func HandleDeleteEventSink ¶ added in v0.28.0
func HandleDeleteEventSink(w http.ResponseWriter, r *http.Request)
func HandleDeleteGroup ¶
func HandleDeleteGroup(w http.ResponseWriter, r *http.Request)
func HandleDeleteMCPServer ¶ added in v0.29.0
func HandleDeleteMCPServer(w http.ResponseWriter, r *http.Request)
func HandleDeletePool ¶ added in v0.28.0
func HandleDeletePool(w http.ResponseWriter, r *http.Request)
func HandleDeleteRole ¶
func HandleDeleteRole(w http.ResponseWriter, r *http.Request)
func HandleDeleteScript ¶ added in v0.23.0
func HandleDeleteScript(w http.ResponseWriter, r *http.Request)
func HandleDeleteSessions ¶
func HandleDeleteSessions(w http.ResponseWriter, r *http.Request)
func HandleDeleteSkill ¶ added in v0.23.0
func HandleDeleteSkill(w http.ResponseWriter, r *http.Request)
func HandleDeleteSpace ¶
func HandleDeleteSpace(w http.ResponseWriter, r *http.Request)
func HandleDeleteSpaceFile ¶ added in v0.31.0
func HandleDeleteSpaceFile(w http.ResponseWriter, r *http.Request)
HandleDeleteSpaceFile removes a file or directory from a space. A recursive delete uses os.RemoveAll semantics; a non-recursive delete on a non-empty directory fails. Missing paths are treated as success so the call is idempotent — important for sync tools whose "delete list" was computed against a slightly stale remote snapshot.
func HandleDeleteStackDefinition ¶ added in v0.24.0
func HandleDeleteStackDefinition(w http.ResponseWriter, r *http.Request)
func HandleDeleteTemplate ¶
func HandleDeleteTemplate(w http.ResponseWriter, r *http.Request)
func HandleDeleteTemplateVar ¶
func HandleDeleteTemplateVar(w http.ResponseWriter, r *http.Request)
func HandleDeleteToken ¶
func HandleDeleteToken(w http.ResponseWriter, r *http.Request)
func HandleDeleteTunnel ¶
func HandleDeleteTunnel(w http.ResponseWriter, r *http.Request)
func HandleDeleteUser ¶
func HandleDeleteUser(w http.ResponseWriter, r *http.Request)
func HandleDeleteVolume ¶
func HandleDeleteVolume(w http.ResponseWriter, r *http.Request)
func HandleEditFile ¶ added in v0.30.0
func HandleEditFile(w http.ResponseWriter, r *http.Request)
HandleEditFile performs a targeted search-and-replace edit in a space.
func HandleEmitEvent ¶ added in v0.28.0
func HandleEmitEvent(w http.ResponseWriter, r *http.Request)
HandleEmitEvent raises a custom event from within a space. It is used by the space-side scriptling knot.event.emit() via the apiclient MuxClient.
func HandleEmitUserEvent ¶ added in v0.28.1
func HandleEmitUserEvent(w http.ResponseWriter, r *http.Request)
HandleEmitUserEvent raises a user-scoped custom event from a server-side script context (e.g. MCP tool execution) where there is no associated space. It is the target of the loopback knot.event.emit() library registered in the MCP scriptling environment.
func HandleExecuteScript ¶ added in v0.23.0
func HandleExecuteScript(w http.ResponseWriter, r *http.Request)
func HandleExecuteScriptStream ¶ added in v0.23.0
func HandleExecuteScriptStream(w http.ResponseWriter, r *http.Request)
func HandleExportAuditLogs ¶ added in v0.24.0
func HandleExportAuditLogs(w http.ResponseWriter, r *http.Request)
func HandleExportTemplate ¶ added in v0.32.0
func HandleExportTemplate(w http.ResponseWriter, r *http.Request)
HandleExportTemplate returns a portable YAML representation of a template suitable for version control and cross-instance import.
func HandleFind ¶ added in v0.30.0
func HandleFind(w http.ResponseWriter, r *http.Request)
HandleFind finds files/directories in a space.
func HandleGetAuditLogs ¶
func HandleGetAuditLogs(w http.ResponseWriter, r *http.Request)
func HandleGetBaseImages ¶ added in v0.32.0
func HandleGetBaseImages(w http.ResponseWriter, r *http.Request)
HandleGetBaseImages returns the active base image manifest (embedded or external per server config). The Image field's ${{ .server.base_image_registry }} is left as-is; resolution happens at deploy time in the spec itself.
func HandleGetCapabilities ¶ added in v0.32.0
func HandleGetCapabilities(w http.ResponseWriter, r *http.Request)
HandleGetCapabilities returns the Linux capability catalog the wizard's capability picker renders (name + description, searchable client-side). The list is a static common subset; unknown-but-well-formed CAP_* names already present in a spec still round-trip through the wizard.
func HandleGetClusterInfo ¶
func HandleGetClusterInfo(w http.ResponseWriter, r *http.Request)
func HandleGetClusterNode ¶ added in v0.22.0
func HandleGetClusterNode(w http.ResponseWriter, r *http.Request)
func HandleGetCommand ¶ added in v0.29.0
func HandleGetCommand(w http.ResponseWriter, r *http.Request)
func HandleGetCommands ¶ added in v0.29.0
func HandleGetCommands(w http.ResponseWriter, r *http.Request)
func HandleGetEventSink ¶ added in v0.28.0
func HandleGetEventSink(w http.ResponseWriter, r *http.Request)
func HandleGetEventSinks ¶ added in v0.28.0
func HandleGetEventSinks(w http.ResponseWriter, r *http.Request)
func HandleGetGlobalScripts ¶ added in v0.23.0
func HandleGetGlobalScripts(w http.ResponseWriter, r *http.Request)
HandleGetGlobalScripts returns global scripts for template editing. Users with PermissionManageTemplates can see global scripts even without PermissionManageScripts.
func HandleGetGroup ¶
func HandleGetGroup(w http.ResponseWriter, r *http.Request)
func HandleGetGroups ¶
func HandleGetGroups(w http.ResponseWriter, r *http.Request)
func HandleGetIcons ¶ added in v0.23.0
func HandleGetIcons(w http.ResponseWriter, r *http.Request)
func HandleGetMCPServer ¶ added in v0.29.0
func HandleGetMCPServer(w http.ResponseWriter, r *http.Request)
func HandleGetMCPServers ¶ added in v0.29.0
func HandleGetMCPServers(w http.ResponseWriter, r *http.Request)
func HandleGetMethods ¶ added in v0.28.0
func HandleGetMethods(w http.ResponseWriter, r *http.Request)
func HandleGetOwnNavPreferences ¶ added in v0.32.0
func HandleGetOwnNavPreferences(w http.ResponseWriter, r *http.Request)
HandleGetOwnNavPreferences returns the current user's pinned (starred) sidebar URLs in their stored display order.
func HandleGetPermissions ¶
func HandleGetPermissions(w http.ResponseWriter, r *http.Request)
func HandleGetPool ¶ added in v0.28.0
func HandleGetPool(w http.ResponseWriter, r *http.Request)
func HandleGetPools ¶ added in v0.28.0
func HandleGetPools(w http.ResponseWriter, r *http.Request)
func HandleGetRole ¶
func HandleGetRole(w http.ResponseWriter, r *http.Request)
func HandleGetRoles ¶
func HandleGetRoles(w http.ResponseWriter, r *http.Request)
func HandleGetScript ¶ added in v0.23.0
func HandleGetScript(w http.ResponseWriter, r *http.Request)
func HandleGetScriptByName ¶ added in v0.23.0
func HandleGetScriptByName(w http.ResponseWriter, r *http.Request)
func HandleGetScriptDetailsByName ¶ added in v0.23.0
func HandleGetScriptDetailsByName(w http.ResponseWriter, r *http.Request)
func HandleGetScriptLibsZip ¶ added in v0.33.0
func HandleGetScriptLibsZip(w http.ResponseWriter, r *http.Request)
HandleGetScriptLibsZip serves the requesting user's `lib` scripts (their own plus global libraries, user overriding global on name collisions) packaged as a scriptling library zip: manifest.toml + lib/<name>.py. Agents fetch and cache this and re-serve it to in-space scriptling as /packages/libs.zip.
func HandleGetScripts ¶ added in v0.23.0
func HandleGetScripts(w http.ResponseWriter, r *http.Request)
func HandleGetServerInfo ¶ added in v0.26.0
func HandleGetServerInfo(w http.ResponseWriter, r *http.Request)
HandleGetServerInfo returns server-wide configuration that clients need but that is not user-specific (e.g. the wildcard domain used to build space web-port URLs).
func HandleGetSessions ¶
func HandleGetSessions(w http.ResponseWriter, r *http.Request)
func HandleGetSkill ¶ added in v0.23.0
func HandleGetSkill(w http.ResponseWriter, r *http.Request)
func HandleGetSkills ¶ added in v0.23.0
func HandleGetSkills(w http.ResponseWriter, r *http.Request)
func HandleGetSpace ¶
func HandleGetSpace(w http.ResponseWriter, r *http.Request)
func HandleGetSpaceCustomField ¶ added in v0.21.5
func HandleGetSpaceCustomField(w http.ResponseWriter, r *http.Request)
func HandleGetSpaceJobs ¶ added in v0.33.0
func HandleGetSpaceJobs(w http.ResponseWriter, r *http.Request)
HandleGetSpaceJobs returns the space's persisted job definitions and runner state. Works for stopped spaces too — the space record is the source of truth, only live run status needs the agent.
func HandleGetSpaceUsageCurrent ¶ added in v0.24.0
func HandleGetSpaceUsageCurrent(w http.ResponseWriter, r *http.Request)
func HandleGetSpaceUsageHistory ¶ added in v0.24.0
func HandleGetSpaceUsageHistory(w http.ResponseWriter, r *http.Request)
func HandleGetSpaces ¶
func HandleGetSpaces(w http.ResponseWriter, r *http.Request)
func HandleGetStackDefinition ¶ added in v0.24.0
func HandleGetStackDefinition(w http.ResponseWriter, r *http.Request)
func HandleGetStackDefinitions ¶ added in v0.24.0
func HandleGetStackDefinitions(w http.ResponseWriter, r *http.Request)
func HandleGetTemplate ¶
func HandleGetTemplate(w http.ResponseWriter, r *http.Request)
func HandleGetTemplateNodes ¶ added in v0.22.0
func HandleGetTemplateNodes(w http.ResponseWriter, r *http.Request)
func HandleGetTemplateVar ¶
func HandleGetTemplateVar(w http.ResponseWriter, r *http.Request)
func HandleGetTemplateVars ¶
func HandleGetTemplateVars(w http.ResponseWriter, r *http.Request)
func HandleGetTemplates ¶
func HandleGetTemplates(w http.ResponseWriter, r *http.Request)
func HandleGetTokens ¶
func HandleGetTokens(w http.ResponseWriter, r *http.Request)
func HandleGetTunnelServerInfo ¶
func HandleGetTunnelServerInfo(w http.ResponseWriter, r *http.Request)
func HandleGetTunnels ¶
func HandleGetTunnels(w http.ResponseWriter, r *http.Request)
func HandleGetUser ¶
func HandleGetUser(w http.ResponseWriter, r *http.Request)
func HandleGetUserHasPermission ¶ added in v0.23.0
func HandleGetUserHasPermission(w http.ResponseWriter, r *http.Request)
func HandleGetUserPermissions ¶ added in v0.23.0
func HandleGetUserPermissions(w http.ResponseWriter, r *http.Request)
func HandleGetUserQuota ¶
func HandleGetUserQuota(w http.ResponseWriter, r *http.Request)
func HandleGetUsers ¶
func HandleGetUsers(w http.ResponseWriter, r *http.Request)
func HandleGetVolume ¶
func HandleGetVolume(w http.ResponseWriter, r *http.Request)
func HandleGetVolumeNodes ¶ added in v0.23.6
func HandleGetVolumeNodes(w http.ResponseWriter, r *http.Request)
func HandleGetVolumes ¶
func HandleGetVolumes(w http.ResponseWriter, r *http.Request)
func HandleGrep ¶ added in v0.30.0
func HandleGrep(w http.ResponseWriter, r *http.Request)
HandleGrep searches file contents in a space.
func HandleImportTemplate ¶ added in v0.32.0
func HandleImportTemplate(w http.ResponseWriter, r *http.Request)
HandleImportTemplate accepts a portable YAML template export, resolves script names to IDs, and creates the template via the existing create path.
func HandleListMCPServerTools ¶ added in v0.29.0
func HandleListMCPServerTools(w http.ResponseWriter, r *http.Request)
func HandleLogout ¶
func HandleLogout(w http.ResponseWriter, r *http.Request)
func HandlePing ¶
func HandlePing(w http.ResponseWriter, r *http.Request)
func HandlePoolStart ¶ added in v0.28.0
func HandlePoolStart(w http.ResponseWriter, r *http.Request)
func HandlePoolStop ¶ added in v0.28.0
func HandlePoolStop(w http.ResponseWriter, r *http.Request)
func HandleReadSpaceFile ¶ added in v0.23.0
func HandleReadSpaceFile(w http.ResponseWriter, r *http.Request)
func HandleRefreshBaseImages ¶ added in v0.32.0
func HandleRefreshBaseImages(w http.ResponseWriter, r *http.Request)
HandleRefreshBaseImages forces an immediate fetch of the base image manifest. It uses the same FetchDecision as the startup path: it fetches iff --base-images-update-enabled is on and (no manifest file is set, or a manifest file is set AND an explicit --base-images-update-url is given). The fetched copy overlays the baseline only when its manifest_version is newer. Exposed via the `knot admin refresh-base-images` CLI command.
func HandleRunCommand ¶ added in v0.23.0
func HandleRunCommand(w http.ResponseWriter, r *http.Request)
func HandleSSE ¶ added in v0.21.8
func HandleSSE(w http.ResponseWriter, r *http.Request)
HandleSSE handles Server-Sent Events connections for real-time updates
func HandleSearch ¶ added in v0.32.0
func HandleSearch(w http.ResponseWriter, r *http.Request)
HandleSearch performs a permission-, ownership- and zone-scoped keyword search across the entity types the current user may see. Matching is a case-insensitive substring match on each entity's primary name. Each result group is capped at searchLimitPerType entries; empty groups are omitted.
Scoping mirrors the sidebar visibility gates:
- spaces are the current user's own plus any shared with them;
- admin entities (templates, variables, volumes, users, groups, roles, stacks, event sinks) appear only when the user holds the manage permission for that type;
- personal entities (scripts, skills, slash commands, MCP servers, tokens) are scoped to the user's own (plus global ones where the list endpoint exposes them);
- leaf nodes get the same reduced set as the sidebar (no users/groups/roles).
func HandleSearchSkills ¶ added in v0.23.0
func HandleSearchSkills(w http.ResponseWriter, r *http.Request)
func HandleSed ¶ added in v0.30.0
func HandleSed(w http.ResponseWriter, r *http.Request)
HandleSed performs in-place edits or capture extraction in a space.
func HandleSetPoolSize ¶ added in v0.28.0
func HandleSetPoolSize(w http.ResponseWriter, r *http.Request)
func HandleSetSpaceCustomField ¶ added in v0.21.5
func HandleSetSpaceCustomField(w http.ResponseWriter, r *http.Request)
func HandleSpaceAddShare ¶
func HandleSpaceAddShare(w http.ResponseWriter, r *http.Request)
func HandleSpaceRemoveShare ¶
func HandleSpaceRemoveShare(w http.ResponseWriter, r *http.Request)
func HandleSpaceRestart ¶
func HandleSpaceRestart(w http.ResponseWriter, r *http.Request)
func HandleSpaceStart ¶
func HandleSpaceStart(w http.ResponseWriter, r *http.Request)
func HandleSpaceStop ¶
func HandleSpaceStop(w http.ResponseWriter, r *http.Request)
func HandleSpaceStopUsersSpaces ¶
func HandleSpaceStopUsersSpaces(w http.ResponseWriter, r *http.Request)
func HandleSpaceTransfer ¶
func HandleSpaceTransfer(w http.ResponseWriter, r *http.Request)
func HandleSpecBuild ¶ added in v0.32.0
func HandleSpecBuild(w http.ResponseWriter, r *http.Request)
HandleSpecBuild converts a unified spec back into native text. On the Nomad side this patches the wizard's fields into the original HCL; on the container side it regenerates from the spec. See BuildNomadHCL / BuildContainerYAML for the per-platform behaviour.
func HandleSpecParse ¶ added in v0.32.0
func HandleSpecParse(w http.ResponseWriter, r *http.Request)
HandleSpecParse converts a native template spec into the unified JSON the wizard edits. Returns wizardable=false if the spec is too complex for the wizard (multi-task Nomad job, unparseable HCL, unsupported driver, etc.); the UI uses that flag to disable the wizard button.
func HandleStackDelete ¶ added in v0.26.2
func HandleStackDelete(w http.ResponseWriter, r *http.Request)
func HandleStackExists ¶ added in v0.30.1
func HandleStackExists(w http.ResponseWriter, r *http.Request)
HandleStackExists reports whether a stack name is already in use for the requesting user (i.e. there is at least one non-deleted space with that Stack). Used by the create-stack flows to refuse reusing an existing stack name, which would otherwise mix spaces from different stack instances.
func HandleStackRestart ¶ added in v0.24.0
func HandleStackRestart(w http.ResponseWriter, r *http.Request)
func HandleStackStart ¶ added in v0.24.0
func HandleStackStart(w http.ResponseWriter, r *http.Request)
func HandleStackStop ¶ added in v0.24.0
func HandleStackStop(w http.ResponseWriter, r *http.Request)
func HandleToggleMCPServerTool ¶ added in v0.29.0
func HandleToggleMCPServerTool(w http.ResponseWriter, r *http.Request)
func HandleUpdateCommand ¶ added in v0.29.0
func HandleUpdateCommand(w http.ResponseWriter, r *http.Request)
func HandleUpdateEventSink ¶ added in v0.28.0
func HandleUpdateEventSink(w http.ResponseWriter, r *http.Request)
func HandleUpdateGroup ¶
func HandleUpdateGroup(w http.ResponseWriter, r *http.Request)
func HandleUpdateMCPServer ¶ added in v0.29.0
func HandleUpdateMCPServer(w http.ResponseWriter, r *http.Request)
func HandleUpdateOwnNavPreferences ¶ added in v0.32.0
func HandleUpdateOwnNavPreferences(w http.ResponseWriter, r *http.Request)
HandleUpdateOwnNavPreferences replaces the current user's pinned sidebar ordering. URLs are validated against apiclient.ValidNavURLs and de-duplicated (preserving order); an empty slice clears the preference, returning the sidebar to its default layout. The canonical stored order is returned.
func HandleUpdateOwnSSHPrivateKey ¶ added in v0.25.0
func HandleUpdateOwnSSHPrivateKey(w http.ResponseWriter, r *http.Request)
func HandleUpdateOwnSSHPublicKey ¶ added in v0.25.0
func HandleUpdateOwnSSHPublicKey(w http.ResponseWriter, r *http.Request)
func HandleUpdatePool ¶ added in v0.28.0
func HandleUpdatePool(w http.ResponseWriter, r *http.Request)
func HandleUpdateRole ¶
func HandleUpdateRole(w http.ResponseWriter, r *http.Request)
func HandleUpdateScript ¶ added in v0.23.0
func HandleUpdateScript(w http.ResponseWriter, r *http.Request)
func HandleUpdateSkill ¶ added in v0.23.0
func HandleUpdateSkill(w http.ResponseWriter, r *http.Request)
func HandleUpdateSpace ¶
func HandleUpdateSpace(w http.ResponseWriter, r *http.Request)
func HandleUpdateSpaceJobs ¶ added in v0.33.0
func HandleUpdateSpaceJobs(w http.ResponseWriter, r *http.Request)
HandleUpdateSpaceJobs replaces the space's job definitions and runner state, then pushes the change to the agent when the space is running.
func HandleUpdateStackDefinition ¶ added in v0.24.0
func HandleUpdateStackDefinition(w http.ResponseWriter, r *http.Request)
func HandleUpdateTemplate ¶
func HandleUpdateTemplate(w http.ResponseWriter, r *http.Request)
func HandleUpdateTemplateVar ¶
func HandleUpdateTemplateVar(w http.ResponseWriter, r *http.Request)
func HandleUpdateToken ¶ added in v0.28.0
func HandleUpdateToken(w http.ResponseWriter, r *http.Request)
HandleUpdateToken allows changing a token's name and/or scopes without recreating it (the token ID stays the same, so callers don't need to re-credential).
func HandleUpdateUser ¶
func HandleUpdateUser(w http.ResponseWriter, r *http.Request)
func HandleUpdateVolume ¶
func HandleUpdateVolume(w http.ResponseWriter, r *http.Request)
func HandleUsingTotp ¶
func HandleUsingTotp(w http.ResponseWriter, r *http.Request)
Returns if the server is using TOTP or not, the CLI client uses this to work out the authentication flow it should use.
func HandleValidateStackDefinition ¶ added in v0.24.0
func HandleValidateStackDefinition(w http.ResponseWriter, r *http.Request)
func HandleValidateTemplate ¶ added in v0.24.0
func HandleValidateTemplate(w http.ResponseWriter, r *http.Request)
func HandleValidateVolume ¶ added in v0.24.0
func HandleValidateVolume(w http.ResponseWriter, r *http.Request)
func HandleVolumeStart ¶
func HandleVolumeStart(w http.ResponseWriter, r *http.Request)
func HandleVolumeStop ¶
func HandleVolumeStop(w http.ResponseWriter, r *http.Request)
func HandleWhoAmI ¶
func HandleWhoAmI(w http.ResponseWriter, r *http.Request)
func HandleWriteSpaceFile ¶ added in v0.23.0
func HandleWriteSpaceFile(w http.ResponseWriter, r *http.Request)
Types ¶
type AvailableNode ¶ added in v0.22.0
type ErrorResponse ¶
type ErrorResponse struct {
Error string `json:"error" msgpack:"error"`
}
type JobsErrorResponse ¶ added in v0.33.0
type JobsErrorResponse struct {
Error string `json:"error"`
JobErrors map[string]string `json:"job_errors,omitempty"`
}
JobsErrorResponse is the 400 body from the jobs update endpoint: JobErrors maps each invalid job name to its validation error.
type MethodListResponse ¶ added in v0.28.0
type MethodListResponse struct {
Count int `json:"count" msgpack:"count"`
Methods []methods.MethodInfo `json:"methods" msgpack:"methods"`
}
type ReadFileRequest ¶ added in v0.23.0
type ReadFileRequest struct {
Path string `json:"path" msgpack:"path"`
Offset int `json:"offset,omitempty" msgpack:"offset,omitempty"` // 1-based line number to start at (0/absent = from beginning)
Limit int `json:"limit,omitempty" msgpack:"limit,omitempty"` // max lines to return (0/absent = no limit)
}
type ReadFileResponse ¶ added in v0.23.0
type ReadFileResponse struct {
Success bool `json:"success" msgpack:"success"`
Content string `json:"content,omitempty" msgpack:"content,omitempty"`
Size int `json:"size,omitempty" msgpack:"size,omitempty"`
TotalLines int `json:"total_lines,omitempty" msgpack:"total_lines,omitempty"` // total lines in the file (only when offset/limit used)
Offset int `json:"offset,omitempty" msgpack:"offset,omitempty"` // applied offset (1-based, only when offset/limit used)
Limit int `json:"limit,omitempty" msgpack:"limit,omitempty"` // applied limit (only when offset/limit used)
Error string `json:"error,omitempty" msgpack:"error,omitempty"`
}
type RunCommandRequest ¶ added in v0.23.0
type RunCommandResponse ¶ added in v0.23.0
type UnifiedScriptExecuteRequest ¶ added in v0.23.0
type UnifiedScriptExecuteRequest struct {
ScriptId string `json:"script_id,omitempty" msgpack:"script_id,omitempty"`
ScriptName string `json:"script_name,omitempty" msgpack:"script_name,omitempty"`
Content string `json:"content,omitempty" msgpack:"content,omitempty"`
Arguments []string `json:"arguments" msgpack:"arguments"`
}
type WriteFileRequest ¶ added in v0.23.0
type WriteFileRequest struct {
Path string `json:"path" msgpack:"path"`
Content string `json:"content" msgpack:"content"`
Mode string `json:"mode,omitempty" msgpack:"mode,omitempty"`
// SymlinkTarget, when set, creates a symlink at Path pointing to this
// target instead of writing content. Used by knot mirror for symlinks.
SymlinkTarget string `json:"symlink_target,omitempty" msgpack:"symlink_target,omitempty"`
// Sync metadata (optional). When set, the agent applies them after the
// write so the destination file matches the source's mtime and permission
// bits — used by knot sync tools (copy --recursive, watch).
MtimeNs int64 `json:"mtime_ns,omitempty" msgpack:"mtime_ns,omitempty"`
FilePerm uint32 `json:"file_perm,omitempty" msgpack:"file_perm,omitempty"`
}
type WriteFileResponse ¶ added in v0.23.0
Source Files
¶
- auditlogs.go
- auth.go
- clusterinfo.go
- commands.go
- error-response.go
- event_sinks.go
- groups.go
- icons.go
- mcpservers.go
- methods.go
- permissions.go
- ping.go
- pools.go
- roles.go
- routes.go
- scripts.go
- scripts_execution.go
- scripts_stream.go
- search.go
- server_info.go
- sessions.go
- skills.go
- space_file_ops.go
- space_files.go
- space_jobs.go
- space_run_command.go
- space_usage.go
- spaces.go
- specwizard.go
- sse.go
- stack_definitions.go
- template_export.go
- template_nodes.go
- templates.go
- templatevars.go
- tokens.go
- tunnels.go
- users.go
- volumes.go