refactor: replace api.tokendance.space with api.turingtoken.ai on homepage
This commit is contained in:
parent
6eec903060
commit
4f8cde37d8
|
|
@ -1,4 +1,4 @@
|
||||||
/*
|
/*
|
||||||
Copyright (C) 2025 QuantumNous
|
Copyright (C) 2025 QuantumNous
|
||||||
|
|
||||||
This program is free software: you can redistribute it and/or modify
|
This program is free software: you can redistribute it and/or modify
|
||||||
|
|
@ -216,7 +216,7 @@ function HeroSection() {
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
<pre className="p-5 text-sm font-mono leading-relaxed text-white/80 overflow-x-auto">
|
<pre className="p-5 text-sm font-mono leading-relaxed text-white/80 overflow-x-auto">
|
||||||
<code>{`curl https://api.tokendance.space/v1/chat/completions \\
|
<code>{`curl https://api.turingtoken.ai/v1/chat/completions \\
|
||||||
-H "Authorization: Bearer \$YOUR_API_KEY" \\
|
-H "Authorization: Bearer \$YOUR_API_KEY" \\
|
||||||
-H "Content-Type: application/json" \\
|
-H "Content-Type: application/json" \\
|
||||||
-d '{
|
-d '{
|
||||||
|
|
@ -259,7 +259,7 @@ function HeroSection() {
|
||||||
titleKey: '多协议兼容',
|
titleKey: '多协议兼容',
|
||||||
descKey:
|
descKey:
|
||||||
'原生支持 OpenAI、Claude、Gemini 文本协议,覆盖图像 / 视频 / 文本转语音生成。无需修改代码,切换 Base URL 即可接入。',
|
'原生支持 OpenAI、Claude、Gemini 文本协议,覆盖图像 / 视频 / 文本转语音生成。无需修改代码,切换 Base URL 即可接入。',
|
||||||
code: 'baseURL: "api.tokendance.space"',
|
code: 'baseURL: "api.turingtoken.ai"',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
titleKey: '智能路由',
|
titleKey: '智能路由',
|
||||||
|
|
@ -408,7 +408,7 @@ const LANG_LABELS = { curl: 'cURL', python: 'Python', nodejs: 'Node.js' };
|
||||||
|
|
||||||
const CODE_SAMPLES = {
|
const CODE_SAMPLES = {
|
||||||
openai: {
|
openai: {
|
||||||
curl: `curl https://api.tokendance.space/v1/chat/completions \\
|
curl: `curl https://api.turingtoken.ai/v1/chat/completions \\
|
||||||
-H "Authorization: Bearer $OPENAI_API_KEY" \\
|
-H "Authorization: Bearer $OPENAI_API_KEY" \\
|
||||||
-H "Content-Type: application/json" \\
|
-H "Content-Type: application/json" \\
|
||||||
-d '{
|
-d '{
|
||||||
|
|
@ -418,7 +418,7 @@ const CODE_SAMPLES = {
|
||||||
python: `from openai import OpenAI
|
python: `from openai import OpenAI
|
||||||
|
|
||||||
client = OpenAI(
|
client = OpenAI(
|
||||||
base_url="https://api.tokendance.space",
|
base_url="https://api.turingtoken.ai",
|
||||||
api_key="sk-your-key"
|
api_key="sk-your-key"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -430,7 +430,7 @@ print(response.choices[0].message.content)`,
|
||||||
nodejs: `import OpenAI from "openai";
|
nodejs: `import OpenAI from "openai";
|
||||||
|
|
||||||
const client = new OpenAI({
|
const client = new OpenAI({
|
||||||
baseURL: "https://api.tokendance.space",
|
baseURL: "https://api.turingtoken.ai",
|
||||||
apiKey: "sk-your-key",
|
apiKey: "sk-your-key",
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
@ -441,7 +441,7 @@ const response = await client.chat.completions.create({
|
||||||
console.log(response.choices[0].message.content);`,
|
console.log(response.choices[0].message.content);`,
|
||||||
},
|
},
|
||||||
claude: {
|
claude: {
|
||||||
curl: `curl https://api.tokendance.space/v1/messages \\
|
curl: `curl https://api.turingtoken.ai/v1/messages \\
|
||||||
-H "x-api-key: sk-your-key" \\
|
-H "x-api-key: sk-your-key" \\
|
||||||
-H "anthropic-version: 2023-06-01" \\
|
-H "anthropic-version: 2023-06-01" \\
|
||||||
-H "Content-Type: application/json" \\
|
-H "Content-Type: application/json" \\
|
||||||
|
|
@ -453,7 +453,7 @@ console.log(response.choices[0].message.content);`,
|
||||||
python: `import anthropic
|
python: `import anthropic
|
||||||
|
|
||||||
client = anthropic.Anthropic(
|
client = anthropic.Anthropic(
|
||||||
base_url="https://api.tokendance.space",
|
base_url="https://api.turingtoken.ai",
|
||||||
api_key="sk-your-key"
|
api_key="sk-your-key"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -466,7 +466,7 @@ print(response.content[0].text)`,
|
||||||
nodejs: `import Anthropic from "@anthropic-ai/sdk";
|
nodejs: `import Anthropic from "@anthropic-ai/sdk";
|
||||||
|
|
||||||
const client = new Anthropic({
|
const client = new Anthropic({
|
||||||
baseURL: "https://api.tokendance.space",
|
baseURL: "https://api.turingtoken.ai",
|
||||||
apiKey: "sk-your-key",
|
apiKey: "sk-your-key",
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
@ -478,7 +478,7 @@ const response = await client.messages.create({
|
||||||
console.log(response.content[0].text);`,
|
console.log(response.content[0].text);`,
|
||||||
},
|
},
|
||||||
gemini: {
|
gemini: {
|
||||||
curl: `curl "https://api.tokendance.space/v1beta/models/gemini-2.0-flash:generateContent?key=sk-your-key" \\
|
curl: `curl "https://api.turingtoken.ai/v1beta/models/gemini-2.0-flash:generateContent?key=sk-your-key" \\
|
||||||
-H "Content-Type: application/json" \\
|
-H "Content-Type: application/json" \\
|
||||||
-d '{
|
-d '{
|
||||||
"contents": [{"parts":[{"text": "Hello!"}]}]
|
"contents": [{"parts":[{"text": "Hello!"}]}]
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue