CLI Overview
The Transactional CLI provides a powerful command-line interface for managing your email infrastructure.
CLI Overview
The Transactional CLI (transactional) is a command-line tool for managing your Transactional account, sending emails, and configuring your email infrastructure directly from the terminal.
Installation
Install the CLI globally using npm:
npm install -g @usetransactional/cliOr using yarn:
yarn global add @usetransactional/cliOr using pnpm:
pnpm add -g @usetransactional/cliQuick Start
- Login to your account:
transactional loginThis opens your browser to complete authentication. Follow the prompts to authorize the CLI.
- Select an organization:
transactional org list
transactional org use <slug>- Send your first email:
transactional email send \
--from "hello@yourdomain.com" \
--to "recipient@example.com" \
--subject "Hello from CLI" \
--html "<h1>Hello World</h1>"Command Groups
| Command Group | Description |
|---|---|
login/logout | Authentication commands |
whoami | Show current user info |
org | Organization management |
switch | Quick organization switch |
email | Email operations |
config | CLI configuration |
mcp | MCP server integration |
Global Options
Most commands support these options:
| Option | Description |
|---|---|
-o, --org <slug> | Override the current organization |
--json | Output results as JSON |
-h, --help | Show help for a command |
Configuration
The CLI stores configuration and credentials in ~/.transactional/:
config.json- CLI configuration (API URL, output format)credentials.json- Authentication tokens
View current config:
transactional config showEnvironment Variables
| Variable | Description |
|---|---|
TRANSACTIONAL_API_URL | Override API URL |
TRANSACTIONAL_WEB_URL | Override Web URL |
NO_COLOR | Disable colored output |
Next Steps
- Authentication - Login and organization management
- Email Commands - Sending and managing emails
- Configuration - Customizing the CLI
- Claude Code Integration - Use with Claude Code
- MCP Integration - AI assistant integration