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/$%7Bart_info.art.src%7D?q=api&page=1002&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 11580 results for "api"(2653ms)

dailyMathFactmain.tsx1 match

@andrewn•Updated 1 year ago
3export async function dailyMathFact() {
4 let mathFact = await fetchText(
5 "http://numbersapi.com/random/math",
6 );
7 return { data: mathFact };

myApimain.tsx1 match

@andrewn•Updated 1 year ago
1export function myApi() {
2 return { something: "is happening" };
3}

myApimain.tsx1 match

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

get_weathermain.tsx1 match

@malloc•Updated 1 year ago
3export let get_weather = async function () {
4 let response = await fetch(
5 "https://api.open-meteo.com/v1/forecast?latitude=49.26&longitude=-123.07&current_weather=true"
6 );
7 return response.ok;

myApimain.tsx1 match

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

hiapimain.tsx1 match

@dnomadb•Updated 1 year ago
1export let hiapi = (a) => {
2 console.log(a);
3 return [...new Array(100)].map((_, i) => {

myApimain.tsx1 match

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

myApimain.tsx1 match

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

myApimain.tsx1 match

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

wee2main.tsx1 match

@val•Updated 1 year ago
2
3export let wee2 = fetchJSON(
4 "https://api.val.town/express/@val.wee1",
5 {
6 method: "POST",

new-val-api-21 file match

@shouser•Updated 2 hours ago
This is an example of using the API to create a val.

gptApiTemplate2 file matches

@charmaine•Updated 1 day ago
apiv1
papimark21