1import { myName } from "https://esm.town/v/jakesing/myName";
2
3export function myApi() {
4 return "hi " + myName;
5}
1export function myApi(name) {
2 return "hi " + name;
3}
33 "model": "gpt-3.5-turbo",
34 });
35 let openApiKey = process.env.OPEN_API_KEY;
36 var requestOptions = {
37 method: "POST",
38 headers: {
39 "Content-Type": "application/json",
40 "Authorization": `Bearer ${openApiKey}`,
41 },
42 body: rawBody,
43 redirect: "follow",
44 };
45 let openApiResponse = await fetch(
46 "https://api.openai.com/v1/chat/completions",
47 requestOptions,
48 );
49 let jsonResponse = await openApiResponse.json();
50 let choice = jsonResponse?.choices[0]?.message.content;
51 if (!choice) {
1export function myApi(name) {
2 return "hi " + name;
3}
1export function myApi(name) {
2 return "hi " + name;
3}
1export function myApi(name) {
2 return "hi " + name;
3}
3// Github following
4export let githubFollowing = fetchJSON(
5 "https://api.github.com/users/stevekrouse/following"
6);
1export function myApi(name) {
2 return "hi " + name;
3}
10}) =>
11 fetchJSON(
12 `https://api.telegram.org/bot${botToken}/setWebhook`,
13 {
14 method: "POST",
2
3export const exampleExpressPOST = fetchText(
4 "https://api.val.town/v1/express/stevekrouse.expressHTMLExample",
5 { method: "POST", body: JSON.stringify({ name: "Docs" }) },
6);