Overview
Traycer allows you to create custom CLI agent templates with custom arguments and permissions for any CLI-based coding agent. This powerful feature enables you to pass special flags and create platform-specific configurations tailored to your workflow.What are Custom CLI Agents?
Custom CLI agents allow you to:- Execute any CLI-based coding agent with custom arguments.
- Pass special flags like
--dangerousor--forcefor elevated permissions. - Create platform-specific templates for different environments.
Available Template Tags
Custom CLI agent templates support the following environment variables set by Traycer at runtime:The prompt content. This environment variable is required in all templates.
Per-phase identifier for maintaining session across plan and verification.
Phase breakdown identifier for maintaining session across current phase list.
Task identifier for maintaining session across all phase iterations, plans, and verification execution
Creating Custom CLI Agents

1
1. Open Manage CLI Agents
Click the three dots on the top of the sidebar to open the context menu, then click “Manage CLI Agents”.
2
2. Click Add CLI Agent
Click “Add CLI Agent” to add a new custom CLI agent.
3
3. Choose scope
Select either User (personal CLI agents available across all projects) or Workspace (project-specific CLI agents stored in workspace settings).
4
4. CLI Agent Name
Provide a descriptive name for your custom CLI agent and click “Create CLI Agent”.
5
5. Add CLI Agent Command
Add your custom command to the created file and save it.
Template Scopes
Custom CLI agents can be created in two different scopes:- User scope: Personal CLI agents that are available across all your projects. These templates are stored in the home directory under
.traycer/cli-agentsand travel with you. - Workspace scope: Project-specific CLI agents that are stored in your workspace root under
.traycer/cli-agents. These are ideal for team-shared configurations or project-specific agent setups.
Popular CLI Agents
Here are some popular CLI-based coding agents you can use with custom templates:- Claude Code CLI
- Codex CLI
- Gemini CLI
- Cline CLI
- Factory Droid CLI
- Cursor CLI
- Aider
The following are frequently used arguments. For more details, visit the official documentation.
Basic
Verbose
Dangerous Mode
Using Custom Paths
If your CLI agent is installed at a custom location, you can specify the full path in your template:The
$TRAYCER_PROMPT environment variable is required in all templates. The prompt content is securely passed via temporary files.Flags like
--dangerous grant elevated permissions to the agent. Always review what permissions you’re granting to CLI agents.Use Cases
Custom CLI agents are particularly useful for:- Passing dangerous/elevated permissions flags.
- Using custom model configurations.
- Setting specific output formats.
- Creating environment-specific agent configurations.
FAQ
Can I pass dangerous or elevated permission flags?
Can I pass dangerous or elevated permission flags?
Yes, you can pass any flags supported by your CLI agent, including
--dangerous, --force, or other elevated permission flags. However, be cautious as these flags grant the agent more control over your system. Always understand what permissions you’re granting before using such flags.How do I share custom CLI agents with my team?
How do I share custom CLI agents with my team?
What's the difference between User and Workspace scope?
What's the difference between User and Workspace scope?
User scope templates are stored in your personal settings and available across all projects. Workspace scope templates are project-specific and stored in the workspace settings, making them ideal for team collaboration.
Which file extension should I use?
Which file extension should I use?
Use
.sh for shell scripts on Linux, macOS, or Git Bash on Windows. Use .bat for Windows Command Prompt or PowerShell. The extension determines how the template is executed.Can I edit an existing template?
Can I edit an existing template?
Yes, you can edit any custom CLI agent template by clicking on it in the Custom CLI Agents section of Traycer settings. The template file will open for editing.
What happens if I don't include the $TRAYCER_PROMPT environment variable?
What happens if I don't include the $TRAYCER_PROMPT environment variable?
The template validation will fail. The
$TRAYCER_PROMPT environment variable is required in all custom CLI agent templates as it contains the actual task instructions.Can I use custom CLI agents with YOLO Mode?
Can I use custom CLI agents with YOLO Mode?
Yes, custom CLI agents that use supported CLI tools (like Claude Code CLI, Codex CLI, or Gemini CLI) can work with YOLO Mode for automated execution.
Can I have multiple versions of the same agent?
Can I have multiple versions of the same agent?
Yes, you can create multiple custom CLI agents with different names that use the same underlying CLI tool. For example, you could have “Claude Verbose”, “Claude Dangerous”, and “Claude Standard” - each with different flags but all calling the same
claude CLI agent.What if the CLI tool isn't installed on my system?
What if the CLI tool isn't installed on my system?
Traycer does not install CLI agents for you. You must install the CLI tool separately before creating a custom template. We recommend testing the CLI command in your terminal first to ensure it works correctly before adding it to a template.