/* Copyright (C) 2025 QuantumNous */ import React, { useState, useEffect, useCallback, useRef, useContext } from 'react'; import { Link, useNavigate } from 'react-router-dom'; import { useTranslation } from 'react-i18next'; import { Copy, Check, Box, Grid3X3, Trophy, BookOpen, Zap, Shield, Globe, ArrowRight, Layers, Sparkles, ArrowUpRight, Cpu, CreditCard, RefreshCw, MessageSquare, Send, Terminal, Database, Workflow, Lock, BarChart3, Users, ChevronRight, Cloud, Server, Activity, TrendingUp, Headphones, FileText, Key, Settings, Monitor, Smartphone, BarChart2, Globe2, } from 'lucide-react'; import { UserContext } from '../../context/User'; import { stringToColor, getSystemName } from '../../helpers'; /* ═══════════════ SECTION 1: HERO ═══════════════ */ function Hero() { const { t } = useTranslation(); const [userState] = useContext(UserContext); const [copied, setCopied] = useState(false); const copyUrl = useCallback(() => { navigator.clipboard.writeText('https://api.turingtoken.ai'); setCopied(true); setTimeout(() => setCopied(false), 1500); }, []); return (
{/* Background decorative elements */}
{/* Grid pattern */}
{/* Nav */} {/* Content */}
{/* Left */}
Unified AI Gateway

{t('更快、更稳、更省')}
{t('Token服务平台')}

{t('兼容 OpenAI / Claude / Gemini 等协议,覆盖文本、图像、视频、语音,智能路由,统一计费。')}

{t('开始使用')} {t('查看价格')}
{/* Stats */}
{[ { n: '80+', l: 'AI 模型' }, { n: '40+', l: '供应商' }, { n: '99.9%', l: '可用率' }, ].map((s, i) => (
{s.n}
{s.l}
))}
{/* Right — Code card */}
{/* Header */}
terminal
{/* Code */}
# Quick start with curl
curl{' '} https://api.turingtoken.ai/v1/chat/completions \
{' '}-H "Authorization: Bearer $KEY" \
{' '}-H "Content-Type: application/json" \
{' '}-d '{'{'}
{' '}"model": "gpt-4o",
{' '}"messages": [{'{'}"role": "user", "content": "Hello"{'}'}]
{'}'}'
# Response
{'{'} "choices": [{'{'} "message": {'{'} "content": "Hello! How can I help?" {'}'} {'}'}] {'}'}
{/* Bottom marquee */}
{[...Array(3)].fill(null).map((_, gi) => ( {['OpenAI', 'Claude', 'Gemini', 'DeepSeek', 'Qwen', 'MiniMax', 'Kimi', '智谱', 'Groq', 'Azure'].map((name, i) => ( {name} ))} ))}
); } /* ═══════════════ SECTION 2: CAPABILITIES ═══════════════ */ const CAPABILITIES = [ { icon: , title: '多协议兼容', desc: '原生支持 OpenAI、Claude、Gemini,切换 Base URL 即可接入' }, { icon: , title: '智能路由', desc: '根据模型名称自动路由至最优供应商,无需关心底层调度' }, { icon: , title: '统一计费', desc: '跨供应商统一 Token 消耗统计与账单,告别多平台充值' }, { icon: , title: '容错降级', desc: '多供应商端点自动切换,逐级降级保障服务持续可用' }, { icon: , title: '模型丰富', desc: '接入 80+ 主流模型,覆盖文本、图像、视频、语音全模态' }, { icon: , title: '开箱即用', desc: '一键登录,分钟级接入,兼容现有 SDK,零迁移成本' }, ]; function Capabilities() { const { t } = useTranslation(); return (

{t('平台核心能力')}

一个 API 网关,连接所有主流 AI 模型供应商

{CAPABILITIES.map((p, i) => (
{p.icon}

{t(p.title)}

{t(p.desc)}

))}
); } /* ═══════════════ SECTION 3: HOW IT WORKS ═══════════════ */ const STEPS = [ { n: '01', title: '注册账号', desc: '通过邮箱一键注册,即刻开始使用。', icon: , link: '/register' }, { n: '02', title: '创建 API Key', desc: '在控制台创建密钥,支持多 Key 管理。', icon: , link: '/console/token' }, { n: '03', title: '发起请求', desc: '使用你熟悉的 SDK 调用任意模型。', icon: , link: '/pricing' }, ]; function HowItWorks() { const { t } = useTranslation(); return (

{t('三步接入,分钟级上线')}

{STEPS.map((s, i) => (
{s.icon}
{s.n}

{t(s.title)}

{t(s.desc)}

{i < STEPS.length - 1 && (
)} ))}
); } /* ═══════════════ SECTION 5: QUICK START ═══════════════ */ const PROVS = ['openai', 'claude', 'gemini']; const PROV_LABELS = { openai: 'OpenAI', claude: 'Claude', gemini: 'Gemini' }; const LANGS = ['curl', 'python', 'nodejs']; const LANG_LABELS = { curl: 'cURL', python: 'Python', nodejs: 'Node.js' }; const SAMPLES = { openai: { curl: `curl https://api.turingtoken.ai/v1/chat/completions \\ -H "Authorization: Bearer $OPENAI_API_KEY" \\ -H "Content-Type: application/json" \\ -d '{ "model": "gpt-4o", "messages": [{"role": "user", "content": "Hello!"}] }'`, python: `from openai import OpenAI client = OpenAI( base_url="https://api.turingtoken.ai", api_key="sk-your-key" ) response = client.chat.completions.create( model="gpt-4o", messages=[{"role": "user", "content": "Hello!"}] ) print(response.choices[0].message.content)`, nodejs: `import OpenAI from "openai"; const client = new OpenAI({ baseURL: "https://api.turingtoken.ai", apiKey: "sk-your-key", }); const response = await client.chat.completions.create({ model: "gpt-4o", messages: [{ role: "user", content: "Hello!" }], }); console.log(response.choices[0].message.content);`, }, claude: { curl: `curl https://api.turingtoken.ai/v1/messages \\ -H "x-api-key: sk-your-key" \\ -H "anthropic-version: 2023-06-01" \\ -H "Content-Type: application/json" \\ -d '{ "model": "claude-sonnet-4-20250514", "max_tokens": 1024, "messages": [{"role": "user", "content": "Hello!"}] }'`, python: `import anthropic client = anthropic.Anthropic( base_url="https://api.turingtoken.ai", api_key="sk-your-key" ) response = client.messages.create( model="claude-sonnet-4-20250514", max_tokens=1024, messages=[{"role": "user", "content": "Hello!"}] ) print(response.content[0].text)`, nodejs: `import Anthropic from "@anthropic-ai/sdk"; const client = new Anthropic({ baseURL: "https://api.turingtoken.ai", apiKey: "sk-your-key", }); const response = await client.messages.create({ model: "claude-sonnet-4-20250514", max_tokens: 1024, messages: [{ role: "user", content: "Hello!" }], }); console.log(response.content[0].text);`, }, gemini: { curl: `curl "https://api.turingtoken.ai/v1beta/models/gemini-2.0-flash:generateContent?key=sk-your-key" \\ -H "Content-Type: application/json" \\ -d '{ "contents": [{"parts":[{"text": "Hello!"}]}] }'`, python: `import google.generativeai as genai genai.configure(api_key="sk-your-key") model = genai.GenerativeModel("gemini-2.0-flash") response = model.generate_content("Hello!") print(response.text)`, nodejs: `import { GoogleGenerativeAI } from "@google/generative-ai"; const genAI = new GoogleGenerativeAI("sk-your-key"); const model = genAI.getGenerativeModel({ model: "gemini-2.0-flash" }); const result = await model.generateContent("Hello!"); console.log(result.response.text());`, }, }; function QuickStart() { const { t } = useTranslation(); const [prov, setProv] = useState('openai'); const [lang, setLang] = useState('curl'); const [copied, setCopied] = useState(false); const code = SAMPLES[prov]?.[lang] || ''; const copy = useCallback(() => { navigator.clipboard.writeText(code); setCopied(true); setTimeout(() => setCopied(false), 1500); }, [code]); return (

{t('快速开始')}

{PROVS.map(p => ( ))}
{LANGS.map(l => ( ))}
{code}

Model Pricing

{t('查看模型定价,了解完整列表')}

); } /* ═══════════════ SECTION 6: CTA ═══════════════ */ function CTA() { const { t } = useTranslation(); return (
限时活动
SPECIAL OFFER

{t('注册即送 ¥10 额度')}

{t('新用户注册即赠 ¥10 Token,7 天有效期。兼容 OpenAI / Claude / Gemini 协议,一个 API Key 调用所有主流模型。')}

无需绑定信用卡 即开即用 按量计费
{t('免费注册')} {t('查看价格')}
); } /* ═══════════════ SECTION 7: STATS ═══════════════ */ function Stats() { const { t } = useTranslation(); const nav = useNavigate(); return (
{[ { n: '80+', l: 'AI 模型', d: '覆盖主流模型' }, { n: '40+', l: '供应商', d: '全球优质渠道' }, { n: '99.9%', l: '可用率', d: '稳定可靠' }, { n: '<100ms', l: '响应延迟', d: '极速响应' }, ].map((s, i) => (
{s.n}
{s.l}
{s.d}
))}
); } /* ═══════════════ SECTION 8: PRICING PREVIEW ═══════════════ */ const PRICING_MODELS = [ { name: 'deepseek-V4', input: '¥0.014/1K', output: '¥0.056/1K' }, { name: 'deepseek-v4-Flash', input: '¥0.0028/1K', output: '¥0.011/1K' }, { name: 'MiniMax-M2.1', input: '¥0.014/1K', output: '¥0.056/1K' }, { name: 'MiniMax-M2.5', input: '¥0.017/1K', output: '¥0.067/1K' }, ]; function PricingPreview() { const { t } = useTranslation(); const nav = useNavigate(); return (

{t('透明定价')}

按量计费,用多少付多少,无隐藏费用

模型
输入价格
输出价格
操作
{PRICING_MODELS.map((m, i) => (
{m.name}
{m.input}
{m.output}
))}
); } /* ═══════════════ SECTION 10: TESTIMONIALS ═══════════════ */ const TESTIMONIALS = [ { name: '张工', role: 'AI 创业公司 CTO', content: '接入 TuringToken 后,我们无需逐一对接各家 API,开发效率提升了 3 倍。智能路由让我们的服务稳定性达到了 99.95%。' }, { name: '李经理', role: '互联网大厂技术负责人', content: '统一计费功能非常实用,以前每个月要对账 5 家供应商,现在一个后台全搞定。成本降低了 20%。' }, { name: '王同学', role: '独立开发者', content: '作为个人开发者,最看重的是按量计费和免费额度。TuringToken 让我能用上 GPT-4o 而不用担心账单。' }, ]; function Testimonials() { const { t } = useTranslation(); return (

{t('用户评价')}

来自真实用户的声音

{TESTIMONIALS.map((t, i) => (
{t.name.charAt(0)}
{t.name}
{t.role}

"{t.content}"

{[1,2,3,4,5].map(s => ( ))}
))}
); } /* ═══════════════ SECTION 11: FAQ ═══════════════ */ const FAQS = [ { q: '什么是 TuringToken?', a: 'TuringToken 是一个统一的 AI 网关平台,通过一个 API Key 即可调用 OpenAI、Claude、Gemini 等多家主流大模型,无需分别对接。' }, { q: '如何开始使用?', a: '注册账号后,在控制台创建 API Key,将 Base URL 设置为 api.turingtoken.ai 即可。兼容现有 OpenAI SDK,无需修改代码。' }, { q: '支持哪些模型?', a: '目前支持 80+ 模型,包括 GPT-4o、Claude 3.5 Sonnet、Gemini 1.5 Pro、DeepSeek V3、通义千问、智谱 GLM-4 等主流模型。' }, { q: '计费方式是什么?', a: '按 Token 消耗量计费,用多少付多少。新用户注册即送 ¥10 额度,7 天有效期。无最低消费,无月费。' }, { q: '数据安全如何保障?', a: '我们不存储任何请求和响应内容,所有数据仅用于实时转发。支持 HTTPS 加密传输,企业版可选私有部署。' }, ]; function FAQ() { const { t } = useTranslation(); const [openIdx, setOpenIdx] = useState(null); return (

{t('常见问题')}

如有其他问题,请联系 support@turingtoken.ai

{FAQS.map((f, i) => (
{openIdx === i && (

{f.a}

)}
))}
); } /* ═══════════════ SECTION: CONTACT US ═══════════════ */ function ContactUs() { const { t } = useTranslation(); return (

{t('联系我们')}

如有任何问题或合作需求,欢迎随时联系

{t('邮箱联系')}

support@turingtoken.com

{t('在线客服')}

工作日 9:00 - 18:00 在线

{t('商务合作')}

business@turingtoken.com

); } /* ═══════════════ FOOTER ═══════════════ */ function Footer() { const { t } = useTranslation(); return (
TuringToken

统一 AI 网关,一个 API 连接所有主流大模型。

产品

{t('定价')} {t('控制台')} {t('模型评测')}

支持

{t('文档')} {t('关于我们')} support@turingtoken.ai

法律

服务协议 隐私政策 合规声明
© 2026 {getSystemName()} All rights reserved. Powered by QuantumNous
); } /* ═══════════════ EXPORT ═══════════════ */ const Home = () => (
); export default Home;