Booking trace API

This commit is contained in:
mr
2024-08-21 16:03:56 +02:00
parent 6ef8cde225
commit 950bbf1d7b
4 changed files with 19 additions and 7 deletions

View File

@@ -46,7 +46,7 @@ func (caller *HTTPCaller) CallDelete(url string, subpath string) ([]byte, error)
return io.ReadAll(resp.Body)
}
func (caller *HTTPCaller) CallPost(url string, subpath string, body map[string]interface{}) ([]byte, error) {
func (caller *HTTPCaller) CallPost(url string, subpath string, body interface{}) ([]byte, error) {
postBody, _ := json.Marshal(body)
responseBody := bytes.NewBuffer(postBody)
resp, err := http.Post(url+subpath, "application/json", responseBody)