@plexor-dev/claude-code-plugin 0.1.0-beta.14 → 0.1.0-beta.15
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/commands/plexor-status.md +4 -60
- package/package.json +1 -1
|
@@ -4,66 +4,10 @@ description: Show Plexor optimization statistics and savings (user)
|
|
|
4
4
|
|
|
5
5
|
# Plexor Status
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Run this command to display Plexor statistics:
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
1. Read `~/.plexor/config.json` to get settings and API key
|
|
12
|
-
2. Read `~/.plexor/session.json` to get current session stats (if exists and not expired after 30min inactivity)
|
|
13
|
-
3. Call the Plexor APIs to get user info and stats:
|
|
14
|
-
- `GET {apiUrl}/v1/user` with header `X-Plexor-Key: {api_key}`
|
|
15
|
-
- `GET {apiUrl}/v1/stats` with header `X-Plexor-Key: {api_key}`
|
|
16
|
-
4. Output the formatted status box directly as text (not in a code block):
|
|
17
|
-
|
|
18
|
-
```
|
|
19
|
-
┌─────────────────────────────────────────────┐
|
|
20
|
-
│ Plexor Status │
|
|
21
|
-
├─────────────────────────────────────────────┤
|
|
22
|
-
│ Account: {tier.name} │
|
|
23
|
-
│ Email: {email} │
|
|
24
|
-
│ Status: ● Active │
|
|
25
|
-
├─────────────────────────────────────────────┤
|
|
26
|
-
│ This Session ({duration}) │
|
|
27
|
-
│ ├── Requests: {session_requests} │
|
|
28
|
-
│ ├── Optimizations: {session_optimizations} │
|
|
29
|
-
│ ├── Cache hits: {session_cache_hits} │
|
|
30
|
-
│ ├── Tokens saved: {tokens} ({%}) │
|
|
31
|
-
│ └── Cost saved: ${session_cost_saved} │
|
|
32
|
-
├─────────────────────────────────────────────┤
|
|
33
|
-
│ This Week ({period.start} - {period.end}) │
|
|
34
|
-
│ ├── Requests: {total_requests} │
|
|
35
|
-
│ ├── Original tokens: {original_tokens} │
|
|
36
|
-
│ ├── Optimized tokens: {optimized_tokens} │
|
|
37
|
-
│ ├── Tokens saved: {tokens_saved} ({%}) │
|
|
38
|
-
│ ├── Baseline cost: ${baseline_cost} │
|
|
39
|
-
│ ├── Actual cost: ${total_cost} │
|
|
40
|
-
│ └── Cost saved: ${cost_saved} ({%}) │
|
|
41
|
-
├─────────────────────────────────────────────┤
|
|
42
|
-
│ Performance │
|
|
43
|
-
│ └── Cache hit rate: {cache_hit_rate}% │
|
|
44
|
-
├─────────────────────────────────────────────┤
|
|
45
|
-
│ Limits │
|
|
46
|
-
│ ├── Monthly optimizations: {limit} │
|
|
47
|
-
│ └── Monthly completions: {limit} │
|
|
48
|
-
├─────────────────────────────────────────────┤
|
|
49
|
-
│ Settings │
|
|
50
|
-
│ ├── Optimization: {Enabled/Disabled} │
|
|
51
|
-
│ ├── Local cache: {Enabled/Disabled} │
|
|
52
|
-
│ ├── Mode: {mode} │
|
|
53
|
-
│ └── Provider routing: {provider} │
|
|
54
|
-
└─────────────────────────────────────────────┘
|
|
55
|
-
|
|
56
|
-
Dashboard: {dashboard_url}
|
|
9
|
+
```bash
|
|
10
|
+
node ~/.claude/plugins/plexor/commands/plexor-status.js
|
|
57
11
|
```
|
|
58
12
|
|
|
59
|
-
|
|
60
|
-
- Output ONLY the status box as plain text, exactly as shown above
|
|
61
|
-
- Do NOT wrap in markdown code blocks
|
|
62
|
-
- Do NOT add any commentary before or after
|
|
63
|
-
- Format numbers with commas (e.g., 50,000)
|
|
64
|
-
- Format costs with 2 decimals (e.g., $4.50)
|
|
65
|
-
- Format dates as "Mon D" (e.g., "Jan 7")
|
|
66
|
-
- Use "● Active" if enabled, "○ Inactive" if disabled
|
|
67
|
-
- Multiply cache_hit_rate by 100 for percentage
|
|
68
|
-
- Only show "This Session" section if session.json exists and is not expired (30min timeout)
|
|
69
|
-
- Session duration format: "Xm" for minutes, "Xh Ym" for hours
|
|
13
|
+
Use the Bash tool to execute this single command. Do not read files manually or format output yourself.
|
package/package.json
CHANGED