@pi-plugins/claude-cli 0.0.0-stage → 0.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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 kedom
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,3 +1,61 @@
1
- # Temporary Holding Version
1
+ # `@pi-plugins/claude-cli`
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ Use a Claude subscription in [pi](https://github.com/earendil-works/pi) through the
4
+ official Claude Code CLI. Each model request runs as one `claude --print` process, so
5
+ sign-in, request format and billing are Claude Code's own. Pi keeps the conversation
6
+ and runs the tools.
7
+
8
+ ## Requirements
9
+
10
+ The `claude` CLI must be on your `PATH` and signed in to a Pro or Max plan:
11
+
12
+ ```bash
13
+ claude auth login
14
+ ```
15
+
16
+ Requests are billed to the account `claude` is signed in to, not to pi's `/login`.
17
+
18
+ Tested with pi 1.2.0 and Claude Code 2.1.299.
19
+
20
+ ## Install
21
+
22
+ ```bash
23
+ pi install npm:@pi-plugins/claude-cli
24
+ ```
25
+
26
+ To try it for one session without changing your settings:
27
+
28
+ ```bash
29
+ pi -e npm:@pi-plugins/claude-cli
30
+ ```
31
+
32
+ ## Usage
33
+
34
+ Pick a model from the `claude-cli` provider with `/model`, or start pi with one:
35
+
36
+ ```bash
37
+ pi --model claude-cli/claude-sonnet-5-5
38
+ ```
39
+
40
+ The provider offers the same Claude models as pi's built-in `anthropic` provider.
41
+
42
+ ## How it works
43
+
44
+ Every request starts a fresh `claude` process, which signs the request and sends it
45
+ with your subscription. pi supplies the conversation, system prompt, tools and
46
+ thinking settings in place of Claude Code's own. Claude Code's tools, settings, MCP
47
+ servers, skills and project instructions stay off. The process is stopped as soon as
48
+ the model's response is complete, so Claude Code does not run tools or send follow-up
49
+ requests of its own.
50
+
51
+ API keys in the environment, such as `ANTHROPIC_API_KEY`, are not passed on, so
52
+ requests always use the subscription.
53
+
54
+ Cache retention follows pi's `PI_CACHE_RETENTION` setting. It is five minutes by
55
+ default and one hour with `long`.
56
+
57
+ When another Claude Code process is refreshing the login, the request waits and tries
58
+ again for up to a minute.
59
+
60
+ The [`usage`](../usage) plugin reads Claude limits through pi's own Anthropic login.
61
+ To see them for this provider, sign in to the same account with `/login`.
@@ -0,0 +1,6 @@
1
+ import { ExtensionAPI } from "@earendil-works/pi-coding-agent";
2
+ //#region src/index.d.ts
3
+ declare function claudeCli(pi: ExtensionAPI): void;
4
+ //#endregion
5
+ export { claudeCli as default };
6
+ //# sourceMappingURL=index.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.mts","names":[],"sources":["../src/index.ts"],"mappings":";;iBAKwB,UAAU,IAAI"}