9To use it on your own Val Town SQLite database, [fork it](https://www.val.town/v/stevekrouse/sqlite_admin/fork) to your account.
10
11It uses [basic authentication](https://www.val.town/v/pomdtr/basicAuth) with your [Val Town API Token](https://www.val.town/settings/api) as the password (leave the username field blank).
425 if (url.pathname === "/create-checkout-session" && req.method === "POST") {
426 const stripe = new Stripe(Deno.env.get("STRIPE_SECRET_KEY"), {
427 apiVersion: "2022-11-15",
428 });
429
464
465 const stripe = new Stripe(Deno.env.get("STRIPE_SECRET_KEY"), {
466 apiVersion: "2022-11-15",
467 });
468
27 <head>
28 <title>SQLite Explorer</title>
29 <link rel="preconnect" href="https://fonts.googleapis.com" />
30
31 <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
32 <link
33 href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@300..700&family=Source+Sans+3:ital,wght@0,200..900;1,200..900&display=swap"
34 rel="stylesheet"
35 />
13## Authentication
14
15Login to your SQLite Explorer with [password authentication](https://www.val.town/v/pomdtr/password_auth) with your [Val Town API Token](https://www.val.town/settings/api) as the password.
16
17## Todos / Plans
9async function fetchRandomJoke() {
10 const response = await fetch(
11 "https://official-joke-api.appspot.com/random_joke",
12 );
13 return response.json();
4async function fetchRandomJoke() {
5 const response = await fetch(
6 "https://official-joke-api.appspot.com/random_joke",
7 );
8 return response.json();
4async function fetchRandomJoke() {
5 const response = await fetch(
6 "https://official-joke-api.appspot.com/random_joke",
7 );
8 return response.json();
4function fetchRandomJoke() {
5 const response = fetch(
6 "https://official-joke-api.appspot.com/random_joke",
7 );
8 return response;
8const query = "(@AliveEvidence -from:AliveEvidence) OR \"Alive Evidence\" OR \"Alive evidence\" -is:retweet";
9
10// Define the structure of a tweet based on Twitter API v2
11interface Tweet {
12 id: string;
39 const encodedQuery = encodeURIComponent(query);
40 const url =
41 `https://api.twitter.com/2/tweets/search/recent?query=${encodedQuery}&start_time=${since}&tweet.fields=author_id&expansions=author_id`;
42
43 const response = await fetch(url, {
1## API setup to vercel database