GitHub Copilot Paperclip Adapter
External Paperclip adapter that wraps the GitHub Copilot CLI as a managed subprocess. Passes prompts via `-p`, parses JSON output, and resumes sessions via `--resume=<sessionId>`. Supports GitHub BYOK, Provider BYOK (OpenAI / Anthropic / Azure), and GitHub Enterprise.
External [Paperclip](https://github.com/paperclipai/paperclip) adapter that integrates [GitHub Copilot CLI](https://docs.github.com/en/copilot/github-copilot-in-the-cli) as a managed subprocess. Wraps the copilot command, passes prompts via -p, parses JSON-formatted output, and persists session IDs for resuming conversations across heartbeats using --resume=<sessionId>.
Part of the [@superbiche/paperclip-adapters](https://github.com/superbiche/paperclip-adapters) external adapter pack.
Origins
Foundation — core execution, parsing, and session retry logic by [@tjp2021](https://github.com/tjp2021) in [paperclipai/paperclip#2085](https://github.com/paperclipai/paperclip/pull/2085) Auth & features — token resolution, model discovery, and skill injection by [@HearthCore](https://github.com/HearthCore) in [paperclipai/paperclip#3629](https://github.com/paperclipai/paperclip/pull/3629), with additional SSRF defense External port — packaged as a standalone external adapter with provider configuration support by [@superbiche](https://github.com/superbiche) and [@tsbwc](https://github.com/tsbwc)
Capabilities
Session resumption via native Copilot CLI GitHub token BYOK with classic-PAT rejection Provider BYOK supporting OpenAI-compatible, Anthropic, and Azure endpoints (no GitHub subscription required) GitHub Enterprise support with strict hostname validation Dynamic model discovery with fallback list Skill injection via COPILOTSKILLSDIRS
Prerequisites
Install Copilot CLI: npm i -g @githubnext/github-copilot-cli (v1.0.12+) Authenticate via interactive login, token, or gh CLI Maintain active Copilot CLI subscription access (unless using Provider BYOK)
Install
bash curl -X POST http://127.0.0.1:3100/api/adapters/install \ -H 'content-type: application/json' \ -d '{"packageName":"@superbiche/copilot-paperclip-adapter"}'
Shared by superbiche