CLI commands
ak content
Publish content to channels
ak content
Publish content to channels
Synopsis
What it does: Publish posts to external channels via pluggable channel adapters. The Discord webhook adapter is implemented; Twitter, LinkedIn, and RSS adapters are not implemented.
Who it's for: Both: power devs (--json --no-interactive --dry-run) and non-tech users (TUI defaults).
When to use it:
Use ak content publish to push a message to a channel from a script or workflow.
Examples: ak content publish --channel discord --body "Hello from AgentKit!" ak content publish --channel discord --body "Update" --dry-run ak content publish --channel discord --body "$(cat release-notes.md)" --json
What changes on disk: Read-only (reads ~/.agentkit/config.yaml for channel config). Network write on publish (webhook POST). --dry-run makes this fully read-only.
Output modes: pretty default on TTY (colors, ASCII markers) plain auto when stdout piped or --no-interactive json --json (single-object envelope, NDJSON-safe)
Exit codes: 0 success 1 runtime error 2 invalid flags 3 user-cancel (SIGINT, prompt-cancel) 1 publish failed (network error, bad webhook URL, adapter error) 2 invalid flags or arguments 3 validation error (body too long, missing required config)
Options
-h, --help help for content
--json Emit machine-readable JSON (implies --no-interactive)
--no-interactive Disable interactive prompts (CI-safe)
-q, --quiet Suppress non-error output on stderr
-V, --verbose Extra diagnostic output on stderr (loses to --quiet)
-y, --yes Assume yes for all promptsSEE ALSO
- ak - AgentKit CLI
- ak content publish - Publish a post to a channel
- ak content queue - Manage the scheduled post queue
- ak content schedule - Manage the content scheduler