Skip to content

Instantly share code, notes, and snippets.

@micahwalter
Created January 4, 2024 18:23
Show Gist options
  • Save micahwalter/7b5e026e3f2fd2bcbebf902937aef8ed to your computer and use it in GitHub Desktop.
Save micahwalter/7b5e026e3f2fd2bcbebf902937aef8ed to your computer and use it in GitHub Desktop.
package main
import (
"fmt"
"net/http"
"os"
"github.com/aws/aws-lambda-go/lambda"
)
func handler() {
url := os.Getenv("AMPLIFY_WEBHOOK_URL")
fmt.Printf("Sending to webhook: %s", url)
_, err := http.Post(url, "application/json", nil)
if err != nil {
fmt.Println(err)
}
}
func main() {
lambda.Start(handler)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment