Skip to content

Net

Lets a plugin fetch from a website. The app checks the permission first, and only https addresses are accepted.

fetch(url, init?): Promise<NetResponse>;

Fetches a URL over https.

Parameter Type Description
url string an https address
init? { body?: string; headers?: Readonly<Record<string, string>>; method?: string; } method, headers and body
init.body? string -
init.headers? Readonly<Record<string, string>> -
init.method? string -

Promise<NetResponse>

the status, the headers and the body as text