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/?q=fetch&page=594&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 8298 results for "fetch"(2504ms)

getSpotifyTrackUrlmain.tsx1 match

@dthyresson•Updated 9 months ago
69
70 // Search for the track
71 const response = await fetch(`https://api.spotify.com/v1/search?q=${query}&type=track`, {
72 headers: {
73 "Authorization": `Bearer ${accessToken.access_token}`,

tracksAPImain.tsx1 match

@dthyresson•Updated 9 months ago
89});
90
91export default yoga.fetch;

playRandomSongmain.tsx1 match

@dthyresson•Updated 9 months ago
43});
44
45export default app.fetch;

graphQLYogamain.tsx1 match

@dthyresson•Updated 9 months ago
45});
46
47export default yoga.fetch;

graphQLYogaDeferAndStreammain.tsx1 match

@dthyresson•Updated 9 months ago
95});
96
97export default yoga.fetch;

graphQLYogaWithSubscriptionsmain.tsx1 match

@dthyresson•Updated 9 months ago
91});
92
93export default yoga.fetch;

compileAndUploadTinygoWasmREADME.md1 match

@kora•Updated 9 months ago
34
35import { wasmHandler } from "https://esm.town/v/maxm/tinygoHttp";
36const resp = await fetch("https://maxm-wasmBlobHost.web.val.run/jpxqvyy5tphiwehzklmioklpkpz4gpzs.wasm");
37const handler = await wasmHandler(new Uint8Array(await resp.arrayBuffer()));
38export default async function(req: Request): Promise<Response> {

compileAndUploadTinygoWasmmain.tsx2 matches

@kora•Updated 9 months ago
42})();
43
44let resp = await fetch("https://maxm-wasmBlobHost.web.val.run", {
45 method: "POST",
46 headers: {
57
58import { wasmHandler } from "https://esm.town/v/maxm/tinygoHttp";
59const resp = await fetch("${url}");
60const handler = await wasmHandler(new Uint8Array(await resp.arrayBuffer()));
61export default async function(req: Request): Promise<Response> {

coffeeReptilemain.tsx1 match

@tempguy•Updated 9 months ago
1import { blob } from "https://esm.town/v/std/blob?v=12";
2export default async function(interval: Interval) {
3 await fetch("https://tempguy-scarletsole.web.val.run/refresh");
4 const date = new Date();
5 await blob.setJSON("turnstileCron", { ptime: date.getTime(), ntime: interval.delay + interval.lastRunAt.getTime() });

tealPheasantmain.tsx9 matches

@tempguy•Updated 9 months ago
2const url =
3 "https://streambucket.net/playvideo.php?video_id=S0dpVVFEbWV3ZDBBNGI3QldBPT0=&server_id=42&token=S0dLWFR6NkcxTUllNHIzSlRGb0tTaXFTVStiSHNRdkpNcXFsOWtJamljYU5nQ1JId1dac2hVeTN5VGkrRG1ZN2FiSUs0ZU9MUEo1Sk9XcEhUTHJLOUt0cGc0aXZvTGhDUDhRV1IyMGR3Qnl4d0YyNERsQWRhOXBvK2tQanNvODBzc3FOQnVDRjl2UUJDVjJURjFqNjNER202TzJNNUxzcEtnPT0=";
4const req = await fetch(
5 "https://streambucket.net/playvideo.php?video_id=S0dpVVFEbWV3ZDBBNGI3QldBPT0=&server_id=42&token=S0dLWFR6NkcxTUllNHIzSlRGb0tTaXFTVStiSHNRdkpNcXFsOWtJamljYU5nQ1JId1dac2hVeTN5VGkrRG1ZN2FiSUs0ZU9MUEo1Sk9XcEhUTHJLOUt0cGc0aXZvTGhDUDhRV1IyMGR3Qnl4d0YyNERsQWRhOXBvK2tQanNvODBzc3FOQnVDRjl2UUJDVjJURjFqNjNER202TzJNNUxzcEtnPT0=",
6);
25 "Alt-Used": "streambucket.net",
26 "Upgrade-Insecure-Requests": "1",
27 "Sec-Fetch-Dest": "iframe",
28 "Sec-Fetch-Mode": "navigate",
29 "Sec-Fetch-Site": "same-origin",
30 "Sec-Fetch-User": "?1",
31 "Priority": "u=4",
32 "Pragma": "no-cache",
67
68 try {
69 // Perform the fetch request
70 const response = await fetch(url, {
71 method: "POST",
72 headers: headers,
74 });
75
76 // Await and log the result of the fetch request
77 const result = await response.status;
78 console.log(result);
79 } catch (error) {
80 console.error("Error fetching combination:", combination, error);
81 }
82 }

fetchPaginatedData2 file matches

@nbbaier•Updated 2 weeks ago

FetchBasic1 file match

@fredmoon•Updated 2 weeks ago