CLI Reference

The AgentPreso CLI is a standalone binary that works with local files and cloud storage. No Node.js required.

Global Options

These options apply to all commands:

OptionDescription
--help, -hShow help for a command
--version, -vShow CLI version
--config <path>Use a custom config file
--quiet, -qSuppress non-error output
--verboseShow detailed output

Authentication Commands

agentpreso login

Authenticate with the AgentPreso server and store your API key locally.

agentpreso login

Opens a browser window for authentication. After successful login, your API key is stored in ~/.agentpreso/credentials.

Options:

OptionDescription
--server <url>Use a custom server URL
--key <api-key>Provide an API key directly (non-interactive)

agentpreso logout

Remove stored credentials.

agentpreso logout

agentpreso whoami

Display the currently authenticated user and server.

agentpreso whoami

Output:

Logged in as: [email protected]
Server: https://api.agentpreso.com

Deck Commands

agentpreso create <name>

Create a new presentation from a template.

agentpreso create quarterly-review

Options:

OptionDescription
--template, -tTemplate to use (default: minimal)
--output, -oOutput directory (default: current directory)

Examples:

# Create with corporate template
agentpreso create sales-deck --template corporate

# Create in a specific directory
agentpreso create pitch --output ./presentations

agentpreso render <file>

Render a presentation to HTML, PDF, or PowerPoint.

agentpreso render presentation.md

Options:

OptionDescription
--format, -fOutput format: html, pdf, pptx (default: html)
--output, -oOutput file path
--template, -tOverride template from frontmatter
--watch, -wWatch for changes and re-render

Examples:

# Render to PDF
agentpreso render deck.md --format pdf

# Custom output path
agentpreso render deck.md --format pptx --output ./output/final.pptx

# Watch mode
agentpreso render deck.md --watch

agentpreso serve <file>

Start a local development server with hot-reload preview.

agentpreso serve presentation.md

Options:

OptionDescription
--port, -pServer port (default: 3000)
--hostHost to bind to (default: localhost)
--openOpen browser automatically

Examples:

# Custom port
agentpreso serve deck.md --port 8080

# Open browser automatically
agentpreso serve deck.md --open

agentpreso push [file]

Upload a local deck to cloud storage.

agentpreso push presentation.md

If no file is specified, pushes all .md files in the current directory that have AgentPreso frontmatter.

Options:

OptionDescription
--slugOverride the deck slug (default: filename)
--forceOverwrite existing deck without confirmation

Examples:

# Push with custom slug
agentpreso push deck.md --slug q3-results

# Force overwrite
agentpreso push deck.md --force

agentpreso pull <slug>

Download a cloud deck to a local file.

agentpreso pull quarterly-review

Options:

OptionDescription
--output, -oOutput file path (default: <slug>.md)
--forceOverwrite existing local file

Examples:

# Custom output path
agentpreso pull q3-results --output ./decks/q3.md

agentpreso list

List your cloud decks.

agentpreso list

Options:

OptionDescription
--jsonOutput as JSON
--limit, -nMaximum number of results

Output:

SLUG              TITLE                    UPDATED
quarterly-review  Q3 2024 Review           2 hours ago
sales-pitch       Enterprise Sales Deck    3 days ago
onboarding        New Hire Onboarding      1 week ago

Template Commands

agentpreso templates

List available templates.

agentpreso templates

Options:

OptionDescription
--jsonOutput as JSON

Output:

NAME        DESCRIPTION                              TYPE
minimal     Clean, lots of whitespace                built-in
dark        Dark background, high contrast           built-in
corporate   Professional, muted blues/grays          built-in
creative    Bold colors, modern typography           built-in
my-brand    Custom company branding                  custom

agentpreso templates add <path>

Upload a custom template to your account.

agentpreso templates add ./my-template/

The path should be a directory containing:

  • template.yaml - manifest file
  • theme.css - Marp theme CSS
  • scaffold.md - optional starter content
  • assets/ - optional directory with images

Configuration Commands

agentpreso config

Show current configuration.

agentpreso config

agentpreso config set <key> <value>

Set a configuration value.

agentpreso config set defaults.template corporate

Available settings:

KeyDescription
server.urlAPI server URL
defaults.templateDefault template for new decks
defaults.formatDefault render format

agentpreso config reset

Reset configuration to defaults.

agentpreso config reset

Configuration Files

~/.agentpreso/config.yaml

Global configuration:

server:
  url: https://api.agentpreso.com
defaults:
  template: minimal
  format: html

~/.agentpreso/credentials

API key storage (do not commit to version control):

api_key: imp_a1b2c3d4e5f6...

Exit Codes

CodeDescription
0Success
1General error
2Invalid arguments
3Authentication required
4Network error
5File not found