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/$%7Burl%7D?q=api&page=1061&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 11633 results for "api"(1542ms)

myApimain.tsx1 match

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

getRandomDogImgmain.tsx1 match

@mutuguangda•Updated 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

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

searchManifoldMarketsmain.tsx1 match

@piotr•Updated 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

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

myApimain.tsx1 match

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

tidbytDeviceInfomain.tsx4 matches

@andreterron•Updated 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

@raphaelrk•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

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

myApimain.tsx1 match

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

new-val-api-21 file match

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

gptApiTemplate2 file matches

@charmaine•Updated 1 day ago
mux
Your friendly, neighborhood video API.
api