update types

This commit is contained in:
Geoffrey Plitt 2023-11-21 13:47:42 -08:00
parent 982786ceae
commit 84d1095134
1 changed files with 22 additions and 0 deletions

22
types.d.ts vendored
View File

@ -21,4 +21,26 @@ declare namespace root__request {
function put(opts: any, ...args: any[]): any;
type Headers = Record<string, string | string[]>;
interface RequestOptions {
body ?: any;
form ?: any;
headers ?: Headers;
method ?: string;
json ?: boolean | any;
url: string;
}
interface Response {
body: any;
headers: Headers;
ok: boolean;
response ?: any;
request ?: any;
status: string;
statusCode: number;
}
function Request(opts: RequestOptions): Response;
}