Skip to content

feat(node-providers): implement openrouter provider#196

Merged
calchiwo merged 1 commit intomainfrom
feat/node-openrouter-provider
Mar 22, 2026
Merged

feat(node-providers): implement openrouter provider#196
calchiwo merged 1 commit intomainfrom
feat/node-openrouter-provider

Conversation

@calchiwo
Copy link
Copy Markdown
Owner

Add OpenRouter provider for the Node CLI.

Implements the provider using the OpenAI-compatible interface and integrates with the existing provider system.

Changes

  • Implemented OpenRouterProvider

  • Integrated provider into registry

  • Enabled usage via --llm openrouter

  • Added support for OpenRouter config in config.toml

Provider Behavior

  • Requires api_key

  • Requires model to be defined in config

  • Uses OpenAI client with OpenRouter base URL

  • Returns generated text from chat.completions.create

All OpenRouter-specific logic is contained within the provider.

Usage

explainthisrepo owner/repo --llm openrouter

Configuration

[llm]
provider = "openrouter"

[providers.openrouter]
api_key = "sk-or-..."
model = "openai/gpt-4o"

Notes

  • No default model

  • Supports any valid OpenRouter model (provider/model format)

  • No changes to CLI or core generation pipeline were required

@vercel
Copy link
Copy Markdown

vercel bot commented Mar 22, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
explainthisrepo Ready Ready Preview, Comment Mar 22, 2026 10:08pm

@calchiwo calchiwo merged commit 67e107b into main Mar 22, 2026
7 checks passed
@calchiwo calchiwo added the node Pull requests that update the node code label Mar 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

node Pull requests that update the node code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant