microsoft/copilot-sdk
Developer ToolsMulti-language SDK for embedding the Copilot agent runtime and its planning, tool and file-edit capabilities into your own apps.
What it is
Microsoft Copilot SDK exposes the agent runtime behind Copilot CLI through Python, TypeScript/Node.js, Go, .NET, Java, and Rust packages, so an application can delegate planning, tool invocation, and file edits to Copilot instead of implementing its own orchestration. It is aimed at developers building agents into products or services, not at end users looking for a chat app. The project is in a phased rename from GitHub Copilot SDK to Microsoft Copilot SDK; existing package names and namespaces may still use the old name, and no immediate migration is required (transition announcement).
Architecture
All language SDKs drive the same agent runtime over protocol-4 JSON-RPC. By default, SDK v2 loads a native Rust runtime in-process through a C ABI, without embedding Node.js or starting a separate process. The runtime stays loaded for the application's lifetime, and in-process hosting provides neither crash isolation nor a sandbox (in-process runtime notes). For crash isolation or per-client configuration, the SDK can spawn the runtime as a child process over stdio or TCP; alternatively, you can run a standalone multi-tenant runtime server with copilot-runtime --server and attach over TCP (setup guide).
Quick start
- Install the SDK for your language, for example
npm install @microsoft/copilot-sdk,pip install microsoft-copilot-sdk,go get github.com/microsoft/copilot-sdk/go/v2,dotnet add package Microsoft.Copilot.SDK, orcargo add copilot-sdk. Java uses the Maven coordinatescom.microsoft:copilot-sdkwith separate Maven and Gradle instructions. - Make sure a compatible runtime is available. Node.js and .NET include platform artifacts, Python downloads them, and Rust bundles them by default. Go applications must run the bundler or reference a compatible runtime package, and Java applications must add their platform runtime classifier; follow the language README before creating a client.
- Choose authentication: a signed-in Copilot CLI session, a GitHub OAuth App token, the
COPILOT_GITHUB_TOKEN/GH_TOKEN/GITHUB_TOKENenvironment variables, or BYOK with your own provider keys (authentication docs). - Follow the Getting Started Guide and the language-specific cookbook for client construction and a first agent invocation.
Usage constraints
- Standard use requires a GitHub Copilot subscription and counts each prompt toward the Copilot usage allowance, billed like Copilot CLI (billing details).
- BYOK works without GitHub authentication but supports key-based authentication only; Microsoft Entra ID, managed identities, and third-party identity providers are not supported (BYOK docs).
- By default the SDK exposes Copilot CLI first-party tools, similar to
--allow-all; each SDK's permission handler should approve, deny, or customize tool calls. - Form elicitation schemas should rely on modeled
propertiesandrequiredfields only. Node.js and Rust preserve extra wire metadata and property order; Python, Go, .NET, and Java rebuild the schema and offer no such guarantee. - The project is generally available and follows semantic versioning under the MIT license.
HotRepo's take
On the 2026-11-18 Java daily list the repository ranked 6th with 10 stars gained for the day, against 10,686 total stars and 1,530 forks. That single snapshot shows steady rather than explosive movement on that list; it does not establish a broader trend. The substantive point for readers is the breadth of the offering: one runtime contract shared by six officially supported languages, with documented choices for in-process, child-process, and standalone server hosting, which matters more for adoption than the day's star count.
Written by AI from the project's README, updated . The project's own docs are the source of truth.
You might also like
- github/copilot-sdkEmbed GitHub Copilot's agent loop in your own app without building orchestration, for teams with Copilot access or their own model keys.
- github/copilot-cliA terminal AI coding agent that plans, edits, and debugs code with GitHub context and approval-gated actions.
- github/awesome-copilotA curated catalog of Copilot agents, instruction files, skills and plugins, plus a searchable site to find and install them.
- microsoft/power-platform-skillsLets Copilot CLI and Claude Code build and deploy Power Platform apps through installable Microsoft-authored plugins.
- google-gemini/gemini-skillsAgent skills that teach coding assistants current Gemini API, SDK, and Live API practices.