Skip to content

Never stop coding. Free MIT AI gateway: one endpoint, 375 providers (150+ free), 1,400+ models Kimi, Claude, GPT, Gemini, GLM, DeepSeek, MiniMax. Works with Claude Code, Codex, Cursor, OpenCode, Cline & Copilot. Quota-aware auto-fallback, RTK+Caveman compression saves 15-95% tokens, MCP/A2A, Desktop/PWA. Built by 900+ contributors

1.3 KB
Raw Blame
/**
 * GitHub Enterprise (GHE) Copilot — MITM target descriptor.
 */
import type { MitmTarget } from "../types";

export const GHE_COPILOT_TARGET: MitmTarget = {
  id: "ghe-copilot",
  name: "GitHub Enterprise Copilot",
  icon: "code",
  color: "#10B981",
  // Hosts will be dynamically matched via the configured gheUrl
  // Empty array means "match via provider config" in the MITM layer
  hosts: [],
  port: 443,
  endpointPatterns: ["/chat/completions", "/v1/chat/completions", "/responses"],
  defaultModels: [
    { id: "gpt-4o", name: "GPT-4o", alias: "gpt-4o" },
    { id: "claude-3.5-sonnet", name: "Claude 3.5 Sonnet", alias: "claude-3.5-sonnet" },
    { id: "gemini-2.0-flash", name: "Gemini 2.0 Flash", alias: "gemini-2.0-flash" },
  ],
  setupTutorial: {
    steps: [
      "Configure your GHE Copilot endpoint URL in OmniRoute provider settings",
      "Ensure your GHE instance has Copilot enabled",
      "Sign in to GitHub Enterprise with a Copilot-enabled account",
      "Enable DNS routing for this agent",
      "Restart your IDE (VS Code, JetBrains, etc.)",
      "Done — GHE Copilot now routes via OmniRoute",
    ],
    detection: { command: "code --list-extensions", platform: "all" },
  },
  handler: () =>
    import("../handlers/copilot").then((m) => ({ default: m.CopilotHandler })),
  riskNoticeKey: "providers.riskNotice.oauth",
};