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=fetch&page=1354&format=json

For typeahead suggestions, use the /typeahead endpoint:

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

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

Found 16244 results for "fetch"(3972ms)

fluxImageGeneratormain.tsx1 match

@danyslicer•Updated 10 months ago
81 setError("");
82 try {
83 const response = await fetch("/generate", {
84 method: "POST",
85 headers: { "Content-Type": "application/json" },

weatherGPTmain.tsx1 match

@tgrv•Updated 10 months ago
4let location = "Wolfsburg";
5let lang = "de";
6const weather = await fetch(
7 `https://wttr.in/${location}?lang=${lang}&format=j1`,
8).then(r => r.json());

verySalmonEmumain.tsx1 match

@tgrv•Updated 10 months ago
4let location = "brooklyn ny";
5let lang = "en";
6const weather = await fetch(
7 `https://wttr.in/${location}?lang=${lang}&format=j1`,
8).then(r => r.json());

sqliteExplorerAppmain.tsx4 matches

@teamgroove•Updated 10 months ago
1/** @jsxImportSource https://esm.sh/hono@latest/jsx **/
2
3import { modifyFetchHandler } from "https://esm.town/v/andreterron/codeOnValTown?v=50";
4import { iframeHandler } from "https://esm.town/v/nbbaier/iframeHandler";
5import { resetStyle } from "https://esm.town/v/nbbaier/resetStyle";
16import { verifyToken } from "https://esm.town/v/pomdtr/verifyToken";
17import { ResultSet, sqlite } from "https://esm.town/v/std/sqlite";
18import { reloadOnSaveFetchMiddleware } from "https://esm.town/v/stevekrouse/reloadOnSave";
19import { Hono } from "npm:hono";
20import type { FC } from "npm:hono/jsx";
175});
176
177export const handler = app.fetch;
178export default iframeHandler(modifyFetchHandler(passwordAuth(handler, { verifyPassword: verifyToken })));

aiTextEditormain.tsx1 match

@sharanbabu•Updated 10 months ago
131
132 try {
133 const response = await fetch("/process", {
134 method: "POST",
135 headers: { "Content-Type": "application/json" },

htmlkitREADME.md1 match

@yawnxyz•Updated 10 months ago
1This module provides functions to convert HTML to various formats such as Markdown, Pug, and Turndown.
2It also includes utilities to fetch HTML from a URL, extract metadata, and clean HTML by removing unwanted selectors.
3Dependencies include Cheerio for HTML parsing, JSDOM for DOM manipulation, and Turndown for converting HTML to Markdown.
4

slackScoutmain.tsx8 matches

@ewinney•Updated 10 months ago
20 for (const topic of KEYWORDS) {
21 const results = await Promise.allSettled([
22 fetchHackerNewsResults(topic),
23 fetchTwitterResults(topic),
24 fetchRedditResults(topic),
25 ]);
26
49}
50
51// Fetch Hacker news, Twitter, and Reddit results
52async function fetchHackerNewsResults(topic: string): Promise<Website[]> {
53 return hackerNewsSearch({
54 query: topic,
58}
59
60async function fetchTwitterResults(topic: string): Promise<Website[]> {
61 return twitterSearch({
62 query: topic,
67}
68
69async function fetchRedditResults(topic: string): Promise<Website[]> {
70 return redditSearch({ query: topic });
71}
84 }
85
86 const response = await fetch(slackWebhookUrl, {
87 method: "POST",
88 headers: { "Content-Type": "application/json" },

smsjournalertextrelaymain.tsx2 matches

@cephalization•Updated 10 months ago
54// Helper function to send SMS using TextBelt API
55async function sendSMS(phone: string, message: string) {
56 const response = await fetch("https://textbelt.com/text", {
57 method: "POST",
58 headers: { "Content-Type": "application/json" },
107
108export default async function server(request: Request): Promise<Response> {
109 const quotaResponse = await fetch(
110 `https://textbelt.com/quota/${textbeltKey}`,
111 )

blob_adminmain.tsx2 matches

@davisshaver•Updated 10 months ago
1/** @jsxImportSource https://esm.sh/hono@4.0.8/jsx **/
2
3import { modifyFetchHandler } from "https://esm.town/v/andreterron/codeOnValTown?v=50";
4import view_route from "https://esm.town/v/pomdtr/blob_admin_blob";
5import create_route from "https://esm.town/v/pomdtr/blob_admin_create";
137});
138
139export default modifyFetchHandler(passwordAuth(app.fetch));

resyBookSlotmain.tsx2 matches

@vtdocs•Updated 10 months ago
1import { fetch } from "https://esm.town/v/std/fetch";
2import { resyPublicAPIKey } from "https://esm.town/v/vtdocs/resyPublicAPIKey";
3import { sleep } from "https://esm.town/v/vtdocs/sleep";
18 while (true) {
19 try {
20 const bookRes = await fetch(`https://api.resy.com/3/book`, {
21 method: "POST",
22 headers: {

readwise-instapaper1 file match

@welson•Updated 2 days ago
Fetches my articles from Readwise. Syncs with/ Neon + Instapaper

manual-fetcher

@miz•Updated 2 weeks ago