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/$1?q=api&page=1413&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 15629 results for "api"(4295ms)

myApimain.tsx1 match

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

getGithubUsermain.tsx1 match

@vtdocs•Updated 1 year ago
3export const getGithubUser = async (username: string) => {
4 const user = await fetchJSON(
5 `https://api.github.com/users/${username}`,
6 );
7 return user;

myApimain.tsx1 match

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

myApimain.tsx1 match

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

nameNationalitymain.tsx1 match

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

myApimain.tsx1 match

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

openapi2TSmain.tsx1 match

@pomdtr•Updated 1 year ago
2import { prettifyTS } from "https://esm.town/v/pomdtr/prettifyTS";
3
4export async function openapi2TS(url: string) {
5 const yaml = await import("npm:yaml");
6 const resp = await fetch(url);

untitled_pinkSkunkmain.tsx2 matches

@neoneffect•Updated 1 year ago
655 "https://www.itraveljerusalem.com/accommodation/little-house-in-the-colony",
656 "https://www.itraveljerusalem.com/accommodation/nof-hahan-zimmers",
657 "https://www.itraveljerusalem.com/accommodation/capitol-hotel",
658 "https://www.itraveljerusalem.com/accommodation/mamilla-hotel",
659 "https://www.itraveljerusalem.com/accommodation/city-center-hotel",
1007 "https://www.itraveljerusalem.com/attraction/rehavia-taxis",
1008 "https://www.itraveljerusalem.com/attraction/palmach-taxis",
1009 "https://www.itraveljerusalem.com/attraction/hapisga-taxis",
1010 "https://www.itraveljerusalem.com/attraction/jerusalem-taxis",
1011 "https://www.itraveljerusalem.com/attraction/jerusalem-light-rail",

myApimain.tsx1 match

@abdulamite•Updated 1 year ago
1export function myApi(name, date) {
2 console.log("Here is something in the console");
3 return "hi " + name + date;

myApimain.tsx3 matches

@joakim•Updated 1 year ago
1import { myApi as myApi2 } from "https://esm.town/v/joakim/myApi";
2
3export function myApi(name) {
4 return "hi " + name + ". This is posted from " + myApi2;
5}

googleGeminiAPI2 file matches

@michaelwschultz•Updated 5 hours ago

HN-fetch-call2 file matches

@ImGqb•Updated 3 days ago
fetch HackerNews by API
Kapil01
apiv1