Skip to content

Class: FetchTransport ​

A transport backed by the runtime's global fetch. Fetch adds the browser sec-fetch-* headers, which the private API rejects, so Instagram calls go through HttpsTransport. This one is kept for generic use and testing.

Implements ​

Constructors ​

Constructor ​

ts
new FetchTransport(): FetchTransport;

Returns ​

FetchTransport

Methods ​

request() ​

ts
request(req): Promise<HttpResponse>;

Sends the request with the global fetch.

Parameters ​

ParameterType
reqHttpRequest

Returns ​

Promise<HttpResponse>

Implementation of ​

HttpTransport.request

MIT License. Not affiliated with, endorsed or sponsored by Meta or Instagram.