HNU-TimeLetter uses Feishu (Lark) Bitable as its sole CMS. Stories, location pins, creation board ideas, and the contributor credits list all live in Feishu multi-dimensional tables. TheDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/HNU-himematsu/HNU-TimeLetter/llms.txt
Use this file to discover all available pages before exploring further.
npm run sync command (or the admin panel) pulls this data, uploads any new images to Aliyun OSS, back-fills OSS URLs into Feishu, and writes ready-to-serve JSON artifacts under src/data/. This guide walks through the one-time setup required before the first sync can run.
Setting Up the Feishu App
Create a Feishu Enterprise Self-Built App
- Open the Feishu Developer Console and click Create App → Enterprise Self-Built App.
- Give it a name (e.g.
HNU-TimeLetter Sync) and save. - Copy the App ID and App Secret from the Credentials page — these become
FEISHU_APP_IDandFEISHU_APP_SECRET.
Enable Bitable Permissions
In the app’s Permissions & Scopes panel, enable:
Click Publish Version to activate the permissions.
| Permission | Purpose |
|---|---|
bitable:app:readonly | Read records from Bitable |
bitable:app | Write back OSS URLs to attachment fields |
Add the App to Your Bitable
Open your target Bitable, click ··· (top-right) → More → Add App, then select the app you just created.This step must be repeated for every Bitable that the sync touches (stories table, creation board table, contributors table).
Collect Table and View IDs
From the Bitable URL you can extract the token and table IDs:Copy the relevant values into
.env.local:.env.local
Configure the Creation Board Tables
The creation board uses two separate tables — a header table (card metadata) and a main table (idea entries):
.env.local
If these variables are left empty, the sync service uses built-in defaults and will warn you in the log output.
Configure Aliyun OSS
Create an OSS bucket with public-read ACL and allow CORS from For least-privilege access, create a RAM sub-user with
* (required for browser image loading). Then add the credentials:.env.local
oss:PutObject and oss:GetObject permissions on the target bucket only.Run the First Sync
With all variables set, trigger the initial sync:The sync will:
- Authenticate with Feishu and pull all table records
- Download any image attachments from Feishu
- Compute MD5 hashes and upload images to Aliyun OSS
- Back-fill permanent OSS URLs into the Feishu record (
头像OSS_URL,大图OSS_URLfields) - Write
src/data/content.json,src/data/creation-board.json,src/data/contributors.json, andsrc/config/locations.json
First-Time Field Initialization
If you are setting up the Feishu tables from scratch, three scripts create the required fields automatically:Image Sync Pipeline
Every timenpm run sync runs, the image pipeline processes each record:
- Detect: Check if
头像OSS_URL/大图OSS_URLis already populated - Download: Fetch the raw attachment bytes from Feishu’s temporary CDN
- Hash: Compute MD5 to skip re-uploads of unchanged files
- Upload: PUT the file to Aliyun OSS at a stable path
- Back-fill: Write the permanent OSS URL back to the Feishu record
JSAPI Signature for Feishu Document Embeds
The frontend announcement popup embeds a Feishu document. When opened in a browser, Feishu’s JS SDK requires a server-signed URL. TheGET /api/feishu-jsapi-signature?url=<current-page-url> endpoint handles this automatically — it needs only FEISHU_APP_ID and FEISHU_APP_SECRET to be set.
Webhook Auto-Sync
For real-time creation board updates, configure Feishu Automation to call the sync webhook whenever a new record is added:202 Accepted immediately and the sync completes in the background. See the Webhook API reference for the full configuration guide.