@xano/developer-mcp 1.0.73 → 1.0.74
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/cli_docs/index.js +4 -4
- package/dist/cli_docs/topics/auth.js +16 -11
- package/dist/cli_docs/topics/branch.js +83 -74
- package/dist/cli_docs/topics/function.js +86 -59
- package/dist/cli_docs/topics/integration.js +47 -32
- package/dist/cli_docs/topics/platform.js +14 -14
- package/dist/cli_docs/topics/profile.js +58 -55
- package/dist/cli_docs/topics/release.js +150 -96
- package/dist/cli_docs/topics/sandbox.d.ts +2 -0
- package/dist/cli_docs/topics/sandbox.js +317 -0
- package/dist/cli_docs/topics/start.js +31 -26
- package/dist/cli_docs/topics/static_host.js +52 -26
- package/dist/cli_docs/topics/tenant.js +355 -223
- package/dist/cli_docs/topics/unit_test.js +30 -30
- package/dist/cli_docs/topics/update.js +1 -0
- package/dist/cli_docs/topics/workflow_test.js +42 -39
- package/dist/cli_docs/topics/workspace.js +143 -108
- package/package.json +1 -1
|
@@ -0,0 +1,317 @@
|
|
|
1
|
+
export const sandboxDoc = {
|
|
2
|
+
topic: "sandbox",
|
|
3
|
+
title: "Xano CLI - Sandbox Environment",
|
|
4
|
+
description: `Sandbox is a personal, auto-provisioned development environment tied to your Xano account. It's a singleton per user — there's exactly one sandbox, and the CLI creates it on first use. Designed for free-tier users and local iteration, sandbox supports the full pull/push multidoc workflow without the ceremony of workspace/tenant management.
|
|
5
|
+
|
|
6
|
+
## Key Concepts
|
|
7
|
+
|
|
8
|
+
- **Singleton**: Each user has exactly one sandbox. No name/ID to manage.
|
|
9
|
+
- **Auto-provisioned**: \`xano sandbox get\` creates it on first call if it doesn't exist.
|
|
10
|
+
- **Free-tier friendly**: Available without paid plan, scoped to the authenticated user.
|
|
11
|
+
- **Review-driven**: After pushing, open the sandbox in a browser to review and promote changes to a real workspace.
|
|
12
|
+
- **Multidoc push/pull**: Same file layout as \`xano workspace pull/push\` — API groups, functions, tables, agents, etc. split into \`.xs\` files.
|
|
13
|
+
|
|
14
|
+
## When to Use Sandbox vs Workspace
|
|
15
|
+
|
|
16
|
+
- Use **sandbox** for: personal experimentation, prototyping, AI-assisted code generation, CI examples, quick tests without risking shared state.
|
|
17
|
+
- Use **workspace** for: team collaboration, production code, release management, tenant deployments.`,
|
|
18
|
+
ai_hints: `**Prefer sandbox for AI-assisted development and code experimentation:**
|
|
19
|
+
- It's free-tier, auto-created, and disposable (\`sandbox reset\` wipes it clean).
|
|
20
|
+
- The push/pull interface mirrors \`workspace\`, so workflows translate directly.
|
|
21
|
+
- Use \`sandbox push --review\` to push and immediately open the browser to verify changes.
|
|
22
|
+
- Use \`sandbox reset\` to start over without recreating the sandbox.
|
|
23
|
+
- Use \`sandbox delete\` only if the user really wants to remove the sandbox entirely — \`reset\` is usually what they want.
|
|
24
|
+
|
|
25
|
+
**Typical flow:**
|
|
26
|
+
1. \`xano sandbox pull -d ./code\` — grab the current state
|
|
27
|
+
2. Edit .xs files locally
|
|
28
|
+
3. \`xano sandbox push --review\` — push and open browser
|
|
29
|
+
4. In the dashboard, promote changes to a real workspace if desired
|
|
30
|
+
|
|
31
|
+
**Partial push is the default** — only changed files are sent. Use \`--sync\` for a full push, \`--sync --delete\` to also remove remote objects missing locally, and \`--dry-run\` to preview.
|
|
32
|
+
|
|
33
|
+
**Glob filters** (\`-i\` include, \`-e\` exclude) are repeatable and match relative paths from the push directory.
|
|
34
|
+
|
|
35
|
+
**Transaction / GUID flags:** push wraps imports in a database transaction by default (\`--no-transaction\` to disable) and writes server-assigned GUIDs back to local files by default (\`--no-guids\` to disable).
|
|
36
|
+
|
|
37
|
+
**Environment variables and tests** are managed per-sandbox via \`sandbox env\` and \`sandbox unit_test\` / \`sandbox workflow_test\` subcommands.
|
|
38
|
+
|
|
39
|
+
**\`sandbox impersonate\` is a hidden alias for \`sandbox review\`** — prefer \`sandbox review\`.`,
|
|
40
|
+
related_topics: ["workspace", "tenant", "start", "integration"],
|
|
41
|
+
commands: [
|
|
42
|
+
{
|
|
43
|
+
name: "sandbox get",
|
|
44
|
+
description: "Get your sandbox environment, creating it if it doesn't exist. Safe to run repeatedly.",
|
|
45
|
+
usage: "xano sandbox get [options]",
|
|
46
|
+
flags: [
|
|
47
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
48
|
+
],
|
|
49
|
+
examples: ["xano sandbox get", "xano sandbox get -o json"]
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
name: "sandbox pull",
|
|
53
|
+
description: "Pull sandbox contents to a local directory, splitting multidoc output into individual .xs files organized by type.",
|
|
54
|
+
usage: "xano sandbox pull [options]",
|
|
55
|
+
flags: [
|
|
56
|
+
{ name: "directory", short: "d", type: "string", required: false, default: ".", description: "Output directory for pulled documents" },
|
|
57
|
+
{ name: "env", type: "boolean", required: false, description: "Include environment variables" },
|
|
58
|
+
{ name: "records", type: "boolean", required: false, description: "Include table records" },
|
|
59
|
+
{ name: "draft", type: "boolean", required: false, description: "Include draft versions" }
|
|
60
|
+
],
|
|
61
|
+
examples: [
|
|
62
|
+
"xano sandbox pull",
|
|
63
|
+
"xano sandbox pull -d ./my-sandbox",
|
|
64
|
+
"xano sandbox pull -d ./my-sandbox --env --records"
|
|
65
|
+
]
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
name: "sandbox push",
|
|
69
|
+
description: "Push local documents to the sandbox via multidoc import. Partial (changed-only) by default; shows a preview unless --force.",
|
|
70
|
+
usage: "xano sandbox push [options]",
|
|
71
|
+
flags: [
|
|
72
|
+
{ name: "directory", short: "d", type: "string", required: false, default: ".", description: "Directory containing documents to push" },
|
|
73
|
+
{ name: "sync", type: "boolean", required: false, description: "Full push of all files (default is partial/changed-only)" },
|
|
74
|
+
{ name: "delete", type: "boolean", required: false, description: "Delete remote objects not in local files (requires --sync)" },
|
|
75
|
+
{ name: "dry-run", type: "boolean", required: false, description: "Preview changes without applying" },
|
|
76
|
+
{ name: "force", type: "boolean", required: false, description: "Skip preview and confirmation (for CI/CD)" },
|
|
77
|
+
{ name: "env", type: "boolean", required: false, description: "Include environment variables" },
|
|
78
|
+
{ name: "records", type: "boolean", required: false, description: "Include table records" },
|
|
79
|
+
{ name: "truncate", type: "boolean", required: false, description: "Truncate tables before importing records" },
|
|
80
|
+
{ name: "transaction", type: "boolean", required: false, default: "true", description: "Wrap import in a database transaction (--no-transaction to disable)" },
|
|
81
|
+
{ name: "guids", type: "boolean", required: false, default: "true", description: "Write server-assigned GUIDs back to local files after push (--no-guids to disable)" },
|
|
82
|
+
{ name: "include", short: "i", type: "string", required: false, description: "Glob pattern to include (repeatable)" },
|
|
83
|
+
{ name: "exclude", short: "e", type: "string", required: false, description: "Glob pattern to exclude (repeatable)" },
|
|
84
|
+
{ name: "review", type: "boolean", required: false, description: "After pushing, open sandbox in the browser to review" }
|
|
85
|
+
],
|
|
86
|
+
examples: [
|
|
87
|
+
"xano sandbox push",
|
|
88
|
+
"xano sandbox push -d ./my-sandbox",
|
|
89
|
+
"xano sandbox push --sync",
|
|
90
|
+
"xano sandbox push --sync --delete",
|
|
91
|
+
"xano sandbox push --dry-run",
|
|
92
|
+
"xano sandbox push --review",
|
|
93
|
+
"xano sandbox push -i 'function/*' -i 'table/*'",
|
|
94
|
+
"xano sandbox push -e 'table/*' --records"
|
|
95
|
+
]
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
name: "sandbox review",
|
|
99
|
+
description: "Open the sandbox in the browser to review and promote changes.",
|
|
100
|
+
usage: "xano sandbox review [options]",
|
|
101
|
+
flags: [
|
|
102
|
+
{ name: "url-only", short: "u", type: "boolean", required: false, description: "Print the URL without opening the browser" },
|
|
103
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
104
|
+
],
|
|
105
|
+
examples: ["xano sandbox review", "xano sandbox review --url-only"]
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
name: "sandbox impersonate",
|
|
109
|
+
description: "Hidden alias for `sandbox review`. Prefer `sandbox review`.",
|
|
110
|
+
usage: "xano sandbox impersonate",
|
|
111
|
+
examples: ["xano sandbox impersonate"]
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
name: "sandbox reset",
|
|
115
|
+
description: "Reset the sandbox — clears all workspace data and drafts but keeps the sandbox itself.",
|
|
116
|
+
usage: "xano sandbox reset [--force]",
|
|
117
|
+
flags: [
|
|
118
|
+
{ name: "force", short: "f", type: "boolean", required: false, description: "Skip confirmation prompt" }
|
|
119
|
+
],
|
|
120
|
+
examples: ["xano sandbox reset", "xano sandbox reset --force"]
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
name: "sandbox delete",
|
|
124
|
+
description: "Delete the sandbox entirely. Use `reset` instead if you just want to wipe data.",
|
|
125
|
+
usage: "xano sandbox delete [--force]",
|
|
126
|
+
flags: [
|
|
127
|
+
{ name: "force", short: "f", type: "boolean", required: false, description: "Skip confirmation prompt" }
|
|
128
|
+
],
|
|
129
|
+
examples: ["xano sandbox delete --force"]
|
|
130
|
+
},
|
|
131
|
+
{
|
|
132
|
+
name: "sandbox env list",
|
|
133
|
+
description: "List environment variable keys for the sandbox.",
|
|
134
|
+
usage: "xano sandbox env list [-o <format>]",
|
|
135
|
+
flags: [
|
|
136
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
137
|
+
],
|
|
138
|
+
examples: ["xano sandbox env list"]
|
|
139
|
+
},
|
|
140
|
+
{
|
|
141
|
+
name: "sandbox env get",
|
|
142
|
+
description: "Get a single environment variable value.",
|
|
143
|
+
usage: "xano sandbox env get --name <key> [-o <format>]",
|
|
144
|
+
flags: [
|
|
145
|
+
{ name: "name", short: "n", type: "string", required: true, description: "Environment variable name" },
|
|
146
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
147
|
+
],
|
|
148
|
+
examples: ["xano sandbox env get -n API_KEY"]
|
|
149
|
+
},
|
|
150
|
+
{
|
|
151
|
+
name: "sandbox env set",
|
|
152
|
+
description: "Create or update an environment variable.",
|
|
153
|
+
usage: "xano sandbox env set --name <key> --value <val>",
|
|
154
|
+
flags: [
|
|
155
|
+
{ name: "name", short: "n", type: "string", required: true, description: "Environment variable name" },
|
|
156
|
+
{ name: "value", type: "string", required: true, description: "Environment variable value" },
|
|
157
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
158
|
+
],
|
|
159
|
+
examples: ["xano sandbox env set -n API_KEY --value sk-123"]
|
|
160
|
+
},
|
|
161
|
+
{
|
|
162
|
+
name: "sandbox env delete",
|
|
163
|
+
description: "Delete an environment variable.",
|
|
164
|
+
usage: "xano sandbox env delete --name <key> [--force]",
|
|
165
|
+
flags: [
|
|
166
|
+
{ name: "name", short: "n", type: "string", required: true, description: "Environment variable name" },
|
|
167
|
+
{ name: "force", short: "f", type: "boolean", required: false, description: "Skip confirmation prompt" },
|
|
168
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
169
|
+
],
|
|
170
|
+
examples: ["xano sandbox env delete -n OLD_KEY --force"]
|
|
171
|
+
},
|
|
172
|
+
{
|
|
173
|
+
name: "sandbox env get_all",
|
|
174
|
+
description: "Export all sandbox environment variables to a YAML file (default: ./env.yaml) or stdout with --view.",
|
|
175
|
+
usage: "xano sandbox env get_all [-f <path>] [--view]",
|
|
176
|
+
flags: [
|
|
177
|
+
{ name: "file", short: "f", type: "string", required: false, description: "Output file path (default: ./env.yaml)" },
|
|
178
|
+
{ name: "view", type: "boolean", required: false, description: "Print to stdout instead of saving to file" },
|
|
179
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
180
|
+
],
|
|
181
|
+
examples: [
|
|
182
|
+
"xano sandbox env get_all",
|
|
183
|
+
"xano sandbox env get_all -f ./env.yaml",
|
|
184
|
+
"xano sandbox env get_all --view"
|
|
185
|
+
]
|
|
186
|
+
},
|
|
187
|
+
{
|
|
188
|
+
name: "sandbox env set_all",
|
|
189
|
+
description: "Import environment variables from a YAML file (default: ./env.yaml).",
|
|
190
|
+
usage: "xano sandbox env set_all [-f <path>] [--clean]",
|
|
191
|
+
flags: [
|
|
192
|
+
{ name: "file", short: "f", type: "string", required: false, description: "Path to env file (default: ./env.yaml)" },
|
|
193
|
+
{ name: "clean", type: "boolean", required: false, description: "Remove source file after successful upload" },
|
|
194
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
195
|
+
],
|
|
196
|
+
examples: ["xano sandbox env set_all -f ./env.yaml"]
|
|
197
|
+
},
|
|
198
|
+
{
|
|
199
|
+
name: "sandbox license get",
|
|
200
|
+
description: "Get the sandbox license (saves to ./license.yaml by default; use --view to print).",
|
|
201
|
+
usage: "xano sandbox license get [-f <path>] [--view]",
|
|
202
|
+
flags: [
|
|
203
|
+
{ name: "file", short: "f", type: "string", required: false, description: "Output file path (default: ./license.yaml)" },
|
|
204
|
+
{ name: "view", type: "boolean", required: false, description: "Print license to stdout instead of saving" },
|
|
205
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
206
|
+
],
|
|
207
|
+
examples: ["xano sandbox license get --view"]
|
|
208
|
+
},
|
|
209
|
+
{
|
|
210
|
+
name: "sandbox license set",
|
|
211
|
+
description: "Set/update the sandbox license from a file or inline value. `--value` is mutually exclusive with `--file` and `--clean`.",
|
|
212
|
+
usage: "xano sandbox license set (-f <path> | --value <license>)",
|
|
213
|
+
flags: [
|
|
214
|
+
{ name: "file", short: "f", type: "string", required: false, description: "Path to license file (default: ./license.yaml). Mutually exclusive with --value." },
|
|
215
|
+
{ name: "value", type: "string", required: false, description: "Inline license value. Mutually exclusive with --file and --clean." },
|
|
216
|
+
{ name: "clean", type: "boolean", required: false, description: "Remove source file after successful upload. Mutually exclusive with --value." },
|
|
217
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
218
|
+
],
|
|
219
|
+
examples: ["xano sandbox license set -f ./license.yaml", "xano sandbox license set --value 'key: value'"]
|
|
220
|
+
},
|
|
221
|
+
{
|
|
222
|
+
name: "sandbox unit_test list",
|
|
223
|
+
description: "List unit tests in the sandbox.",
|
|
224
|
+
usage: "xano sandbox unit_test list [--branch <b>] [--obj-type <type>]",
|
|
225
|
+
flags: [
|
|
226
|
+
{ name: "branch", short: "b", type: "string", required: false, description: "Filter by branch" },
|
|
227
|
+
{ name: "obj-type", type: "string", required: false, description: "Filter by object type: function, query, or middleware" },
|
|
228
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
229
|
+
],
|
|
230
|
+
examples: ["xano sandbox unit_test list"]
|
|
231
|
+
},
|
|
232
|
+
{
|
|
233
|
+
name: "sandbox unit_test run",
|
|
234
|
+
description: "Run a single unit test in the sandbox.",
|
|
235
|
+
usage: "xano sandbox unit_test run <unit_test_id>",
|
|
236
|
+
args: [{ name: "unit_test_id", required: true, description: "ID of the unit test to run" }],
|
|
237
|
+
flags: [
|
|
238
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
239
|
+
],
|
|
240
|
+
examples: ["xano sandbox unit_test run 42", "xano sandbox unit_test run 42 -o json"]
|
|
241
|
+
},
|
|
242
|
+
{
|
|
243
|
+
name: "sandbox unit_test run_all",
|
|
244
|
+
description: "Run all unit tests in the sandbox.",
|
|
245
|
+
usage: "xano sandbox unit_test run_all [--branch <b>] [--obj-type <type>]",
|
|
246
|
+
flags: [
|
|
247
|
+
{ name: "branch", short: "b", type: "string", required: false, description: "Filter by branch" },
|
|
248
|
+
{ name: "obj-type", type: "string", required: false, description: "Filter by object type: function, query, or middleware" },
|
|
249
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
250
|
+
],
|
|
251
|
+
examples: ["xano sandbox unit_test run_all"]
|
|
252
|
+
},
|
|
253
|
+
{
|
|
254
|
+
name: "sandbox workflow_test list",
|
|
255
|
+
description: "List workflow tests in the sandbox.",
|
|
256
|
+
usage: "xano sandbox workflow_test list [--branch <b>]",
|
|
257
|
+
flags: [
|
|
258
|
+
{ name: "branch", short: "b", type: "string", required: false, description: "Filter by branch" },
|
|
259
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
260
|
+
],
|
|
261
|
+
examples: ["xano sandbox workflow_test list"]
|
|
262
|
+
},
|
|
263
|
+
{
|
|
264
|
+
name: "sandbox workflow_test run",
|
|
265
|
+
description: "Run a single workflow test in the sandbox.",
|
|
266
|
+
usage: "xano sandbox workflow_test run <workflow_test_id>",
|
|
267
|
+
args: [{ name: "workflow_test_id", required: true, description: "ID of the workflow test to run (integer)" }],
|
|
268
|
+
flags: [
|
|
269
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
270
|
+
],
|
|
271
|
+
examples: ["xano sandbox workflow_test run 7", "xano sandbox workflow_test run 7 -o json"]
|
|
272
|
+
},
|
|
273
|
+
{
|
|
274
|
+
name: "sandbox workflow_test run_all",
|
|
275
|
+
description: "Run all workflow tests in the sandbox.",
|
|
276
|
+
usage: "xano sandbox workflow_test run_all [--branch <b>]",
|
|
277
|
+
flags: [
|
|
278
|
+
{ name: "branch", short: "b", type: "string", required: false, description: "Filter by branch" },
|
|
279
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
280
|
+
],
|
|
281
|
+
examples: ["xano sandbox workflow_test run_all"]
|
|
282
|
+
}
|
|
283
|
+
],
|
|
284
|
+
workflows: [
|
|
285
|
+
{
|
|
286
|
+
name: "Prototype in Sandbox",
|
|
287
|
+
description: "Iterate on changes in your personal sandbox, then promote to a real workspace",
|
|
288
|
+
steps: [
|
|
289
|
+
"Pull sandbox state: `xano sandbox pull -d ./code`",
|
|
290
|
+
"Edit .xs files locally",
|
|
291
|
+
"Push and review: `xano sandbox push --review`",
|
|
292
|
+
"In the browser, promote changes to a real workspace if desired"
|
|
293
|
+
],
|
|
294
|
+
example: `xano sandbox pull -d ./code
|
|
295
|
+
# ... edit files ...
|
|
296
|
+
xano sandbox push --review`
|
|
297
|
+
},
|
|
298
|
+
{
|
|
299
|
+
name: "Reset Sandbox State",
|
|
300
|
+
description: "Wipe sandbox data when starting a new experiment",
|
|
301
|
+
steps: [
|
|
302
|
+
"Reset data: `xano sandbox reset --force`",
|
|
303
|
+
"Re-provision by any command, e.g. `xano sandbox get`",
|
|
304
|
+
"Pull a clean slate or push fresh code"
|
|
305
|
+
]
|
|
306
|
+
},
|
|
307
|
+
{
|
|
308
|
+
name: "Sandbox Environment Variables",
|
|
309
|
+
description: "Manage per-sandbox configuration",
|
|
310
|
+
steps: [
|
|
311
|
+
"Export current env: `xano sandbox env get_all -f ./env.yaml`",
|
|
312
|
+
"Edit env.yaml locally",
|
|
313
|
+
"Re-import: `xano sandbox env set_all -f ./env.yaml`"
|
|
314
|
+
]
|
|
315
|
+
}
|
|
316
|
+
]
|
|
317
|
+
};
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
export const startDoc = {
|
|
2
2
|
topic: "start",
|
|
3
3
|
title: "Xano CLI - Getting Started",
|
|
4
|
-
description: `The Xano CLI provides command-line access to manage your Xano workspaces,
|
|
4
|
+
description: `The Xano CLI provides command-line access to manage your Xano workspaces, sandbox environments, branches, releases, and tenants.
|
|
5
5
|
|
|
6
6
|
> **Note:** The CLI is optional but recommended for local development workflows. Not all Xano users will have it installed. You can accomplish most tasks using the Meta API directly, but the CLI provides a more convenient developer experience for code sync and local editing.
|
|
7
7
|
|
|
8
8
|
## Installation
|
|
9
9
|
|
|
10
|
+
**Requirements:** Node.js >= 20.12.0
|
|
11
|
+
|
|
10
12
|
**Via npm (recommended):**
|
|
11
13
|
\`\`\`bash
|
|
12
14
|
npm install -g @xano/cli
|
|
@@ -34,22 +36,23 @@ Opens your browser to log in. Automatically creates a profile.
|
|
|
34
36
|
|
|
35
37
|
**Option 2: Interactive wizard**
|
|
36
38
|
\`\`\`bash
|
|
37
|
-
xano profile
|
|
39
|
+
xano profile wizard
|
|
38
40
|
\`\`\`
|
|
39
41
|
Prompts you for your access token, instance, workspace, and branch.
|
|
40
42
|
|
|
41
43
|
## Credential Storage
|
|
42
44
|
|
|
43
|
-
Credentials are stored in \`~/.xano/credentials.yaml
|
|
45
|
+
Credentials are stored in \`~/.xano/credentials.yaml\` by default (override with \`-c/--config\` or \`XANO_CONFIG\`):
|
|
44
46
|
|
|
45
47
|
\`\`\`yaml
|
|
46
48
|
profiles:
|
|
47
49
|
default:
|
|
50
|
+
account_origin: https://app.xano.com # optional, for custom/self-hosted accounts
|
|
48
51
|
instance_origin: https://your-instance.xano.io
|
|
49
52
|
access_token: <your-token>
|
|
50
53
|
workspace: 1
|
|
51
|
-
branch:
|
|
52
|
-
|
|
54
|
+
branch: v1
|
|
55
|
+
insecure: false # optional, skip TLS verification
|
|
53
56
|
default: default
|
|
54
57
|
\`\`\`
|
|
55
58
|
|
|
@@ -57,29 +60,31 @@ default: default
|
|
|
57
60
|
|
|
58
61
|
All commands support:
|
|
59
62
|
- \`-p, --profile <name>\` - Use a specific profile (overrides default)
|
|
63
|
+
- \`-c, --config <path>\` - Path to credentials file (default: \`~/.xano/credentials.yaml\`)
|
|
60
64
|
- \`-v, --verbose\` - Show detailed HTTP request/response logs
|
|
61
65
|
|
|
62
66
|
## Environment Variables
|
|
63
67
|
|
|
64
|
-
- \`XANO_PROFILE\` - Override the default profile
|
|
65
|
-
- \`
|
|
68
|
+
- \`XANO_PROFILE\` - Override the default profile (same effect as \`-p\`)
|
|
69
|
+
- \`XANO_CONFIG\` - Override the credentials file path (same effect as \`-c\`)
|
|
70
|
+
- \`XANO_VERBOSE\` - Enable verbose logging (same effect as \`-v\`)
|
|
66
71
|
|
|
67
72
|
## Command Categories
|
|
68
73
|
|
|
69
74
|
| Category | Description |
|
|
70
75
|
|----------|-------------|
|
|
71
76
|
| \`auth\` | Browser-based OAuth login |
|
|
72
|
-
| \`profile
|
|
73
|
-
| \`workspace
|
|
74
|
-
| \`
|
|
75
|
-
| \`
|
|
76
|
-
| \`
|
|
77
|
-
| \`
|
|
78
|
-
| \`
|
|
79
|
-
| \`
|
|
80
|
-
| \`
|
|
81
|
-
| \`platform
|
|
82
|
-
| \`static_host
|
|
77
|
+
| \`profile\` | Manage authentication profiles |
|
|
78
|
+
| \`workspace\` | Sync workspaces (pull/push), git integration |
|
|
79
|
+
| \`sandbox\` | Personal auto-provisioned dev environment (free-tier friendly) |
|
|
80
|
+
| \`branch\` | Manage workspace branches |
|
|
81
|
+
| \`function\` | Manage individual functions |
|
|
82
|
+
| \`release\` | Create and manage named releases |
|
|
83
|
+
| \`tenant\` | Manage tenants, deployments, backups, env vars |
|
|
84
|
+
| \`unit_test\` | Run unit tests |
|
|
85
|
+
| \`workflow_test\` | Run workflow tests |
|
|
86
|
+
| \`platform\` | View available platform versions |
|
|
87
|
+
| \`static_host\` | Deploy static sites |
|
|
83
88
|
| \`update\` | Update CLI to latest version |`,
|
|
84
89
|
ai_hints: `**Important:** The CLI is optional - not all users will have it installed. Before suggesting CLI commands, check if the user has it available or ask if they'd like to install it. The Meta API can accomplish the same tasks programmatically.
|
|
85
90
|
|
|
@@ -89,30 +94,30 @@ All commands support:
|
|
|
89
94
|
- If CLI not installed: Use Meta API endpoints directly
|
|
90
95
|
|
|
91
96
|
**Getting started workflow (if CLI is installed):**
|
|
92
|
-
1. Run \`xano auth\` (browser login) or \`xano profile
|
|
93
|
-
2. Use \`xano workspace
|
|
97
|
+
1. Run \`xano auth\` (browser login) or \`xano profile wizard\` (token-based) to set up authentication
|
|
98
|
+
2. Use \`xano workspace pull -d ./code\` to download workspace code (or \`xano sandbox pull -d ./code\` for the personal dev sandbox)
|
|
94
99
|
3. Edit .xs files locally
|
|
95
|
-
4. Use \`xano workspace
|
|
100
|
+
4. Use \`xano workspace push -d ./code\` to deploy changes (or \`xano sandbox push --review\`)
|
|
96
101
|
|
|
97
102
|
**Profile selection priority:**
|
|
98
103
|
1. \`-p\` flag on command
|
|
99
104
|
2. \`XANO_PROFILE\` environment variable
|
|
100
105
|
3. Default profile in credentials.yaml`,
|
|
101
|
-
related_topics: ["auth", "profile", "workspace", "integration"],
|
|
106
|
+
related_topics: ["auth", "profile", "workspace", "sandbox", "integration"],
|
|
102
107
|
workflows: [
|
|
103
108
|
{
|
|
104
109
|
name: "Initial Setup",
|
|
105
110
|
description: "Set up the CLI for first use",
|
|
106
111
|
steps: [
|
|
107
112
|
"Install: `npm install -g @xano/cli`",
|
|
108
|
-
"Run wizard: `xano profile
|
|
113
|
+
"Run wizard: `xano profile wizard`",
|
|
109
114
|
"Enter your access token when prompted",
|
|
110
115
|
"Select your instance, workspace, and branch",
|
|
111
|
-
"Verify: `xano profile
|
|
116
|
+
"Verify: `xano profile me`"
|
|
112
117
|
],
|
|
113
118
|
example: `npm install -g @xano/cli
|
|
114
|
-
xano profile
|
|
115
|
-
xano profile
|
|
119
|
+
xano profile wizard
|
|
120
|
+
xano profile me`
|
|
116
121
|
}
|
|
117
122
|
]
|
|
118
123
|
};
|
|
@@ -5,59 +5,85 @@ export const staticHostDoc = {
|
|
|
5
5
|
ai_hints: `**Static hosting workflow:**
|
|
6
6
|
1. Build your frontend (React, Vue, etc.)
|
|
7
7
|
2. Zip the build output
|
|
8
|
-
3. Upload with \`static_host
|
|
8
|
+
3. Upload with \`static_host build create\`
|
|
9
9
|
|
|
10
10
|
**Use cases:**
|
|
11
11
|
- Deploy SPAs built with modern frameworks
|
|
12
12
|
- Host static documentation sites
|
|
13
|
-
- Serve frontend that calls your Xano APIs
|
|
14
|
-
|
|
13
|
+
- Serve frontend that calls your Xano APIs
|
|
14
|
+
|
|
15
|
+
**Sandbox tip:** If the user doesn't have a dedicated tenant, suggest \`xano sandbox\` - the free-tier personal dev environment supports static hosting for experimentation.`,
|
|
16
|
+
related_topics: ["workspace", "tenant", "sandbox"],
|
|
15
17
|
commands: [
|
|
16
18
|
{
|
|
17
|
-
name: "static_host
|
|
18
|
-
description: "List all static hosts in workspace",
|
|
19
|
-
usage: "xano static_host
|
|
19
|
+
name: "static_host list",
|
|
20
|
+
description: "List all static hosts in a workspace",
|
|
21
|
+
usage: "xano static_host list [-w <workspace>]",
|
|
20
22
|
flags: [
|
|
21
|
-
{ name: "workspace", short: "w", type: "string", required: false, description: "Workspace ID" }
|
|
23
|
+
{ name: "workspace", short: "w", type: "string", required: false, description: "Workspace ID (optional if set in profile)" },
|
|
24
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" },
|
|
25
|
+
{ name: "page", type: "integer", required: false, default: "1", description: "Page number for pagination" },
|
|
26
|
+
{ name: "per_page", type: "integer", required: false, default: "50", description: "Results per page" }
|
|
22
27
|
],
|
|
23
|
-
examples: [
|
|
28
|
+
examples: [
|
|
29
|
+
"xano static_host list",
|
|
30
|
+
"xano static_host list -w 40",
|
|
31
|
+
"xano static_host list -o json"
|
|
32
|
+
]
|
|
24
33
|
},
|
|
25
34
|
{
|
|
26
|
-
name: "static_host
|
|
27
|
-
description: "Create a new build for a static host",
|
|
28
|
-
usage: "xano static_host
|
|
35
|
+
name: "static_host build create",
|
|
36
|
+
description: "Create a new build for a static host by uploading a ZIP file",
|
|
37
|
+
usage: "xano static_host build create <host_name> -f <file> -n <name> [options]",
|
|
29
38
|
args: [
|
|
30
|
-
{ name: "
|
|
39
|
+
{ name: "host_name", required: true, description: "Static host name" }
|
|
31
40
|
],
|
|
32
41
|
flags: [
|
|
33
|
-
{ name: "file", short: "f", type: "string", required: true, description: "Path to ZIP file" },
|
|
42
|
+
{ name: "file", short: "f", type: "string", required: true, description: "Path to ZIP file to upload" },
|
|
34
43
|
{ name: "name", short: "n", type: "string", required: true, description: "Build name/version" },
|
|
35
44
|
{ name: "description", short: "d", type: "string", required: false, description: "Build description" },
|
|
36
|
-
{ name: "workspace", short: "w", type: "string", required: false, description: "Workspace ID" }
|
|
45
|
+
{ name: "workspace", short: "w", type: "string", required: false, description: "Workspace ID (optional if set in profile)" },
|
|
46
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
37
47
|
],
|
|
38
48
|
examples: [
|
|
39
|
-
"xano static_host
|
|
40
|
-
"xano static_host
|
|
49
|
+
"xano static_host build create my-app -f ./build.zip -n 'v1.0.0'",
|
|
50
|
+
"xano static_host build create my-app -f ./dist.zip -n 'v1.1.0' -d 'Bug fixes'"
|
|
41
51
|
]
|
|
42
52
|
},
|
|
43
53
|
{
|
|
44
|
-
name: "static_host
|
|
54
|
+
name: "static_host build list",
|
|
45
55
|
description: "List all builds for a static host",
|
|
46
|
-
usage: "xano static_host
|
|
56
|
+
usage: "xano static_host build list <host_name> [-w <workspace>]",
|
|
47
57
|
args: [
|
|
48
|
-
{ name: "
|
|
58
|
+
{ name: "host_name", required: true, description: "Static host name" }
|
|
49
59
|
],
|
|
50
|
-
|
|
60
|
+
flags: [
|
|
61
|
+
{ name: "workspace", short: "w", type: "string", required: false, description: "Workspace ID (optional if set in profile)" },
|
|
62
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" },
|
|
63
|
+
{ name: "page", type: "integer", required: false, default: "1", description: "Page number for pagination" },
|
|
64
|
+
{ name: "per_page", type: "integer", required: false, default: "50", description: "Results per page" }
|
|
65
|
+
],
|
|
66
|
+
examples: [
|
|
67
|
+
"xano static_host build list my-app",
|
|
68
|
+
"xano static_host build list my-app -o json"
|
|
69
|
+
]
|
|
51
70
|
},
|
|
52
71
|
{
|
|
53
|
-
name: "static_host
|
|
72
|
+
name: "static_host build get",
|
|
54
73
|
description: "Get details of a specific build",
|
|
55
|
-
usage: "xano static_host
|
|
74
|
+
usage: "xano static_host build get <host_name> <build_id>",
|
|
56
75
|
args: [
|
|
57
|
-
{ name: "
|
|
76
|
+
{ name: "host_name", required: true, description: "Static host name" },
|
|
58
77
|
{ name: "build_id", required: true, description: "Build ID" }
|
|
59
78
|
],
|
|
60
|
-
|
|
79
|
+
flags: [
|
|
80
|
+
{ name: "workspace", short: "w", type: "string", required: false, description: "Workspace ID (optional if set in profile)" },
|
|
81
|
+
{ name: "output", short: "o", type: "string", required: false, default: "summary", description: "Output format: summary or json" }
|
|
82
|
+
],
|
|
83
|
+
examples: [
|
|
84
|
+
"xano static_host build get my-app 52",
|
|
85
|
+
"xano static_host build get my-app 52 -o json"
|
|
86
|
+
]
|
|
61
87
|
}
|
|
62
88
|
],
|
|
63
89
|
workflows: [
|
|
@@ -67,11 +93,11 @@ export const staticHostDoc = {
|
|
|
67
93
|
steps: [
|
|
68
94
|
"Build your app: `npm run build`",
|
|
69
95
|
"Create ZIP: `zip -r build.zip dist/`",
|
|
70
|
-
"Deploy: `xano static_host
|
|
96
|
+
"Deploy: `xano static_host build create my-app -f build.zip -n 'v1.0.0'`"
|
|
71
97
|
],
|
|
72
98
|
example: `npm run build
|
|
73
99
|
zip -r build.zip dist/
|
|
74
|
-
xano static_host
|
|
100
|
+
xano static_host build create my-frontend -f build.zip -n 'v1.0.0' -d 'Initial release'`
|
|
75
101
|
}
|
|
76
102
|
]
|
|
77
103
|
};
|