diff --git a/app/page.tsx b/app/page.tsx index 8e339b5..a70ba07 100644 --- a/app/page.tsx +++ b/app/page.tsx @@ -1,263 +1,18 @@ -"use client" +export const dynamic = 'force-dynamic' -import { useState } from "react" -import { Copy, CheckCheck, ExternalLink, ImageIcon, UserCircle, Code } from "lucide-react" -import { Button } from "@/components/ui/button" -import { Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle } from "@/components/ui/card" -import { Tabs, TabsContent, TabsList, TabsTrigger } from "@/components/ui/tabs" -import { Alert, AlertDescription, AlertTitle } from "@/components/ui/alert" -import { AlertTriangle } from "lucide-react" -import { Badge } from "@/components/ui/badge" - -export default function Home() { - const [copied, setCopied] = useState(null) - const baseUrl = typeof window !== "undefined" ? window.location.origin : "" - const randomImageUrl = `${baseUrl}/random-image` - const gravatarProxyUrl = `${baseUrl}/avatar` - - const copyToClipboard = (text: string, id: string) => { - navigator.clipboard.writeText(text) - setCopied(id) - setTimeout(() => setCopied(null), 2000) - } - - return ( -
-
-
-

- API Services -

-

Connect the world with us

-
- - - - Access Restricted - - The API is not open to the public. If you need it, please contact us at{" "} - - 10010@spircape.com - - - - - - - - - Integration Guide - - Follow these examples to integrate our services into your application - - - - - - - Random Image - - - - Gravatar Proxy - - - - -
-
-

Random Image API

- - GET - -
-

- This API randomly serves an image from a predefined collection. Perfect for placeholder images, - random backgrounds, or testing purposes. -

- -
-
-

- - HTML Usage -

-
-
-                          {`Random image`}
-                        
- -
-
- -
-

- - React Usage -

-
-
-                          {`import { useState } from 'react';\n\nfunction RandomImage() {\n  const [refresh, setRefresh] = useState(0);\n  \n  return (\n    Random image setRefresh(Date.now())}\n      className="cursor-pointer transition-opacity hover:opacity-90"\n    />\n  );\n}`}
-                        
- -
-
-
-
-
- - -
-
-

Gravatar Proxy

- - GET - -
-

- Our Gravatar proxy service improves loading speed and reliability for Gravatar images. It caches and - optimizes avatar delivery for your applications. -

- -
-
-

- - Basic Usage -

-
-
-                          {`\nUser avatar`}
-                        
- -
-
- -
-

- - With Size Parameter -

-
-
-                          {`\nUser avatar`}
-                        
- -
-
- -
-

- - With Default Image -

-
-
-                          {`\nUser avatar`}
-                        
- -
-
-
-
-
-
-
- -
- - - The above is for example only, please adjust according to the specific development environment - -
-
-
- -
-
-

© {new Date().getFullYear()} Spircape. All rights reserved.

-
-
-
-
+export async function GET() { + return new Response( + JSON.stringify({ + success: true, + code: 200, + message: "所谓的奇迹,要真的发生才有价值。", + version: "1.6" + }), + { + status: 200, + headers: { + 'Content-Type': 'application/json' + } + } ) } diff --git a/package.json b/package.json index 7efa5a8..3613b47 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "spapi", - "version": "0.1.0", + "version": "0.1.6", "private": true, "scripts": { "dev": "next dev", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml deleted file mode 100644 index ca98c48..0000000 --- a/pnpm-lock.yaml +++ /dev/null @@ -1,5 +0,0 @@ -lockfileVersion: '9.0' - -settings: - autoInstallPeers: true - excludeLinksFromLockfile: false \ No newline at end of file