Pull
Pull downloads your workspace as individual.xs (XanoScript) files, organized by type.
Terminal
.xs file. Key details:
- API endpoints are grouped under
api/{group_name}/directories, with each group containing anapi_group.xsand endpoint files named{name}_{verb}.xs - Hierarchical functions (with
/in the name) are split into subdirectories - AI resources (agents, tools, MCP servers) are grouped under
ai/, with triggers inai/{type}/trigger/ - Realtime resources are organized under
realtime/channel/andrealtime/trigger/ - Triggers are placed in
trigger/subdirectories within their parent type (table/trigger/,ai/agent/trigger/, etc.) - All filenames are converted to
snake_case
Pull Options
| Flag | Description |
|---|---|
-b | Branch name (overrides profile; defaults to live branch) |
-w | Workspace ID (overrides profile) |
--env | Include environment variables |
--records | Include database records |
--draft | Include draft versions of resources |
Include environment variables
Terminal
Include database records
Pull your table records alongside the schema. This is also a convenient way to create a local backup of your data before pushing schema changes.Terminal
Both
Terminal
Pull a specific branch
Terminal
-b is not provided, the pull targets the branch stored in your profile. If no branch is set in your profile, it defaults to the live branch.
Push
Push uploads all local.xs files back to your Xano workspace, syncing your local changes.
Terminal
.xs files from the directory, sorts them alphabetically, combines them into a single payload, and sends them to Xano. After completion, the CLI displays the total execution time.
| Flag | Description |
|---|---|
-b | Branch name (overrides profile; defaults to live branch) |
-w | Workspace ID (overrides profile) |
--partial | Push without requiring a workspace block — useful for pushing a subset of files |
--delete | Delete objects in Xano that are not present in the push |
--no-records | Skip importing table records (push schema only) |
--no-env | Skip overwriting environment variables |
--no-sync-guids | Skip writing server-assigned GUIDs back to local files |
--truncate | Truncate all table records before importing |
Push Options
Push schema only (skip records)
Terminal
Push without overwriting environment variables
Terminal
Partial push (no workspace block required)
Use--partial to push a subset of files without needing a complete workspace block. This is useful when you only want to update specific resources.
Terminal
Delete removed objects
Use--delete to remove any objects in Xano that are not present in your local files. This ensures your workspace matches your local directory exactly.
Terminal
Truncate table records before importing
Terminal
Skip GUID sync
By default, after a push the CLI writes server-assigned GUIDs back into your local.xs files. Use --no-sync-guids to skip this step — useful in CI/CD pipelines or when you don’t want local files modified.
Terminal
Combine flags
Terminal
Pull from Git
You can pull XanoScript files directly from a Git repository (GitHub, GitLab, or any git URL) into a local directory — without needing to clone the repo yourself.Terminal
.xs files from the repository and organizes them into the same directory structure as a workspace pull.
Git Pull Options
| Flag | Description |
|---|---|
-r | Git repository URL (required) — supports HTTPS, SSH, GitHub, and GitLab URLs |
-b | Branch, tag, or ref to fetch (defaults to the repository’s default branch) |
-t | Personal access token for private repos (falls back to GITHUB_TOKEN env var) |
--path | Subdirectory within the repo to import from |
URL Formats
You can pass a variety of URL formats — the CLI extracts the owner, repo, branch, and path automatically:Terminal
Workflow: Import from Git, Push to Xano
A common use case is pulling XanoScript from a shared Git repository and pushing it to a workspace. For example, you can pull the Hello World sample from the XanoScript examples repo and push it to your workspace:Terminal
Typical Workflow
A common development cycle looks like this:Make changes locally
Edit
.xs files in your editor of choice. Use the XanoScript VS Code Extension for syntax highlighting and autocomplete.
Git works like it always has
Your workspace is plain files on disk — git init, commit, branch, and open PRs exactly like any other project. Xano’s push/pull fits into your Git workflow, not the other way around.
Working with Git
Since pull outputs standard files to your filesystem, you can version control your XanoScript with Git:Terminal
Tips
- Pull before you push to avoid overwriting changes made by teammates in the Xano dashboard.
- Use branches for development work. Create a branch with
xano branch create -l dev, then use-b devon push and pull commands to target it without affecting the live branch. - Snapshot your data by pulling with
--recordsbefore pushing schema changes. This gives you a local copy of your database records you can restore from if needed. - Use
--partialwhen you only need to push a few specific resources instead of the entire workspace. - Combine with AI tools like Claude Code or Cursor to generate and edit XanoScript locally, then push the results. See the Start from Scratch and Work from Existing guides for full walkthroughs.
Troubleshooting
If a push or pull isn’t working as expected, use the-v (verbose) flag to see the full request and response details:
Terminal
- The HTTP method and full URL being called
- Request headers (with the authorization token partially masked)
- The request body (truncated to 500 characters for readability)
- The response status code and elapsed time
XANO_VERBOSE environment variable:
Terminal