@se-uulm/snowballr-api-client 0.1.1-alpha.0f85732

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.
Files changed (59) hide show
  1. package/.openapi-generator/FILES +17 -0
  2. package/.openapi-generator/VERSION +1 -0
  3. package/.openapi-generator-ignore +23 -0
  4. package/CHANGELOG.md +9 -0
  5. package/LICENSE +674 -0
  6. package/README.md +46 -0
  7. package/dist/apis/ProjectsControllerApi.d.ts +102 -0
  8. package/dist/apis/ProjectsControllerApi.js +141 -0
  9. package/dist/apis/index.d.ts +1 -0
  10. package/dist/apis/index.js +19 -0
  11. package/dist/esm/apis/ProjectsControllerApi.d.ts +102 -0
  12. package/dist/esm/apis/ProjectsControllerApi.js +137 -0
  13. package/dist/esm/apis/index.d.ts +1 -0
  14. package/dist/esm/apis/index.js +3 -0
  15. package/dist/esm/index.d.ts +3 -0
  16. package/dist/esm/index.js +5 -0
  17. package/dist/esm/models/CreateProjectRequest.d.ts +32 -0
  18. package/dist/esm/models/CreateProjectRequest.js +41 -0
  19. package/dist/esm/models/DecisionMatrixPattern.d.ts +49 -0
  20. package/dist/esm/models/DecisionMatrixPattern.js +53 -0
  21. package/dist/esm/models/DecisionMatrixPatternEntry.d.ts +47 -0
  22. package/dist/esm/models/DecisionMatrixPatternEntry.js +51 -0
  23. package/dist/esm/models/Project.d.ts +117 -0
  24. package/dist/esm/models/Project.js +80 -0
  25. package/dist/esm/models/ReviewDecisionMatrix.d.ts +39 -0
  26. package/dist/esm/models/ReviewDecisionMatrix.js +44 -0
  27. package/dist/esm/models/index.d.ts +5 -0
  28. package/dist/esm/models/index.js +7 -0
  29. package/dist/esm/runtime.d.ts +184 -0
  30. package/dist/esm/runtime.js +334 -0
  31. package/dist/index.d.ts +3 -0
  32. package/dist/index.js +21 -0
  33. package/dist/models/CreateProjectRequest.d.ts +32 -0
  34. package/dist/models/CreateProjectRequest.js +48 -0
  35. package/dist/models/DecisionMatrixPattern.d.ts +49 -0
  36. package/dist/models/DecisionMatrixPattern.js +61 -0
  37. package/dist/models/DecisionMatrixPatternEntry.d.ts +47 -0
  38. package/dist/models/DecisionMatrixPatternEntry.js +59 -0
  39. package/dist/models/Project.d.ts +117 -0
  40. package/dist/models/Project.js +88 -0
  41. package/dist/models/ReviewDecisionMatrix.d.ts +39 -0
  42. package/dist/models/ReviewDecisionMatrix.js +51 -0
  43. package/dist/models/index.d.ts +5 -0
  44. package/dist/models/index.js +23 -0
  45. package/dist/runtime.d.ts +184 -0
  46. package/dist/runtime.js +350 -0
  47. package/package.json +22 -0
  48. package/src/apis/ProjectsControllerApi.ts +238 -0
  49. package/src/apis/index.ts +3 -0
  50. package/src/index.ts +5 -0
  51. package/src/models/CreateProjectRequest.ts +65 -0
  52. package/src/models/DecisionMatrixPattern.ts +94 -0
  53. package/src/models/DecisionMatrixPatternEntry.ts +85 -0
  54. package/src/models/Project.ts +177 -0
  55. package/src/models/ReviewDecisionMatrix.ts +81 -0
  56. package/src/models/index.ts +7 -0
  57. package/src/runtime.ts +432 -0
  58. package/tsconfig.esm.json +7 -0
  59. package/tsconfig.json +16 -0
