• Blog
  • Docs
  • Pricing
  • We’re hiring!
Log inSign up
sitnik

sitnik

trmnl-spotify

Spotify public plugin for TRMNL
Unlisted
Like
1
trmnl-spotify
Home
Code
4
docs
1
frontend
4
routes
6
H
main.ts
Branches
2
Pull requests
Remixes
History
Environment variables
4
Val Town is a collaborative website to build and scale JavaScript apps.
Deploy APIs, crons, & store data – all from the browser, and deployed in milliseconds.
Sign up now
Code
/
docs
/
dbqueries.md
Code
/
docs
/
dbqueries.md
Search
11/22/2025
Viewing readonly version of main branch: v212
View latest version
dbqueries.md

Database Queries

Create Installations Database

Create val
app.get("/db/create", async (c) => { await sqlite.execute(`create table if not exists installations ( id INTEGER PRIMARY KEY AUTOINCREMENT not null, active boolean not null default 0, uninstalled boolean not null default 0, name varchar(255) not null, first_name varchar(255) not null, last_name varchar(255) not null, email varchar(255) not null, locale varchar(255) not null, time_zone_iana varchar(255) not null, plugin_setting_id INTEGER not null, uuid varchar(255) not null, access_token varchar(255) not null, created_at datetime not null default CURRENT_TIMESTAMP, updated_at datetime not null default CURRENT_TIMESTAMP, uninstalled_at datetime null )`); await sqlite.execute(`create table if not exists tokens ( id INTEGER PRIMARY KEY not null, access_token varchar(255) not null, expires_at integer not null, refresh_token varchar(255) not null, FOREIGN KEY (id) REFERENCES installations (id) )`); return c.text("ok"); });
FeaturesVersion controlCode intelligenceCLIMCP
Use cases
TeamsAI agentsSlackGTM
DocsShowcaseTemplatesNewestTrendingAPI examplesNPM packages
PricingNewsletterBlogAboutCareers
We’re hiring!
Brandhi@val.townStatus
X (Twitter)
Discord community
GitHub discussions
YouTube channel
Bluesky
Open Source Pledge
Terms of usePrivacy policyAbuse contact
© 2026 Val Town, Inc.