Repository navigation
Commit 24e3801
authored
fix minimax use (chriswritescode-dev#44)
* Fix provider API key storage to match OpenCode schema
Backend was writing credentials with type 'apiKey' and field 'apiKey',
but OpenCode expects type 'api' and field 'key'. This caused UI-set
credentials to be silently ignored while environment variables worked.
- Update AuthEntrySchema to use 'api' type and 'key' field
- Update AuthService.set() to write new format
- Add migration to convert existing entries on read
Fixes chriswritescode-dev#40
* Add auth service tests to validate schema fix and migration
Tests verify:
- Migration from old 'apiKey' format to 'api' format
- New credentials are written in correct format
- getAll, set, delete, list, and has methods work correctly
---------
Co-authored-by: Chris Scott <[email protected]>1 parent b91cebf commit 24e3801
3 files changed
Lines changed: 391 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
13 | 23 | | |
14 | 24 | | |
15 | 25 | | |
16 | | - | |
17 | | - | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
18 | 45 | | |
19 | 46 | | |
20 | 47 | | |
| |||
27 | 54 | | |
28 | 55 | | |
29 | 56 | | |
30 | | - | |
31 | | - | |
| 57 | + | |
| 58 | + | |
32 | 59 | | |
33 | 60 | | |
34 | 61 | | |
| |||
0 commit comments