Skip to content

Commit 375d83f

Browse files
committed
chore: also print request body
1 parent e422a5c commit 375d83f

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

‎main.go‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,13 @@ func buildPostEventHandler(plausibleApiUrl string) func(w http.ResponseWriter, r
108108
}
109109
}
110110

111+
b, err := io.ReadAll(r.Body)
112+
if err != nil {
113+
fmt.Println("Error reading body", err)
114+
}
115+
116+
fmt.Println(string(b))
117+
111118
client := http.DefaultClient
112119
response, error := client.Do(request)
113120

0 commit comments

Comments
 (0)