mirror of
https://github.com/sst/opencode.git
synced 2025-08-27 08:24:06 +00:00
fix anthropic console auth (#2049)
This commit is contained in:
parent
5d12cadba7
commit
f19586cebd
10 changed files with 121 additions and 24 deletions
|
@ -32,12 +32,16 @@ export interface Hooks {
|
|||
| {
|
||||
method: "auto"
|
||||
callback(): Promise<
|
||||
| {
|
||||
| ({
|
||||
type: "success"
|
||||
refresh: string
|
||||
access: string
|
||||
expires: number
|
||||
}
|
||||
} & (
|
||||
| {
|
||||
refresh: string
|
||||
access: string
|
||||
expires: number
|
||||
}
|
||||
| { key: string }
|
||||
))
|
||||
| {
|
||||
type: "failed"
|
||||
}
|
||||
|
@ -46,12 +50,16 @@ export interface Hooks {
|
|||
| {
|
||||
method: "code"
|
||||
callback(code: string): Promise<
|
||||
| {
|
||||
| ({
|
||||
type: "success"
|
||||
refresh: string
|
||||
access: string
|
||||
expires: number
|
||||
}
|
||||
} & (
|
||||
| {
|
||||
refresh: string
|
||||
access: string
|
||||
expires: number
|
||||
}
|
||||
| { key: string }
|
||||
))
|
||||
| {
|
||||
type: "failed"
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue