diff --git a/main.go b/main.go index 58a4dde..ea1333a 100644 --- a/main.go +++ b/main.go @@ -87,7 +87,14 @@ func main() { } endpoint := strings.TrimRight(baseURL, "/") + "/api/v1/patch_gitea_odoo" - resp, err := http.Post(endpoint, "application/json", bytes.NewBuffer(payloadBytes)) + req, err := http.NewRequest(http.MethodPatch, endpoint, bytes.NewBuffer(payloadBytes)) + if err != nil { + logger.Printf("Error creating HTTP request: %v\n", err) + os.Exit(1) + } + req.Header.Set("Content-Type", "application/json") + + resp, err := http.DefaultClient.Do(req) if err != nil { logger.Printf("HTTP request failed: %v\n", err) os.Exit(1)