mirror of
https://github.com/Wei-Shaw/sub2api.git
synced 2026-11-03 00:33:13 +00:00
feat: add grok subscription support
This commit is contained in:
1 parent
fd9c945fab
commit
39be1ec97f
92 files changed
+3277
-197
No files matched your search
@@ -487,7 +487,7 @@ export interface PaginationConfig {
|
||||
|
||||
// ==================== API Key & Group Types ====================
|
||||
|
||||
export type GroupPlatform = 'anthropic' | 'openai' | 'gemini' | 'antigravity'
|
||||
export type GroupPlatform = 'anthropic' | 'openai' | 'gemini' | 'antigravity' | 'grok'
|
||||
|
||||
export type SubscriptionType = 'standard' | 'subscription'
|
||||
|
||||
@@ -690,7 +690,7 @@ export interface UpdateGroupRequest {
|
||||
|
||||
// ==================== Account & Proxy Types ====================
|
||||
|
||||
export type AccountPlatform = 'anthropic' | 'openai' | 'gemini' | 'antigravity'
|
||||
export type AccountPlatform = 'anthropic' | 'openai' | 'gemini' | 'antigravity' | 'grok'
|
||||
export type AccountType = 'oauth' | 'setup-token' | 'apikey' | 'upstream' | 'bedrock' | 'service_account'
|
||||
export type OAuthAddMethod = 'oauth' | 'setup-token'
|
||||
export type ProxyProtocol = 'http' | 'https' | 'socks5' | 'socks5h'
|
||||
@@ -944,6 +944,13 @@ export interface AntigravityModelQuota {
|
||||
reset_time: string // 重置时间 ISO8601
|
||||
}
|
||||
|
||||
export interface GrokQuotaWindow {
|
||||
limit?: number
|
||||
remaining?: number
|
||||
reset_unix?: number
|
||||
reset_at?: string
|
||||
}
|
||||
|
||||
export interface AccountUsageInfo {
|
||||
source?: 'passive' | 'active'
|
||||
updated_at: string | null
|
||||
@@ -957,6 +964,12 @@ export interface AccountUsageInfo {
|
||||
gemini_pro_minute?: UsageProgress | null
|
||||
gemini_flash_minute?: UsageProgress | null
|
||||
antigravity_quota?: Record<string, AntigravityModelQuota> | null
|
||||
grok_request_quota?: GrokQuotaWindow | null
|
||||
grok_token_quota?: GrokQuotaWindow | null
|
||||
grok_retry_after_seconds?: number | null
|
||||
grok_entitlement_status?: string
|
||||
grok_quota_snapshot_state?: string
|
||||
grok_local_usage?: WindowStats | null
|
||||
ai_credits?: Array<{
|
||||
credit_type?: string
|
||||
amount?: number
|
||||
|
||||
Reference in new issue
Block a user