dochub-sdk 0.1.130 → 0.1.132
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/interfaces/protocols.ts +3 -4
- package/package.json +1 -1
package/interfaces/protocols.ts
CHANGED
@@ -1,8 +1,7 @@
|
|
1
1
|
import { AxiosResponse, AxiosRequestConfig } from 'axios';
|
2
2
|
import { IDocHubContext } from './contexts';
|
3
|
-
import { IDataLakePullFileOptions } from './datalake';
|
4
3
|
|
5
|
-
export enum
|
4
|
+
export enum ProtocolOptionsResponseTypes {
|
6
5
|
arraybuffer = 'arraybuffer',
|
7
6
|
document = 'document',
|
8
7
|
json = 'json',
|
@@ -14,12 +13,12 @@ export enum DataLakePullFileOptionsResponseTypes {
|
|
14
13
|
* Опции получения файла из DataLake
|
15
14
|
*/
|
16
15
|
export interface IProtocolResponseOptions {
|
17
|
-
responseType?:
|
16
|
+
responseType?: ProtocolOptionsResponseTypes;
|
18
17
|
responseEncoding?: string;
|
19
18
|
timeout?: number;
|
20
19
|
}
|
21
20
|
|
22
|
-
export type IDocHubProtocolResponseDecoder = (response: AxiosResponse, options?: IProtocolResponseOptions) => AxiosResponse
|
21
|
+
export type IDocHubProtocolResponseDecoder = (response: AxiosResponse, options?: IProtocolResponseOptions) => Promise<AxiosResponse>;
|
23
22
|
|
24
23
|
// Прослойка интерфейсов Axios для последующей кастомизации и поддержания совместимости
|
25
24
|
export interface IDocHubProtocolRequestConfig extends AxiosRequestConfig {
|