From f4b717c92f599ac8f70bf6cffc7528314af0a753 Mon Sep 17 00:00:00 2001 From: sbansla Date: Mon, 22 Apr 2024 00:20:49 +0530 Subject: [PATCH] chore: added put method support --- client/request_handler.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/client/request_handler.go b/client/request_handler.go index 3b918e9ba..e1393823e 100644 --- a/client/request_handler.go +++ b/client/request_handler.go @@ -86,6 +86,10 @@ func (c *RequestHandler) Post(path string, bodyData url.Values, headers map[stri return c.sendRequest(http.MethodPost, path, bodyData, headers, body...) } +func (c *RequestHandler) Put(path string, bodyData url.Values, headers map[string]interface{}, body ...byte) (*http.Response, error) { + return c.sendRequest(http.MethodPut, path, bodyData, headers, body...) +} + func (c *RequestHandler) Get(path string, queryData url.Values, headers map[string]interface{}) (*http.Response, error) { return c.sendRequest(http.MethodGet, path, queryData, headers) }