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=1276&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 14397 results for "api"(2522ms)

myApimain.tsx1 match

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

redirectmain.tsx1 match

@thomasatflexos•Updated 1 year ago
19 const token = process.env.OAUTH_CLIENT_ID + ":" +
20 process.env.OAUTH_CLIENT_SECRET;
21 const response = await fetch("https://api.notion.com/v1/oauth/token", {
22 method: "POST",
23 headers: {

githubReposmain.tsx1 match

@enzonotario•Updated 1 year ago
3// GitHub repos
4export let githubRepos = fetchJSON(
5 "https://api.github.com/users/stevekrouse/repos"
6);

aqimain.tsx1 match

@lavallee•Updated 1 year ago
4 let pm25 = (
5 await fetchJSON(
6 "https://api.openaq.org/v2/latest?" +
7 new URLSearchParams({
8 limit: "10",

FigmaFileObjectAsyncmain.tsx2 matches

@rodrigotello•Updated 1 year ago
4
5export const FigmaFileObjectAsync = (async () => {
6 const apiToken = process.env.myFigmaAPIToken;
7 const fileKey = FigmaURLJSONexample.key;
8 return fetchFigmaFile(apiToken, fileKey);
9})();

imBoredmain.tsx1 match

@valbee•Updated 1 year ago
4export const imBored = async () => {
5 return (boredActivities = fetchJSON(
6 "https://www.boredapi.com/api/activity"
7 ));
8};

githubFollowersmain.tsx1 match

@aviddabbler•Updated 1 year ago
3// GitHub followers
4export let githubFollowers = fetchJSON(
5 "https://api.github.com/users/stevekrouse/followers"
6);

myApimain.tsx1 match

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

friendIdsmain.tsx1 match

@charles2•Updated 1 year ago
3
4export let friendIds = twitterJSON({
5 url: `https://api.twitter.com/1.1/friends/ids.json?screen_name=stevekrouse`,
6 bearerToken: twitterCredentials.bearerToken
7}).then(x => x.ids)

satsNameApimain.tsx2 matches

@ryanwaits•Updated 1 year ago
1import { hexToUtf8 } from "https://esm.town/v/ryanwaits/hexToUtf8";
2
3export const satsNameApi = async (req: Request) => {
4 const { Hono } = await import("npm:hono");
5 const app = new Hono();
6 let events = [];
7 app.post("/api/events", async (c) => {
8 const body = await c.req.json();
9 const { apply } = body;

createemailapiv22 file matches

@souravvmishra•Updated 10 hours ago

waec_api6 file matches

@seyistry•Updated 17 hours ago
snartapi
mux
Your friendly, neighborhood video API.