Feat: GitHub Copilot Student Integration via Device Flow#513
Open
wticllasucal wants to merge 10 commits intorowboatlabs:mainfrom
Open
Feat: GitHub Copilot Student Integration via Device Flow#513wticllasucal wants to merge 10 commits intorowboatlabs:mainfrom
wticllasucal wants to merge 10 commits intorowboatlabs:mainfrom
Conversation
added 10 commits
April 17, 2026 09:14
- Add github-copilot as LLM provider flavor in schema - Implement GitHub Copilot API integration using OpenAI-compatible endpoint - Add OAuth Device Flow implementation (RFC 8628) for GitHub authentication - Configure GitHub OAuth endpoints and client ID - Add comprehensive documentation for GitHub Copilot integration This allows users to authenticate with GitHub and use GitHub Copilot models (GPT-4o, GPT-4, etc.) directly in Rowboat using device code flow authentication.
- Add github-copilot-auth.ts: Complete Device Flow authentication service with token management and refresh logic - Add github-copilot-models.ts: Model discovery and LLM provider integration for GitHub Copilot - Make createProvider() async to support Device Flow OAuth authentication - Update all createProvider() calls to await the async result - Ensure proper token storage/retrieval from oauth.json - Support automatic token refresh with fallback to re-authentication - Add error handling for expired tokens and authentication failures - All packages compile successfully without errors
…ation - Add github-copilot.test.ts with 25+ test cases - Tests cover Device Flow (request, polling, error handling) - Tests cover authentication service (start, token management) - Tests cover model discovery and validation - Update GITHUB_COPILOT_INTEGRATION.md with complete implementation details - Document all features, architecture, and usage patterns - Include token storage, refresh logic, and error handling
- Add step-by-step testing procedures for all components - Include manual Device Flow authentication testing - Add LLM provider testing examples - Include token storage and refresh verification - Add model discovery and disconnection tests - Provide troubleshooting guide - Add security notes and best practices
- Add exclusion for .test.ts and .spec.ts files in core tsconfig - Allows tests to exist in source without blocking compilation
- Remove unused imports in github-copilot-auth.ts - Remove unused variable in github-copilot-device-flow.ts - Add eslint-disable comment for any in test file
- Add 'github-copilot' to LlmProviderFlavor type in settings dialog - Add GitHub Copilot Student to moreProviders array in UI - Add github-copilot to initial providerConfigs state - Add isGitHubCopilot flag to handle Device Flow auth flow - Add GitHub Copilot authentication button in settings UI - Add GitHub Copilot models (6 models) to listOnboardingModels() output - Add eslint-disable comment for mock fetch in tests This fixes the issue where GitHub Copilot Student was not appearing in the Models dropdown in the Settings dialog.
- Add IPC handlers for github-copilot:authenticate, isAuthenticated, disconnect - Add schema definitions for new IPC handlers in shared/ipc.ts - Implement Device Flow authentication button with real flow - Show device code and verification URL to user when authenticating - Automatically open GitHub verification page in browser - Auto-load models after successful authentication - Update GitHub Copilot model list (gpt-4o, gpt-4-turbo, gpt-3.5-turbo, claude-3.5-sonnet) - Display loading state and error messages in UI - Properly integrate with existing auth service This fixes the broken authentication flow where the button didn't do anything.
…ken type case (Bearer, bearer, etc)
… internal API exchange
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Disconnectcapabilities.api.github.com/copilot_internal/v2/token) dynamically.@ai-sdk/openai-compatibleproxy configured toapi.githubcopilot.comto prevent SDK incompatibilities (resolves "model not supported via Responses API" issues).gpt-4o,claude-3.5-sonnet,gemini-3.1-pro-preview, etc.).