feat(payment): add new DeepSeek V4 models to claw402 endpoints and pricing (#1488)

- Introduced "deepseek-v4-flash" and "deepseek-v4-pro" endpoints in claw402ModelEndpoints.
- Updated modelPrices to include pricing for the new DeepSeek V4 models.
- Added model constants for the new DeepSeek V4 models in the trader component.

Co-authored-by: Dean <afei.wuhao@gmail.com>
This commit is contained in:
deanokk
2026-04-24 14:44:28 +08:00
committed by GitHub
parent 5d6ec35bb4
commit 3dbf5beece
3 changed files with 14 additions and 8 deletions
+2
View File
@@ -65,6 +65,8 @@ var claw402ModelEndpoints = map[string]string{
// DeepSeek // DeepSeek
"deepseek": "/api/v1/ai/deepseek/chat", "deepseek": "/api/v1/ai/deepseek/chat",
"deepseek-reasoner": "/api/v1/ai/deepseek/chat/reasoner", "deepseek-reasoner": "/api/v1/ai/deepseek/chat/reasoner",
"deepseek-v4-flash": "/api/v1/ai/deepseek/v4-flash",
"deepseek-v4-pro": "/api/v1/ai/deepseek/v4-pro",
// Qwen // Qwen
"qwen-max": "/api/v1/ai/qwen/chat/max", "qwen-max": "/api/v1/ai/qwen/chat/max",
"qwen-plus": "/api/v1/ai/qwen/chat/plus", "qwen-plus": "/api/v1/ai/qwen/chat/plus",
+10 -8
View File
@@ -22,18 +22,20 @@ func (AICharge) TableName() string { return "ai_charges" }
var modelPrices = map[string]float64{ var modelPrices = map[string]float64{
"deepseek": 0.003, "deepseek": 0.003,
"deepseek-reasoner": 0.005, "deepseek-reasoner": 0.005,
"deepseek-v4-flash": 0.003,
"deepseek-v4-pro": 0.01,
"gpt-5.4": 0.05, "gpt-5.4": 0.05,
"gpt-5.4-pro": 0.50, "gpt-5.4-pro": 0.50,
"gpt-5.3": 0.01, "gpt-5.3": 0.01,
"gpt-5-mini": 0.005, "gpt-5-mini": 0.005,
"claude-opus": 0.12, "claude-opus": 0.12,
"qwen-max": 0.01, "qwen-max": 0.01,
"qwen-plus": 0.005, "qwen-plus": 0.005,
"qwen-turbo": 0.002, "qwen-turbo": 0.002,
"qwen-flash": 0.002, "qwen-flash": 0.002,
"grok-4.1": 0.06, "grok-4.1": 0.06,
"gemini-3.1-pro": 0.03, "gemini-3.1-pro": 0.03,
"kimi-k2.5": 0.008, "kimi-k2.5": 0.008,
} }
// GetModelPrice returns the price per call for a given model // GetModelPrice returns the price per call for a given model
@@ -43,6 +43,8 @@ export function getShortName(fullName: string): string {
// Models available through Claw402 (x402 USDC payment protocol) // Models available through Claw402 (x402 USDC payment protocol)
export const CLAW402_MODELS: Claw402Model[] = [ export const CLAW402_MODELS: Claw402Model[] = [
{ id: 'deepseek-v4-flash', name: 'DeepSeek V4 Flash', provider: 'DeepSeek', desc: '$0.003/call', icon: '⚡', price: 0.003 },
{ id: 'deepseek-v4-pro', name: 'DeepSeek V4 Pro', provider: 'DeepSeek', desc: '$0.01/call', icon: '🧠', price: 0.01 },
{ id: 'deepseek', name: 'DeepSeek V3', provider: 'DeepSeek', desc: '$0.003/call', icon: '🔥', price: 0.003 }, { id: 'deepseek', name: 'DeepSeek V3', provider: 'DeepSeek', desc: '$0.003/call', icon: '🔥', price: 0.003 },
{ id: 'deepseek-reasoner', name: 'DeepSeek R1', provider: 'DeepSeek', desc: '$0.005/call', icon: '🤔', price: 0.005 }, { id: 'deepseek-reasoner', name: 'DeepSeek R1', provider: 'DeepSeek', desc: '$0.005/call', icon: '🤔', price: 0.005 },
{ id: 'gpt-5-mini', name: 'GPT-5 Mini', provider: 'OpenAI', desc: '$0.005/call', icon: '🚀', price: 0.005 }, { id: 'gpt-5-mini', name: 'GPT-5 Mini', provider: 'OpenAI', desc: '$0.005/call', icon: '🚀', price: 0.005 },