Skip to main content
Module

x/netzo/deno.d.ts>fetch

SDK for Netzo, the open Web platform to unify IoT devices, applications and services.
Go to Latest
function fetch
allow-net
allow-read
import { fetch } from "https://deno.land/x/netzo@v0.1.11/deno.d.ts";

Fetch a resource from the network. It returns a Promise that resolves to the Response to that Request, whether it is successful or not.

const response = await fetch("http://my.json.host/data.json");
console.log(response.status);  // e.g. 200
console.log(response.statusText); // e.g. "OK"
const jsonData = await response.json();

Parameters

input: URL | Request | string
optional
init: RequestInit