igpapi — Instagram private API Simulator for Node.js (API reference) 4.14.0
    Preparing search index...

    Interface HttpRenderTransportOptions

    interface HttpRenderTransportOptions {
        client?: HttpRequestRenderer;
        clientOptions?:
            | ClientOptions
            | ((request: TransportRequest) => ClientOptions);
        respond?: (
            request: RenderedHttpRequest,
            services: Context<never>,
        ) => TransportResponse | Promise<TransportResponse>;
    }
    Index

    Properties

    The client that renders; pass this or clientOptions (which needs a profile).

    clientOptions?: ClientOptions | ((request: TransportRequest) => ClientOptions)

    The options of the client that renders, or a function that picks them per request. A function builds one client for each options value it returns and renders the request through the client of the value it returned for that request, so a caller that renders requests over more than one transport path (a protocolMode, for one) passes the same options object for every request of one path and keeps one client per path. The network-session pair (x-fb-appnetsession-nid / -sid) is the process's, so it is one value across those clients: the first pair any client renders is rendered for all of them.

    respond?: (
        request: RenderedHttpRequest,
        services: Context<never>,
    ) => TransportResponse | Promise<TransportResponse>

    Answers each rendered request. services are the services of the fiber that sent it, so a caller can tell requests apart by what that fiber runs under (the conformance harness's cut).