HttpExtensions extension
- on
Methods
-
httpDelete(
String endPoint, {Map< String, String> ? headers}) → Future -
Sends an HTTP DELETE request with the given headers to the given URL, which
can be a Uri or a String.
endPoint
- end point of current url example: current string is www.mydomain.com endpoint param - user result request -> www.mydomain.com/user -
httpGet(
String endPoint) → Future -
Sends an HTTP GET request with the given headers to the given URL, which can
be a Uri or a String.
endPoint
- end point of current url example: current string is www.mydomain.com endpoint param - user result request -> www.mydomain.com/user -
httpPost(
String endPoint, String json, [Map< String, String> headers = _defaultHeaders]) → Future -
Sends an HTTP POST request with the given headers and body to the given URL,
which can be a Uri or a String.
endPoint
- end point of current url example: current string is www.mydomain.com endpoint param - user result request -> www.mydomain.com/user -
httpPut(
String endPoint, String json, [Map< String, String> headers = _defaultHeaders]) → Future -
Sends an HTTP PUT request with the given headers and body to the given URL,
which can be a Uri or a String.
endPoint
- end point of current url example: current string is www.mydomain.com endpoint param - user result request -> www.mydomain.com/user