internal/

directory
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

Directories

Path Synopsis
Package aitableprotocol contains small, stable validations shared by the native AI Table commands and their shortcut adapters.
Package aitableprotocol contains small, stable validations shared by the native AI Table commands and their shortcut adapters.
Package apiclient provides a lightweight HTTP client for calling DingTalk OpenAPI (https://api.dingtalk.com) directly, bypassing the MCP JSON-RPC transport.
Package apiclient provides a lightweight HTTP client for calling DingTalk OpenAPI (https://api.dingtalk.com) directly, bypassing the MCP JSON-RPC transport.
This file holds deliberate no-op stubs that act as edition-sync anchors for the private wukong edition overlay.
This file holds deliberate no-op stubs that act as edition-sync anchors for the private wukong edition overlay.
Package atomicfile 提供不依赖命令层的安全原子文件写入。
Package atomicfile 提供不依赖命令层的安全原子文件写入。
agent_code_detect.go resolves the agent_code — which agent HOST is driving dws (claudecode / qoder / cursor / vscode / openclaw / hermes / ...).
agent_code_detect.go resolves the agent_code — which agent HOST is driving dws (claudecode / qoder / cursor / vscode / openclaw / hermes / ...).
Package buildversion owns the shared public version text, without build-state discovery, command construction or filesystem access.
Package buildversion owns the shared public version text, without build-state discovery, command construction or filesystem access.
card
cli
homology
Package homology holds Schema/CLI homology and ContractFinal consistency gates that exercise the live command tree and delivered Catalog.
Package homology holds Schema/CLI homology and ContractFinal consistency gates that exercise the live command tree and delivered Catalog.
schemacachepb
Package schemacachepb contains the private generated Schema cache DTO.
Package schemacachepb contains the private generated Schema cache DTO.
Package clisignal shares process interruption semantics between CLI entrypoints.
Package clisignal shares process interruption semantics between CLI entrypoints.
Package clitelemetry owns the reviewed CLI tracking configuration and privacy projection.
Package clitelemetry owns the reviewed CLI tracking configuration and privacy projection.
Package cobracmd provides shared Cobra command utilities used across multiple internal packages (app, cli, compat, helpers).
Package cobracmd provides shared Cobra command utilities used across multiple internal packages (app, cli, compat, helpers).
Package commentreaction validates the reviewed DingTalk names accepted by comment emoji replies.
Package commentreaction validates the reviewed DingTalk names accepted by comment emoji replies.
Package corecmd is the shared, dispatch-agnostic base for building commands.
Package corecmd is the shared, dispatch-agnostic base for building commands.
commandstore
Package commandstore ties framework metadata to the lifetime of a live Cobra command without keeping discarded command trees alive.
Package commandstore ties framework metadata to the lifetime of a live Cobra command without keeping discarded command trees alive.
contract
Package contract owns command-framework declaration DTOs and the ProductDecl registry.
Package contract owns command-framework declaration DTOs and the ProductDecl registry.
contractfinal
Package contractfinal owns the Cobra-keyed ContractFinal runtime store and the annotate+store registration seam.
Package contractfinal owns the Cobra-keyed ContractFinal runtime store and the annotate+store registration seam.
runtimeannotate
Package runtimeannotate owns Cobra dws.schema.* annotation writers and the RuntimeSchemaConstraints helpers used by the command framework.
Package runtimeannotate owns Cobra dws.schema.* annotation writers and the RuntimeSchemaConstraints helpers used by the command framework.
Package event implements the DingTalk Stream event subscription pipeline for dws.
Package event implements the DingTalk Stream event subscription pipeline for dws.
bus
Package bus implements the daemon side of the dws event subsystem: one long-lived process per ClientID that holds the single cloud connection and fans out events to N local consumers over IPC.
Package bus implements the daemon side of the dws event subsystem: one long-lived process per ClientID that holds the single cloud connection and fans out events to N local consumers over IPC.
busctl
Package busctl glues the consume client to the bus daemon.
Package busctl glues the consume client to the bus daemon.
consume
Package consume implements the consumer-side process of `dws event consume`: dial the bus, send Hello, read Event frames, format them, and write them out (stdout / file / dir).
Package consume implements the consumer-side process of `dws event consume`: dial the bus, send Hello, read Event frames, format them, and write them out (stdout / file / dir).
dedup
Package dedup implements a fixed-capacity LRU set used by the bus to suppress duplicate events that the DingTalk Stream SDK redelivers on reconnect (see plan invariant #2).
Package dedup implements a fixed-capacity LRU set used by the bus to suppress duplicate events that the DingTalk Stream SDK redelivers on reconnect (see plan invariant #2).
lock
Package lock implements a cross-platform exclusive file lock primitive used by the bus daemon to enforce the "single bus per ClientID" invariant (plan invariant #3).
Package lock implements a cross-platform exclusive file lock primitive used by the bus daemon to enforce the "single bus per ClientID" invariant (plan invariant #3).
process
Package process provides cross-platform process-existence checks.
Package process provides cross-platform process-existence checks.
registry
Package registry holds two cross-cutting reference data sets used by daemon, consume, and the cobra command layer:
Package registry holds two cross-cutting reference data sets used by daemon, consume, and the cobra command layer:
runtimecred
Package runtimecred provides an in-memory credential broker for event bus processes.
Package runtimecred provides an in-memory credential broker for event bus processes.
source
Package source wraps the open-dingtalk Stream SDK and exposes a small blocking Start interface plus a connection state machine.
Package source wraps the open-dingtalk Stream SDK and exposes a small blocking Start interface plus a connection state machine.
transport
Package transport implements the cross-platform local IPC between the bus daemon and consume clients.
Package transport implements the cross-platform local IPC between the bus daemon and consume clients.
generator
cmd_command_path_fallbacks command
Command cmd_command_path_fallbacks validates the reviewed recovery-only command path table against the live distribution Cobra tree and writes the deterministic runtime lookup source.
Command cmd_command_path_fallbacks validates the reviewed recovery-only command path table against the live distribution Cobra tree and writes the deterministic runtime lookup source.
cmd_param_aliases command
Command cmd_param_aliases reduces the reviewed parameter concept dictionary (internal/cli/param_concepts.json) against the live Cobra command tree and writes the deterministic per-command alias table to internal/cli/param_aliases_generated.go.
Command cmd_param_aliases reduces the reviewed parameter concept dictionary (internal/cli/param_concepts.json) against the live Cobra command tree and writes the deterministic per-command alias table to internal/cli/param_aliases_generated.go.
cmd_schema_registry_smoke command
Command cmd_schema_registry_smoke emits the complete public binary-smoke vector from EffectiveCommandRegistry.
Command cmd_schema_registry_smoke emits the complete public binary-smoke vector from EffectiveCommandRegistry.
outputguard
Package outputguard prevents generators from overwriting reviewed or generated inputs that participate in the same one-way build graph.
Package outputguard prevents generators from overwriting reviewed or generated inputs that participate in the same one-way build graph.
doc
Package i18n provides lightweight internationalization for the DWS CLI.
Package i18n provides lightweight internationalization for the DWS CLI.
Package interfacesnapshot captures and compares the public Cobra command surface without executing commands or contacting runtime services.
Package interfacesnapshot captures and compares the public Cobra command surface without executing commands or contacting runtime services.
Package keychain provides cross-platform secure storage for secrets.
Package keychain provides cross-platform secure storage for secrets.
Package localio owns safe local artifact publication shared by product shortcuts.
Package localio owns safe local artifact publication shared by product shortcuts.
Package logging provides file-based structured logging for diagnostics.
Package logging provides file-based structured logging for diagnostics.
Package mcpschema owns the bounded, fail-closed contract for validating arguments against remotely discovered MCP input schemas.
Package mcpschema owns the bounded, fail-closed contract for validating arguments against remotely discovered MCP input schemas.
Package msgcrypto wraps the third-party SafeChat SDK so DWS can decrypt DingTalk messages that an organization has encrypted with its own key material, and encrypt outbound ones.
Package msgcrypto wraps the third-party SafeChat SDK so DWS can decrypt DingTalk messages that an organization has encrypted with its own key material, and encrypt outbound ones.
Package pat implements the "dws pat" command group for PAT (Personal Action Token) authorization management.
Package pat implements the "dws pat" command group for PAT (Personal Action Token) authorization management.
Package plugin implements the DWS CLI plugin system.
Package plugin implements the DWS CLI plugin system.
Package profilectx owns the process-local profile selector without importing authentication or transport packages.
Package profilectx owns the process-local profile selector without importing authentication or transport packages.
Package profilemetadata owns non-sensitive profile data and pure selector rules.
Package profilemetadata owns non-sensitive profile data and pure selector rules.
Package publishedmcp owns runtime protocol access to published MCP servers.
Package publishedmcp owns runtime protocol access to published MCP servers.
Package requestmeta owns DWS request metadata header names.
Package requestmeta owns DWS request metadata header names.
Package runtimecontext supplies an optional, process-scoped request context.
Package runtimecontext supplies an optional, process-scoped request context.
Package runtimepayload implements the self-contained runtime payload format.
Package runtimepayload implements the self-contained runtime payload format.
Package schemareader composes authenticated cache I/O with the shared typed Schema decoder.
Package schemareader composes authenticated cache I/O with the shared typed Schema decoder.
Package shortcut provides a declarative framework for high-fidelity CLI commands (shortcuts) on top of the DingTalk MCP runtime.
Package shortcut provides a declarative framework for high-fidelity CLI commands (shortcuts) on top of the DingTalk MCP runtime.
agoal
Package agoal declares reviewed shortcuts for DingTalk Agoal.
Package agoal declares reviewed shortcuts for DingTalk Agoal.
aisearch
Package aisearch implements strict, task-oriented Shortcut projections over DingTalk's enterprise search APIs.
Package aisearch implements strict, task-oriented Shortcut projections over DingTalk's enterprise search APIs.
aitable
Package aitable provides declarative shortcuts for the DingTalk AI 表格 (aitable) service: Base / table / field / record / view / form / dashboard / chart / workflow / advanced-permission / section management.
Package aitable provides declarative shortcuts for the DingTalk AI 表格 (aitable) service: Base / table / field / record / view / form / dashboard / chart / workflow / advanced-permission / section management.
aitabletarget
Package aitabletarget provides deterministic AI Table URL and name resolution shared by read and write shortcuts.
Package aitabletarget provides deterministic AI Table URL and name resolution shared by read and write shortcuts.
attendance
Package attendance provides declarative shortcuts for the DingTalk attendance (考勤) service: attendance records, check results/records, approvals, shifts, schedules, class/group/rule management, statistics, settings, reports and vacation.
Package attendance provides declarative shortcuts for the DingTalk attendance (考勤) service: attendance records, check results/records, approvals, shifts, schedules, class/group/rule management, statistics, settings, reports and vacation.
builtin
Package builtin aggregates all built-in shortcut service packages via blank imports so their init() registrations run, applies the reviewed semantic and public-catalog decorations in the core registry, then re-exports the compiled cobra commands.
Package builtin aggregates all built-in shortcut service packages via blank imports so their init() registrations run, applies the reviewed semantic and public-catalog decorations in the core registry, then re-exports the compiled cobra commands.
calendar
Package calendar declares the declarative shortcut (+command) layer for the DingTalk calendar MCP product.
Package calendar declares the declarative shortcut (+command) layer for the DingTalk calendar MCP product.
calendarcompat
Package calendarcompat contains narrow compatibility adapters for observed Calendar wire shapes shared by the calendar and smart Shortcut packages.
Package calendarcompat contains narrow compatibility adapters for observed Calendar wire shapes shared by the calendar and smart Shortcut packages.
chat
Package chat provides declarative shortcuts for the DingTalk chat service (群聊 / 会话 / 消息 / 机器人).
Package chat provides declarative shortcuts for the DingTalk chat service (群聊 / 会话 / 消息 / 机器人).
chatmsg
Package chatmsg holds the shared, read-only projection helpers for DingTalk message-list responses (list_individual_chat_message, list_conversation_message_v2, search_at_me_message, search_messages_by_keyword, list_topic_replies, …).
Package chatmsg holds the shared, read-only projection helpers for DingTalk message-list responses (list_individual_chat_message, list_conversation_message_v2, search_at_me_message, search_messages_by_keyword, list_topic_replies, …).
contact
Package contact provides declarative shortcuts for the DingTalk contact (通讯录) service: user / department / role / relation queries and the HR roster (花名册) lookups.
Package contact provides declarative shortcuts for the DingTalk contact (通讯录) service: user / department / role / relation queries and the HR roster (花名册) lookups.
devapp
Package devapp declares high-fidelity shortcuts for the DingTalk open-platform developer application ("devapp") MCP service, for the apps command surface.
Package devapp declares high-fidelity shortcuts for the DingTalk open-platform developer application ("devapp") MCP service, for the apps command surface.
devdoc
Package devdoc registers strict Shortcut adapters for DingTalk Open Platform documentation discovery.
Package devdoc registers strict Shortcut adapters for DingTalk Open Platform documentation discovery.
ding
Package ding registers strict declarative shortcuts for DingTalk DING.
Package ding registers strict declarative shortcuts for DingTalk DING.
doc
docresolver
Package docresolver resolves document IDs, URLs, and natural titles to one typed document target before a shortcut performs a business operation.
Package docresolver resolves document IDs, URLs, and natural titles to one typed document target before a shortcut performs a business operation.
drive
Package drive declares high-fidelity shortcuts for the DingTalk drive (钉盘) service: file/folder listing, metadata, download link, folder creation, upload credentials, search, recycle bin, internet publish and the document space proxy operations (copy/move/rename/permission/recent).
Package drive declares high-fidelity shortcuts for the DingTalk drive (钉盘) service: file/folder listing, metadata, download link, folder creation, upload credentials, search, recycle bin, internet publish and the document space proxy operations (copy/move/rename/permission/recent).
hrbrain
Package hrbrain registers fail-closed Shortcut adapters for DingTalk Organization Brain reads.
Package hrbrain registers fail-closed Shortcut adapters for DingTalk Organization Brain reads.
live
Package live defines strict task-oriented Shortcut candidates for DingTalk live broadcasts.
Package live defines strict task-oriented Shortcut candidates for DingTalk live broadcasts.
mail
Package mail provides declarative shortcuts for the DingTalk mail (邮箱) service: mailbox / message / draft / thread / folder / tag / user / attachment / template / contact / auto-reply / rule operations.
Package mail provides declarative shortcuts for the DingTalk mail (邮箱) service: mailbox / message / draft / thread / folder / tag / user / attachment / template / contact / auto-reply / rule operations.
minutes
Package minutes contains declarative shortcuts for DingTalk AI 听记 (minutes).
Package minutes contains declarative shortcuts for DingTalk AI 听记 (minutes).
minutesdata
Package minutesdata owns response validation and pagination facts shared by Minutes shortcuts.
Package minutesdata owns response validation and pagination facts shared by Minutes shortcuts.
oa
Package oa registers strict declarative shortcuts for DingTalk OA approval.
Package oa registers strict declarative shortcuts for DingTalk OA approval.
pat
Package pat registers safe Shortcut routing for PAT authorization tasks.
Package pat registers safe Shortcut routing for PAT authorization tasks.
report
Package report registers strict declarative shortcuts for DingTalk reports.
Package report registers strict declarative shortcuts for DingTalk reports.
responsecheck
Package responsecheck contains fail-closed response validators shared by built-in shortcuts.
Package responsecheck contains fail-closed response validators shared by built-in shortcuts.
sheet
Package sheet declares high-fidelity shortcuts for the DingTalk sheet MCP product.
Package sheet declares high-fidelity shortcuts for the DingTalk sheet MCP product.
smart
Package smart holds genuine multi-step / intelligent shortcuts — commands that orchestrate several MCP calls or resolve names to IDs, so they are NOT a 1:1 wrapper over a single tool.
Package smart holds genuine multi-step / intelligent shortcuts — commands that orchestrate several MCP calls or resolve names to IDs, so they are NOT a 1:1 wrapper over a single tool.
targetresolver
Package targetresolver provides deterministic natural-target resolution for shortcuts.
Package targetresolver provides deterministic natural-target resolution for shortcuts.
todo
Package todo declares high-fidelity shortcuts for the DingTalk "todo" (personal todo) MCP service.
Package todo declares high-fidelity shortcuts for the DingTalk "todo" (personal todo) MCP service.
usage
Package usage records the SHAPE of MCP tool calls (which product/tool, which argument keys, and a redacted sample of ID/enum-like values) so that the shortcut layer can later mine high-frequency patterns and suggest distilling them into custom shortcuts (see docs/shortcut-p2-design.md).
Package usage records the SHAPE of MCP tool calls (which product/tool, which argument keys, and a redacted sample of ID/enum-like values) so that the shortcut layer can later mine high-frequency patterns and suggest distilling them into custom shortcuts (see docs/shortcut-p2-design.md).
userdef
Package userdef loads user-defined shortcuts from ~/.dws/shortcuts/*.yaml and compiles them into the same shortcut.Shortcut model as the built-ins, so a distilled high-frequency operation behaves exactly like a native `+command`.
Package userdef loads user-defined shortcuts from ~/.dws/shortcuts/*.yaml and compiles them into the same shortcut.Shortcut model as the built-ins, so a distilled high-frequency operation behaves exactly like a native `+command`.
whiteboard
Package whiteboard declares strict Shortcut adapters for DingTalk document whiteboards.
Package whiteboard declares strict Shortcut adapters for DingTalk document whiteboards.
wiki
Package wiki declares reviewed, truth-preserving shortcuts for Wiki spaces, members, nodes, and activity feeds.
Package wiki declares reviewed, truth-preserving shortcuts for Wiki spaces, members, nodes, and activity feeds.
Package skillpaths owns the ordered agent-relative install footprint shared by core setup/compatibility warnings and the thin startup eligibility check.
Package skillpaths owns the ordered agent-relative install footprint shared by core setup/compatibility warnings and the thin startup eligibility check.
Package skillprovenance builds the per-Skill provenance records stored in the single ~/.dws/skills-state.json metadata file.
Package skillprovenance builds the per-Skill provenance records stored in the single ~/.dws/skills-state.json metadata file.
Package skillstate persists the official Skill snapshot and centralized ownership metadata written after setup and upgrade.
Package skillstate persists the official Skill snapshot and centralized ownership metadata written after setup and upgrade.
Package syncdata holds the wukong product registry, synced from dws-wukong.
Package syncdata holds the wukong product registry, synced from dws-wukong.
Package telemetry hands completed CLI events to a short-lived sender process.
Package telemetry hands completed CLI events to a short-lived sender process.
Package testseam turns the package-var injection-seam swap into a mechanism instead of a convention.
Package testseam turns the package-var injection-seam swap into a mechanism instead of a convention.
Package upgrade provides self-update functionality for the DWS CLI using GitHub Releases as the data source.
Package upgrade provides self-update functionality for the DWS CLI using GitHub Releases as the data source.
Package wait is the framework terminal-state wait engine behind the reviewed contract.WaitSpec capability.
Package wait is the framework terminal-state wait engine behind the reviewed contract.WaitSpec capability.
Package whiteboard owns the framework-independent routing contract shared by the native whiteboard commands and their strict Shortcut counterparts.
Package whiteboard owns the framework-independent routing contract shared by the native whiteboard commands and their strict Shortcut counterparts.
opennodes
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.
render
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