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

Tumitumie

wikiapptry

Public
Like
wikiapptry
Home
Code
3
backend
6
shared
1
README.md
Branches
1
Pull requests
Remixes
History
Environment variables
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
/
backend
/
database
/
README.md
Code
/
backend
/
database
/
README.md
Search
5/19/2025
Viewing readonly version of main branch: v18
View latest version
README.md

Database Structure

This directory contains the database setup and query functions for the WhatsApp Wikipedia Bot.

Tables

Users Table (whatsapp_wiki_users_v1)

Stores information about users who have interacted with the bot.

ColumnTypeDescription
idINTEGERPrimary key
phone_numberTEXTUser's WhatsApp phone number (unique)
nameTEXTUser's name
preferred_content_typeTEXTUser's preferred content type (fact, audio, video)
last_interaction_timeINTEGERTimestamp of last interaction
created_atINTEGERTimestamp when user was created

Facts Table (whatsapp_wiki_facts_v1)

Stores fun facts that can be sent to users.

ColumnTypeDescription
idINTEGERPrimary key
topicTEXTTopic category of the fact
contentTEXTThe fact content
sourceTEXTSource of the fact
created_atINTEGERTimestamp when fact was added

Audio Table (whatsapp_wiki_audio_v1)

Stores audio clips that can be sent to users.

ColumnTypeDescription
idINTEGERPrimary key
titleTEXTTitle of the audio clip
descriptionTEXTDescription of the audio clip
urlTEXTURL to the audio file
topicTEXTTopic category of the audio
durationINTEGERDuration in seconds
created_atINTEGERTimestamp when audio was added

Video Table (whatsapp_wiki_video_v1)

Stores video clips that can be sent to users.

ColumnTypeDescription
idINTEGERPrimary key
titleTEXTTitle of the video clip
descriptionTEXTDescription of the video clip
urlTEXTURL to the video file
topicTEXTTopic category of the video
durationINTEGERDuration in seconds
created_atINTEGERTimestamp when video was added

Schema Changes

When changing the schema, create a new table with an incremented version number (e.g., whatsapp_wiki_users_v2) rather than altering the existing table.

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
© 2025 Val Town, Inc.