Skip to main content
synth-ai deploy packages the selected task app and runs the Modal CLI so you can ship it to your Modal account. It reuses the same discovery and registry logic as other task-app commands.
  • If you omit APP_ID, the CLI scans registered apps, demos, and local files so you can pick one interactively.
  • The command loads credentials from .env files (either the one you pass with --env-file, an entry’s own env_files, or the first .env it finds in the workspace). Missing keys trigger interactive prompts, and the helper will mint a fresh ENVIRONMENT_API_KEY when the backend supports it.
  • A temporary Modal entrypoint is generated on the fly. It installs the current synth-ai version, any packages declared in the registry metadata, and mounts the repo directories that contain your task app code.
  • When an environment key is available it is inlined into the Modal script, so you don’t have to add extra Modal secrets for ENVIRONMENT_API_KEY/ENVIRONMENT_API_KEY_ALIASES.
  • The command shells out to modal deploy (or whatever binary you pass to --modal-cli) and streams the live output. If Modal prints a public URL it is written back to your .env as TASK_APP_BASE_URL.
uvx synth-ai deploy grpo-crafter --name grpo-crafter-prod
Example session:
synth@Nomans-Resolve sdk % uvx synth-ai deploy grpo-crafter --name grpo-crafter-prod
Using env file(s): /Users/synth/qa/sdk/.env
[deploy] inline ENVIRONMENT_API_KEY prepared (sk-...46a)
[modal-exec] modal deploy /var/folders/.../grpo_crafter_modal.py --name grpo-crafter-prod
 Building image...
 Uploading image...
 Deploying app...
 Task app URL: https://grpo-crafter-prod.modal.run

Options

  • APP_ID (optional) — pick a specific task app; otherwise the CLI prompts.
  • --env-file PATH — load credentials from this .env. If omitted the command falls back to the app’s declared env files or auto-discovers one.
  • --name NAME — override the Modal app name. Defaults to the name stored in the task app registry.
  • --modal-cli PATH — point to a custom Modal CLI binary. By default the command resolves modal on your PATH or falls back to the built-in shim when the modal Python package is installed.
  • --dry-run — print the modal deploy … command and exit without running it.

Notes

  • Make sure you are authenticated with Modal before running the command; we simply invoke the CLI on your behalf.
  • The same env-file resolution and key preflighting power the task-app deploy subcommand and the legacy compatibility wrappers (synth-ai deploy).
  • If you are targeting a script with its own deploy_task_app.sh, the CLI prompts you to select a .env and then runs that script instead of generating a wrapper.