1export function myApi(name) {
2 return "hi " + name;
3}
1export function myApi(name) {
2 return "hi " + name;
3}
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3// Explore the Star Wars universe, from StarWarsAPI
4export let starWars = fetchJSON(
5 "https://swapi.dev/api/people/1/"
6);
7 commands: Array<Object>
8) => {
9 let url = `https://discord.com/api/v10/applications/${app_id}/`;
10 if (guild_id) {
11 url += `guilds/${guild_id}/commands`;
11 token: process.env.vt_token,
12 error: true,
13 source: ["api", "interval"],
14 since: interval.lastRunAt,
15 });
34}> {
35 return fetchJSON(
36 "http://api.val.town/v1/me/comments?" +
37 searchParams({
38 since: since?.toISOString(),
40 };
41}) {
42 const { default: atproto } = await import("https://cdn.jsdelivr.net/npm/@atproto/api/+esm");
43 const { default: resolver } = await import("npm:@atproto/did-resolver");
44 const feedUri = atproto.AtUri.make(
108 }
109 else {
110 res.json("TODO, proxy all request to the Val Town API from this val");
111 }
112 };
1export function myApi(name) {
2 return "hi " + name;
3}
7 const url = "https://blog.samaltman.com/how-to-be-successful";
8 const res = await fetch(
9 "https://extractus.deno.dev/extract?apikey=rn0wbHos2e73W6ghQf705bdF&type=article&url=" +
10 url
11 );
1import { fetch } from "https://esm.town/v/std/fetch";
2import { set } from "https://esm.town/v/std/set?v=11";
3import { postHogAPICapture } from "https://esm.town/v/ianvph/postHogAPICapture";
4import { email } from "https://esm.town/v/ianvph/email";
5import { phProjectAPIKey } from "https://esm.town/v/ianvph/phProjectAPIKey";
6import { newestBlogLink } from "https://esm.town/v/ianvph/newestBlogLink";
7import { parseXML } from "https://esm.town/v/stevekrouse/parseXML?v=1";
26 };
27 const captureData = {
28 key: phProjectAPIKey,
29 event: "new blog published",
30 properties: properties,
31 distinct_id: email,
32 };
33 postHogAPICapture(captureData);
34 await set("newestBlogLink", newestEntry.link);
35 return "new blog captured";