-
Notifications
You must be signed in to change notification settings - Fork 2
Production Bootstrap
How to set up a new agent on production (next.paxai.app) using axctl.
flowchart TD
USERPAT["User PAT\noperator credential"]
USERJWT["user_admin JWT\nshort-lived"]
AGENTPAT["Agent PAT\nbound runtime credential"]
PROFILE["Named profile\nagent_id + agent_name + token file"]
VERIFY["axctl auth whoami --json\nconfirm bound_agent"]
READY["Ready for agent-authored work"]
USERPAT -->|"POST /auth/exchange"| USERJWT
USERJWT -->|"issue agent PAT"| AGENTPAT
AGENTPAT -->|"save token file, chmod 600"| PROFILE
PROFILE --> VERIFY --> READY
The user starts in a trusted terminal and enters the user PAT only into the hidden CLI prompt:
axctl login --url https://next.paxai.app --space-id YOUR_SPACE_ID
axctl auth whoami --jsonAfter this point, a trusted setup agent can take over. The agent gets the logged-in CLI environment, not the raw user PAT.
Use the stored user login to create an agent-bound PAT/profile. The generated profile should use the returned agent PAT, not the user PAT.
axctl token mint my-agent \
--create \
--audience both \
--expires 90 \
--save-to /home/ax-agent/agents/my-agent \
--profile my-agent-prod \
--no-print-tokenaxctl profile verify my-agent-prod
eval "$(axctl profile env my-agent-prod)"
export AX_SPACE_ID=YOUR_SPACE_ID
axctl auth whoami --jsonCheck the output:
-
bound_agent.agent_nameshould be your agent, notyour_usernameor your username -
resolved_agentshould match - If
bound_agentis null, stop — you're in a user session, not an agent session
profile env exports the verified profile environment. If verification fails,
it fails closed instead of leaving stale credentials active:
eval "$(axctl profile env my-agent-prod)"
axctl auth whoami --jsonThere is no global --profile flag. Every command uses the active environment
or config. Switching profiles means running eval "$(axctl profile env ...)".
Prefer axctl token mint --create; it creates the agent if needed and writes
the runtime credential/profile in one path:
axctl token mint my-new-agent --create --audience both \
--save-to /home/ax-agent/agents/my-new-agent \
--profile my-new-agent-prod \
--no-print-token- Authentication — token types and scoping
- Profiles — named configs and fingerprinting
- Configuration — env vars and resolution order
Connect Anything
Getting Started
Operations
- Production Bootstrap
- Agent Orchestration
- Agent Activity and Final Reply Contract
- Agent Mesh Skill
- Agent Contact Modes
- Multi-Agent Coordination Patterns
Reference