mirror of
https://github.com/sst/opencode.git
synced 2025-07-07 16:14:59 +00:00
Changed handling of OpenRouter requests to add some custom headers so that it can see the app (#613)
Co-authored-by: Dax Raad <d@ironbay.co>
This commit is contained in:
parent
35d6273fb3
commit
63e783ef79
1 changed files with 11 additions and 0 deletions
|
@ -205,6 +205,17 @@ export namespace Provider {
|
|||
},
|
||||
}
|
||||
},
|
||||
openrouter: async (provider) => {
|
||||
return {
|
||||
autoload: false,
|
||||
options: {
|
||||
headers: {
|
||||
"HTTP-Referer": "https://opencode.ai/",
|
||||
"X-Title": "opencode",
|
||||
},
|
||||
},
|
||||
}
|
||||
},
|
||||
}
|
||||
|
||||
const state = App.state("provider", async () => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue