1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON";
2
3export function nominatimSearch(params: Search): Promise<Place[]> {
4 return fetchJSON(
5 "https://nominatim.openstreetmap.org/search?"
6 + new URLSearchParams({
17
181. User enters GitHub token, repository information, and date range
192. User clicks "Fetch Commits" to retrieve commit data
203. User reviews commits and associated PR information
214. User clicks "Generate Release Notes" to process commits through LLM
5## Files
6
7- `github.ts` - GitHub API integration for fetching commits and PR data
8- `llm.ts` - OpenAI integration for generating release notes
9- `types.ts` - Type definitions for the backend
13### POST /api/commits
14
15Fetches commits and associated PR data from GitHub within a specified date range.
16
17**Request Body:**
43
44 try {
45 const response = await fetch("/api/user/username", {
46 method: "POST",
47 headers: {
22
23 try {
24 const response = await fetch("/auth/magic-link", {
25 method: "POST",
26 headers: {
77});
78
79// HTTP vals expect an exported "fetch handler"
80// This is how you "run the server" in Val Town with Hono
81export default app.fetch;
571
572 try {
573 const response = await fetch('/api/leads', {
574 method: 'POST',
575 headers: {
601 try {
602 // Get lead data
603 const response = await fetch('/api/leads?id=' + leadId);
604 const result = await response.json();
605
624 }
625 } catch (error) {
626 console.error('Error fetching lead:', error);
627 alert('Error fetching lead: ' + error.message);
628 }
629 });
653
654 try {
655 const response = await fetch('/api/leads', {
656 method: 'PUT',
657 headers: {
705
706 try {
707 const response = await fetch('/api/leads', {
708 method: 'PUT',
709 headers: {
1import { fetchJSON } from "https://esm.town/v/stevekrouse/fetchJSON?v=41";
2
3export const slackReplyToMessage = async (req: Request) => {
15 // Note: `body.event` has information about the event
16 // like the sender and the message text
17 const result = await fetchJSON(
18 "https://slack.com/api/chat.postMessage",
19 {
77});
78
79// HTTP vals expect an exported "fetch handler"
80// This is how you "run the server" in Val Town with Hono
81export default app.fetch;
43
44 try {
45 const response = await fetch("/api/user/username", {
46 method: "POST",
47 headers: {