@betterness/cli 1.1.2 → 1.3.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 +55 -1
- package/dist/index.js +963 -137
- package/package.json +1 -1
- package/CLI_REFERENCE.md +0 -493
package/README.md
CHANGED
|
@@ -12,6 +12,17 @@ Requires Node.js 20+.
|
|
|
12
12
|
|
|
13
13
|
## Authentication
|
|
14
14
|
|
|
15
|
+
### OAuth (default)
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
betterness auth login # Opens browser for OAuth login
|
|
19
|
+
betterness auth whoami # Verify
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
The CLI opens a browser window for secure authentication via OAuth. Tokens are stored in `~/.betterness/tokens.json` and refreshed automatically.
|
|
23
|
+
|
|
24
|
+
### API Key
|
|
25
|
+
|
|
15
26
|
Get your API key from either:
|
|
16
27
|
|
|
17
28
|
- [app.betti.bot/settings/betterness-mcp](https://app.betti.bot/settings/betterness-mcp)
|
|
@@ -26,7 +37,11 @@ betterness auth whoami # verify
|
|
|
26
37
|
|
|
27
38
|
You can also set the `BETTERNESS_API_KEY` environment variable instead of storing credentials.
|
|
28
39
|
|
|
29
|
-
|
|
40
|
+
### Credential priority
|
|
41
|
+
|
|
42
|
+
`--api-key` flag > `BETTERNESS_API_KEY` env var > OAuth tokens > stored API key.
|
|
43
|
+
|
|
44
|
+
Only one auth method is active at a time — logging in with one clears the other.
|
|
30
45
|
|
|
31
46
|
## Quick Start
|
|
32
47
|
|
|
@@ -131,6 +146,18 @@ betterness lab-results update-biomarker --biomarker-id <id> --result 5.2 --unit
|
|
|
131
146
|
betterness lab-results update-metadata --result-id <id> --patient-name "Jane Doe"
|
|
132
147
|
```
|
|
133
148
|
|
|
149
|
+
### Health Profile
|
|
150
|
+
|
|
151
|
+
```bash
|
|
152
|
+
betterness health-profile schema # List all sections
|
|
153
|
+
betterness health-profile schema --section HWP # Questions in a section
|
|
154
|
+
betterness health-profile get # Full profile (flat map)
|
|
155
|
+
betterness health-profile get-section --section DA # Single section answers
|
|
156
|
+
betterness health-profile summary # Human-readable summary
|
|
157
|
+
betterness health-profile update --data '{"HWP_HAB_do_you_smoke_cigarettes_or_use_tobacco_products": false}'
|
|
158
|
+
betterness health-profile reset-section --section DA
|
|
159
|
+
```
|
|
160
|
+
|
|
134
161
|
### Smart Listings (Wellness Providers)
|
|
135
162
|
|
|
136
163
|
```bash
|
|
@@ -145,6 +172,30 @@ betterness workflow daily-brief # Full health snapshot
|
|
|
145
172
|
betterness workflow next-actions # AI-driven recommendations
|
|
146
173
|
```
|
|
147
174
|
|
|
175
|
+
### MCP Integration
|
|
176
|
+
|
|
177
|
+
One-command setup for the [Betterness MCP server](https://www.betterness.ai/mcp) in your AI client:
|
|
178
|
+
|
|
179
|
+
```bash
|
|
180
|
+
# Install into Claude Desktop, Claude Code, Cursor, or Windsurf
|
|
181
|
+
betterness mcp install claude
|
|
182
|
+
betterness mcp install claude-code
|
|
183
|
+
betterness mcp install claude-code --scope project # project-level .mcp.json
|
|
184
|
+
betterness mcp install cursor
|
|
185
|
+
betterness mcp install windsurf
|
|
186
|
+
|
|
187
|
+
# Preview without writing
|
|
188
|
+
betterness mcp install claude --dry-run
|
|
189
|
+
|
|
190
|
+
# Check status across all clients
|
|
191
|
+
betterness mcp status
|
|
192
|
+
|
|
193
|
+
# Remove
|
|
194
|
+
betterness mcp uninstall claude
|
|
195
|
+
```
|
|
196
|
+
|
|
197
|
+
The install command reads your stored credentials, merges the MCP config into the client's config file (preserving existing entries), and creates a `.bak` backup.
|
|
198
|
+
|
|
148
199
|
### Schema Discovery
|
|
149
200
|
|
|
150
201
|
```bash
|
|
@@ -162,6 +213,7 @@ The CLI is designed to be consumed by AI agents. Key features:
|
|
|
162
213
|
- `betterness schema` for runtime capability discovery
|
|
163
214
|
- `--quiet` mode for exit-code-only checks
|
|
164
215
|
- `--dry-run` on destructive commands for safe planning
|
|
216
|
+
- `betterness mcp install <client>` for one-command MCP setup
|
|
165
217
|
|
|
166
218
|
### Skills
|
|
167
219
|
|
|
@@ -184,6 +236,8 @@ Agent skills teach your AI coding agent the Betterness API surface — endpoints
|
|
|
184
236
|
| [betterness-purchases](https://github.com/Betterness/betterness-cli/tree/main/skills/betterness-purchases) | Purchases and Stripe checkout |
|
|
185
237
|
| [betterness-smart-listings](https://github.com/Betterness/betterness-cli/tree/main/skills/betterness-smart-listings) | Wellness provider search |
|
|
186
238
|
| [betterness-workflow](https://github.com/Betterness/betterness-cli/tree/main/skills/betterness-workflow) | Composite commands (daily brief, next actions) |
|
|
239
|
+
| [betterness-health-profile](https://github.com/Betterness/betterness-cli/tree/main/skills/betterness-health-profile) | Health profile questionnaire management |
|
|
240
|
+
| [betterness-mcp](https://github.com/Betterness/betterness-cli/tree/main/skills/betterness-mcp) | MCP server integration for AI clients |
|
|
187
241
|
|
|
188
242
|
**Persona skills:**
|
|
189
243
|
|