16 const json = await fetchJSON(url, {
17 headers: {
18 apiKey: process.env.transit,
19 },
20 });
3// Github profile
4export let githubUser = fetchJSON(
5 "https://api.github.com/users/stevekrouse"
6);
2let { nameList } = await import("https://esm.town/v/acmu/nameList");
3
4export async function myApiAdd(name) {
5 if (Array.isArray(nameList)) {
6 nameList.push(name);
13 }[];
14 } = await fetchJSON(
15 "https://api.openai.com/v1/images/generations",
16 {
17 method: "POST",
1export function myApi(name) {
2 return "hi " + name;
3}
1export function myApi(name) {
2 return "hi " + name;
3}
4 try {
5 const title = url.split("/wiki/")[1];
6 const apiUrl = `https://en.wikipedia.org/w/api.php?action=query&prop=extracts&exintro&explaintext&format=json&origin=*&titles=${title}`;
7 const response = await fetch(apiUrl);
8 const data = await response.json();
9 const pageId = Object.keys(data.query.pages)[0];
2
3export async function sendMessage(ptnKey: string, message: string) {
4 await fetch("https://app.phonetonote.com/hooks/zapier", {
5 body: JSON.stringify({
6 ptn_key: ptnKey,
1export function myApi(name) {
2 var sentence = "hi " + name;
3 console.email(sentence);
1export function myApi(name) {
2 return "hi " + name;
3}