Skip to content

feat: add GitHub Copilot SDK agent binding - #189

Merged
hallvictoria merged 13 commits into
devfrom
hallvictoria/copilot-sdk-binding
Oct 29, 2026
Merged

hallvictoria merged 13 commits into
devfrom
hallvictoria/copilot-sdk-binding

Conversation

@hallvictoria

@hallvictoria hallvictoria commented Sep 30, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Adds azurefunctions-agents-extensions-copilot-sdk, an Azure Functions Agent binding provider that injects GitHub Copilot SDK sessions built from raw .agent.md instructions. Adds a skill for adding new Agent Bindings.

Binding lifecycle

  • The injected SDK type is copilot.session.CopilotSession.
  • The binding lazily creates and caches one CopilotClient, then creates and closes a fresh CopilotSession for each Function invocation.
  • By default, the binding creates CopilotClient(mode="empty") with COPILOT_GITHUB_TOKEN and an isolated COPILOT_BASE_DIRECTORY, disables telemetry and interactive logged-in-user authentication, and reads the session model from COPILOT_MODEL.

Public configuration

AgentFunctionApp(...) accepts model, client_factory, app_root, on_permission_request, provider, tools, session_options, and http_auth_level. It defaults on_permission_request to PermissionHandler.approve_all, which is intended only for trusted tools.

@app.markdown_agent(...) requires arg_name and agent_name and accepts the same session arguments a customer would pass directly to CopilotClient.create_session(...):

@app.markdown_agent(
    arg_name="agent",
    agent_name="orders",
    streaming=True,
    reasoning_effort="high",
    ...
)

The extension forwards these values when creating the injected session. Unsupported argument names fail with a clear validation error. The decorator can also override client_factory, model, on_permission_request, provider, and tools for one binding.

Capabilities

  • Discovers skills/*/SKILL.md and remote HTTP MCP servers from mcp.json, including tool allowlists, environment expansion, static headers, and optional Entra authentication.
  • Supports Durable orchestrations by routing Agent calls through the generated activity binding.

Fixes https://github.com/Azure/azure-functions-bucees-planning/issues/1356

This comment was marked as resolved.

This comment was marked as resolved.

This comment was marked as resolved.

This comment was marked as resolved.

@hallvictoria
hallvictoria merged commit 11568c2 into dev Oct 29, 2026
58 checks passed
@hallvictoria
hallvictoria deleted the hallvictoria/copilot-sdk-binding branch October 29, 2026 18:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants