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%22Image%20title%22?q=fetch&page=953&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 10361 results for "fetch"(2008ms)

nasaAPODmain.tsx2 matches

@ritz•Updated 1 year ago
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3// Returns NASA's Astronomy Picture of the Day (APOD)
4export const nasaAPOD = fetchJSON("cutt.ly/T7ksirK");
5// Forked from @iBrokeit.nasaAPOD

fetchCongressTradeReportsmain.tsx4 matches

@nari•Updated 1 year ago
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3/**
5 Receive daily emails of reported congress trades by scheduling a call to
6
7 @claytn.fetchCongressTradeReports((reports) => console.email(reports))
8*/
9
10
11export async function fetchCongressTradeReports(callback) {
12 const res = await fetchJSON(
13 "https://bff.capitoltrades.com/trades?sortBy=-pubDate"
14 );

sendNotificationmain.tsx2 matches

@axelav•Updated 1 year ago
1import { fetch } from "https://esm.town/v/std/fetch";
2
3export let sendNotification = async (params: { channel: string, message: string }) => {
9
10 try {
11 const response = await fetch(`https://ntfy.sh/${channel}`, {
12 method: "POST",
13 body: message,

fetchAndStoremain.tsx4 matches

@tal•Updated 1 year ago
3import { dateCalendarKey } from "https://esm.town/v/tal/dateCalendarKey";
4import { parseMenuLine } from "https://esm.town/v/tal/parseMenuLine";
5import { fetchDOEMenu } from "https://esm.town/v/tal/fetchDOEMenu";
6
7export async function fetchAndStore(opts: {
8 schoolYear: `${number}-${number}`;
9 month: string;
10 menuType: string;
11}) {
12 const menuText = await fetchDOEMenu(opts);
13 const lines: ReturnType<typeof parseMenuLine>[] = await Promise
14 .all(menuText.split("\r\n").map(parseMenuLine));
15 const key = dateCalendarKey(opts);
16 doeMenuResponseStore[key] = {
17 lastFetchedAt: new Date(),
18 lines,
19 };

communityBoatingFlagmain.tsx2 matches

@twschiller•Updated 1 year ago
1import { fetch } from "https://esm.town/v/std/fetch";
2
3export async function communityBoatingFlag() {
4 const response = await fetch("https://api.community-boating.org/api/flag");
5 const text = await response.text();
6 // Regex by Chat GPT :shrug:

emailDailyJokemain.tsx4 matches

@jay•Updated 1 year ago
1import { fetch } from "https://esm.town/v/std/fetch";
2
3export async function emailDailyJoke() {
4 async function fetchJoke() {
5 let response = await fetch(
6 "https://official-joke-api.appspot.com/random_joke",
7 );
10 }
11 }
12 const randomJoke = await fetchJoke();
13 const setup = randomJoke.setup;
14 const punchline = randomJoke.punchline;

openAiTextCompletionmain.tsx2 matches

@patrickjm•Updated 1 year ago
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3export let openAiTextCompletion = async (params: {
33 args.stream = false;
34
35 const response = await fetchJSON("https://api.openai.com/v1/completions", {
36 method: "POST",
37 headers: {

tradestationMarginsmain.tsx2 matches

@simone•Updated 1 year ago
1import { fetch } from "https://esm.town/v/std/fetch";
2
3let { tradestationMarginsState } = await import("https://esm.town/v/simone/tradestationMarginsState");
13 async function loadTradestationData() {
14 const cheerio = await import("npm:cheerio");
15 const response = await fetch(
16 "https://www.tradestation.com/pricing/futures-margin-requirements/"
17 );

timemain.tsx2 matches

@vs•Updated 1 year ago
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3export async function time() {
4 return await fetchJSON(
5 "https://api.openaq.org/v2/latest?" +
6 new URLSearchParams({

githubFollowersmain.tsx2 matches

@rym•Updated 1 year ago
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3// GitHub followers
4export let githubFollowers = fetchJSON(
5 "https://api.github.com/users/stevekrouse/followers"
6);

fetchTechNews

@josiasaurel•Updated 3 hours ago

agentplex-deal-flow-email-fetch1 file match

@anandvc•Updated 5 days ago