@nick3/copilot-api 1.1.6 → 1.1.7
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 +16 -22
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -585,35 +585,29 @@ You can also read more about IDE integration here: [Add Claude Code to your IDE]
|
|
|
585
585
|
|
|
586
586
|
### Subagent Marker Integration (Optional)
|
|
587
587
|
|
|
588
|
-
This project supports `X-Initiator: agent` for subagent-originated requests
|
|
588
|
+
This project supports `X-Initiator: agent` for subagent-originated requests.
|
|
589
589
|
|
|
590
|
-
#### Claude Code
|
|
590
|
+
#### Claude Code plugin producer (marketplace-based)
|
|
591
591
|
|
|
592
|
-
|
|
593
|
-
If you place the script under your user Claude directory (`~/.claude/hooks`), use this cross-platform command in `.claude/settings.json`:
|
|
592
|
+
The marker producer is packaged as a Claude Code plugin named `claude-plugin`.
|
|
594
593
|
|
|
595
|
-
- `.claude/
|
|
594
|
+
- Marketplace catalog in this repository: `.claude-plugin/marketplace.json`
|
|
595
|
+
- Plugin source in this repository: `claude-plugin`
|
|
596
596
|
|
|
597
|
-
|
|
597
|
+
Add the marketplace remotely:
|
|
598
598
|
|
|
599
|
-
```
|
|
600
|
-
|
|
601
|
-
"hooks": {
|
|
602
|
-
"SubagentStart": [
|
|
603
|
-
{
|
|
604
|
-
"matcher": "*",
|
|
605
|
-
"hooks": [
|
|
606
|
-
{
|
|
607
|
-
"type": "command",
|
|
608
|
-
"command": "node --input-type=module -e \"import { homedir } from 'node:os'; import { join } from 'node:path'; import { readFile } from 'node:fs/promises'; const file = join(homedir(), '.claude', 'hooks', 'subagent-start-marker.js'); const source = await readFile(file, 'utf8'); const url = 'data:text/javascript;base64,' + Buffer.from(source).toString('base64'); await import(url);\""
|
|
609
|
-
}
|
|
610
|
-
]
|
|
611
|
-
}
|
|
612
|
-
]
|
|
613
|
-
}
|
|
614
|
-
}
|
|
599
|
+
```sh
|
|
600
|
+
/plugin marketplace add https://github.com/nick3/copilot-api.git#all
|
|
615
601
|
```
|
|
616
602
|
|
|
603
|
+
Install the plugin from the marketplace:
|
|
604
|
+
|
|
605
|
+
```sh
|
|
606
|
+
/plugin install claude-plugin@copilot-api-marketplace
|
|
607
|
+
```
|
|
608
|
+
|
|
609
|
+
After installation, the plugin injects `__SUBAGENT_MARKER__...` on `SubagentStart`, and this proxy uses it to infer `X-Initiator: agent`.
|
|
610
|
+
|
|
617
611
|
#### Opencode plugin producer
|
|
618
612
|
|
|
619
613
|
For opencode, use the plugin implementation at:
|