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=909&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 12894 results for "api"(2285ms)

GDI_GoodMorningmain.tsx1 match

@rozekUpdated 7 months ago
3async function getWeather() {
4 const response = await fetch(
5 "https://api.open-meteo.com/v1/forecast?latitude=48.7758&longitude=9.1829&current=temperature_2m,weathercode&daily=weathercode,temperature_2m_max,temperature_2m_min&timezone=Europe%2FBerlin"
6 );
7 return await response.json();

slamBotPostmain.tsx3 matches

@dupontguUpdated 7 months ago
6
7// Replace with your actual access token and Mastodon instance URL
8const MASTODON_TOKEN = Deno.env.get("MASTODON_API_KEY");
9const MASTODON_URL = "https://mastodon.social";
10
130 formData.append("description", altText);
131
132 const uploadResponse = await fetch(`${MASTODON_URL}/api/v2/media`, {
133 method: "POST",
134 headers: {
149 const mediaId = await uploadImage(imageBuffer, altText);
150
151 const postResponse = await fetch(`${MASTODON_URL}/api/v1/statuses`, {
152 method: "POST",
153 headers: {

heavenlyOrangeMarmosetmain.tsx1 match

@dupontguUpdated 7 months ago
1import { BskyAgent, BlobRef, RichText } from 'npm:@atproto/api';
2
3export async function blueskyPostWithImage(statusText: string, imageBuffer: any, altText: string) {

testplaywrightmain.tsx5 matches

@stevekrouseUpdated 7 months ago
5console.info("Launching browser...");
6
7// Use Deno.env to get the API key
8const apiKey = Deno.env.get("BROWSERBASE_API_KEY");
9if (!apiKey) {
10 console.error("BROWSERBASE_API_KEY environment variable is not set");
11 Deno.exit(1);
12}
14try {
15 const browser = await chromium.connectOverCDP(
16 `wss://connect.browserbase.com?apiKey=${apiKey}`,
17 );
18 console.info("Connected!");

blob_adminREADME.md1 match

@thesolarmonkUpdated 7 months ago
9[![](https://stevekrouse-button.web.val.run/Install)](https://www.val.town/v/stevekrouse/blob_admin_app/fork)
10
11It uses [basic authentication](https://www.val.town/v/pomdtr/basicAuth) with your [Val Town API Token](https://www.val.town/settings/api) as the password (leave the username field blank).
12
13# TODO

getReverseDependenciesmain.tsx2 matches

@peterqliuUpdated 7 months ago
1import { api } from "https://esm.town/v/pomdtr/api";
2
3type Module = {
19 // search appears in the readme. We'll filter all these out later.
20 const searchString = ` from "https://esm.town/v/${initialSlug}`;
21 const { data } = await api(`/v1/search/vals?query=${encodeURI(searchString)}&offset=0&limit=100`);
22
23 return data

dependency_graphmain.tsx3 matches

@peterqliuUpdated 7 months ago
24### TODO
25Some ideas for how to expand this site:
26* **show the upstream dependencies** - no public API for this yet, but could probably make it work with the search api
27* **search for vals** - let people search for vals right from here, using the search api and debouncing
28* **toggle graph complexity** - let people choose to see all dependencies or only valtown dependencies (thru the browser)
29* **cache graphs in DB** - we should be kind to valtown's API by caching graph data as exploring the
30graph involves a lot of calls. maybe only update it when the val version number changes?
31* **handle more module sources** - currently we only group npm, esm.sh, and valtown modules. we could add more or make

blob_adminREADME.md1 match

@akilanghUpdated 7 months ago
9[![](https://stevekrouse-button.web.val.run/Install)](https://www.val.town/v/stevekrouse/blob_admin_app/fork)
10
11It uses [basic authentication](https://www.val.town/v/pomdtr/basicAuth) with your [Val Town API Token](https://www.val.town/settings/api) as the password (leave the username field blank).
12
13# TODO

browserbasemain.tsx1 match

@koraUpdated 7 months ago
2
3const browser = await puppeteer.connect({
4 browserWSEndpoint: `wss://connect.browserbase.com?apiKey=${Deno.env.get("BROWSERBASE_API_KEY")}`,
5});
6

twitterRecentMentionsmain.tsx1 match

@charmaineUpdated 7 months ago
1// This val fetches recent tweets about @SnapAR or Lens Studio
2// Updated to use Social Data instead of Twitter API
3
4import { socialDataSearch } from "https://esm.town/v/stevekrouse/socialDataSearch";

vapi-minutes-db1 file match

@henrywilliamsUpdated 1 day ago

vapi-minutes-db2 file matches

@henrywilliamsUpdated 1 day 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