2 res.json({
3 schema_version: "v1",
4 name_for_human: "APIs.guru Plugin",
5 name_for_model: "apis.guru",
6 description_for_human: "Plugin for accessing APIs.guru OpenAPI Directory.",
7 description_for_model:
8 "Plugin for accessing APIs.guru OpenAPI Directory. Use the list.json endpoint to find APIs. Use the metrics.json endpoint to find metadata about APIs such as counts, totals and charting data.",
9 auth: {
10 type: "none",
11 },
12 api: {
13 type: "openapi",
14 url: "https://api.apis.guru/v2/ai-openapi.yaml",
15 is_user_authenticated: false,
16 },
17 logo_url: "https://api.apis.guru/logo.svg",
18 contact_email: "mike.ralphson@gmail.com",
19 legal_info_url: "https://apis.guru",
20 });
21};
1export function myApi(name) {
2 return "hi " + name;
3}
1export function myApi(name) {
2 return "hi " + name;
3}
4 let pm25 = (
5 await fetchJSON(
6 "https://api.openaq.org/v2/latest?" +
7 new URLSearchParams({
8 limit: "10",
7 isInterval?: boolean;
8}) =>
9 fetchJSON(`api.val.town/run/`, {
10 headers: {
11 accept: "*/*",
1export function myApi(name) {
2 return "hi " + name;
3}
3// Activity suggestions for when you're bored
4export let boredActivities = fetchJSON(
5 "https://www.boredapi.com/api/activity"
6);
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3export function tidbytDeviceInstallations({ deviceId, apiKey }: {
4 deviceId: string;
5 apiKey: string;
6}) {
7 return fetchJSON(
8 `https://api.tidbyt.com/v0/devices/${deviceId}/installations`,
9 {
10 headers: {
11 Authorization: `Bearer ${apiKey}`,
12 },
13 },
24}[]> {
25 const res = await fetchJSON(
26 "https://api.val.town/v1/me/references?" +
27 searchParams({
28 since: since?.toISOString(),
38 await new Promise<void>((resolve) => setTimeout(() => resolve(), 150));
39 }
40 const code = `await api(
41 @andreterron.paintGraffitiPixel,
42 ${Math.min(Math.floor(Math.random() * 64), 64)}, // x