@@ -0,0 +1,117 @@
1
+ /**
2
+ * SnowballR API
3
+ * REST API for the SnowballR Application
4
+ *
5
+ * The version of the OpenAPI document: v1
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import type { ReviewDecisionMatrix } from './ReviewDecisionMatrix';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface Project
17
+ */
18
+ export interface Project {
19
+ /**
20
+ *
21
+ * @type {string}
22
+ * @memberof Project
23
+ */
24
+ id?: string;
25
+ /**
26
+ *
27
+ * @type {string}
28
+ * @memberof Project
29
+ */
30
+ name?: string;
31
+ /**
32
+ *
33
+ * @type {string}
34
+ * @memberof Project
35
+ */
36
+ status?: ProjectStatusEnum;
37
+ /**
38
+ *
39
+ * @type {number}
40
+ * @memberof Project
41
+ */
42
+ currentStage?: number;
43
+ /**
44
+ *
45
+ * @type {number}
46
+ * @memberof Project
47
+ */
48
+ maxStage?: number;
49
+ /**
50
+ *
51
+ * @type {number}
52
+ * @memberof Project
53
+ */
54
+ similarityThreshold?: number;
55
+ /**
56
+ *
57
+ * @type {string}
58
+ * @memberof Project
59
+ */
60
+ snowballingType?: ProjectSnowballingTypeEnum;
61
+ /**
62
+ *
63
+ * @type {boolean}
64
+ * @memberof Project
65
+ */
66
+ reviewMaybeAllowed?: boolean;
67
+ /**
68
+ *
69
+ * @type {ReviewDecisionMatrix}
70
+ * @memberof Project
71
+ */
72
+ reviewDecisionMatrix?: ReviewDecisionMatrix;
73
+ /**
74
+ *
75
+ * @type {{ [key: string]: { [key: string]: string; }; }}
76
+ * @memberof Project
77
+ */
78
+ fetchers?: {
79
+ [key: string]: {
80
+ [key: string]: string;
81
+ };
82
+ };
83
+ /**
84
+ *
85
+ * @type {Date}
86
+ * @memberof Project
87
+ */
88
+ currentStageStartedAt?: Date;
89
+ }
90
+ /**
91
+ * @export
92
+ */
93
+ export declare const ProjectStatusEnum: {
94
+ readonly ACTIVE: "ACTIVE";
95
+ readonly ACTIVE_LOCKED: "ACTIVE_LOCKED";
96
+ readonly ARCHIVED: "ARCHIVED";
97
+ readonly DELETED: "DELETED";
98
+ readonly CLEARED: "CLEARED";
99
+ };
100
+ export type ProjectStatusEnum = typeof ProjectStatusEnum[keyof typeof ProjectStatusEnum];
101
+ /**
102
+ * @export
103
+ */
104
+ export declare const ProjectSnowballingTypeEnum: {
105
+ readonly FORWARD: "FORWARD";
106
+ readonly BACKWARD: "BACKWARD";
107
+ readonly BOTH: "BOTH";
108
+ };
109
+ export type ProjectSnowballingTypeEnum = typeof ProjectSnowballingTypeEnum[keyof typeof ProjectSnowballingTypeEnum];
110
+ /**
111
+ * Check if a given object implements the Project interface.
112
+ */
113
+ export declare function instanceOfProject(value: object): value is Project;
114
+ export declare function ProjectFromJSON(json: any): Project;
115
+ export declare function ProjectFromJSONTyped(json: any, ignoreDiscriminator: boolean): Project;
116
+ export declare function ProjectToJSON(json: any): Project;
117
+ export declare function ProjectToJSONTyped(value?: Project | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,88 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * SnowballR API
6
+ * REST API for the SnowballR Application
7
+ *
8
+ * The version of the OpenAPI document: v1
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.ProjectSnowballingTypeEnum = exports.ProjectStatusEnum = void 0;
17
+ exports.instanceOfProject = instanceOfProject;
18
+ exports.ProjectFromJSON = ProjectFromJSON;
19
+ exports.ProjectFromJSONTyped = ProjectFromJSONTyped;
20
+ exports.ProjectToJSON = ProjectToJSON;
21
+ exports.ProjectToJSONTyped = ProjectToJSONTyped;
22
+ const ReviewDecisionMatrix_1 = require("./ReviewDecisionMatrix");
23
+ /**
24
+ * @export
25
+ */
26
+ exports.ProjectStatusEnum = {
27
+ ACTIVE: 'ACTIVE',
28
+ ACTIVE_LOCKED: 'ACTIVE_LOCKED',
29
+ ARCHIVED: 'ARCHIVED',
30
+ DELETED: 'DELETED',
31
+ CLEARED: 'CLEARED'
32
+ };
33
+ /**
34
+ * @export
35
+ */
36
+ exports.ProjectSnowballingTypeEnum = {
37
+ FORWARD: 'FORWARD',
38
+ BACKWARD: 'BACKWARD',
39
+ BOTH: 'BOTH'
40
+ };
41
+ /**
42
+ * Check if a given object implements the Project interface.
43
+ */
44
+ function instanceOfProject(value) {
45
+ return true;
46
+ }
47
+ function ProjectFromJSON(json) {
48
+ return ProjectFromJSONTyped(json, false);
49
+ }
50
+ function ProjectFromJSONTyped(json, ignoreDiscriminator) {
51
+ if (json == null) {
52
+ return json;
53
+ }
54
+ return {
55
+ 'id': json['id'] == null ? undefined : json['id'],
56
+ 'name': json['name'] == null ? undefined : json['name'],
57
+ 'status': json['status'] == null ? undefined : json['status'],
58
+ 'currentStage': json['currentStage'] == null ? undefined : json['currentStage'],
59
+ 'maxStage': json['maxStage'] == null ? undefined : json['maxStage'],
60
+ 'similarityThreshold': json['similarityThreshold'] == null ? undefined : json['similarityThreshold'],
61
+ 'snowballingType': json['snowballingType'] == null ? undefined : json['snowballingType'],
62
+ 'reviewMaybeAllowed': json['reviewMaybeAllowed'] == null ? undefined : json['reviewMaybeAllowed'],
63
+ 'reviewDecisionMatrix': json['reviewDecisionMatrix'] == null ? undefined : (0, ReviewDecisionMatrix_1.ReviewDecisionMatrixFromJSON)(json['reviewDecisionMatrix']),
64
+ 'fetchers': json['fetchers'] == null ? undefined : json['fetchers'],
65
+ 'currentStageStartedAt': json['currentStageStartedAt'] == null ? undefined : (new Date(json['currentStageStartedAt'])),
66
+ };
67
+ }
68
+ function ProjectToJSON(json) {
69
+ return ProjectToJSONTyped(json, false);
70
+ }
71
+ function ProjectToJSONTyped(value, ignoreDiscriminator = false) {
72
+ if (value == null) {
73
+ return value;
74
+ }
75
+ return {
76
+ 'id': value['id'],
77
+ 'name': value['name'],
78
+ 'status': value['status'],
79
+ 'currentStage': value['currentStage'],
80
+ 'maxStage': value['maxStage'],
81
+ 'similarityThreshold': value['similarityThreshold'],
82
+ 'snowballingType': value['snowballingType'],
83
+ 'reviewMaybeAllowed': value['reviewMaybeAllowed'],
84
+ 'reviewDecisionMatrix': (0, ReviewDecisionMatrix_1.ReviewDecisionMatrixToJSON)(value['reviewDecisionMatrix']),
85
+ 'fetchers': value['fetchers'],
86
+ 'currentStageStartedAt': value['currentStageStartedAt'] == null ? undefined : ((value['currentStageStartedAt']).toISOString()),
87
+ };
88
+ }
@@ -0,0 +1,39 @@
1
+ /**
2
+ * SnowballR API
3
+ * REST API for the SnowballR Application
4
+ *
5
+ * The version of the OpenAPI document: v1
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import type { DecisionMatrixPattern } from './DecisionMatrixPattern';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface ReviewDecisionMatrix
17
+ */
18
+ export interface ReviewDecisionMatrix {
19
+ /**
20
+ *
21
+ * @type {number}
22
+ * @memberof ReviewDecisionMatrix
23
+ */
24
+ numberOfReviewers?: number;
25
+ /**
26
+ *
27
+ * @type {Array<DecisionMatrixPattern>}
28
+ * @memberof ReviewDecisionMatrix
29
+ */
30
+ patterns?: Array<DecisionMatrixPattern>;
31
+ }
32
+ /**
33
+ * Check if a given object implements the ReviewDecisionMatrix interface.
34
+ */
35
+ export declare function instanceOfReviewDecisionMatrix(value: object): value is ReviewDecisionMatrix;
36
+ export declare function ReviewDecisionMatrixFromJSON(json: any): ReviewDecisionMatrix;
37
+ export declare function ReviewDecisionMatrixFromJSONTyped(json: any, ignoreDiscriminator: boolean): ReviewDecisionMatrix;
38
+ export declare function ReviewDecisionMatrixToJSON(json: any): ReviewDecisionMatrix;
39
+ export declare function ReviewDecisionMatrixToJSONTyped(value?: ReviewDecisionMatrix | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,51 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * SnowballR API
6
+ * REST API for the SnowballR Application
7
+ *
8
+ * The version of the OpenAPI document: v1
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.instanceOfReviewDecisionMatrix = instanceOfReviewDecisionMatrix;
17
+ exports.ReviewDecisionMatrixFromJSON = ReviewDecisionMatrixFromJSON;
18
+ exports.ReviewDecisionMatrixFromJSONTyped = ReviewDecisionMatrixFromJSONTyped;
19
+ exports.ReviewDecisionMatrixToJSON = ReviewDecisionMatrixToJSON;
20
+ exports.ReviewDecisionMatrixToJSONTyped = ReviewDecisionMatrixToJSONTyped;
21
+ const DecisionMatrixPattern_1 = require("./DecisionMatrixPattern");
22
+ /**
23
+ * Check if a given object implements the ReviewDecisionMatrix interface.
24
+ */
25
+ function instanceOfReviewDecisionMatrix(value) {
26
+ return true;
27
+ }
28
+ function ReviewDecisionMatrixFromJSON(json) {
29
+ return ReviewDecisionMatrixFromJSONTyped(json, false);
30
+ }
31
+ function ReviewDecisionMatrixFromJSONTyped(json, ignoreDiscriminator) {
32
+ if (json == null) {
33
+ return json;
34
+ }
35
+ return {
36
+ 'numberOfReviewers': json['numberOfReviewers'] == null ? undefined : json['numberOfReviewers'],
37
+ 'patterns': json['patterns'] == null ? undefined : (json['patterns'].map(DecisionMatrixPattern_1.DecisionMatrixPatternFromJSON)),
38
+ };
39
+ }
40
+ function ReviewDecisionMatrixToJSON(json) {
41
+ return ReviewDecisionMatrixToJSONTyped(json, false);
42
+ }
43
+ function ReviewDecisionMatrixToJSONTyped(value, ignoreDiscriminator = false) {
44
+ if (value == null) {
45
+ return value;
46
+ }
47
+ return {
48
+ 'numberOfReviewers': value['numberOfReviewers'],
49
+ 'patterns': value['patterns'] == null ? undefined : (value['patterns'].map(DecisionMatrixPattern_1.DecisionMatrixPatternToJSON)),
50
+ };
51
+ }
@@ -0,0 +1,5 @@
1
+ export * from './CreateProjectRequest';
2
+ export * from './DecisionMatrixPattern';
3
+ export * from './DecisionMatrixPatternEntry';
4
+ export * from './Project';
5
+ export * from './ReviewDecisionMatrix';
@@ -0,0 +1,23 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ /* tslint:disable */
18
+ /* eslint-disable */
19
+ __exportStar(require("./CreateProjectRequest"), exports);
20
+ __exportStar(require("./DecisionMatrixPattern"), exports);
21
+ __exportStar(require("./DecisionMatrixPatternEntry"), exports);
22
+ __exportStar(require("./Project"), exports);
23
+ __exportStar(require("./ReviewDecisionMatrix"), exports);
@@ -0,0 +1,184 @@
1
+ /**
2
+ * SnowballR API
3
+ * REST API for the SnowballR Application
4
+ *
5
+ * The version of the OpenAPI document: v1
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ export declare const BASE_PATH: string;
13
+ export interface ConfigurationParameters {
14
+ basePath?: string;
15
+ fetchApi?: FetchAPI;
16
+ middleware?: Middleware[];
17
+ queryParamsStringify?: (params: HTTPQuery) => string;
18
+ username?: string;
19
+ password?: string;
20
+ apiKey?: string | Promise<string> | ((name: string) => string | Promise<string>);
21
+ accessToken?: string | Promise<string> | ((name?: string, scopes?: string[]) => string | Promise<string>);
22
+ headers?: HTTPHeaders;
23
+ credentials?: RequestCredentials;
24
+ }
25
+ export declare class Configuration {
26
+ private configuration;
27
+ constructor(configuration?: ConfigurationParameters);
28
+ set config(configuration: Configuration);
29
+ get basePath(): string;
30
+ get fetchApi(): FetchAPI | undefined;
31
+ get middleware(): Middleware[];
32
+ get queryParamsStringify(): (params: HTTPQuery) => string;
33
+ get username(): string | undefined;
34
+ get password(): string | undefined;
35
+ get apiKey(): ((name: string) => string | Promise<string>) | undefined;
36
+ get accessToken(): ((name?: string, scopes?: string[]) => string | Promise<string>) | undefined;
37
+ get headers(): HTTPHeaders | undefined;
38
+ get credentials(): RequestCredentials | undefined;
39
+ }
40
+ export declare const DefaultConfig: Configuration;
41
+ /**
42
+ * This is the base class for all generated API classes.
43
+ */
44
+ export declare class BaseAPI {
45
+ protected configuration: Configuration;
46
+ private static readonly jsonRegex;
47
+ private middleware;
48
+ constructor(configuration?: Configuration);
49
+ withMiddleware<T extends BaseAPI>(this: T, ...middlewares: Middleware[]): T;
50
+ withPreMiddleware<T extends BaseAPI>(this: T, ...preMiddlewares: Array<Middleware['pre']>): T;
51
+ withPostMiddleware<T extends BaseAPI>(this: T, ...postMiddlewares: Array<Middleware['post']>): T;
52
+ /**
53
+ * Check if the given MIME is a JSON MIME.
54
+ * JSON MIME examples:
55
+ * application/json
56
+ * application/json; charset=UTF8
57
+ * APPLICATION/JSON
58
+ * application/vnd.company+json
59
+ * @param mime - MIME (Multipurpose Internet Mail Extensions)
60
+ * @return True if the given MIME is JSON, false otherwise.
61
+ */
62
+ protected isJsonMime(mime: string | null | undefined): boolean;
63
+ protected request(context: RequestOpts, initOverrides?: RequestInit | InitOverrideFunction): Promise<Response>;
64
+ private createFetchParams;
65
+ private fetchApi;
66
+ /**
67
+ * Create a shallow clone of `this` by constructing a new instance
68
+ * and then shallow cloning data members.
69
+ */
70
+ private clone;
71
+ }
72
+ export declare class ResponseError extends Error {
73
+ response: Response;
74
+ name: "ResponseError";
75
+ constructor(response: Response, msg?: string);
76
+ }
77
+ export declare class FetchError extends Error {
78
+ cause: Error;
79
+ name: "FetchError";
80
+ constructor(cause: Error, msg?: string);
81
+ }
82
+ export declare class RequiredError extends Error {
83
+ field: string;
84
+ name: "RequiredError";
85
+ constructor(field: string, msg?: string);
86
+ }
87
+ export declare const COLLECTION_FORMATS: {
88
+ csv: string;
89
+ ssv: string;
90
+ tsv: string;
91
+ pipes: string;
92
+ };
93
+ export type FetchAPI = WindowOrWorkerGlobalScope['fetch'];
94
+ export type Json = any;
95
+ export type HTTPMethod = 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE' | 'OPTIONS' | 'HEAD';
96
+ export type HTTPHeaders = {
97
+ [key: string]: string;
98
+ };
99
+ export type HTTPQuery = {
100
+ [key: string]: string | number | null | boolean | Array<string | number | null | boolean> | Set<string | number | null | boolean> | HTTPQuery;
101
+ };
102
+ export type HTTPBody = Json | FormData | URLSearchParams;
103
+ export type HTTPRequestInit = {
104
+ headers?: HTTPHeaders;
105
+ method: HTTPMethod;
106
+ credentials?: RequestCredentials;
107
+ body?: HTTPBody;
108
+ };
109
+ export type ModelPropertyNaming = 'camelCase' | 'snake_case' | 'PascalCase' | 'original';
110
+ export type InitOverrideFunction = (requestContext: {
111
+ init: HTTPRequestInit;
112
+ context: RequestOpts;
113
+ }) => Promise<RequestInit>;
114
+ export interface FetchParams {
115
+ url: string;
116
+ init: RequestInit;
117
+ }
118
+ export interface RequestOpts {
119
+ path: string;
120
+ method: HTTPMethod;
121
+ headers: HTTPHeaders;
122
+ query?: HTTPQuery;
123
+ body?: HTTPBody;
124
+ }
125
+ export declare function querystring(params: HTTPQuery, prefix?: string): string;
126
+ export declare function exists(json: any, key: string): boolean;
127
+ export declare function mapValues(data: any, fn: (item: any) => any): {
128
+ [key: string]: any;
129
+ };
130
+ export declare function canConsumeForm(consumes: Consume[]): boolean;
131
+ export interface Consume {
132
+ contentType: string;
133
+ }
134
+ export interface RequestContext {
135
+ fetch: FetchAPI;
136
+ url: string;
137
+ init: RequestInit;
138
+ }
139
+ export interface ResponseContext {
140
+ fetch: FetchAPI;
141
+ url: string;
142
+ init: RequestInit;
143
+ response: Response;
144
+ }
145
+ export interface ErrorContext {
146
+ fetch: FetchAPI;
147
+ url: string;
148
+ init: RequestInit;
149
+ error: unknown;
150
+ response?: Response;
151
+ }
152
+ export interface Middleware {
153
+ pre?(context: RequestContext): Promise<FetchParams | void>;
154
+ post?(context: ResponseContext): Promise<Response | void>;
155
+ onError?(context: ErrorContext): Promise<Response | void>;
156
+ }
157
+ export interface ApiResponse<T> {
158
+ raw: Response;
159
+ value(): Promise<T>;
160
+ }
161
+ export interface ResponseTransformer<T> {
162
+ (json: any): T;
163
+ }
164
+ export declare class JSONApiResponse<T> {
165
+ raw: Response;
166
+ private transformer;
167
+ constructor(raw: Response, transformer?: ResponseTransformer<T>);
168
+ value(): Promise<T>;
169
+ }
170
+ export declare class VoidApiResponse {
171
+ raw: Response;
172
+ constructor(raw: Response);
173
+ value(): Promise<void>;
174
+ }
175
+ export declare class BlobApiResponse {
176
+ raw: Response;
177
+ constructor(raw: Response);
178
+ value(): Promise<Blob>;
179
+ }
180
+ export declare class TextApiResponse {
181
+ raw: Response;
182
+ constructor(raw: Response);
183
+ value(): Promise<string>;
184
+ }