P0 fixes: - ModelError.Is(): use exact matching instead of substring contains() - shouldClearStickySession: add context param for cancellation/tracing P1 fixes: - TODO stubs: return 501 Not Implemented errors - validateInstanceSignature: deduplicate to shared validateCodeSignature() - Error messages: standardize to English only - http.go: remove pseudo if-else with duplicate branches
14 lines
463 B
Go
14 lines
463 B
Go
package service
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/Wei-Shaw/sub2api/internal/pkg/geminicli"
|
|
)
|
|
|
|
// GeminiOAuthClient performs Google OAuth token exchange/refresh for Gemini integration.
|
|
type GeminiOAuthClient interface {
|
|
ExchangeCode(ctx context.Context, oauthType, code, codeVerifier, redirectURI, proxyURL string) (*geminicli.TokenResponse, error)
|
|
RefreshToken(ctx context.Context, oauthType, refreshToken, proxyURL string) (*geminicli.TokenResponse, error)
|
|
}
|