[microservice-utilities] Add a type for flat object with string for the header object in PlatformClient

This commit is contained in:
Daan Boerlage
2018-11-27 19:15:31 +01:00
parent 70d843fd2f
commit de00f487a8
+7 -7
View File
@@ -42,13 +42,13 @@ export interface PlatformClientResponse {
export class PlatformClient {
constructor(logFunction: (msg: any) => void, tokenResolverFunction?: Promise<() => string>, configuration?: PlatformClientConfiguration)
get(url: string, headers?: object, type?: string): Promise<PlatformClientResponse>;
post(url: string, data: object, headers?: object): Promise<PlatformClientResponse>;
put(url: string, data: object, headers?: object): Promise<PlatformClientResponse>;
patch(url: string, data: object, headers?: object): Promise<PlatformClientResponse>;
delete(url: string, headers?: object): Promise<PlatformClientResponse>;
head(url: string, headers?: object): Promise<PlatformClientResponse>;
options(url: string, headers?: object): Promise<PlatformClientResponse>;
get(url: string, headers?: { [s: string]: string; }, type?: string): Promise<PlatformClientResponse>;
post(url: string, data: object, headers?: { [s: string]: string; }): Promise<PlatformClientResponse>;
put(url: string, data: object, headers?: { [s: string]: string; }): Promise<PlatformClientResponse>;
patch(url: string, data: object, headers?: { [s: string]: string; }): Promise<PlatformClientResponse>;
delete(url: string, headers?: { [s: string]: string; }): Promise<PlatformClientResponse>;
head(url: string, headers?: { [s: string]: string; }): Promise<PlatformClientResponse>;
options(url: string, headers?: { [s: string]: string; }): Promise<PlatformClientResponse>;
}
/**