whiteboard

package
v1.0.63 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 3, 2026 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package whiteboard owns the framework-independent routing contract shared by the native whiteboard commands and their strict Shortcut counterparts.

Index

Constants

View Source
const (
	ServerID = "whiteboard"

	EmbeddedQueryTool  = "read_whiteboard_content"
	EmbeddedUpdateTool = "update_whiteboard"

	StandaloneCreateTool      = "create_whiteboard"
	StandaloneQueryTool       = "get_whiteboard_detail"
	StandaloneUpdateTool      = "update_whiteboard_content"
	StandaloneExportTool      = "export_whiteboard"
	StandaloneExportQueryTool = "query_export_job"
)
View Source
const (
	TemplateType = 9

	PersonalTemplateSaveTool   = "save_personal_whiteboard_tpl"
	PersonalTemplateListTool   = "list_personal_whiteboard_tpls"
	PersonalTemplateCreateTool = "apply_personal_whiteboard_tpl"
	TeamTemplateSaveTool       = "save_team_whiteboard_tpl"
	TeamTemplateListTool       = "list_team_whiteboard_tpls"
	TeamTemplateCreateTool     = "apply_team_whiteboard_tpl"
	PublicTemplateListTool     = "list_public_whiteboard_tpls"
	PublicTemplateCreateTool   = "apply_public_whiteboard_tpl"
)

Variables

This section is empty.

Functions

func ValidateCreateRequestID

func ValidateCreateRequestID(value string) error

ValidateCreateRequestID enforces the idempotency-key contract shared by standalone create and update.

func ValidateTemplateCursor added in v1.0.63

func ValidateTemplateCursor(value string) error

func ValidateTemplateMaxPages added in v1.0.63

func ValidateTemplateMaxPages(value int) error

func ValidateTemplatePageSize added in v1.0.63

func ValidateTemplatePageSize(value int) error

func ValidateTemplatePreviewCall added in v1.0.63

func ValidateTemplatePreviewCall(server, tool string, args map[string]any) error

ValidateTemplatePreviewCall bounds the remote preflight exception to five reviewed tools and an explicit boolean true; strings and missing flags fail.

func ValidateTemplateRequestID added in v1.0.63

func ValidateTemplateRequestID(value string) error

Types

type Call

type Call struct {
	Kind Kind
	Tool string
	Args map[string]any
}

Call is one resolved MCP invocation.

func BuildQueryCall

func BuildQueryCall(options QueryOptions) (Call, error)

BuildQueryCall validates branch-specific flags and returns the only tool that may be invoked. Callers must not fall back to the sibling tool on failure.

func BuildUpdateCall

func BuildUpdateCall(options UpdateOptions) (Call, error)

BuildUpdateCall applies the same compatibility split to writes. The caller supplies already-validated OpenNodes mode/nodes so both command surfaces keep one routing and conditional-parameter contract.

type Kind

type Kind string

Kind identifies the target model selected before the first remote call.

const (
	KindEmbedded   Kind = "embedded"
	KindStandalone Kind = "standalone"
)

func ResolveKind

func ResolveKind(target Target) (Kind, error)

ResolveKind implements the public compatibility rule: only an explicitly provided, non-empty part id selects the embedded path. Omission selects the standalone path; explicit empty input fails closed.

type QueryOptions

type QueryOptions struct {
	Target
	View          string
	ViewChanged   bool
	PageID        string
	PageIDChanged bool
}

type Target

type Target struct {
	NodeID        string
	PartID        string
	PartIDChanged bool
}

Target preserves flag presence separately from its value. An explicitly empty --part-id is invalid and must never be reinterpreted as standalone.

type TemplateScope added in v1.0.63

type TemplateScope string
const (
	TemplateScopePersonal TemplateScope = "personal"
	TemplateScopeTeam     TemplateScope = "team"
	TemplateScopePublic   TemplateScope = "public"
)

type UpdateOptions

type UpdateOptions struct {
	Target
	PageID                  string
	PageIDChanged           bool
	ExpectedRevision        int
	ExpectedRevisionChanged bool
	RequestID               string
	RequestIDChanged        bool
	Mode                    string
	NodesJSON               string
}

Directories

Path Synopsis
Package opennodes owns the local, side-effect-free OpenNodes V1 source representation shared by create guards and visual preview renderers.
Package opennodes owns the local, side-effect-free OpenNodes V1 source representation shared by create guards and visual preview renderers.
Package render implements a deterministic, network-free semantic SVG preview for DWS OpenNodes V1.
Package render implements a deterministic, network-free semantic SVG preview for DWS OpenNodes V1.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL