Skip to main content

Documentation Index

Fetch the complete documentation index at: https://help.helloazhenweb.top/llms.txt

Use this file to discover all available pages before exploring further.

The wish wall lets anyone leave a birthday message without creating an account. Visitors navigate to /write, type their message, and submit — the wish is stored in Supabase and appears on the home page wall. Every message is assigned a random accent color so the wall looks lively and varied.

Writing a wish

Open /write in any browser. You will see a full-screen form with a textarea and a character counter.
1

Type your message

Write anything up to 500 characters. The counter at the bottom of the textarea updates as you type.
2

Submit

Click 送上祝福. The app posts your message to /api/messages. All submissions are anonymous — no name or login is required.
3

Confirmation

On success, the form is replaced by a confirmation screen. After three seconds you are automatically redirected to the home page to see your wish on the wall.

Validation and error messages

Client-side validation runs before the request is sent. The API also validates server-side.
ConditionError message
Empty or whitespace-only content写点什么吧~
Content longer than 500 chars太长了,控制在 500 字以内哦
More than 3 messages in 5 minutes祝福太多啦,休息 5 分钟再发吧~

Rate limiting

The API limits each IP address to 3 messages per 5-minute window. The IP is hashed with SHA-256 before being stored, so no raw IP addresses are persisted in your database.
Rate limiting is based on the x-forwarded-for and x-real-ip headers. Make sure your hosting platform passes these headers correctly. If both are absent, all requests fall under the key "unknown" and share a single rate-limit bucket.

Message colors

Each submitted message is randomly assigned one of six Tailwind color names: rose, sky, amber, emerald, violet, or pink. The color is stored in the color column and used by the home page to style each card.

API reference

GET /api/messages

Returns up to 100 messages, ordered newest first. Response
{
  "messages": [
    {
      "id": "uuid",
      "content": "Happy birthday!",
      "color": "rose",
      "created_at": "2026-05-24T10:00:00.000Z"
    }
  ]
}
messages
object[]
required
Array of message objects, newest first. Maximum 100 items.

POST /api/messages

Submit a new wish. Request body
content
string
required
The birthday message. Must be between 1 and 500 characters after trimming whitespace.
Response codes
StatusMeaning
201Message created successfully.
400Validation failed (empty or too long).
429Rate limit exceeded.
500Database error or unexpected server error.
Success response (201)
{
  "message": {
    "id": "uuid",
    "content": "Wishing you the best birthday ever!",
    "color": "emerald",
    "created_at": "2026-05-24T10:00:00.000Z"
  }
}
Code examples
curl --request POST \
  --url https://your-site.com/api/messages \
  --header 'Content-Type: application/json' \
  --data '{"content": "Happy birthday! Wishing you all the best!"}'

Admin panel

A password-protected admin panel lets you view and delete messages. Access it from the navbar when you are authenticated. The panel shows all messages with their timestamps, colors, and the option to remove any entry.
The admin panel requires the ADMIN_PASSWORD environment variable to be set. See the deployment guide for details.