Deploy on Flow
1
Set up the project
From the agent’s folder, sign in and set up its keys if you have not already:The deploy command uses
Terminal
FLOW_FRAMEWORK_CLOUD_KEY. The starter’s buildAgent already accepts
options.host and passes it to createAgent.2
Deploy to staging
Terminal
deploy sends the project’s .env values as secrets, builds the agent and follows the
deployment to live. The default environment is staging.Check it worked: deploy status shows the live version and the URL the host reports.
Exercise a request, then inspect its log lines:Terminal
3
Promote the checked version
After checking staging, promote its live version:Promotion uses the staged version without a new build. Production has its own secrets.
Terminal
src/mcp.ts for the host to serve beside the agent.
Connect its public URL through the MCP setup.
The buildAgent contract and secrets
The buildAgent contract and secrets
For a custom entry point, accept the host options and pass them as
host: options.host to
createAgent. Do not spread them into the agent options. Production expects the host’s durable
store instead of an agent’s own database.deploy needs package.json, package-lock.json and src/agent.ts. It uploads the project
without node_modules, Git data or environment files, then sends eligible environment values
separately as secrets. Use --no-secrets to skip sending them.The deployment reference covers secret updates, flags, JSON output and exit codes.Host it yourself
Run MCP and messaging on your own Node infrastructure.
Inspect traces
See model calls, tool calls and conversation events.