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=api&page=998&format=json

For typeahead suggestions, use the /typeahead endpoint:

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

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

Found 11003 results for "api"(1100ms)

myApimain.tsx1 match

@wfortinUpdated 1 year ago
1export function myApi(name) {
2 const lastUsedName = name;
3 return "hi " + name;

referencesmain.tsx1 match

@mgruelUpdated 1 year ago
25}): Promise<Reference[]> {
26 const data = await fetchJSON<Reference[]>(
27 "https://api.val.town/v1/me/references?" +
28 searchParams({
29 since: since?.toISOString(),

myApimain.tsx1 match

@miesUpdated 1 year ago
1export function myApi(name) {
2 return "hi " + name;
3}

getRandomDogImgmain.tsx1 match

@mutuguangdaUpdated 1 year ago
5 res: express.Response,
6) => {
7 const data = await fetch("https://dog.ceo/api/breeds/image/random", {
8 method: "get",
9 redirect: "follow",

myApimain.tsx1 match

@benbenbenbenbenbenUpdated 1 year ago
1export function myApi(name) {
2 return "hi " + name;
3}

searchManifoldMarketsmain.tsx1 match

@piotrUpdated 1 year ago
7export async function searchManifoldMarkets(query: string) {
8 const result = await fetch(
9 `https://manifold.markets/api/v0/search-markets?${query}`,
10 );
11 const markets = await result.json() as Market[];

myApimain.tsx1 match

@quocUpdated 1 year ago
1export function myApi(name) {
2 return "hi " + name;
3}

myApimain.tsx1 match

@aendraUpdated 1 year ago
1export function myApi(name) {
2 return "hi " + name;
3}

tidbytDeviceInfomain.tsx4 matches

@andreterronUpdated 1 year ago
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3export function tidbytDeviceInfo({ deviceId, apiKey }: {
4 deviceId: string;
5 apiKey: string;
6}) {
7 return fetchJSON(
8 `https://api.tidbyt.com/v0/devices/${deviceId}`,
9 {
10 headers: {
11 Authorization: `Bearer ${apiKey}`,
12 },
13 },

nameNationalitymain.tsx1 match

@raphaelrkUpdated 1 year ago
3// Predict the nationality of a name
4export let nameNationality = fetchJSON(
5 "https://api.nationalize.io/?name=michael"
6);

daily-advice-app1 file match

@dcm31Updated 2 days ago
Random advice app using Advice Slip API

gptApiTemplate1 file match

@charmaineUpdated 3 days ago
papimark21
socialdata
Affordable & reliable alternative to Twitter API: ➡️ Access user profiles, tweets, followers & timeline data in real-time ➡️ Monitor profiles with nearly instant alerts for new tweets, follows & profile updates ➡️ Simple integration