@http:fetch
Fetch a URL and return the response body as a string.
Returns: string
Syntax
Section titled “Syntax”@http:fetch(url method? body? auth?)Arguments
Section titled “Arguments”| Name | Type | Description |
|---|---|---|
url | string | Request URL |
[method] | string | HTTP method (GET, POST, etc.) |
[body] | string | Request body (JSON string) |
[auth] | string | Authorization header value |
See Also
Section titled “See Also”- @http:json — parse JSON response
- @http:json.format — build JSON request body