Home > @curity/identityserver-haapi-web-driver > FetchLike

FetchLike type

A function similar to fetch used to perform HAAPI requests.


export declare type FetchLike = (link: string, init?: {
    method?: string;
    body?: URLSearchParams | Record<string, string> | null;
    credentials?: RequestCredentials;
    headers?: HeadersInit;
}) => Promise<Response>;


The init parameter accepts less or stricter properties than its equivalent in fetch, namely for the types allowed in body.