GitHub Copilot SDK Languages: The 6 Official SDKs Explained

GitHub Copilot provides first-class SDKs for six programming languages—Node.js / TypeScript, Python, Go, .NET, Rust, and Java—each exposing the same agentic runtime through a JSON-RPC client that communicates with the Copilot CLI server.

The github/copilot-sdk repository enables developers to embed Copilot's agentic capabilities directly into applications across multiple stacks. Every official SDK implements an identical protocol, allowing teams to choose their preferred language without redesigning their AI workflow. Understanding the SDK languages supported by GitHub Copilot ensures you pick the right client library for your automation tools, backend services, or scripting environments.

How the GitHub Copilot SDK Architecture Works

All six SDKs share a common runtime pattern documented in the repository's top-level README. According to the github/copilot-sdk source code, the workflow follows four steps:

  1. Application code imports the language-specific client.
  2. The client starts (or connects to) the Copilot CLI in server mode.
  3. Calls are marshalled over JSON-RPC to the CLI process.
  4. The CLI handles planning, tool execution, and model inference, returning events back to the SDK.
Your App → SDK Client → JSON-RPC → Copilot CLI (server)

Because each SDK implements the same protocol, developers can switch languages without rebuilding their integration logic.

Node.js / TypeScript SDK

The Node.js / TypeScript SDK lives in the nodejs/ directory and is distributed via npm as @github/copilot-sdk.

npm install @github/copilot-sdk

The core client logic resides in nodejs/src/client.ts, where the CopilotClient class wraps the JSON-RPC transport.

import { CopilotClient } from "@github/copilot-sdk";

const client = new CopilotClient();
const session = await client.createSession();
const response = await session.chat({ content: "Explain the difference between const and let." });
console.log(response.message);

Python SDK

The Python SDK is located under python/ and installs from PyPI as github-copilot-sdk.

pip install github-copilot-sdk

The main entry point is python/copilot/client.py, exposing the CopilotClient class and create_session() method.

from copilot.client import CopilotClient

client = CopilotClient()
session = client.create_session()
msg = session.chat("Explain the difference between list and tuple.")
print(msg.message)

Go SDK

The Go SDK is maintained in the go/ folder and can be added with go get.

go get github.com/github/copilot-sdk/go

go/client.go defines copilot.NewClient(), CreateSession(), and the Chat method used in the snippet below.

import "github.com/github/copilot-sdk/go"

func main() {
    client := copilot.NewClient()
    sess, _ := client.CreateSession(context.Background())
    resp, _ := sess.Chat(context.Background(), "Explain the difference between slices and arrays.")
    fmt.Println(resp.Message)
}

.NET SDK

The .NET SDK ships from the dotnet/ directory as the NuGet package GitHub.Copilot.SDK.

dotnet add package GitHub.Copilot.SDK

Session management is implemented in dotnet/src/Session.cs, while the CopilotClient class provides CreateSessionAsync() and ChatAsync().

using GitHub.Copilot.SDK;

var client = new CopilotClient();
var session = await client.CreateSessionAsync();
var result = await session.ChatAsync("Explain the difference between async and await.");
Console.WriteLine(result.Message);

Rust SDK

The Rust SDK is hosted in rust/ and published to crates.io as github-copilot-sdk.

cargo add github-copilot-sdk

rust/src/client.rs contains the async CopilotClient implementation.

use github_copilot_sdk::client::CopilotClient;

#[tokio::main]
async fn main() {
    let client = CopilotClient::new().await.unwrap();
    let session = client.create_session().await.unwrap();
    let response = session.chat("Explain the difference between Result and Option.").await.unwrap();
    println!("{}", response.message);
}

Java SDK

The Java SDK resides under java/ and is available via Maven with the coordinates com.github:copilot-sdk-java. Setup details are listed in the repository's top-level README under the Available SDKs section.

java/src/main/java/com/github/copilot/sdk/Client.java implements the CopilotClient class.

import com.github.copilot.sdk.CopilotClient;
import com.github.copilot.sdk.Session;

CopilotClient client = new CopilotClient();
Session session = client.createSession();
String reply = session.chat("Explain the difference between Stream and Iterable.");
System.out.println(reply);

Summary

  • GitHub Copilot officially supports six SDK languages: Node.js / TypeScript, Python, Go, .NET, Rust, and Java.
  • Each SDK communicates with the Copilot CLI server over a shared JSON-RPC protocol, ensuring consistent behavior across languages.
  • Core client classes such as CopilotClient and methods like createSession() and chat() are implemented in every SDK.
  • Key source files including nodejs/src/client.ts, python/copilot/client.py, and go/client.go demonstrate how each language wraps the transport layer.
  • Because the runtime architecture is identical, teams can migrate between languages without re-architecting their Copilot integration.

Frequently Asked Questions

Which SDK languages does GitHub Copilot support?

GitHub Copilot supports six SDK languages: Node.js / TypeScript, Python, Go, .NET, Rust, and Java. Each SDK is maintained in its own directory within the github/copilot-sdk repository and connects to the same Copilot CLI backend via JSON-RPC.

Are all GitHub Copilot SDKs functionally identical?

Yes. As implemented in github/copilot-sdk, every SDK exposes the same agentic runtime and protocol. An application imports its language-specific client, starts a Copilot CLI server session, and marshalls calls over JSON-RPC, regardless of whether the code is written in Python, Go, Rust, or another supported language.

Where can I find the core source files for each GitHub Copilot SDK?

The core client source files are nodejs/src/client.ts for Node.js / TypeScript, python/copilot/client.py for Python, go/client.go for Go, dotnet/src/Session.cs for .NET, rust/src/client.rs for Rust, and java/src/main/java/com/github/copilot/sdk/Client.java for Java.

How do I install the GitHub Copilot SDK for my language?

Installation commands vary by ecosystem: use npm install @github/copilot-sdk for Node.js, pip install github-copilot-sdk for Python, go get github.com/github/copilot-sdk/go for Go, dotnet add package GitHub.Copilot.SDK for .NET, cargo add github-copilot-sdk for Rust, and add the Maven dependency com.github:copilot-sdk-java for Java.

Have a question about this repo?

These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:

Share the following with your agent to get started:
curl -s "https://instagit.com/install.md"

Works with
Claude Codex Cursor VS Code OpenClaw Any MCP Client

Maintain an open-source project? Get it listed too →