@getfrontline/cli 1.0.0
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 +319 -0
- package/dist/assets/logo3.png +0 -0
- package/dist/commands/agents/analytics.d.ts +3 -0
- package/dist/commands/agents/analytics.d.ts.map +1 -0
- package/dist/commands/agents/analytics.js +67 -0
- package/dist/commands/agents/analytics.js.map +1 -0
- package/dist/commands/agents/flows.d.ts +3 -0
- package/dist/commands/agents/flows.d.ts.map +1 -0
- package/dist/commands/agents/flows.js +47 -0
- package/dist/commands/agents/flows.js.map +1 -0
- package/dist/commands/agents/list.d.ts +3 -0
- package/dist/commands/agents/list.d.ts.map +1 -0
- package/dist/commands/agents/list.js +46 -0
- package/dist/commands/agents/list.js.map +1 -0
- package/dist/commands/api/raw.d.ts +3 -0
- package/dist/commands/api/raw.d.ts.map +1 -0
- package/dist/commands/api/raw.js +54 -0
- package/dist/commands/api/raw.js.map +1 -0
- package/dist/commands/auth/login.d.ts +3 -0
- package/dist/commands/auth/login.d.ts.map +1 -0
- package/dist/commands/auth/login.js +39 -0
- package/dist/commands/auth/login.js.map +1 -0
- package/dist/commands/auth/logout.d.ts +3 -0
- package/dist/commands/auth/logout.d.ts.map +1 -0
- package/dist/commands/auth/logout.js +16 -0
- package/dist/commands/auth/logout.js.map +1 -0
- package/dist/commands/auth/profiles.d.ts +3 -0
- package/dist/commands/auth/profiles.d.ts.map +1 -0
- package/dist/commands/auth/profiles.js +72 -0
- package/dist/commands/auth/profiles.js.map +1 -0
- package/dist/commands/auth/whoami.d.ts +3 -0
- package/dist/commands/auth/whoami.d.ts.map +1 -0
- package/dist/commands/auth/whoami.js +46 -0
- package/dist/commands/auth/whoami.js.map +1 -0
- package/dist/commands/billing/get.d.ts +3 -0
- package/dist/commands/billing/get.d.ts.map +1 -0
- package/dist/commands/billing/get.js +42 -0
- package/dist/commands/billing/get.js.map +1 -0
- package/dist/commands/object/aggregation.d.ts +3 -0
- package/dist/commands/object/aggregation.d.ts.map +1 -0
- package/dist/commands/object/aggregation.js +78 -0
- package/dist/commands/object/aggregation.js.map +1 -0
- package/dist/commands/object/export.d.ts +3 -0
- package/dist/commands/object/export.d.ts.map +1 -0
- package/dist/commands/object/export.js +98 -0
- package/dist/commands/object/export.js.map +1 -0
- package/dist/commands/object/field.d.ts +3 -0
- package/dist/commands/object/field.d.ts.map +1 -0
- package/dist/commands/object/field.js +76 -0
- package/dist/commands/object/field.js.map +1 -0
- package/dist/commands/object/file.d.ts +3 -0
- package/dist/commands/object/file.d.ts.map +1 -0
- package/dist/commands/object/file.js +105 -0
- package/dist/commands/object/file.js.map +1 -0
- package/dist/commands/object/index.d.ts +3 -0
- package/dist/commands/object/index.d.ts.map +1 -0
- package/dist/commands/object/index.js +136 -0
- package/dist/commands/object/index.js.map +1 -0
- package/dist/commands/object/note.d.ts +3 -0
- package/dist/commands/object/note.d.ts.map +1 -0
- package/dist/commands/object/note.js +62 -0
- package/dist/commands/object/note.js.map +1 -0
- package/dist/commands/object/option.d.ts +3 -0
- package/dist/commands/object/option.d.ts.map +1 -0
- package/dist/commands/object/option.js +78 -0
- package/dist/commands/object/option.js.map +1 -0
- package/dist/commands/object/record-type.d.ts +3 -0
- package/dist/commands/object/record-type.d.ts.map +1 -0
- package/dist/commands/object/record-type.js +73 -0
- package/dist/commands/object/record-type.js.map +1 -0
- package/dist/commands/object/record.d.ts +3 -0
- package/dist/commands/object/record.d.ts.map +1 -0
- package/dist/commands/object/record.js +128 -0
- package/dist/commands/object/record.js.map +1 -0
- package/dist/commands/object/relation.d.ts +3 -0
- package/dist/commands/object/relation.d.ts.map +1 -0
- package/dist/commands/object/relation.js +73 -0
- package/dist/commands/object/relation.js.map +1 -0
- package/dist/commands/object/task.d.ts +3 -0
- package/dist/commands/object/task.d.ts.map +1 -0
- package/dist/commands/object/task.js +88 -0
- package/dist/commands/object/task.js.map +1 -0
- package/dist/commands/object/view.d.ts +3 -0
- package/dist/commands/object/view.d.ts.map +1 -0
- package/dist/commands/object/view.js +118 -0
- package/dist/commands/object/view.js.map +1 -0
- package/dist/commands/setup/claudeSkills.d.ts +3 -0
- package/dist/commands/setup/claudeSkills.d.ts.map +1 -0
- package/dist/commands/setup/claudeSkills.js +84 -0
- package/dist/commands/setup/claudeSkills.js.map +1 -0
- package/dist/commands/table/aggregation.d.ts +3 -0
- package/dist/commands/table/aggregation.d.ts.map +1 -0
- package/dist/commands/table/aggregation.js +78 -0
- package/dist/commands/table/aggregation.js.map +1 -0
- package/dist/commands/table/export.d.ts +3 -0
- package/dist/commands/table/export.d.ts.map +1 -0
- package/dist/commands/table/export.js +97 -0
- package/dist/commands/table/export.js.map +1 -0
- package/dist/commands/table/field.d.ts +3 -0
- package/dist/commands/table/field.d.ts.map +1 -0
- package/dist/commands/table/field.js +76 -0
- package/dist/commands/table/field.js.map +1 -0
- package/dist/commands/table/file.d.ts +3 -0
- package/dist/commands/table/file.d.ts.map +1 -0
- package/dist/commands/table/file.js +106 -0
- package/dist/commands/table/file.js.map +1 -0
- package/dist/commands/table/index.d.ts +3 -0
- package/dist/commands/table/index.d.ts.map +1 -0
- package/dist/commands/table/index.js +142 -0
- package/dist/commands/table/index.js.map +1 -0
- package/dist/commands/table/note.d.ts +3 -0
- package/dist/commands/table/note.d.ts.map +1 -0
- package/dist/commands/table/note.js +62 -0
- package/dist/commands/table/note.js.map +1 -0
- package/dist/commands/table/option.d.ts +3 -0
- package/dist/commands/table/option.d.ts.map +1 -0
- package/dist/commands/table/option.js +78 -0
- package/dist/commands/table/option.js.map +1 -0
- package/dist/commands/table/relation.d.ts +3 -0
- package/dist/commands/table/relation.d.ts.map +1 -0
- package/dist/commands/table/relation.js +74 -0
- package/dist/commands/table/relation.js.map +1 -0
- package/dist/commands/table/row.d.ts +3 -0
- package/dist/commands/table/row.d.ts.map +1 -0
- package/dist/commands/table/row.js +124 -0
- package/dist/commands/table/row.js.map +1 -0
- package/dist/commands/table/task.d.ts +3 -0
- package/dist/commands/table/task.d.ts.map +1 -0
- package/dist/commands/table/task.js +88 -0
- package/dist/commands/table/task.js.map +1 -0
- package/dist/commands/workflows/analytics.d.ts +3 -0
- package/dist/commands/workflows/analytics.d.ts.map +1 -0
- package/dist/commands/workflows/analytics.js +60 -0
- package/dist/commands/workflows/analytics.js.map +1 -0
- package/dist/commands/workflows/list.d.ts +3 -0
- package/dist/commands/workflows/list.d.ts.map +1 -0
- package/dist/commands/workflows/list.js +47 -0
- package/dist/commands/workflows/list.js.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +73 -0
- package/dist/index.js.map +1 -0
- package/dist/lib/auth.d.ts +13 -0
- package/dist/lib/auth.d.ts.map +1 -0
- package/dist/lib/auth.js +40 -0
- package/dist/lib/auth.js.map +1 -0
- package/dist/lib/config.d.ts +28 -0
- package/dist/lib/config.d.ts.map +1 -0
- package/dist/lib/config.js +77 -0
- package/dist/lib/config.js.map +1 -0
- package/dist/lib/errors.d.ts +13 -0
- package/dist/lib/errors.d.ts.map +1 -0
- package/dist/lib/errors.js +31 -0
- package/dist/lib/errors.js.map +1 -0
- package/dist/lib/globalOpts.d.ts +23 -0
- package/dist/lib/globalOpts.d.ts.map +1 -0
- package/dist/lib/globalOpts.js +40 -0
- package/dist/lib/globalOpts.js.map +1 -0
- package/dist/lib/helpEpilog.d.ts +18 -0
- package/dist/lib/helpEpilog.d.ts.map +1 -0
- package/dist/lib/helpEpilog.js +56 -0
- package/dist/lib/helpEpilog.js.map +1 -0
- package/dist/lib/httpClient.d.ts +50 -0
- package/dist/lib/httpClient.d.ts.map +1 -0
- package/dist/lib/httpClient.js +196 -0
- package/dist/lib/httpClient.js.map +1 -0
- package/dist/lib/output.d.ts +38 -0
- package/dist/lib/output.d.ts.map +1 -0
- package/dist/lib/output.js +131 -0
- package/dist/lib/output.js.map +1 -0
- package/dist/max/browserLogin.d.ts +15 -0
- package/dist/max/browserLogin.d.ts.map +1 -0
- package/dist/max/browserLogin.js +164 -0
- package/dist/max/browserLogin.js.map +1 -0
- package/dist/max/commands/auth/login.d.ts +3 -0
- package/dist/max/commands/auth/login.d.ts.map +1 -0
- package/dist/max/commands/auth/login.js +58 -0
- package/dist/max/commands/auth/login.js.map +1 -0
- package/dist/max/commands/auth/logout.d.ts +3 -0
- package/dist/max/commands/auth/logout.d.ts.map +1 -0
- package/dist/max/commands/auth/logout.js +23 -0
- package/dist/max/commands/auth/logout.js.map +1 -0
- package/dist/max/commands/auth/whoami.d.ts +3 -0
- package/dist/max/commands/auth/whoami.d.ts.map +1 -0
- package/dist/max/commands/auth/whoami.js +46 -0
- package/dist/max/commands/auth/whoami.js.map +1 -0
- package/dist/max/commands/chat/repl.d.ts +3 -0
- package/dist/max/commands/chat/repl.d.ts.map +1 -0
- package/dist/max/commands/chat/repl.js +104 -0
- package/dist/max/commands/chat/repl.js.map +1 -0
- package/dist/max/commands/chat/send.d.ts +25 -0
- package/dist/max/commands/chat/send.d.ts.map +1 -0
- package/dist/max/commands/chat/send.js +163 -0
- package/dist/max/commands/chat/send.js.map +1 -0
- package/dist/max/commands/conversations/abort.d.ts +3 -0
- package/dist/max/commands/conversations/abort.d.ts.map +1 -0
- package/dist/max/commands/conversations/abort.js +55 -0
- package/dist/max/commands/conversations/abort.js.map +1 -0
- package/dist/max/commands/conversations/get.d.ts +3 -0
- package/dist/max/commands/conversations/get.d.ts.map +1 -0
- package/dist/max/commands/conversations/get.js +42 -0
- package/dist/max/commands/conversations/get.js.map +1 -0
- package/dist/max/commands/conversations/index.d.ts +3 -0
- package/dist/max/commands/conversations/index.d.ts.map +1 -0
- package/dist/max/commands/conversations/index.js +16 -0
- package/dist/max/commands/conversations/index.js.map +1 -0
- package/dist/max/commands/conversations/list.d.ts +3 -0
- package/dist/max/commands/conversations/list.d.ts.map +1 -0
- package/dist/max/commands/conversations/list.js +35 -0
- package/dist/max/commands/conversations/list.js.map +1 -0
- package/dist/max/commands/conversations/update.d.ts +3 -0
- package/dist/max/commands/conversations/update.d.ts.map +1 -0
- package/dist/max/commands/conversations/update.js +53 -0
- package/dist/max/commands/conversations/update.js.map +1 -0
- package/dist/max/jwtDecode.d.ts +5 -0
- package/dist/max/jwtDecode.d.ts.map +1 -0
- package/dist/max/jwtDecode.js +19 -0
- package/dist/max/jwtDecode.js.map +1 -0
- package/dist/max/lib/auth.d.ts +20 -0
- package/dist/max/lib/auth.d.ts.map +1 -0
- package/dist/max/lib/auth.js +53 -0
- package/dist/max/lib/auth.js.map +1 -0
- package/dist/max/lib/httpClient.d.ts +25 -0
- package/dist/max/lib/httpClient.d.ts.map +1 -0
- package/dist/max/lib/httpClient.js +138 -0
- package/dist/max/lib/httpClient.js.map +1 -0
- package/dist/max/lib/maxResponse.d.ts +30 -0
- package/dist/max/lib/maxResponse.d.ts.map +1 -0
- package/dist/max/lib/maxResponse.js +132 -0
- package/dist/max/lib/maxResponse.js.map +1 -0
- package/dist/max/lib/publicApiPaths.d.ts +12 -0
- package/dist/max/lib/publicApiPaths.d.ts.map +1 -0
- package/dist/max/lib/publicApiPaths.js +15 -0
- package/dist/max/lib/publicApiPaths.js.map +1 -0
- package/dist/max/maxConfig.d.ts +31 -0
- package/dist/max/maxConfig.d.ts.map +1 -0
- package/dist/max/maxConfig.js +50 -0
- package/dist/max/maxConfig.js.map +1 -0
- package/dist/max/ui/banner.d.ts +3 -0
- package/dist/max/ui/banner.d.ts.map +1 -0
- package/dist/max/ui/banner.js +96 -0
- package/dist/max/ui/banner.js.map +1 -0
- package/dist/max.d.ts +3 -0
- package/dist/max.d.ts.map +1 -0
- package/dist/max.js +94 -0
- package/dist/max.js.map +1 -0
- package/dist/scripts/postinstall.d.ts +8 -0
- package/dist/scripts/postinstall.d.ts.map +1 -0
- package/dist/scripts/postinstall.js +149 -0
- package/dist/scripts/postinstall.js.map +1 -0
- package/dist/skills/aggregations/SKILL.md +122 -0
- package/dist/skills/auth-and-profiles/SKILL.md +102 -0
- package/dist/skills/crm-setup/SKILL.md +385 -0
- package/dist/skills/crud-operations/SKILL.md +287 -0
- package/dist/skills/export-and-delete/SKILL.md +96 -0
- package/dist/skills/files/SKILL.md +70 -0
- package/dist/skills/filter-and-query/SKILL.md +199 -0
- package/dist/skills/frontline-agents/SKILL.md +99 -0
- package/dist/skills/frontline-api/SKILL.md +59 -0
- package/dist/skills/frontline-billing/SKILL.md +42 -0
- package/dist/skills/frontline-workflows/SKILL.md +72 -0
- package/dist/skills/max-auth/SKILL.md +76 -0
- package/dist/skills/max-chat/SKILL.md +111 -0
- package/dist/skills/notes-and-tasks/SKILL.md +128 -0
- package/dist/skills/pipeline-setup/SKILL.md +233 -0
- package/dist/skills/record-type-management/SKILL.md +104 -0
- package/dist/skills/relations/SKILL.md +153 -0
- package/dist/skills/resource-creation/SKILL.md +86 -0
- package/dist/skills/schema-design/SKILL.md +263 -0
- package/package.json +47 -0
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: frontline-agents
|
|
3
|
+
description: List, filter, and inspect Frontline AI agents using the Frontline CLI. Use when the user asks about their agents, wants to see agent status, flows, or analytics.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
## Prerequisites
|
|
7
|
+
|
|
8
|
+
- The `frontline` CLI must be installed (`npm i -g @frontline/cli`).
|
|
9
|
+
- The user must be authenticated (`frontline auth login`).
|
|
10
|
+
|
|
11
|
+
## Commands
|
|
12
|
+
|
|
13
|
+
### List all agents
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
frontline agents list [--status <status>] [--json] [--debug]
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
| Flag | Description |
|
|
20
|
+
| ------------------- | -------------------------------------------------- |
|
|
21
|
+
| `--status <status>` | Filter by status: `active`, `inactive`, or `draft` |
|
|
22
|
+
| `--json` | Output raw JSON instead of a table |
|
|
23
|
+
| `--api-key <key>` | Override the stored API key for this request |
|
|
24
|
+
| `--profile <name>` | Use a specific CLI profile |
|
|
25
|
+
| `--debug` | Show HTTP request/response diagnostics |
|
|
26
|
+
|
|
27
|
+
**Example:**
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
# List all active agents
|
|
31
|
+
frontline agents list --status active
|
|
32
|
+
|
|
33
|
+
# Get agent list as JSON for programmatic use
|
|
34
|
+
frontline agents list --json
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
**Output columns:** `id`, `name`, `status`, `createdAt`, `updatedAt`
|
|
38
|
+
|
|
39
|
+
### Get flows for a specific agent
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
frontline agents flows <agentId> [--status <status>] [--json] [--debug]
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
| Flag | Description |
|
|
46
|
+
| ------------------- | -------------------------------------- |
|
|
47
|
+
| `<agentId>` | **(required)** The agent ID |
|
|
48
|
+
| `--status <status>` | Filter by flow status |
|
|
49
|
+
| `--json` | Output raw JSON |
|
|
50
|
+
| `--api-key <key>` | Override API key |
|
|
51
|
+
| `--profile <name>` | Use a specific CLI profile |
|
|
52
|
+
| `--debug` | Show HTTP request/response diagnostics |
|
|
53
|
+
|
|
54
|
+
**Example:**
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
# List all flows for agent abc-123
|
|
58
|
+
frontline agents flows abc-123
|
|
59
|
+
|
|
60
|
+
# Filter active flows only
|
|
61
|
+
frontline agents flows abc-123 --status active --json
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
**Output columns:** `id`, `name`, `status`, `runCount`, `createdAt`
|
|
65
|
+
|
|
66
|
+
### Get analytics for a specific agent
|
|
67
|
+
|
|
68
|
+
```bash
|
|
69
|
+
frontline agents analytics <agentId> [--start-date <YYYY-MM-DD>] [--end-date <YYYY-MM-DD>] [--json] [--debug]
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
| Flag | Description |
|
|
73
|
+
| --------------------- | -------------------------------------- |
|
|
74
|
+
| `<agentId>` | **(required)** The agent ID |
|
|
75
|
+
| `--start-date <date>` | Start date in `YYYY-MM-DD` format |
|
|
76
|
+
| `--end-date <date>` | End date in `YYYY-MM-DD` format |
|
|
77
|
+
| `--json` | Output raw JSON |
|
|
78
|
+
| `--api-key <key>` | Override API key |
|
|
79
|
+
| `--profile <name>` | Use a specific CLI profile |
|
|
80
|
+
| `--debug` | Show HTTP request/response diagnostics |
|
|
81
|
+
|
|
82
|
+
**Example:**
|
|
83
|
+
|
|
84
|
+
```bash
|
|
85
|
+
# Get analytics for agent abc-123 for a date range
|
|
86
|
+
frontline agents analytics abc-123 --start-date 2025-01-01 --end-date 2025-01-31
|
|
87
|
+
|
|
88
|
+
# Get analytics as JSON
|
|
89
|
+
frontline agents analytics abc-123 --json
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
**Output:** Summary (totalCredits, totalConversations), Credits by Date table, Conversations by Channel table.
|
|
93
|
+
|
|
94
|
+
## Troubleshooting
|
|
95
|
+
|
|
96
|
+
- **"No API key found"**: run `frontline auth login` to authenticate.
|
|
97
|
+
- Use `--debug` to see the full HTTP request URL, headers, and response status for diagnosing issues.
|
|
98
|
+
- Use `--json` for machine-readable output that can be piped to `jq` or other tools.
|
|
99
|
+
- Use `--profile <name>` if you have multiple Frontline accounts configured.
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: frontline-api
|
|
3
|
+
description: Make raw HTTP requests to the Frontline Public API using the Frontline CLI. Use as an escape hatch when a specific endpoint does not have a dedicated CLI command, or when exploring the API.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
## Prerequisites
|
|
7
|
+
|
|
8
|
+
- The `frontline` CLI must be installed (`npm i -g @frontline/cli`).
|
|
9
|
+
- The user must be authenticated (`frontline auth login`).
|
|
10
|
+
|
|
11
|
+
## Commands
|
|
12
|
+
|
|
13
|
+
### Make a raw API GET request
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
frontline api get <path> [--query <key=value>...] [--json] [--debug]
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
| Flag | Description |
|
|
20
|
+
| -------------------- | ------------------------------------------------------------------------------- |
|
|
21
|
+
| `<path>` | **(required)** API path relative to the base URL (e.g. `/agents`, `/workflows`) |
|
|
22
|
+
| `--query <pairs...>` | Query parameters as `key=value` pairs (repeatable) |
|
|
23
|
+
| `--json` | Output as JSON (default for raw requests) |
|
|
24
|
+
| `--api-key <key>` | Override the stored API key for this request |
|
|
25
|
+
| `--profile <name>` | Use a specific CLI profile |
|
|
26
|
+
| `--debug` | Show HTTP request/response diagnostics |
|
|
27
|
+
|
|
28
|
+
**Important:** Only `GET` requests are supported currently. Passing any other method will result in an error.
|
|
29
|
+
|
|
30
|
+
**Example:**
|
|
31
|
+
|
|
32
|
+
```bash
|
|
33
|
+
# Raw GET request to the agents endpoint
|
|
34
|
+
frontline api get /agents
|
|
35
|
+
|
|
36
|
+
# Raw GET with query parameters
|
|
37
|
+
frontline api get /agents --query status=active --query limit=10
|
|
38
|
+
|
|
39
|
+
# With debug output to see full request details
|
|
40
|
+
frontline api get /billing --debug
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
**Output:** Always returns raw JSON response from the API.
|
|
44
|
+
|
|
45
|
+
## When to use this skill
|
|
46
|
+
|
|
47
|
+
- When you need to access an API endpoint that does not have a dedicated CLI command.
|
|
48
|
+
- When you want to explore the API response structure.
|
|
49
|
+
- When building automation scripts that need raw API data.
|
|
50
|
+
|
|
51
|
+
## Discovering available endpoints
|
|
52
|
+
|
|
53
|
+
Run `frontline --help` to see all available commands. If a resource is not listed, you can try calling it directly via `frontline api get /resource-name`.
|
|
54
|
+
|
|
55
|
+
## Troubleshooting
|
|
56
|
+
|
|
57
|
+
- **"No API key found"**: run `frontline auth login` to authenticate.
|
|
58
|
+
- **"Only GET requests are supported"**: the raw API command currently only supports GET. POST/PUT/DELETE are not yet available.
|
|
59
|
+
- Use `--debug` to see the full HTTP request URL, headers, and response status for diagnosing issues.
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: frontline-billing
|
|
3
|
+
description: Query Frontline billing plan information using the Frontline CLI. Use when the user asks about their billing, credits, plan, or subscription.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
## Prerequisites
|
|
7
|
+
|
|
8
|
+
- The `frontline` CLI must be installed (`npm i -g @frontline/cli`).
|
|
9
|
+
- The user must be authenticated (`frontline auth login`).
|
|
10
|
+
|
|
11
|
+
## Commands
|
|
12
|
+
|
|
13
|
+
### Get current billing information
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
frontline billing get [--json] [--debug]
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
| Flag | Description |
|
|
20
|
+
| ------------------ | -------------------------------------------- |
|
|
21
|
+
| `--json` | Output raw JSON instead of key-value display |
|
|
22
|
+
| `--api-key <key>` | Override the stored API key for this request |
|
|
23
|
+
| `--profile <name>` | Use a specific CLI profile |
|
|
24
|
+
| `--debug` | Show HTTP request/response diagnostics |
|
|
25
|
+
|
|
26
|
+
**Example:**
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
# View current billing plan
|
|
30
|
+
frontline billing get
|
|
31
|
+
|
|
32
|
+
# Get billing info as JSON
|
|
33
|
+
frontline billing get --json
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
**Output fields:** `Plan`, `Credits Used` (e.g. `1500 / 10000`), `Subscription Renews` (date).
|
|
37
|
+
|
|
38
|
+
## Troubleshooting
|
|
39
|
+
|
|
40
|
+
- **"No API key found"**: run `frontline auth login` to authenticate.
|
|
41
|
+
- Use `--debug` to see the full HTTP request URL, headers, and response status for diagnosing issues.
|
|
42
|
+
- Use `--json` for machine-readable output that can be piped to `jq` or other tools.
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: frontline-workflows
|
|
3
|
+
description: List, filter, and inspect Frontline workflows using the Frontline CLI. Use when the user asks about their workflows, wants to see workflow status, run counts, or analytics.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
## Prerequisites
|
|
7
|
+
|
|
8
|
+
- The `frontline` CLI must be installed (`npm i -g @frontline/cli`).
|
|
9
|
+
- The user must be authenticated (`frontline auth login`).
|
|
10
|
+
|
|
11
|
+
## Commands
|
|
12
|
+
|
|
13
|
+
### List all workflows
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
frontline workflows list [--status <status>] [--json] [--debug]
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
| Flag | Description |
|
|
20
|
+
| ------------------- | -------------------------------------------------- |
|
|
21
|
+
| `--status <status>` | Filter by status: `active`, `inactive`, or `draft` |
|
|
22
|
+
| `--json` | Output raw JSON instead of a table |
|
|
23
|
+
| `--api-key <key>` | Override the stored API key for this request |
|
|
24
|
+
| `--profile <name>` | Use a specific CLI profile |
|
|
25
|
+
| `--debug` | Show HTTP request/response diagnostics |
|
|
26
|
+
|
|
27
|
+
**Example:**
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
# List all workflows
|
|
31
|
+
frontline workflows list
|
|
32
|
+
|
|
33
|
+
# List only active workflows as JSON
|
|
34
|
+
frontline workflows list --status active --json
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
**Output columns:** `id`, `name`, `status`, `triggerType`, `runsCount`, `lastRunDate`
|
|
38
|
+
|
|
39
|
+
### Get analytics for a specific workflow
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
frontline workflows analytics <workflowId> [--start-date <YYYY-MM-DD>] [--end-date <YYYY-MM-DD>] [--json] [--debug]
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
| Flag | Description |
|
|
46
|
+
| --------------------- | -------------------------------------- |
|
|
47
|
+
| `<workflowId>` | **(required)** The workflow ID |
|
|
48
|
+
| `--start-date <date>` | Start date in `YYYY-MM-DD` format |
|
|
49
|
+
| `--end-date <date>` | End date in `YYYY-MM-DD` format |
|
|
50
|
+
| `--json` | Output raw JSON |
|
|
51
|
+
| `--api-key <key>` | Override API key |
|
|
52
|
+
| `--profile <name>` | Use a specific CLI profile |
|
|
53
|
+
| `--debug` | Show HTTP request/response diagnostics |
|
|
54
|
+
|
|
55
|
+
**Example:**
|
|
56
|
+
|
|
57
|
+
```bash
|
|
58
|
+
# Get workflow analytics for a date range
|
|
59
|
+
frontline workflows analytics 42 --start-date 2025-01-01 --end-date 2025-01-31
|
|
60
|
+
|
|
61
|
+
# Get workflow analytics as JSON
|
|
62
|
+
frontline workflows analytics 42 --json
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
**Output:** Summary section, Runs by Date table (date, totalRuns, successfulRuns, failedRuns, totalCredits).
|
|
66
|
+
|
|
67
|
+
## Troubleshooting
|
|
68
|
+
|
|
69
|
+
- **"No API key found"**: run `frontline auth login` to authenticate.
|
|
70
|
+
- Use `--debug` to see the full HTTP request URL, headers, and response status for diagnosing issues.
|
|
71
|
+
- Use `--json` for machine-readable output that can be piped to `jq` or other tools.
|
|
72
|
+
- Use `--profile <name>` if you have multiple Frontline accounts configured.
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: max-auth
|
|
3
|
+
description: Manage Max CLI authentication — store per-user API key (synced with Frontline CLI), sign out, and inspect the active profile. Use when the user needs Max terminal auth, whoami, or clearing credentials.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
## Prerequisites
|
|
7
|
+
|
|
8
|
+
- The `max` CLI must be installed (`npm i -g @frontline/cli` — provides both `frontline` and `max` binaries).
|
|
9
|
+
- A **per-user API key** from the Frontline web app (Settings → API keys). The browser SSO (Firebase) flow is **paused** in the CLI; `MAX_CLI_AUTH_URL` is not required for the current flow.
|
|
10
|
+
|
|
11
|
+
## How credentials work
|
|
12
|
+
|
|
13
|
+
- `max auth login <api-key>` saves the same key to the **Max** store (`max-cli`) and the **Frontline** store (`frontline-cli`) under the **same profile name**, so `max` and `frontline` stay aligned.
|
|
14
|
+
- `max` commands call the **Public API** (`…/public/v1/max/...`) with `Authorization: Bearer <apiKey>` (USER key, same as SoR).
|
|
15
|
+
- Public API base URL: same as `frontline` — `FRONTLINE_BASE_URL`, profile `baseUrl`, or `--base-url` on each command (`max auth login --base-url …` persists it on the Frontline profile).
|
|
16
|
+
- API key resolution: `--api-key` → `MAX_API_KEY` / `FRONTLINE_API_KEY` → Max profile `apiKey` → Frontline profile `apiKey` (same name).
|
|
17
|
+
|
|
18
|
+
## Commands
|
|
19
|
+
|
|
20
|
+
### Sign in (save API key)
|
|
21
|
+
|
|
22
|
+
```bash
|
|
23
|
+
max auth login <api-key> [--profile <name>] [--base-url <url>]
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
| Option | Description |
|
|
27
|
+
| ------------------ | ---------------------------------------------------------------------------------------------------- |
|
|
28
|
+
| `<api-key>` | Per-user API key (required argument) |
|
|
29
|
+
| `--profile <name>` | Profile to save under (default: current; if set, also switches active profile for Max and Frontline) |
|
|
30
|
+
| `--base-url <url>` | Public API root for **both** `max` and `frontline` on that profile (must end with `/public/v1`) |
|
|
31
|
+
|
|
32
|
+
**Examples:**
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
max auth login flk_abc123
|
|
36
|
+
|
|
37
|
+
max auth login flk_abc123 --profile staging \
|
|
38
|
+
--base-url https://staging-api.example.com/public/v1
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
### Sign out
|
|
42
|
+
|
|
43
|
+
```bash
|
|
44
|
+
max auth logout [--profile <name>] [--keep-frontline]
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
| Option | Description |
|
|
48
|
+
| ------------------ | -------------------------------------------------------------- |
|
|
49
|
+
| `--profile <name>` | Profile to clear (default: current) |
|
|
50
|
+
| `--keep-frontline` | Only clear the Max store; leave the matching Frontline profile |
|
|
51
|
+
|
|
52
|
+
By default, the matching Frontline profile is removed too.
|
|
53
|
+
|
|
54
|
+
### Check profile / credentials
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
max auth whoami [--json] [--profile <name>]
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
Shows API key preview, `maxApiBaseUrl`, whether a matching Frontline profile exists, and Max config path (no JWT decode; browser SSO is paused).
|
|
61
|
+
|
|
62
|
+
### Config path
|
|
63
|
+
|
|
64
|
+
```bash
|
|
65
|
+
max config-path
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
## Troubleshooting
|
|
69
|
+
|
|
70
|
+
- **"No API key saved for profile …"** — run `max auth login <api-key>` or `frontline auth login <api-key>` with the same `--profile`.
|
|
71
|
+
- **"No Max API key found"** — same as above, or set `MAX_API_KEY` / `FRONTLINE_API_KEY`.
|
|
72
|
+
- **401 on Max** — key revoked or wrong; create a new key in the app and run `max auth login` again.
|
|
73
|
+
|
|
74
|
+
## Browser SSO note
|
|
75
|
+
|
|
76
|
+
The legacy flow (`max auth login` with no argument, hosted page + localhost callback) is commented out in the package. To restore it later, see git history and `packages/cli/src/max/browserLogin.ts`.
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: max-chat
|
|
3
|
+
description: Send messages to the Max AI assistant and manage conversations from the terminal. Use when the user wants to chat with Max, send a quick question, start a new conversation, or open an interactive chat session.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
## Prerequisites
|
|
7
|
+
|
|
8
|
+
- The `max` CLI must be installed (`npm i -g @frontline/cli` — provides both `frontline` and `max` binaries).
|
|
9
|
+
- The user must have a per-user API key saved: `max auth login <api-key>` (or `frontline auth login` on the same profile).
|
|
10
|
+
|
|
11
|
+
## Commands
|
|
12
|
+
|
|
13
|
+
### Quick message (shorthand)
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
max "Your question here"
|
|
17
|
+
max --new "Start a fresh conversation"
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
This is the fastest way to send a single message to Max. It uses the last active conversation by default, or `--new` to start a fresh one.
|
|
21
|
+
|
|
22
|
+
Calls the **Public API**: `POST /public/v1/max/conversations/message` (Bearer = user API key). Responses use `{ "ok": boolean, "data": ... }`. Default stdout is **one-line JSON**; no spinner lines.
|
|
23
|
+
|
|
24
|
+
| Flag | Description |
|
|
25
|
+
| ---------------------- | ----------------------------------------------------------- |
|
|
26
|
+
| `--new` | Start a new conversation instead of continuing the last one |
|
|
27
|
+
| `--conversation <id>` | Send to a specific conversation ID |
|
|
28
|
+
| `--no-wait` | Do not poll for the assistant reply (fire and forget) |
|
|
29
|
+
| `--timeout <seconds>` | Max seconds to wait for assistant reply (default: 60) |
|
|
30
|
+
| `--json` | Print only the POST response JSON (no poll) |
|
|
31
|
+
| `--pretty` | Print assistant plain text from `data` instead of JSON |
|
|
32
|
+
| `--profile <name>` | Use a specific Max CLI profile |
|
|
33
|
+
| `--base-url <url>` | Override Public API root (…/public/v1) for this run |
|
|
34
|
+
| `--api-base-url <url>` | Deprecated alias for `--base-url` |
|
|
35
|
+
| `--api-key <key>` | Override per-user API key for this run |
|
|
36
|
+
| `--debug` | Show HTTP request/response diagnostics |
|
|
37
|
+
|
|
38
|
+
**Example:**
|
|
39
|
+
|
|
40
|
+
```bash
|
|
41
|
+
# Quick question using last conversation
|
|
42
|
+
max "What agents do I have?"
|
|
43
|
+
|
|
44
|
+
# Start a new conversation
|
|
45
|
+
max --new "Help me set up a new workflow"
|
|
46
|
+
|
|
47
|
+
# Send to a specific conversation
|
|
48
|
+
max --conversation 123 "Continue from here"
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
### Send a message (explicit command)
|
|
52
|
+
|
|
53
|
+
```bash
|
|
54
|
+
max chat send <message...> [--new] [--conversation <id>] [--json] [--debug]
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
Same as the shorthand above but under the `chat send` subcommand. Default stdout is **one-line JSON**; **`--pretty`** for assistant plain text from `data`.
|
|
58
|
+
|
|
59
|
+
### Interactive chat (REPL)
|
|
60
|
+
|
|
61
|
+
```bash
|
|
62
|
+
max chat repl [--profile <name>] [--debug] [--timeout <seconds>]
|
|
63
|
+
max chat
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
Opens an interactive readline session for back-and-forth conversation with Max.
|
|
67
|
+
|
|
68
|
+
| REPL Command | Description |
|
|
69
|
+
| ------------ | ---------------------------------------- |
|
|
70
|
+
| `:help` | Show available REPL commands |
|
|
71
|
+
| `:new` | Start a new conversation on next message |
|
|
72
|
+
| `:conv <id>` | Switch to a specific conversation ID |
|
|
73
|
+
| `:exit` | Exit the REPL |
|
|
74
|
+
| `Ctrl+C` | Exit the REPL |
|
|
75
|
+
|
|
76
|
+
**Example:**
|
|
77
|
+
|
|
78
|
+
```bash
|
|
79
|
+
# Start interactive chat
|
|
80
|
+
max chat
|
|
81
|
+
|
|
82
|
+
# Start with a specific profile
|
|
83
|
+
max chat repl --profile work --debug
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
### Conversations (Public API)
|
|
87
|
+
|
|
88
|
+
```bash
|
|
89
|
+
max conversations list
|
|
90
|
+
max conversations get <id>
|
|
91
|
+
max conversations update <id> --data '{"key":"value"}'
|
|
92
|
+
max conversations abort <id>
|
|
93
|
+
# alias: max conv list
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
See `max conversations --help` for flags (`--profile`, `--base-url`, `--api-key`, `--debug`).
|
|
97
|
+
|
|
98
|
+
## Conversation management
|
|
99
|
+
|
|
100
|
+
- Max automatically remembers the last conversation ID in your profile. Subsequent messages continue that conversation.
|
|
101
|
+
- Use `--new` to explicitly start a fresh conversation.
|
|
102
|
+
- Use `--conversation <id>` to jump to a specific conversation.
|
|
103
|
+
- In the REPL, use `:new` and `:conv <id>` to manage conversations interactively.
|
|
104
|
+
|
|
105
|
+
## Troubleshooting
|
|
106
|
+
|
|
107
|
+
- **"No Max API key found"**: run `max auth login <api-key>` or `frontline auth login <api-key>` on the same profile.
|
|
108
|
+
- **"Message cannot be empty"**: provide a non-empty message string.
|
|
109
|
+
- **Timeout waiting for reply**: increase `--timeout` or use `--no-wait` and check the conversation later.
|
|
110
|
+
- Use `--debug` to see the full HTTP request URL, headers, and response status for diagnosing issues.
|
|
111
|
+
- Use `--json` for machine-readable output that can be piped to `jq` or other tools.
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: notes-and-tasks
|
|
3
|
+
description: >
|
|
4
|
+
How to create, read, update, and delete notes and tasks attached to rows
|
|
5
|
+
in tables and objects using the Frontline CLI.
|
|
6
|
+
allowed-tools: Bash(frontline:*)
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
# Notes & Tasks
|
|
10
|
+
|
|
11
|
+
Notes and tasks are sub-resources attached to individual rows. They let you
|
|
12
|
+
track follow-ups, comments, and to-do items without polluting row fields.
|
|
13
|
+
|
|
14
|
+
## Notes
|
|
15
|
+
|
|
16
|
+
Notes are simple text entries attached to a row.
|
|
17
|
+
|
|
18
|
+
### List Notes
|
|
19
|
+
|
|
20
|
+
```bash
|
|
21
|
+
frontline object note list <object> <row-id>
|
|
22
|
+
frontline table note list <table> <row-id>
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
### Create a Note
|
|
26
|
+
|
|
27
|
+
```bash
|
|
28
|
+
frontline object note create <object> <row-id> --content "Follow up next week"
|
|
29
|
+
frontline table note create <table> <row-id> --content "Check inventory levels"
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
### Get a Note by ID
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
frontline object note get <object> <note-id>
|
|
36
|
+
frontline table note get <table> <note-id>
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
### Update a Note
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
frontline object note update <object> <note-id> --content "Updated: follow up tomorrow"
|
|
43
|
+
frontline table note update <table> <note-id> --content "Updated content"
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
### Delete a Note
|
|
47
|
+
|
|
48
|
+
```bash
|
|
49
|
+
frontline object note delete <object> <note-id>
|
|
50
|
+
frontline table note delete <table> <note-id>
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
---
|
|
54
|
+
|
|
55
|
+
## Tasks
|
|
56
|
+
|
|
57
|
+
Tasks have content, optional due dates, assignees, and a completion state.
|
|
58
|
+
|
|
59
|
+
### List Tasks
|
|
60
|
+
|
|
61
|
+
```bash
|
|
62
|
+
frontline object task list <object> <row-id>
|
|
63
|
+
frontline table task list <table> <row-id>
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
### Create a Task
|
|
67
|
+
|
|
68
|
+
```bash
|
|
69
|
+
# Simple task
|
|
70
|
+
frontline object task create <object> <row-id> --content "Call the client"
|
|
71
|
+
|
|
72
|
+
# With due date
|
|
73
|
+
frontline object task create <object> <row-id> \
|
|
74
|
+
--content "Send proposal" \
|
|
75
|
+
--due-date 2026-05-01
|
|
76
|
+
|
|
77
|
+
# With assignees (comma-separated user IDs)
|
|
78
|
+
frontline object task create <object> <row-id> \
|
|
79
|
+
--content "Review contract" \
|
|
80
|
+
--assignees 12,34
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
### Get a Task by ID
|
|
84
|
+
|
|
85
|
+
```bash
|
|
86
|
+
frontline object task get <object> <task-id>
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
### Update a Task
|
|
90
|
+
|
|
91
|
+
```bash
|
|
92
|
+
frontline object task update <object> <task-id> --data '{"content":"Revised task","dueDate":"2026-06-01"}'
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
### Complete / Uncomplete a Task
|
|
96
|
+
|
|
97
|
+
```bash
|
|
98
|
+
frontline object task complete <object> <task-id>
|
|
99
|
+
frontline object task uncomplete <object> <task-id>
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
### Delete a Task
|
|
103
|
+
|
|
104
|
+
```bash
|
|
105
|
+
frontline object task delete <object> <task-id>
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
---
|
|
109
|
+
|
|
110
|
+
## Typical Workflow
|
|
111
|
+
|
|
112
|
+
```bash
|
|
113
|
+
# 1. Find the row you want to annotate
|
|
114
|
+
frontline object record list sor__deals --search "Acme"
|
|
115
|
+
# → row ID = 6625abc123def456
|
|
116
|
+
|
|
117
|
+
# 2. Add a note
|
|
118
|
+
frontline object note create sor__deals 6625abc123def456 \
|
|
119
|
+
--content "Discussed pricing on call"
|
|
120
|
+
|
|
121
|
+
# 3. Add a follow-up task with a due date
|
|
122
|
+
frontline object task create sor__deals 6625abc123def456 \
|
|
123
|
+
--content "Send revised proposal" \
|
|
124
|
+
--due-date 2026-05-15
|
|
125
|
+
|
|
126
|
+
# 4. Later, mark it complete
|
|
127
|
+
frontline object task complete sor__deals 7
|
|
128
|
+
```
|