@lukoweb/apitogo 0.1.102 → 0.1.104
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/cli.js +1 -1
- package/dist/cli/cli.js +873 -869
- package/dist/declarations/lib/components/SiteTitle.d.ts +4 -0
- package/docs/cli/commands.md +3 -3
- package/docs/cli/go-live.md +14 -14
- package/docs/cli/overview.md +19 -19
- package/docs/cli/setup.md +31 -28
- package/docs/cli/shape.md +12 -12
- package/docs/configuration/authentication.md +2 -2
- package/docs/configuration/make-config.mdx +4 -5
- package/docs/configuration/manifest.md +2 -2
- package/docs/configuration/navigation.mdx +1 -1
- package/docs/configuration/overview.md +1 -1
- package/docs/configuration/plans.md +6 -6
- package/docs/deploy/apitogo.md +3 -3
- package/docs/deployment.md +2 -2
- package/docs/guides/custom-pages.md +1 -1
- package/docs/guides/environment-variables.md +1 -1
- package/docs/markdown/frontmatter.md +2 -2
- package/docs/mcp/go-live.md +1 -1
- package/package.json +3 -3
- package/src/lib/components/Header.tsx +2 -4
- package/src/lib/components/SiteTitle.tsx +17 -5
|
@@ -2,5 +2,9 @@ type SiteTitleProps = {
|
|
|
2
2
|
title: string;
|
|
3
3
|
className?: string;
|
|
4
4
|
};
|
|
5
|
+
export declare const splitBrandWordmark: (title: string) => {
|
|
6
|
+
prefix: string;
|
|
7
|
+
accent: string | null;
|
|
8
|
+
};
|
|
5
9
|
export declare const SiteTitle: ({ title, className }: SiteTitleProps) => import("react/jsx-runtime").JSX.Element;
|
|
6
10
|
export {};
|
package/docs/cli/commands.md
CHANGED
|
@@ -76,9 +76,9 @@ These print a redirect message — use the replacement:
|
|
|
76
76
|
|
|
77
77
|
| Removed | Use instead |
|
|
78
78
|
| --------------------------- | ----------------------------------------------------- |
|
|
79
|
-
| `preview` | `apitogo build --preview` or `apitogo run`
|
|
80
|
-
| `remove` | `apitogo teardown --yes`
|
|
81
|
-
| `configure-github-workflow` | `apitogo deploy`
|
|
79
|
+
| `preview` | `npx apitogo build --preview` or `npx apitogo run` |
|
|
80
|
+
| `remove` | `npx apitogo teardown --yes` |
|
|
81
|
+
| `configure-github-workflow` | `npx apitogo deploy` |
|
|
82
82
|
|
|
83
83
|
## Related
|
|
84
84
|
|
package/docs/cli/go-live.md
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: Go live with CLI
|
|
3
3
|
description:
|
|
4
|
-
Publish an APIToGo developer portal with apitogo deploy — platform plans, secrets, and status.
|
|
4
|
+
Publish an APIToGo developer portal with npx apitogo deploy — platform plans, secrets, and status.
|
|
5
5
|
sidebar_icon: rocket
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
**Go live** publishes your shaped portal to APItoGo hosting, optionally deploys the backend, upserts
|
|
9
|
-
gateway plans, and verifies the live site. `apitogo deploy` is the source of truth; MCP
|
|
9
|
+
gateway plans, and verifies the live site. `npx apitogo deploy` is the source of truth; MCP
|
|
10
10
|
`publish_dev_portal` spawns the same CLI.
|
|
11
11
|
|
|
12
12
|
## Before you publish
|
|
@@ -40,11 +40,11 @@ gateway plans, and verifies the live site. `apitogo deploy` is the source of tru
|
|
|
40
40
|
|
|
41
41
|
```bash
|
|
42
42
|
cd ./dev-portal
|
|
43
|
-
apitogo deploy --platform-plan free
|
|
44
|
-
apitogo status
|
|
43
|
+
npx apitogo deploy --platform-plan free
|
|
44
|
+
npx apitogo status
|
|
45
45
|
```
|
|
46
46
|
|
|
47
|
-
`apitogo deploy`:
|
|
47
|
+
`npx apitogo deploy`:
|
|
48
48
|
|
|
49
49
|
- Creates or links the platform project
|
|
50
50
|
- Provisions modules and syncs gateway plans
|
|
@@ -62,11 +62,11 @@ Do not treat warm-pool URLs as live until deploy and status succeed.
|
|
|
62
62
|
## Target specific resources
|
|
63
63
|
|
|
64
64
|
```bash
|
|
65
|
-
apitogo deploy --only apihub
|
|
66
|
-
apitogo deploy --only portal-backend
|
|
67
|
-
apitogo deploy --only portal-frontend
|
|
68
|
-
apitogo deploy --only apihub,portal-frontend
|
|
69
|
-
apitogo deploy --only portal-frontend --force
|
|
65
|
+
npx apitogo deploy --only apihub
|
|
66
|
+
npx apitogo deploy --only portal-backend
|
|
67
|
+
npx apitogo deploy --only portal-frontend
|
|
68
|
+
npx apitogo deploy --only apihub,portal-frontend
|
|
69
|
+
npx apitogo deploy --only portal-frontend --force
|
|
70
70
|
```
|
|
71
71
|
|
|
72
72
|
| Resource | What it updates |
|
|
@@ -93,9 +93,9 @@ Resume state is stored in `.apitogo/publish-state.json`.
|
|
|
93
93
|
## After publish
|
|
94
94
|
|
|
95
95
|
```bash
|
|
96
|
-
apitogo status # account + project + live checks
|
|
97
|
-
apitogo status --skip-live # skip live health probes
|
|
98
|
-
apitogo teardown --yes # delete the platform project
|
|
96
|
+
npx apitogo status # account + project + live checks
|
|
97
|
+
npx apitogo status --skip-live # skip live health probes
|
|
98
|
+
npx apitogo teardown --yes # delete the platform project
|
|
99
99
|
```
|
|
100
100
|
|
|
101
101
|
## Platform plan vs API plans
|
|
@@ -109,7 +109,7 @@ apitogo teardown --yes # delete the platform project
|
|
|
109
109
|
|
|
110
110
|
| Path | Use when |
|
|
111
111
|
| ----------------------- | -------------------------------------------------- |
|
|
112
|
-
| `apitogo deploy`
|
|
112
|
+
| `npx apitogo deploy` | Terminal, CI, scripts — full product go-live |
|
|
113
113
|
| MCP `publish_dev_portal` | Agent-driven go-live with the same engine |
|
|
114
114
|
|
|
115
115
|
## Related
|
package/docs/cli/overview.md
CHANGED
|
@@ -6,19 +6,19 @@ sidebar_icon: terminal
|
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
The **`apitogo`** CLI lets you manage developer portals from the terminal. You scaffold and shape
|
|
9
|
-
local files, preview with `apitogo run`, and publish to APItoGo hosting with `apitogo deploy`.
|
|
9
|
+
local files, preview with `npx apitogo run`, and publish to APItoGo hosting with `npx apitogo deploy`.
|
|
10
10
|
|
|
11
11
|
**First time?** Install and wire credentials → **[Install the CLI](./setup.md)**. Then follow
|
|
12
12
|
[Shape](./shape.md) and [Go live](./go-live.md).
|
|
13
13
|
|
|
14
14
|
## What you get
|
|
15
15
|
|
|
16
|
-
- Scaffold a local portal site (`npx @lukoweb/create-apitogo@latest` or `apitogo init`)
|
|
17
|
-
- Shape backend, OpenAPI, plans, and docs pages via `apitogo config` and file edits
|
|
18
|
-
- Preview locally (`apitogo run`)
|
|
19
|
-
- Publish to APItoGo hosting (`apitogo deploy`) with platform plans **Free**, **Starter**, or
|
|
16
|
+
- Scaffold a local portal site (`npx @lukoweb/create-apitogo@latest` or `npx @lukoweb/apitogo init`)
|
|
17
|
+
- Shape backend, OpenAPI, plans, and docs pages via `npx apitogo config` and file edits
|
|
18
|
+
- Preview locally (`npx apitogo run`)
|
|
19
|
+
- Publish to APItoGo hosting (`npx apitogo deploy`) with platform plans **Free**, **Starter**, or
|
|
20
20
|
**Professional**
|
|
21
|
-
- Check live status (`apitogo status`) and tear down (`apitogo teardown --yes`)
|
|
21
|
+
- Check live status (`npx apitogo status`) and tear down (`npx apitogo teardown --yes`)
|
|
22
22
|
|
|
23
23
|
## Prerequisites
|
|
24
24
|
|
|
@@ -40,17 +40,17 @@ local files, preview with `apitogo run`, and publish to APItoGo hosting with `ap
|
|
|
40
40
|
|
|
41
41
|
| Approach | When it helps |
|
|
42
42
|
| -------- | ------------- |
|
|
43
|
-
| **`apitogo config`** | Wire OpenAPI, custom pages, gateway plans, and site title from the terminal. See [Make config](../configuration/make-config.mdx). |
|
|
43
|
+
| **`npx apitogo config`** | Wire OpenAPI, custom pages, gateway plans, and site title from the terminal. See [Make config](../configuration/make-config.mdx). |
|
|
44
44
|
| **Edit files directly** | Full control — `apitogo.config.json`, `pages/**`, `landing/LandingPage.tsx`, etc. |
|
|
45
45
|
|
|
46
46
|
Common CLI shape tasks:
|
|
47
47
|
|
|
48
48
|
| Change | How |
|
|
49
49
|
| ----------------------------------- | ------------------------------------------------ |
|
|
50
|
-
| Backend runtime | `apitogo config` (backend)
|
|
51
|
-
| OpenAPI + API Reference nav | `apitogo config` (openapi)
|
|
52
|
-
| Custom docs pages | `apitogo config` (page) or add under `pages/`
|
|
53
|
-
| Gateway / API plans | `apitogo config` (plan) or edit manifest
|
|
50
|
+
| Backend runtime | `npx apitogo config` (backend) |
|
|
51
|
+
| OpenAPI + API Reference nav | `npx apitogo config` (openapi) |
|
|
52
|
+
| Custom docs pages | `npx apitogo config` (page) or add under `pages/` |
|
|
53
|
+
| Gateway / API plans | `npx apitogo config` (plan) or edit manifest |
|
|
54
54
|
| Site title | `--title` or edit `apitogo.config.json` |
|
|
55
55
|
| Theme, fonts, branding, projectId | Edit `apitogo.config.json` |
|
|
56
56
|
|
|
@@ -68,16 +68,16 @@ Details: [Manifest](../configuration/manifest.md).
|
|
|
68
68
|
|
|
69
69
|
## CLI vs MCP
|
|
70
70
|
|
|
71
|
-
Both paths use the same config-first model. `apitogo deploy` runs the same engine as MCP
|
|
71
|
+
Both paths use the same config-first model. `npx apitogo deploy` runs the same engine as MCP
|
|
72
72
|
`publish_dev_portal`.
|
|
73
73
|
|
|
74
|
-
| Task | CLI
|
|
75
|
-
| ----------------- |
|
|
76
|
-
| Scaffold | `npm create` / `apitogo init`
|
|
77
|
-
| Shape config | `apitogo config` + file edits
|
|
78
|
-
| Preview | `apitogo run`
|
|
79
|
-
| Publish | `apitogo deploy`
|
|
80
|
-
| Status / teardown | `apitogo status` / `teardown`
|
|
74
|
+
| Task | CLI | MCP (agent) |
|
|
75
|
+
| ----------------- | ---------------------------------------- | ------------------------------ |
|
|
76
|
+
| Scaffold | `npm create` / `npx @lukoweb/apitogo init` | `create_dev_portal` |
|
|
77
|
+
| Shape config | `npx apitogo config` + file edits | `apply_product_intent` (shape) |
|
|
78
|
+
| Preview | `npx apitogo run` | `npm run dev` / preview tool |
|
|
79
|
+
| Publish | `npx apitogo deploy` | `publish_dev_portal` |
|
|
80
|
+
| Status / teardown | `npx apitogo status` / `npx apitogo teardown` | `verify_dev_portal_live` / `teardown_project` |
|
|
81
81
|
|
|
82
82
|
Prefer MCP when an agent should drive changes. Prefer CLI for CI, scripts, or terminal-only
|
|
83
83
|
workflows.
|
package/docs/cli/setup.md
CHANGED
|
@@ -6,35 +6,23 @@ sidebar_icon: terminal
|
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
Use the **`apitogo`** CLI (`@lukoweb/apitogo`) to scaffold a local portal, shape
|
|
9
|
-
`apitogo.config.json`, preview with `apitogo run`, and publish with `apitogo deploy`. Platform
|
|
9
|
+
`apitogo.config.json`, preview with `npx apitogo run`, and publish with `npx apitogo deploy`. Platform
|
|
10
10
|
commands (`deploy`, `status`, `teardown`) use the same engine as MCP `publish_dev_portal`.
|
|
11
11
|
|
|
12
|
+
Examples in these docs use **`npx apitogo`** so they run the project-local CLI. A global install is
|
|
13
|
+
optional and not required.
|
|
14
|
+
|
|
12
15
|
## Prerequisites
|
|
13
16
|
|
|
14
17
|
- **Node.js 20+**
|
|
15
|
-
- Platform API credentials from [apitogo.com](https://apitogo.com) when you run `apitogo deploy` (API
|
|
18
|
+
- Platform API credentials from [apitogo.com](https://apitogo.com) when you run `npx apitogo deploy` (API
|
|
16
19
|
key id + secret)
|
|
17
20
|
|
|
18
21
|
## Install
|
|
19
22
|
|
|
20
23
|
The CLI is the npm package **`@lukoweb/apitogo`**. It exposes the **`apitogo`** binary. Scaffold
|
|
21
|
-
commands add it to your project and `npm install` puts it on `node_modules/.bin`.
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
### Global install
|
|
25
|
-
|
|
26
|
-
```bash
|
|
27
|
-
npm install -g @lukoweb/apitogo
|
|
28
|
-
```
|
|
29
|
-
|
|
30
|
-
Then run `apitogo` from any directory:
|
|
31
|
-
|
|
32
|
-
```bash
|
|
33
|
-
apitogo --help
|
|
34
|
-
```
|
|
35
|
-
|
|
36
|
-
Upgrade later with `npm install -g @lukoweb/apitogo@latest`. Uninstall with
|
|
37
|
-
`npm uninstall -g @lukoweb/apitogo`.
|
|
24
|
+
commands add it to your project and `npm install` puts it on `node_modules/.bin`. Invoke it with
|
|
25
|
+
`npx apitogo`.
|
|
38
26
|
|
|
39
27
|
### New project (recommended)
|
|
40
28
|
|
|
@@ -76,8 +64,8 @@ See `@lukoweb/create-apitogo --help` for package manager and install flags.
|
|
|
76
64
|
|
|
77
65
|
### Scaffold into an existing folder
|
|
78
66
|
|
|
79
|
-
`apitogo init` writes `package.json` with `@lukoweb/apitogo` as a dependency. Run **`npm install`**
|
|
80
|
-
before other `apitogo` commands:
|
|
67
|
+
`npx @lukoweb/apitogo init` writes `package.json` with `@lukoweb/apitogo` as a dependency. Run **`npm install`**
|
|
68
|
+
before other `npx apitogo` commands:
|
|
81
69
|
|
|
82
70
|
```bash
|
|
83
71
|
npx @lukoweb/apitogo init ./dev-portal
|
|
@@ -87,24 +75,39 @@ npx apitogo config
|
|
|
87
75
|
npm run dev
|
|
88
76
|
```
|
|
89
77
|
|
|
90
|
-
`apitogo init` is local only — it does not call the platform. After `config`, run `npm run dev` to
|
|
91
|
-
preview, then `apitogo deploy` when ready to go live.
|
|
78
|
+
`npx @lukoweb/apitogo init` is local only — it does not call the platform. After `config`, run `npm run dev` to
|
|
79
|
+
preview, then `npx apitogo deploy` when ready to go live.
|
|
92
80
|
|
|
93
81
|
### How to run `apitogo`
|
|
94
82
|
|
|
95
83
|
| Situation | Command |
|
|
96
84
|
| ------------------------------------------------------------------- | --------------------------------------------------- |
|
|
97
85
|
| After `npx @lukoweb/create-apitogo` or `npm install` in the project | `npx apitogo <command>` (e.g. `npx apitogo config`) |
|
|
98
|
-
| Same, if `node_modules/.bin` is on your PATH | `apitogo <command>` |
|
|
99
86
|
| One-off, no project yet | `npx @lukoweb/apitogo <command>` |
|
|
100
|
-
| After [global install](#global-install)
|
|
87
|
+
| After [optional global install](#optional-global-install) | `apitogo <command>` anywhere |
|
|
101
88
|
|
|
102
89
|
`npm run dev` / `npm run build` use the project-local CLI via `package.json` scripts — no global
|
|
103
90
|
install required.
|
|
104
91
|
|
|
92
|
+
### Optional global install
|
|
93
|
+
|
|
94
|
+
```bash
|
|
95
|
+
npm install -g @lukoweb/apitogo
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
Then run `apitogo` from any directory:
|
|
99
|
+
|
|
100
|
+
```bash
|
|
101
|
+
apitogo --help
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
Upgrade later with `npm install -g @lukoweb/apitogo@latest`. Uninstall with
|
|
105
|
+
`npm uninstall -g @lukoweb/apitogo`. Prefer `npx apitogo` in projects so each site uses the version
|
|
106
|
+
in its `package.json`.
|
|
107
|
+
|
|
105
108
|
## Platform credentials
|
|
106
109
|
|
|
107
|
-
Export these before `apitogo deploy`, `apitogo status`, or `apitogo teardown`:
|
|
110
|
+
Export these before `npx apitogo deploy`, `npx apitogo status`, or `npx apitogo teardown`:
|
|
108
111
|
|
|
109
112
|
| Variable | Required | Purpose |
|
|
110
113
|
| -------------------- | -------- | ----------------- |
|
|
@@ -132,12 +135,12 @@ You should see `init`, `config`, `run`, `build`, `deploy`, `status`, and `teardo
|
|
|
132
135
|
With credentials set:
|
|
133
136
|
|
|
134
137
|
```bash
|
|
135
|
-
apitogo status
|
|
138
|
+
npx apitogo status
|
|
136
139
|
```
|
|
137
140
|
|
|
138
141
|
## Next
|
|
139
142
|
|
|
140
143
|
- [CLI overview](./overview.md)
|
|
141
144
|
- [Shape](./shape.md) — scaffold and local preview
|
|
142
|
-
- [Go live](./go-live.md) — `apitogo deploy`
|
|
145
|
+
- [Go live](./go-live.md) — `npx apitogo deploy`
|
|
143
146
|
- [Commands](./commands.md) — full catalog
|
package/docs/cli/shape.md
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: Shape with CLI
|
|
3
3
|
description:
|
|
4
|
-
Scaffold and customize a developer portal locally with apitogo init,
|
|
4
|
+
Scaffold and customize a developer portal locally with npx apitogo init, config, and run.
|
|
5
5
|
sidebar_icon: pencil-ruler
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
**Shape** means: create or update a local portal site (OpenAPI, plans, docs pages, auth)
|
|
9
|
-
without publishing. You preview with `apitogo run` or `npm run dev`.
|
|
9
|
+
without publishing. You preview with `npx apitogo run` or `npm run dev`.
|
|
10
10
|
|
|
11
11
|
Requires the **`apitogo`** CLI (`@lukoweb/apitogo`). If you have not installed it yet, see
|
|
12
12
|
[Install the CLI](./setup.md).
|
|
@@ -32,11 +32,11 @@ npx apitogo config
|
|
|
32
32
|
npm run dev
|
|
33
33
|
```
|
|
34
34
|
|
|
35
|
-
`apitogo init` does **not** call the platform. Run `apitogo deploy` when you are ready to go live.
|
|
35
|
+
`npx @lukoweb/apitogo init` does **not** call the platform. Run `npx apitogo deploy` when you are ready to go live.
|
|
36
36
|
|
|
37
|
-
## Interactive config (`apitogo config`)
|
|
37
|
+
## Interactive config (`npx apitogo config`)
|
|
38
38
|
|
|
39
|
-
On a TTY, bare `apitogo config` opens the wizard. Each choice is written immediately; the loop
|
|
39
|
+
On a TTY, bare `npx apitogo config` opens the wizard. Each choice is written immediately; the loop
|
|
40
40
|
continues until you type `done`:
|
|
41
41
|
|
|
42
42
|
| Choice | What it does |
|
|
@@ -46,7 +46,7 @@ continues until you type `done`:
|
|
|
46
46
|
| `page` | Create `pages/<slug>.tsx` and wire it in navigation |
|
|
47
47
|
| `plan` | Add a gateway plan (title, price, rate limit, monthly quota) |
|
|
48
48
|
|
|
49
|
-
Authentication is **on by default** — the wizard does not ask for an auth API URL. `apitogo deploy`
|
|
49
|
+
Authentication is **on by default** — the wizard does not ask for an auth API URL. `npx apitogo deploy`
|
|
50
50
|
fills `VITE_APITOGO_AUTHENTICATION_API_BASE_URL` after the portal backend exists.
|
|
51
51
|
|
|
52
52
|
Fonts and colors are **not** prompted — edit `apitogo.config.json` or see
|
|
@@ -81,7 +81,7 @@ Common flags:
|
|
|
81
81
|
|
|
82
82
|
## Shape by editing files
|
|
83
83
|
|
|
84
|
-
After `apitogo config`, edit the manifest and site files directly:
|
|
84
|
+
After `npx apitogo config`, edit the manifest and site files directly:
|
|
85
85
|
|
|
86
86
|
- **Plans, branding, backend, projectId** — `apitogo.config.json`
|
|
87
87
|
- **Docs pages** — `pages/**/*.mdx` or `.tsx`
|
|
@@ -94,15 +94,15 @@ Never put OIDC or Stripe secrets in `apitogo.config.json`. Use `.env` with
|
|
|
94
94
|
## Preview locally
|
|
95
95
|
|
|
96
96
|
```bash
|
|
97
|
-
apitogo run
|
|
98
|
-
apitogo run --port 4000 --open
|
|
97
|
+
npx apitogo run
|
|
98
|
+
npx apitogo run --port 4000 --open
|
|
99
99
|
```
|
|
100
100
|
|
|
101
101
|
Production build check:
|
|
102
102
|
|
|
103
103
|
```bash
|
|
104
|
-
apitogo build
|
|
105
|
-
apitogo build --preview
|
|
104
|
+
npx apitogo build
|
|
105
|
+
npx apitogo build --preview
|
|
106
106
|
```
|
|
107
107
|
|
|
108
108
|
Shape-phase edits hot-reload when the dev server is running.
|
|
@@ -120,4 +120,4 @@ npm run dev
|
|
|
120
120
|
|
|
121
121
|
## Next
|
|
122
122
|
|
|
123
|
-
When the site looks right, [go live](./go-live.md) with `apitogo deploy`.
|
|
123
|
+
When the site looks right, [go live](./go-live.md) with `npx apitogo deploy`.
|
|
@@ -24,13 +24,13 @@ Set authentication in `apitogo.config.json` (enabled by default on new scaffolds
|
|
|
24
24
|
}
|
|
25
25
|
```
|
|
26
26
|
|
|
27
|
-
Backend API URL (`apitogo deploy` writes this to `.env` after the portal backend is provisioned):
|
|
27
|
+
Backend API URL (`npx apitogo deploy` writes this to `.env` after the portal backend is provisioned):
|
|
28
28
|
|
|
29
29
|
```bash
|
|
30
30
|
VITE_APITOGO_AUTHENTICATION_API_BASE_URL=https://your-dev-portal-api.example.com
|
|
31
31
|
```
|
|
32
32
|
|
|
33
|
-
You do not need to enter this URL in `apitogo config`. Or set `authentication.apiBaseUrl` in JSON /
|
|
33
|
+
You do not need to enter this URL in `npx apitogo config`. Or set `authentication.apiBaseUrl` in JSON /
|
|
34
34
|
`APITOGO_CONFIG_AUTHENTICATION__API_BASE_URL` in `.env` manually.
|
|
35
35
|
|
|
36
36
|
### Local demo mode
|
|
@@ -7,7 +7,7 @@ description:
|
|
|
7
7
|
site settings.
|
|
8
8
|
---
|
|
9
9
|
|
|
10
|
-
The **`apitogo config`** (alias: `make-config`) command writes **`apitogo.config.json`**. It can scaffold a portal
|
|
10
|
+
The **`npx apitogo config`** (alias: `make-config`) command writes **`apitogo.config.json`**. It can scaffold a portal
|
|
11
11
|
project (package.json, tsconfig, landing and user-panel stubs, thin `apitogo.config.tsx`) when those
|
|
12
12
|
files are missing, merge **site / theme / authentication** from flags, run an **interactive wizard**
|
|
13
13
|
on a TTY (apply each change immediately), scan `pages/` for navigation, and wire OpenAPI plus an
|
|
@@ -23,8 +23,7 @@ Install the CLI first — see [Install the CLI](../cli/setup.md). In short:
|
|
|
23
23
|
- **New site:** `npx @lukoweb/create-apitogo@latest` (installs `@lukoweb/apitogo` into the project)
|
|
24
24
|
- **Existing folder:** `npx @lukoweb/apitogo init .` then `npm install`
|
|
25
25
|
|
|
26
|
-
Run config from the project root with `npx apitogo config
|
|
27
|
-
`node_modules/.bin` is on your PATH).
|
|
26
|
+
Run config from the project root with `npx apitogo config`.
|
|
28
27
|
|
|
29
28
|
## What it does
|
|
30
29
|
|
|
@@ -51,7 +50,7 @@ Run config from the project root with `npx apitogo config` (or `apitogo config`
|
|
|
51
50
|
|
|
52
51
|
## Interactive wizard
|
|
53
52
|
|
|
54
|
-
On a TTY, bare `apitogo config` opens the wizard (no `-i` required). `-i` still works as an alias.
|
|
53
|
+
On a TTY, bare `npx apitogo config` opens the wizard (no `-i` required). `-i` still works as an alias.
|
|
55
54
|
Use `--no-interactive` (or pass flags like `--title`) for CI / non-TTY.
|
|
56
55
|
|
|
57
56
|
```bash
|
|
@@ -68,7 +67,7 @@ npx apitogo config
|
|
|
68
67
|
2. **Wrap-up** — links to [docs.apitogo.com](https://docs.apitogo.com) for further configuration
|
|
69
68
|
|
|
70
69
|
The wizard does **not** ask for fonts, colors, logo alt text, or the auth API base URL. Authentication
|
|
71
|
-
stays **enabled**; `apitogo deploy` writes `VITE_APITOGO_AUTHENTICATION_API_BASE_URL` to `.env` after
|
|
70
|
+
stays **enabled**; `npx apitogo deploy` writes `VITE_APITOGO_AUTHENTICATION_API_BASE_URL` to `.env` after
|
|
72
71
|
the portal backend is provisioned.
|
|
73
72
|
|
|
74
73
|
If you add a **paid** plan (`priceAmount > 0`), the CLI warns that **Free platform hosting cannot
|
|
@@ -64,7 +64,7 @@ metadata, with optional `.env` overrides for secrets and local tweaks.
|
|
|
64
64
|
- **Site name / logo:** only `site.title` and `site.logo` (platform branding is derived at publish).
|
|
65
65
|
- **OpenAPI path:** `backend.openApiPath` is derived from `apis[0].input`.
|
|
66
66
|
- **Billing / account plans:** use `modules.userPanel.plans.enabled` and store the plan catalog in
|
|
67
|
-
`modules.userPanel.plans.items`. Add plans with `apitogo config` or edit the manifest by hand.
|
|
67
|
+
`modules.userPanel.plans.items`. Add plans with `npx apitogo config` or edit the manifest by hand.
|
|
68
68
|
See [Gateway plans](./plans.md). Legacy root `plans` is migrated on load.
|
|
69
69
|
- **Docs / API keys:** configure under `modules.docs` and `modules.userPanel.apiKeys` only.
|
|
70
70
|
- **Gateway:** top-level `gateway` (not under `authentication`). See [Gateway CORS](#gateway-cors)
|
|
@@ -96,7 +96,7 @@ when tenant apps or local frontends call the gateway:
|
|
|
96
96
|
| Wildcard | `"*"` is allowed (replaces the list; credentials stay off). |
|
|
97
97
|
| Empty / omitted | Portal playground still works; only extras are missing. |
|
|
98
98
|
|
|
99
|
-
Apply with `apitogo deploy` / `publish_dev_portal` so APIM policies pick up the change.
|
|
99
|
+
Apply with `npx apitogo deploy` / `publish_dev_portal` so APIM policies pick up the change.
|
|
100
100
|
|
|
101
101
|
## Environment variables
|
|
102
102
|
|
|
@@ -58,7 +58,7 @@ one of several types. At the simplest level you may only have links and categori
|
|
|
58
58
|
|
|
59
59
|
## Generate navigation automatically
|
|
60
60
|
|
|
61
|
-
Use the CLI command **`apitogo make-config`** to merge **`navigation`** from your pages folder into
|
|
61
|
+
Use the CLI command **`npx apitogo make-config`** to merge **`navigation`** from your pages folder into
|
|
62
62
|
`apitogo.config.json`. See **[Make config (CLI)](./make-config.md)** for usage. The command does **not**
|
|
63
63
|
change **`redirects`**.
|
|
64
64
|
|
|
@@ -160,7 +160,7 @@ Put navigation in `apitogo.config.json`, or keep large trees in a separate modul
|
|
|
160
160
|
## Related
|
|
161
161
|
|
|
162
162
|
- [Manifest (`apitogo.config.json`)](./manifest.md)
|
|
163
|
-
- [Make config (CLI)](./make-config.mdx) — interactive wizard (`apitogo config`)
|
|
163
|
+
- [Make config (CLI)](./make-config.mdx) — interactive wizard (`npx apitogo config`)
|
|
164
164
|
- [Gateway plans](./plans.md)
|
|
165
165
|
- [Authentication](./authentication.md)
|
|
166
166
|
- [MCP overview](../mcp/overview.md)
|
|
@@ -12,13 +12,13 @@ description:
|
|
|
12
12
|
- **`/account/plans`** — authenticated billing. Sign-in required. Manage and change subscriptions.
|
|
13
13
|
|
|
14
14
|
They are separate from **platform hosting** (Free / Starter / Professional on APItoGo), which you
|
|
15
|
-
select with `apitogo deploy --platform-plan`.
|
|
15
|
+
select with `npx apitogo deploy --platform-plan`.
|
|
16
16
|
|
|
17
17
|
Store the catalog under `modules.userPanel.plans.items` in `apitogo.config.json`.
|
|
18
18
|
|
|
19
19
|
## Shape with the CLI
|
|
20
20
|
|
|
21
|
-
`apitogo config` can add plans interactively (title, price, rate limit, monthly quota). Each plan is
|
|
21
|
+
`npx apitogo config` can add plans interactively (title, price, rate limit, monthly quota). Each plan is
|
|
22
22
|
written immediately. You can also edit the manifest by hand or use MCP `update_dev_portal_manifest`.
|
|
23
23
|
|
|
24
24
|
```bash
|
|
@@ -92,17 +92,17 @@ After OpenAPI is deployed, you can scope a plan to specific operations with
|
|
|
92
92
|
Gateway plans are applied when you run:
|
|
93
93
|
|
|
94
94
|
```bash
|
|
95
|
-
apitogo deploy
|
|
95
|
+
npx apitogo deploy
|
|
96
96
|
```
|
|
97
97
|
|
|
98
|
-
`apitogo deploy` syncs plans from the manifest to the platform gateway. Paid plans require Stripe
|
|
98
|
+
`npx apitogo deploy` syncs plans from the manifest to the platform gateway. Paid plans require Stripe
|
|
99
99
|
secrets in `.env` before publish — see [Go live with CLI](../cli/go-live.md).
|
|
100
100
|
|
|
101
101
|
## Platform hosting vs gateway plans
|
|
102
102
|
|
|
103
103
|
| Kind | What it is | How |
|
|
104
104
|
| ---- | ---------- | --- |
|
|
105
|
-
| **Platform hosting** | APItoGo bill for hosting your portal + API hub | `apitogo deploy --platform-plan` |
|
|
105
|
+
| **Platform hosting** | APItoGo bill for hosting your portal + API hub | `npx apitogo deploy --platform-plan` |
|
|
106
106
|
| **Gateway / API plans** | What your customers pay for API access | `modules.userPanel.plans.items` |
|
|
107
107
|
|
|
108
108
|
### Free platform limitations
|
|
@@ -113,7 +113,7 @@ The **Free** platform plan cannot:
|
|
|
113
113
|
- Attach a **custom domain** to the dev portal
|
|
114
114
|
|
|
115
115
|
Use **Starter** or **Professional** for paid API tiers, Stripe checkout, and custom domains. If your
|
|
116
|
-
manifest has paid plans and you try `apitogo deploy --platform-plan free`, apply is blocked until you
|
|
116
|
+
manifest has paid plans and you try `npx apitogo deploy --platform-plan free`, apply is blocked until you
|
|
117
117
|
upgrade or zero/remove those paid plans.
|
|
118
118
|
|
|
119
119
|
## Related
|
package/docs/deploy/apitogo.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Deploy with APIToGo CLI
|
|
2
2
|
|
|
3
|
-
Platform publish is **`apitogo deploy`** — the same engine as MCP `publish_dev_portal`.
|
|
3
|
+
Platform publish is **`npx apitogo deploy`** — the same engine as MCP `publish_dev_portal`.
|
|
4
4
|
|
|
5
5
|
Full walkthrough (prerequisites, secrets, `--only`, status, teardown):
|
|
6
6
|
|
|
@@ -12,6 +12,6 @@ Quick reference:
|
|
|
12
12
|
export APITOGO_API_KEY_ID=apk_...
|
|
13
13
|
export APITOGO_API_SECRET=...
|
|
14
14
|
cd ./dev-portal
|
|
15
|
-
apitogo deploy --platform-plan free
|
|
16
|
-
apitogo status
|
|
15
|
+
npx apitogo deploy --platform-plan free
|
|
16
|
+
npx apitogo status
|
|
17
17
|
```
|
package/docs/deployment.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
| Path | Docs |
|
|
4
4
|
| --- | --- |
|
|
5
|
-
| **CLI** (`apitogo deploy`) | [Go live with CLI](./cli/go-live.md) |
|
|
5
|
+
| **CLI** (`npx apitogo deploy`) | [Go live with CLI](./cli/go-live.md) |
|
|
6
6
|
| **MCP / agents** | [Go live](./mcp/go-live.md) |
|
|
7
7
|
|
|
8
|
-
Local-only builds: `apitogo build` (optional `--preview`). Platform publish is always `apitogo deploy`.
|
|
8
|
+
Local-only builds: `npx apitogo build` (optional `--preview`). Platform publish is always `npx apitogo deploy`.
|
|
@@ -13,7 +13,7 @@ Start by creating the page you want to add.
|
|
|
13
13
|
|
|
14
14
|
## CLI scaffold
|
|
15
15
|
|
|
16
|
-
`apitogo config` can create a starter page under `pages/` and wire it into navigation immediately.
|
|
16
|
+
`npx apitogo config` can create a starter page under `pages/` and wire it into navigation immediately.
|
|
17
17
|
Choose `page` in the wizard loop, then edit the generated `.tsx` file.
|
|
18
18
|
|
|
19
19
|
Predefined UI components (Callout, Card, Button, Heading, and more) are documented under
|
|
@@ -21,7 +21,7 @@ APIToGo uses Vite’s [env and mode](https://vite.dev/guide/env-and-mode) model,
|
|
|
21
21
|
Nested overrides use `__` path segments (SCREAMING_SNAKE). See [Manifest](../configuration/manifest.md).
|
|
22
22
|
|
|
23
23
|
**Never commit** OIDC client secrets or Stripe keys. MCP never puts secrets in chat — you write them
|
|
24
|
-
to `.env` before [go-live](../mcp/go-live.md) or `apitogo deploy` ([CLI go-live](../cli/go-live.md)).
|
|
24
|
+
to `.env` before [go-live](../mcp/go-live.md) or `npx apitogo deploy` ([CLI go-live](../cli/go-live.md)).
|
|
25
25
|
|
|
26
26
|
Example:
|
|
27
27
|
|
|
@@ -122,8 +122,8 @@ draft: true
|
|
|
122
122
|
|
|
123
123
|
When `draft: true` is set:
|
|
124
124
|
|
|
125
|
-
- The document will be visible when running `apitogo run`
|
|
126
|
-
- The document will be excluded from builds created with `apitogo build`
|
|
125
|
+
- The document will be visible when running `npx apitogo run`
|
|
126
|
+
- The document will be excluded from builds created with `npx apitogo build`
|
|
127
127
|
- The document won't appear in the navigation or be accessible via URL in production
|
|
128
128
|
|
|
129
129
|
:::
|
package/docs/mcp/go-live.md
CHANGED
|
@@ -88,7 +88,7 @@ shape → deploy_backend → publish_dev_portal(skipBackendRedeploy: true)
|
|
|
88
88
|
| Path | Use when |
|
|
89
89
|
| ---------------------------- | ----------------------------------------------------- |
|
|
90
90
|
| MCP `publish_dev_portal` | Full product go-live (plans, auth, hosting, verify) |
|
|
91
|
-
| CLI `apitogo deploy`
|
|
91
|
+
| CLI `npx apitogo deploy` | Publish config to platform (apihub + portal) |
|
|
92
92
|
|
|
93
93
|
See [Go live with CLI](../cli/go-live.md).
|
|
94
94
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lukoweb/apitogo",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.104",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"sideEffects": [
|
|
6
6
|
"**/*.css",
|
|
@@ -23,8 +23,8 @@
|
|
|
23
23
|
"docs"
|
|
24
24
|
],
|
|
25
25
|
"bin": {
|
|
26
|
-
"
|
|
27
|
-
"
|
|
26
|
+
"apitogo": "./cli.js",
|
|
27
|
+
"zudoku": "./cli.js"
|
|
28
28
|
},
|
|
29
29
|
"exports": {
|
|
30
30
|
".": {
|
|
@@ -176,7 +176,7 @@ export const Header = memo(function HeaderInner() {
|
|
|
176
176
|
<Link
|
|
177
177
|
to={site?.logo?.href ?? "/"}
|
|
178
178
|
reloadDocument={site?.logo?.reloadDocument ?? true}
|
|
179
|
-
className="shrink-0"
|
|
179
|
+
className="shrink-0 no-underline"
|
|
180
180
|
>
|
|
181
181
|
<div className="flex items-center gap-3.5">
|
|
182
182
|
{site?.logo ? (
|
|
@@ -200,9 +200,7 @@ export const Header = memo(function HeaderInner() {
|
|
|
200
200
|
) : null}
|
|
201
201
|
</>
|
|
202
202
|
) : (
|
|
203
|
-
<
|
|
204
|
-
{site?.title}
|
|
205
|
-
</span>
|
|
203
|
+
<SiteTitle title={site?.title ?? ""} />
|
|
206
204
|
)}
|
|
207
205
|
</div>
|
|
208
206
|
</Link>
|
|
@@ -5,16 +5,28 @@ type SiteTitleProps = {
|
|
|
5
5
|
className?: string;
|
|
6
6
|
};
|
|
7
7
|
|
|
8
|
+
const API_SUFFIX = /^(.*?)(?:\s*)(API)$/i;
|
|
9
|
+
|
|
10
|
+
export const splitBrandWordmark = (title: string) => {
|
|
11
|
+
const match = title.trim().match(API_SUFFIX);
|
|
12
|
+
if (!match?.[1]) {
|
|
13
|
+
return { prefix: title, accent: null as string | null };
|
|
14
|
+
}
|
|
15
|
+
return { prefix: match[1], accent: match[2] ?? "API" };
|
|
16
|
+
};
|
|
17
|
+
|
|
8
18
|
export const SiteTitle = ({ title, className }: SiteTitleProps) => {
|
|
19
|
+
const { prefix, accent } = splitBrandWordmark(title);
|
|
20
|
+
|
|
9
21
|
return (
|
|
10
|
-
<
|
|
22
|
+
<span
|
|
11
23
|
className={cn(
|
|
12
|
-
"
|
|
24
|
+
"font-sans text-[1.4rem] font-extrabold tracking-[-0.03em] text-foreground",
|
|
13
25
|
className,
|
|
14
26
|
)}
|
|
15
|
-
style={{ fontFamily: '"Space Grotesk", var(--font-sans, sans-serif)' }}
|
|
16
27
|
>
|
|
17
|
-
{
|
|
18
|
-
|
|
28
|
+
{prefix}
|
|
29
|
+
{accent ? <span className="text-primary">{accent}</span> : null}
|
|
30
|
+
</span>
|
|
19
31
|
);
|
|
20
32
|
};
|