# Class RequestClient

### Hierarchy

- RequestClient

### Implements

- HttpClient

### Constructors

- constructor

### Methods

- authorize
- clearCsrfTokens
- delete
- get
- getCsrfToken
- patch
- post
- put
- uploadFile

## Constructors

### constructor

- new RequestClient(baseUrl: string, allowInsecure?: boolean): RequestClient

- - Defined in src/request/RequestClient.ts:49

  #### Parameters

  - ##### baseUrl: string

  - ##### Default value allowInsecure: boolean = false

  #### Returns RequestClient

## Methods

### authorize

- authorize(response: string): Promise<any>

- - Defined in src/request/RequestClient.ts:242

  #### Parameters

  - ##### response: string

  #### Returns Promise<any>

### clearCsrfTokens

- clearCsrfTokens(): void

- Implementation of HttpClient.clearCsrfTokens

  - Defined in src/request/RequestClient.ts:71

  #### Returns void

### delete

- delete<T>(url: string, accessToken?: undefined | string): Promise<object>

- Implementation of HttpClient.delete

  - Defined in src/request/RequestClient.ts:172

  #### Type parameters

  - #### T

  #### Parameters

  - ##### url: string

  - ##### Optional accessToken: undefined | string

  #### Returns Promise<object>

### get

- get<T>(url: string, accessToken: string | undefined, contentType?: string, overrideHeaders?: object, debug?: boolean): Promise<object>

- - Defined in src/request/RequestClient.ts:76

  #### Type parameters

  - #### T

  #### Parameters

  - ##### url: string

  - ##### accessToken: string | undefined

  - ##### Default value contentType: string = "application/json"

  - ##### Default value overrideHeaders: object = {}

    - ##### [key: string]: string | number

  - ##### Default value debug: boolean = false

  #### Returns Promise<object>

### getCsrfToken

- getCsrfToken(type?: "general" | "file"): undefined | CsrfToken

- Implementation of HttpClient.getCsrfToken

  - Defined in src/request/RequestClient.ts:67

  #### Parameters

  - ##### Default value type: "general" | "file" = "general"

  #### Returns undefined | CsrfToken

### patch

- patch<T>(url: string, data?: any, accessToken?: undefined | string): Promise<object>

- - Defined in src/request/RequestClient.ts:189

  #### Type parameters

  - #### T

  #### Parameters

  - ##### url: string

  - ##### Default value data: any = {}

  - ##### Optional accessToken: undefined | string

  #### Returns Promise<object>

### post

- post<T>(url: string, data: any, accessToken: string | undefined, contentType?: string, overrideHeaders?: object): Promise<object>

- - Defined in src/request/RequestClient.ts:123

  #### Type parameters

  - #### T

  #### Parameters

  - ##### url: string

  - ##### data: any

  - ##### accessToken: string | undefined

  - ##### Default value contentType: string = "application/json"

  - ##### Default value overrideHeaders: object = {}

    - ##### [key: string]: string | number

  #### Returns Promise<object>

### put

- put<T>(url: string, data: any, accessToken: string | undefined, overrideHeaders?: object): Promise<object>

- - Defined in src/request/RequestClient.ts:148

  #### Type parameters

  - #### T

  #### Parameters

  - ##### url: string

  - ##### data: any

  - ##### accessToken: string | undefined

  - ##### Default value overrideHeaders: object = {}

    - ##### [key: string]: string | number

  #### Returns Promise<object>

### uploadFile

- uploadFile(url: string, content: string, accessToken?: undefined | string): Promise<any>

- - Defined in src/request/RequestClient.ts:209

  #### Parameters

  - ##### url: string

  - ##### content: string

  - ##### Optional accessToken: undefined | string

  #### Returns Promise<any>

Generated using TypeDoc