Skip to content

Commit 907d318

Browse files
committed
fix: Make various TypeScript request components optional
This should address the issues faced in #353 while still ensuring that we accurately cover the type's requirements.
1 parent 4d3819a commit 907d318

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

index.d.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -431,18 +431,18 @@ declare namespace SendGrid.Rest {
431431
export const emptyRequest: Request;
432432

433433
interface Request {
434-
host: string;
434+
host?: string;
435435
method: "GET" | "PATCH" | "POST" | "PUT" | "DELETE";
436436
path: string;
437-
headers: {
437+
headers?: {
438438
[header: string]: string|number;
439439
};
440-
body: string | {};
441-
queryParams: {
440+
body?: string | {};
441+
queryParams?: {
442442
[param: string]: string;
443443
};
444-
test: boolean;
445-
port: string|number;
444+
test?: boolean;
445+
port?: string|number;
446446
}
447447

448448
interface Response {

0 commit comments

Comments
 (0)