authflow-cli 0.1.0 → 0.1.1
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 +11 -6
- package/dist/commands/mcp.js +1 -1
- package/dist/commands/mcp.js.map +1 -1
- package/dist/commands/signup.js +3 -3
- package/dist/commands/signup.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -8,14 +8,19 @@ Minimal TypeScript CLI for Authflow Rail onboarding. Wraps the public admin and
|
|
|
8
8
|
|
|
9
9
|
## Install
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
The command is `authflow`. The npm package is [`authflow-cli`](https://www.npmjs.com/package/authflow-cli) (npm blocked the unscoped name `authflow`). No repo checkout is required:
|
|
12
12
|
|
|
13
13
|
```bash
|
|
14
|
-
npx -y authflow-cli --help
|
|
15
|
-
npx -y authflow-cli init --slug video --price 900 --credits 12
|
|
14
|
+
npx -y -p authflow-cli authflow --help
|
|
15
|
+
npx -y -p authflow-cli authflow init --slug video --price 900 --credits 12
|
|
16
16
|
```
|
|
17
17
|
|
|
18
|
-
Or install globally
|
|
18
|
+
Or install globally and drop the `npx` prefix:
|
|
19
|
+
|
|
20
|
+
```bash
|
|
21
|
+
npm install -g authflow-cli
|
|
22
|
+
authflow --help
|
|
23
|
+
```
|
|
19
24
|
|
|
20
25
|
## From this repo (development)
|
|
21
26
|
|
|
@@ -52,7 +57,7 @@ Mints a per-tenant admin API key. This is how a creator gets `AUTHFLOW_ADMIN_API
|
|
|
52
57
|
|
|
53
58
|
```bash
|
|
54
59
|
export AUTHFLOW_ISSUER=https://app-rail-railstg-4joi6asiofdcm.azurewebsites.net
|
|
55
|
-
npx -y authflow-cli signup --email you@example.com
|
|
60
|
+
npx -y -p authflow-cli authflow signup --email you@example.com
|
|
56
61
|
```
|
|
57
62
|
|
|
58
63
|
The key (`afa_test_` on staging, `afa_live_` in production) is shown once and written to `.env.local` by default. It can only register and manage slugs created with that key. The operator bearer still exists as a super-admin.
|
|
@@ -225,7 +230,7 @@ Add it to Cursor or Claude Desktop:
|
|
|
225
230
|
"mcpServers": {
|
|
226
231
|
"authflow": {
|
|
227
232
|
"command": "npx",
|
|
228
|
-
"args": ["-y", "authflow-cli", "mcp"],
|
|
233
|
+
"args": ["-y", "-p", "authflow-cli", "authflow", "mcp"],
|
|
229
234
|
"env": {
|
|
230
235
|
"AUTHFLOW_ISSUER": "https://app-rail-railstg-4joi6asiofdcm.azurewebsites.net",
|
|
231
236
|
"AUTHFLOW_ADMIN_API_KEY": "…"
|
package/dist/commands/mcp.js
CHANGED
|
@@ -9,7 +9,7 @@ export function mcpCommand(program) {
|
|
|
9
9
|
"against the codebase it already has open:",
|
|
10
10
|
"",
|
|
11
11
|
' { "mcpServers": { "authflow": {',
|
|
12
|
-
' "command": "npx", "args": ["-y", "authflow-cli", "mcp"],',
|
|
12
|
+
' "command": "npx", "args": ["-y", "-p", "authflow-cli", "authflow", "mcp"],',
|
|
13
13
|
' "env": { "AUTHFLOW_ISSUER": "https://…", "AUTHFLOW_ADMIN_API_KEY": "…" } } } }',
|
|
14
14
|
"",
|
|
15
15
|
"Mint AUTHFLOW_ADMIN_API_KEY with `authflow signup --email you@example.com` if you do not",
|
package/dist/commands/mcp.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mcp.js","sourceRoot":"","sources":["../../src/commands/mcp.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAElD,MAAM,UAAU,UAAU,CAAC,OAAgB;IACzC,OAAO;SACJ,OAAO,CAAC,KAAK,CAAC;SACd,WAAW,CAAC,iDAAiD,CAAC;SAC9D,WAAW,CACV,OAAO,EACP;QACE,EAAE;QACF,sFAAsF;QACtF,2CAA2C;QAC3C,EAAE;QACF,mCAAmC;QACnC,
|
|
1
|
+
{"version":3,"file":"mcp.js","sourceRoot":"","sources":["../../src/commands/mcp.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAElD,MAAM,UAAU,UAAU,CAAC,OAAgB;IACzC,OAAO;SACJ,OAAO,CAAC,KAAK,CAAC;SACd,WAAW,CAAC,iDAAiD,CAAC;SAC9D,WAAW,CACV,OAAO,EACP;QACE,EAAE;QACF,sFAAsF;QACtF,2CAA2C;QAC3C,EAAE;QACF,mCAAmC;QACnC,kFAAkF;QAClF,sFAAsF;QACtF,EAAE;QACF,0FAA0F;QAC1F,+EAA+E;QAC/E,EAAE;QACF,yEAAyE;KAC1E,CAAC,IAAI,CAAC,IAAI,CAAC,CACb;SACA,MAAM,CAAC,KAAK,IAAI,EAAE;QACjB,MAAM,cAAc,EAAE,CAAC;IACzB,CAAC,CAAC,CAAC;AACP,CAAC"}
|
package/dist/commands/signup.js
CHANGED
|
@@ -29,7 +29,7 @@ export function signupCommand(program) {
|
|
|
29
29
|
mcpServers: {
|
|
30
30
|
authflow: {
|
|
31
31
|
command: "npx",
|
|
32
|
-
args: ["-y", "authflow-cli", "mcp"],
|
|
32
|
+
args: ["-y", "-p", "authflow-cli", "authflow", "mcp"],
|
|
33
33
|
env: {
|
|
34
34
|
AUTHFLOW_ISSUER: receipt.issuer,
|
|
35
35
|
AUTHFLOW_ADMIN_API_KEY: storedAt ? `<from ${storedAt}>` : receipt.admin_api_key,
|
|
@@ -43,8 +43,8 @@ export function signupCommand(program) {
|
|
|
43
43
|
mcp_config: mcpConfig,
|
|
44
44
|
next_steps: [
|
|
45
45
|
storedAt
|
|
46
|
-
? `Load ${storedAt} (or copy the key into Cursor's MCP env) and run: npx -y authflow-cli init --slug <your-slug>`
|
|
47
|
-
: "Store the admin_api_key, then: npx -y authflow-cli init --slug <your-slug>",
|
|
46
|
+
? `Load ${storedAt} (or copy the key into Cursor's MCP env) and run: npx -y -p authflow-cli authflow init --slug <your-slug>`
|
|
47
|
+
: "Store the admin_api_key, then: npx -y -p authflow-cli authflow init --slug <your-slug>",
|
|
48
48
|
"Or paste mcp_config into Cursor and let the agent finish onboarding.",
|
|
49
49
|
],
|
|
50
50
|
}, null, 2) + "\n");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"signup.js","sourceRoot":"","sources":["../../src/commands/signup.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC7C,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AASjD,MAAM,UAAU,aAAa,CAAC,OAAgB;IAC5C,OAAO;SACJ,OAAO,CAAC,QAAQ,CAAC;SACjB,WAAW,CAAC,8CAA8C,CAAC;SAC3D,cAAc,CAAC,mBAAmB,EAAE,4BAA4B,CAAC;SACjE,MAAM,CAAC,gBAAgB,EAAE,4CAA4C,CAAC;SACtE,MAAM,CAAC,iBAAiB,EAAE,oDAAoD,EAAE,IAAI,CAAC;SACrF,MAAM,CAAC,oBAAoB,EAAE,6CAA6C,CAAC;SAC3E,MAAM,CAAC,6BAA6B,EAAE,mCAAmC,CAAC;SAC1E,WAAW,CACV,OAAO,EACP;QACE,EAAE;QACF,0EAA0E;QAC1E,qEAAqE;KACtE,CAAC,IAAI,CAAC,IAAI,CAAC,CACb;SACA,MAAM,CAAC,KAAK,EAAE,IAAmB,EAAE,EAAE;QACpC,MAAM,MAAM,GAAG,aAAa,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;QAC1C,MAAM,OAAO,GAAG,MAAM,YAAY,CAAC,MAAM,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC;QAEvD,IAAI,QAA4B,CAAC;QACjC,IAAI,IAAI,CAAC,YAAY,KAAK,KAAK,EAAE,CAAC;YAChC,QAAQ,GAAG,MAAM,gBAAgB,CAAC;gBAChC,KAAK,EAAE,OAAO,CAAC,aAAa;gBAC5B,WAAW,EAAE,IAAI,CAAC,iBAAiB;aACpC,CAAC,CAAC;QACL,CAAC;QAED,MAAM,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