@route_33/opencode 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +21 -0
- package/dist/index.d.ts +16 -0
- package/dist/index.js +1786 -0
- package/dist/tui/index.d.ts +5 -0
- package/dist/tui/index.js +476 -0
- package/package.json +57 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
route33.ai opencode plugin — Proprietary License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Tom Van Damme. All rights reserved.
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted to any person obtaining a copy of this package
|
|
6
|
+
through the public npm registry (the "Package") to install and use the
|
|
7
|
+
Package, unmodified, as a plugin for opencode, for any purpose including
|
|
8
|
+
commercial purposes.
|
|
9
|
+
|
|
10
|
+
You may NOT copy, modify, merge, publish, distribute, sublicense, sell, or
|
|
11
|
+
create derivative works of the Package or any part of it, beyond the
|
|
12
|
+
download and installation performed by npm/opencode as part of normal use.
|
|
13
|
+
The source code of the Package is not licensed for reuse.
|
|
14
|
+
|
|
15
|
+
THE PACKAGE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
20
|
+
FROM, OUT OF OR IN CONNECTION WITH THE PACKAGE OR THE USE OR OTHER DEALINGS
|
|
21
|
+
IN THE PACKAGE.
|
package/README.md
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# @route_33/opencode
|
|
2
|
+
|
|
3
|
+
An opencode provider plugin for the [route33.ai](https://route33.ai) AI gateway: model discovery, cost/limit metadata, and a key-setup wizard in the TUI.
|
|
4
|
+
|
|
5
|
+
## Install
|
|
6
|
+
|
|
7
|
+
Add to the `plugin` array of your opencode config and restart opencode:
|
|
8
|
+
|
|
9
|
+
```json
|
|
10
|
+
{
|
|
11
|
+
"plugin": ["@route_33/opencode@^0.1"]
|
|
12
|
+
}
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Auth
|
|
16
|
+
|
|
17
|
+
Run `opencode auth login` and choose `route_33`, or set the `ROUTE33_API_KEY` environment variable. Without a key, the TUI wizard offers to save one: per-project inside a git workspace, global otherwise. `ROUTE33_BASE_URL` overrides the default gateway URL; `ROUTE33_TUI_PROMPT=0` disables the wizard.
|
|
18
|
+
|
|
19
|
+
## License
|
|
20
|
+
|
|
21
|
+
Proprietary — "SEE LICENSE IN LICENSE". Install and use as-is via npm; copying, modification, and redistribution are not permitted. Provided AS-IS, without warranty or liability.
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Plugin } from '@opencode-ai/plugin';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* opencode provider plugin for the route33.ai AI gateway — the single
|
|
5
|
+
* plugin export (R4: one provider, one auth hook, one entry file).
|
|
6
|
+
*
|
|
7
|
+
* Registers the `config` hook — key-scoped model discovery, cost/limit
|
|
8
|
+
* enrichment, add-only injection into the single `route_33` provider block
|
|
9
|
+
* (per-model native-SDK routing via `provider.npm`) and strict flavour-ref
|
|
10
|
+
* validation — plus the `route_33` auth method and options loader.
|
|
11
|
+
* Discovery runs once at startup; restart opencode after a key or config
|
|
12
|
+
* change.
|
|
13
|
+
*/
|
|
14
|
+
declare const Route33Plugin: Plugin;
|
|
15
|
+
|
|
16
|
+
export { Route33Plugin };
|