Quick setup toolkit for new developers
- Data storage based on Google Sheets.
- API based on Vercel Serverless Functions.
- Data cache use LocalStorage & ServiceWorker.
- Fork this project.
- Create a new project in vercel dashboard and connect to your project.
- Create Google Cloud platform credentials keyFile & extract
client_email,private_keyfield. set sheet name toSheet1. - Set environment variables in the project dashboard.
Environment variables required by the project.
| Key | Value | Description |
|---|---|---|
| TOKEN | String | access token |
| SHEET_ID | String | Google Sheets ID |
| CLIENT_EMAIL | String | credentials keyFile client_email field |
| PRIVATE_KEY | String | credentials keyFile private_key field |
Note:
- Recommended
TOKENenv is generated usecrypto.randomBytes(16).toString('hex') - Environment variables are best added using the vercel client, use the Web UI can be problematic
| Category(A) | Name(B) | Icon(C) | Path/Desc(D) | Command(E) | Website(F) | Round(G) |
| ----------- | ------- | ---------------------------- | ------------ | ---------- | ------------------- | -------- |
| app | example | https://example.com/logo.png | /example.app | | https://example.com | 1 |
| command | example | https://example.com/logo.png | demo | example | https://example.com | 0 |
Get all data in data storage.
| Parameter | Type | Description | isRequired? |
|---|---|---|---|
| token | String | access token | required |
const result = await axios.get(`${domain}/api/list`, {
params: {
token: "74e1dcd881627ee5efa73340324ee47f",
},
});
console.log(result);
// output log:
// [
// { name: 'example', icon: 'https://example.com/logo.png', path: '/Applications/example.app', website: 'https://example.com', category: 'app', round: 1 },
// { name: 'example', icon: 'https://example.com/logo.png', desc: 'demo', command: 'example', website: 'https://example.com', category: 'command', round: 1 }
// ]Vercel functions using environment variables
Create Google Cloud platform credentials keyFile
MIT.