Val Town Code SearchReturn to Val Town

API Access

You can access search results via JSON API by adding format=json to your query:

https://codesearch.val.run/image-url.jpg%20%22Optional%20title%22?q=database&page=13&format=json

For typeahead suggestions, use the /typeahead endpoint:

https://codesearch.val.run/typeahead?q=database

Returns an array of strings in format "username" or "username/projectName"

Found 4049 results for "database"(517ms)

stevensDemogetWeather.ts1 match

@talbetโ€ขUpdated 3 days ago
130 }
131
132 console.log(`Weather forecast updated in the database.`);
133 return summary;
134}

stevensDemogetCalendarEvents.ts1 match

@talbetโ€ขUpdated 3 days ago
125 }
126
127 console.log(`Calendar events imported into the database.`);
128 return events;
129 } catch (error) {

stevensDemogenerateFunFacts.ts2 matches

@talbetโ€ขUpdated 3 days ago
8
9/**
10 * Retrieves previously generated fun facts from the memories database
11 * @returns Array of previous fun facts
12 */
47
48/**
49 * Inserts a fun fact into the memories database
50 * @param date Date for the fun fact in ISO format
51 * @param factText The fun fact text

stevensDemo.cursorrules2 matches

@talbetโ€ขUpdated 3 days ago
208```
209โ”œโ”€โ”€ backend/
210โ”‚ โ”œโ”€โ”€ database/
211โ”‚ โ”‚ โ”œโ”€โ”€ migrations.ts # Schema definitions
212โ”‚ โ”‚ โ”œโ”€โ”€ queries.ts # DB query functions
270- Handle API calls properly with proper error catching
271
272### Database Patterns
273- Run migrations on startup or comment out for performance
274- Change table names when modifying schemas rather than altering

repondiverseaddCreation2 matches

@elouanโ€ขUpdated 3 days ago
46 }
47
48 // Now it's time to upload things to database and blob storage
49 // First, add to database, and get the ID
50 const id = await sqlite.execute(
51 `INSERT INTO ${TABLE_NAME} (title, data, type, time) VALUES ($title, $data, $type, $time)`,

telegramBotStartermessage.tsx1 match

@asdfgโ€ขUpdated 3 days ago
21
22/**
23 * Store a message in the database using Val Town's blob storage
24 */
25export default async function storeMessage(

email_random_media_newnew-file-3140.tsx2 matches

@jl98โ€ขUpdated 3 days ago
60 await email({
61 subject: "No Media Found",
62 text: "No media items were found in the database.",
63 html: "<p>No media items were found in the database.</p>",
64 });
65

TownieTODOs.md1 match

@loadingโ€ขUpdated 3 days ago
9- [ ] make it one click to branch off like old jp townie demos
10- [ ] opentownie as a pr bot
11- [ ] give it the ability to see its own client-side and server-side logs by building a middleware that shoves them into a SQL light database date and then give it a tool to access them
12- [ ] do a browser use or screenshot thing to give it access to its own visual output
13- [ ] Have it default to creating a new branch off main

Towniethink.ts1 match

@loadingโ€ขUpdated 3 days ago
7export const thinkTool = tool({
8 description:
9 "Use the tool to think about something. It will not obtain new information or change the database, but just append the thought to the log. Use it when complex reasoning or some cache memory is needed.",
10 parameters: z.object({
11 thought: z.string().describe("A thought to think about."),

Towniesystem_prompt.txt2 matches

@loadingโ€ขUpdated 3 days ago
192```
193โ”œโ”€โ”€ backend/
194โ”‚ โ”œโ”€โ”€ database/
195โ”‚ โ”‚ โ”œโ”€โ”€ migrations.ts # Schema definitions
196โ”‚ โ”‚ โ”œโ”€โ”€ queries.ts # DB query functions
251 ```
252
253### Database Patterns
254- Run migrations on startup or comment out for performance
255- Change table names when modifying schemas rather than altering

bookmarksDatabase

@s3thiโ€ขUpdated 2 months ago

sqLiteDatabase1 file match

@ideofunkโ€ขUpdated 5 months ago