@giveitsmaller/contracts 0.1.0
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/asyncapi/ErrorCode.ts +19 -0
- package/asyncapi/MergeOutputType.ts +9 -0
- package/asyncapi/NotificationsOperationsQueue.ts +4 -0
- package/asyncapi/OperationMetrics.ts +12 -0
- package/asyncapi/OperationProgress.ts +12 -0
- package/asyncapi/OperationRequest.ts +21 -0
- package/asyncapi/OperationResult.ts +20 -0
- package/asyncapi/OperationType.ts +10 -0
- package/asyncapi/ProgressStatus.ts +8 -0
- package/asyncapi/README.md +16 -0
- package/asyncapi/ResultStatus.ts +6 -0
- package/asyncapi/SourceEntry.ts +9 -0
- package/asyncapi/index.ts +11 -0
- package/index.ts +5 -0
- package/openapi/.openapi-generator-ignore +26 -0
- package/openapi/README.md +17 -0
- package/openapi/index.ts +4 -0
- package/openapi/models/CallbackEventType.ts +60 -0
- package/openapi/models/ContactRequest.ts +113 -0
- package/openapi/models/ContactSubject.ts +62 -0
- package/openapi/models/ContactValidationErrorResponse.ts +67 -0
- package/openapi/models/ErrorEnvelope.ts +85 -0
- package/openapi/models/ExportConfig.ts +108 -0
- package/openapi/models/JobDefinition.ts +56 -0
- package/openapi/models/JobDownload.ts +92 -0
- package/openapi/models/JobInput.ts +89 -0
- package/openapi/models/JobResponse.ts +119 -0
- package/openapi/models/JobSource.ts +79 -0
- package/openapi/models/JobStatus.ts +62 -0
- package/openapi/models/JobType.ts +60 -0
- package/openapi/models/LivenessResponse.ts +66 -0
- package/openapi/models/MetadataResponse.ts +223 -0
- package/openapi/models/MetadataResponseDimensions.ts +73 -0
- package/openapi/models/MetadataResponseExif.ts +97 -0
- package/openapi/models/MetadataResponseExifGps.ts +73 -0
- package/openapi/models/MetadataSuccessEnvelope.ts +93 -0
- package/openapi/models/MimeGroupSchema.ts +91 -0
- package/openapi/models/MultipartCompleteRequest.ts +85 -0
- package/openapi/models/MultipartCompleteRequestPartsInner.ts +75 -0
- package/openapi/models/MultipartInitiateResponse.ts +137 -0
- package/openapi/models/MultipartInitiateSuccessEnvelope.ts +93 -0
- package/openapi/models/OperationDefinition.ts +91 -0
- package/openapi/models/OperationDownload.ts +102 -0
- package/openapi/models/OperationInputModel.ts +56 -0
- package/openapi/models/OperationResponse.ts +124 -0
- package/openapi/models/OperationResult.ts +100 -0
- package/openapi/models/OperationResultMetrics.ts +73 -0
- package/openapi/models/OperationSchemaDefinition.ts +163 -0
- package/openapi/models/OperationStatus.ts +62 -0
- package/openapi/models/OperationType.ts +64 -0
- package/openapi/models/OperationsSchemaResponse.ts +90 -0
- package/openapi/models/OptionSchema.ts +160 -0
- package/openapi/models/PresignedUrlPart.ts +86 -0
- package/openapi/models/ReadinessResponse.ts +73 -0
- package/openapi/models/ResponseEnvelope.ts +70 -0
- package/openapi/models/RetryResponse.ts +94 -0
- package/openapi/models/RetrySuccessEnvelope.ts +93 -0
- package/openapi/models/SseEventType.ts +68 -0
- package/openapi/models/SseJobCompletedData.ts +94 -0
- package/openapi/models/SseJobFailedData.ts +94 -0
- package/openapi/models/SseOperationCompletedData.ts +143 -0
- package/openapi/models/SseOperationFailedData.ts +129 -0
- package/openapi/models/SseOperationProgressData.ts +103 -0
- package/openapi/models/SseWorkflowTerminalData.ts +89 -0
- package/openapi/models/UploadResponse.ts +93 -0
- package/openapi/models/UploadSuccessEnvelope.ts +93 -0
- package/openapi/models/ValidationErrorEnvelope.ts +104 -0
- package/openapi/models/ValidationErrorEnvelopeDetailsInner.ts +90 -0
- package/openapi/models/WebhookOperationContext.ts +77 -0
- package/openapi/models/WebhookPayload.ts +132 -0
- package/openapi/models/WorkflowCreateRequest.ts +143 -0
- package/openapi/models/WorkflowCreateResponse.ts +114 -0
- package/openapi/models/WorkflowCreateSuccessEnvelope.ts +93 -0
- package/openapi/models/WorkflowDownloadResponse.ts +74 -0
- package/openapi/models/WorkflowDownloadSuccessEnvelope.ts +93 -0
- package/openapi/models/WorkflowEdge.ts +77 -0
- package/openapi/models/WorkflowStatus.ts +62 -0
- package/openapi/models/WorkflowStatusResponse.ts +101 -0
- package/openapi/models/WorkflowStatusSuccessEnvelope.ts +93 -0
- package/openapi/models/index.ts +64 -0
- package/openapi/runtime.ts +432 -0
- package/operations/README.md +17 -0
- package/operations/archive.ts +16 -0
- package/operations/compress.ts +177 -0
- package/operations/convert.ts +69 -0
- package/operations/index.ts +7 -0
- package/operations/merge.ts +95 -0
- package/operations/thumbnail.ts +66 -0
- package/package.json +19 -0
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* GISL Compression API
|
|
5
|
+
* REST API for the GISL (Give It Smaller) file compression and processing service. **Architecture:** - Upload files to get a `file_id` - Create workflows referencing uploaded files with operations (compress, thumbnail, watermark, merge, archive, convert) - Poll status, stream SSE events, or receive webhook callbacks - Download results per operation output **Response envelope:** All mutation and query endpoints return `{ success: true, data: {...} }` on success and `{ success: false, error: \"...\", details: [...] }` on failure. Exceptions: `GET /api/operations/schema` returns raw JSON (CDN-cacheable), health probes return flat objects, and `POST /api/contact` returns 204 with no body.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 2.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
* Payload for workflow terminal events
|
|
18
|
+
* (workflow.completed, workflow.failed, workflow.partially_failed)
|
|
19
|
+
*
|
|
20
|
+
* @export
|
|
21
|
+
* @interface SseWorkflowTerminalData
|
|
22
|
+
*/
|
|
23
|
+
export interface SseWorkflowTerminalData {
|
|
24
|
+
/**
|
|
25
|
+
* UUID v7 format identifier (time-ordered)
|
|
26
|
+
* @type {string}
|
|
27
|
+
* @memberof SseWorkflowTerminalData
|
|
28
|
+
*/
|
|
29
|
+
workflowId: string;
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {string}
|
|
33
|
+
* @memberof SseWorkflowTerminalData
|
|
34
|
+
*/
|
|
35
|
+
status: SseWorkflowTerminalDataStatusEnum;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
/**
|
|
40
|
+
* @export
|
|
41
|
+
*/
|
|
42
|
+
export const SseWorkflowTerminalDataStatusEnum = {
|
|
43
|
+
completed: 'completed',
|
|
44
|
+
failed: 'failed',
|
|
45
|
+
partially_failed: 'partially_failed'
|
|
46
|
+
} as const;
|
|
47
|
+
export type SseWorkflowTerminalDataStatusEnum = typeof SseWorkflowTerminalDataStatusEnum[keyof typeof SseWorkflowTerminalDataStatusEnum];
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
* Check if a given object implements the SseWorkflowTerminalData interface.
|
|
52
|
+
*/
|
|
53
|
+
export function instanceOfSseWorkflowTerminalData(value: object): value is SseWorkflowTerminalData {
|
|
54
|
+
if (!('workflowId' in value) || value['workflowId'] === undefined) return false;
|
|
55
|
+
if (!('status' in value) || value['status'] === undefined) return false;
|
|
56
|
+
return true;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export function SseWorkflowTerminalDataFromJSON(json: any): SseWorkflowTerminalData {
|
|
60
|
+
return SseWorkflowTerminalDataFromJSONTyped(json, false);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export function SseWorkflowTerminalDataFromJSONTyped(json: any, ignoreDiscriminator: boolean): SseWorkflowTerminalData {
|
|
64
|
+
if (json == null) {
|
|
65
|
+
return json;
|
|
66
|
+
}
|
|
67
|
+
return {
|
|
68
|
+
|
|
69
|
+
'workflowId': json['workflow_id'],
|
|
70
|
+
'status': json['status'],
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
export function SseWorkflowTerminalDataToJSON(json: any): SseWorkflowTerminalData {
|
|
75
|
+
return SseWorkflowTerminalDataToJSONTyped(json, false);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
export function SseWorkflowTerminalDataToJSONTyped(value?: SseWorkflowTerminalData | null, ignoreDiscriminator: boolean = false): any {
|
|
79
|
+
if (value == null) {
|
|
80
|
+
return value;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
return {
|
|
84
|
+
|
|
85
|
+
'workflow_id': value['workflowId'],
|
|
86
|
+
'status': value['status'],
|
|
87
|
+
};
|
|
88
|
+
}
|
|
89
|
+
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* GISL Compression API
|
|
5
|
+
* REST API for the GISL (Give It Smaller) file compression and processing service. **Architecture:** - Upload files to get a `file_id` - Create workflows referencing uploaded files with operations (compress, thumbnail, watermark, merge, archive, convert) - Poll status, stream SSE events, or receive webhook callbacks - Download results per operation output **Response envelope:** All mutation and query endpoints return `{ success: true, data: {...} }` on success and `{ success: false, error: \"...\", details: [...] }` on failure. Exceptions: `GET /api/operations/schema` returns raw JSON (CDN-cacheable), health probes return flat objects, and `POST /api/contact` returns 204 with no body.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 2.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
* Upload result data (same shape for single and multipart complete)
|
|
18
|
+
* @export
|
|
19
|
+
* @interface UploadResponse
|
|
20
|
+
*/
|
|
21
|
+
export interface UploadResponse {
|
|
22
|
+
/**
|
|
23
|
+
* UUID v7 format identifier (time-ordered)
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof UploadResponse
|
|
26
|
+
*/
|
|
27
|
+
fileId: string;
|
|
28
|
+
/**
|
|
29
|
+
* Original filename
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof UploadResponse
|
|
32
|
+
*/
|
|
33
|
+
originalName: string;
|
|
34
|
+
/**
|
|
35
|
+
* Detected MIME type
|
|
36
|
+
* @type {string}
|
|
37
|
+
* @memberof UploadResponse
|
|
38
|
+
*/
|
|
39
|
+
mimeType: string;
|
|
40
|
+
/**
|
|
41
|
+
* File size in bytes
|
|
42
|
+
* @type {number}
|
|
43
|
+
* @memberof UploadResponse
|
|
44
|
+
*/
|
|
45
|
+
sizeBytes: number;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* Check if a given object implements the UploadResponse interface.
|
|
50
|
+
*/
|
|
51
|
+
export function instanceOfUploadResponse(value: object): value is UploadResponse {
|
|
52
|
+
if (!('fileId' in value) || value['fileId'] === undefined) return false;
|
|
53
|
+
if (!('originalName' in value) || value['originalName'] === undefined) return false;
|
|
54
|
+
if (!('mimeType' in value) || value['mimeType'] === undefined) return false;
|
|
55
|
+
if (!('sizeBytes' in value) || value['sizeBytes'] === undefined) return false;
|
|
56
|
+
return true;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export function UploadResponseFromJSON(json: any): UploadResponse {
|
|
60
|
+
return UploadResponseFromJSONTyped(json, false);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export function UploadResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): UploadResponse {
|
|
64
|
+
if (json == null) {
|
|
65
|
+
return json;
|
|
66
|
+
}
|
|
67
|
+
return {
|
|
68
|
+
|
|
69
|
+
'fileId': json['file_id'],
|
|
70
|
+
'originalName': json['original_name'],
|
|
71
|
+
'mimeType': json['mime_type'],
|
|
72
|
+
'sizeBytes': json['size_bytes'],
|
|
73
|
+
};
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
export function UploadResponseToJSON(json: any): UploadResponse {
|
|
77
|
+
return UploadResponseToJSONTyped(json, false);
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
export function UploadResponseToJSONTyped(value?: UploadResponse | null, ignoreDiscriminator: boolean = false): any {
|
|
81
|
+
if (value == null) {
|
|
82
|
+
return value;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
return {
|
|
86
|
+
|
|
87
|
+
'file_id': value['fileId'],
|
|
88
|
+
'original_name': value['originalName'],
|
|
89
|
+
'mime_type': value['mimeType'],
|
|
90
|
+
'size_bytes': value['sizeBytes'],
|
|
91
|
+
};
|
|
92
|
+
}
|
|
93
|
+
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* GISL Compression API
|
|
5
|
+
* REST API for the GISL (Give It Smaller) file compression and processing service. **Architecture:** - Upload files to get a `file_id` - Create workflows referencing uploaded files with operations (compress, thumbnail, watermark, merge, archive, convert) - Poll status, stream SSE events, or receive webhook callbacks - Download results per operation output **Response envelope:** All mutation and query endpoints return `{ success: true, data: {...} }` on success and `{ success: false, error: \"...\", details: [...] }` on failure. Exceptions: `GET /api/operations/schema` returns raw JSON (CDN-cacheable), health probes return flat objects, and `POST /api/contact` returns 204 with no body.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 2.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { UploadResponse } from './UploadResponse';
|
|
17
|
+
import {
|
|
18
|
+
UploadResponseFromJSON,
|
|
19
|
+
UploadResponseFromJSONTyped,
|
|
20
|
+
UploadResponseToJSON,
|
|
21
|
+
UploadResponseToJSONTyped,
|
|
22
|
+
} from './UploadResponse';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @export
|
|
27
|
+
* @interface UploadSuccessEnvelope
|
|
28
|
+
*/
|
|
29
|
+
export interface UploadSuccessEnvelope {
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {boolean}
|
|
33
|
+
* @memberof UploadSuccessEnvelope
|
|
34
|
+
*/
|
|
35
|
+
success: UploadSuccessEnvelopeSuccessEnum;
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
* @type {UploadResponse}
|
|
39
|
+
* @memberof UploadSuccessEnvelope
|
|
40
|
+
*/
|
|
41
|
+
data: UploadResponse;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* @export
|
|
47
|
+
*/
|
|
48
|
+
export const UploadSuccessEnvelopeSuccessEnum = {
|
|
49
|
+
true: true
|
|
50
|
+
} as const;
|
|
51
|
+
export type UploadSuccessEnvelopeSuccessEnum = typeof UploadSuccessEnvelopeSuccessEnum[keyof typeof UploadSuccessEnvelopeSuccessEnum];
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
* Check if a given object implements the UploadSuccessEnvelope interface.
|
|
56
|
+
*/
|
|
57
|
+
export function instanceOfUploadSuccessEnvelope(value: object): value is UploadSuccessEnvelope {
|
|
58
|
+
if (!('success' in value) || value['success'] === undefined) return false;
|
|
59
|
+
if (!('data' in value) || value['data'] === undefined) return false;
|
|
60
|
+
return true;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export function UploadSuccessEnvelopeFromJSON(json: any): UploadSuccessEnvelope {
|
|
64
|
+
return UploadSuccessEnvelopeFromJSONTyped(json, false);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export function UploadSuccessEnvelopeFromJSONTyped(json: any, ignoreDiscriminator: boolean): UploadSuccessEnvelope {
|
|
68
|
+
if (json == null) {
|
|
69
|
+
return json;
|
|
70
|
+
}
|
|
71
|
+
return {
|
|
72
|
+
|
|
73
|
+
'success': json['success'],
|
|
74
|
+
'data': UploadResponseFromJSON(json['data']),
|
|
75
|
+
};
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
export function UploadSuccessEnvelopeToJSON(json: any): UploadSuccessEnvelope {
|
|
79
|
+
return UploadSuccessEnvelopeToJSONTyped(json, false);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
export function UploadSuccessEnvelopeToJSONTyped(value?: UploadSuccessEnvelope | null, ignoreDiscriminator: boolean = false): any {
|
|
83
|
+
if (value == null) {
|
|
84
|
+
return value;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
return {
|
|
88
|
+
|
|
89
|
+
'success': value['success'],
|
|
90
|
+
'data': UploadResponseToJSON(value['data']),
|
|
91
|
+
};
|
|
92
|
+
}
|
|
93
|
+
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* GISL Compression API
|
|
5
|
+
* REST API for the GISL (Give It Smaller) file compression and processing service. **Architecture:** - Upload files to get a `file_id` - Create workflows referencing uploaded files with operations (compress, thumbnail, watermark, merge, archive, convert) - Poll status, stream SSE events, or receive webhook callbacks - Download results per operation output **Response envelope:** All mutation and query endpoints return `{ success: true, data: {...} }` on success and `{ success: false, error: \"...\", details: [...] }` on failure. Exceptions: `GET /api/operations/schema` returns raw JSON (CDN-cacheable), health probes return flat objects, and `POST /api/contact` returns 204 with no body.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 2.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { ValidationErrorEnvelopeDetailsInner } from './ValidationErrorEnvelopeDetailsInner';
|
|
17
|
+
import {
|
|
18
|
+
ValidationErrorEnvelopeDetailsInnerFromJSON,
|
|
19
|
+
ValidationErrorEnvelopeDetailsInnerFromJSONTyped,
|
|
20
|
+
ValidationErrorEnvelopeDetailsInnerToJSON,
|
|
21
|
+
ValidationErrorEnvelopeDetailsInnerToJSONTyped,
|
|
22
|
+
} from './ValidationErrorEnvelopeDetailsInner';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* Validation error response with structured details.
|
|
26
|
+
* Used for 422 responses where multiple validation issues are reported.
|
|
27
|
+
*
|
|
28
|
+
* @export
|
|
29
|
+
* @interface ValidationErrorEnvelope
|
|
30
|
+
*/
|
|
31
|
+
export interface ValidationErrorEnvelope {
|
|
32
|
+
/**
|
|
33
|
+
*
|
|
34
|
+
* @type {boolean}
|
|
35
|
+
* @memberof ValidationErrorEnvelope
|
|
36
|
+
*/
|
|
37
|
+
success: ValidationErrorEnvelopeSuccessEnum;
|
|
38
|
+
/**
|
|
39
|
+
* Error code (e.g. "INVALID_OPTIONS")
|
|
40
|
+
* @type {string}
|
|
41
|
+
* @memberof ValidationErrorEnvelope
|
|
42
|
+
*/
|
|
43
|
+
error: string;
|
|
44
|
+
/**
|
|
45
|
+
* List of individual validation errors
|
|
46
|
+
* @type {Array<ValidationErrorEnvelopeDetailsInner>}
|
|
47
|
+
* @memberof ValidationErrorEnvelope
|
|
48
|
+
*/
|
|
49
|
+
details: Array<ValidationErrorEnvelopeDetailsInner>;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* @export
|
|
55
|
+
*/
|
|
56
|
+
export const ValidationErrorEnvelopeSuccessEnum = {
|
|
57
|
+
false: false
|
|
58
|
+
} as const;
|
|
59
|
+
export type ValidationErrorEnvelopeSuccessEnum = typeof ValidationErrorEnvelopeSuccessEnum[keyof typeof ValidationErrorEnvelopeSuccessEnum];
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* Check if a given object implements the ValidationErrorEnvelope interface.
|
|
64
|
+
*/
|
|
65
|
+
export function instanceOfValidationErrorEnvelope(value: object): value is ValidationErrorEnvelope {
|
|
66
|
+
if (!('success' in value) || value['success'] === undefined) return false;
|
|
67
|
+
if (!('error' in value) || value['error'] === undefined) return false;
|
|
68
|
+
if (!('details' in value) || value['details'] === undefined) return false;
|
|
69
|
+
return true;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export function ValidationErrorEnvelopeFromJSON(json: any): ValidationErrorEnvelope {
|
|
73
|
+
return ValidationErrorEnvelopeFromJSONTyped(json, false);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
export function ValidationErrorEnvelopeFromJSONTyped(json: any, ignoreDiscriminator: boolean): ValidationErrorEnvelope {
|
|
77
|
+
if (json == null) {
|
|
78
|
+
return json;
|
|
79
|
+
}
|
|
80
|
+
return {
|
|
81
|
+
|
|
82
|
+
'success': json['success'],
|
|
83
|
+
'error': json['error'],
|
|
84
|
+
'details': ((json['details'] as Array<any>).map(ValidationErrorEnvelopeDetailsInnerFromJSON)),
|
|
85
|
+
};
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
export function ValidationErrorEnvelopeToJSON(json: any): ValidationErrorEnvelope {
|
|
89
|
+
return ValidationErrorEnvelopeToJSONTyped(json, false);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
export function ValidationErrorEnvelopeToJSONTyped(value?: ValidationErrorEnvelope | null, ignoreDiscriminator: boolean = false): any {
|
|
93
|
+
if (value == null) {
|
|
94
|
+
return value;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
return {
|
|
98
|
+
|
|
99
|
+
'success': value['success'],
|
|
100
|
+
'error': value['error'],
|
|
101
|
+
'details': ((value['details'] as Array<any>).map(ValidationErrorEnvelopeDetailsInnerToJSON)),
|
|
102
|
+
};
|
|
103
|
+
}
|
|
104
|
+
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* GISL Compression API
|
|
5
|
+
* REST API for the GISL (Give It Smaller) file compression and processing service. **Architecture:** - Upload files to get a `file_id` - Create workflows referencing uploaded files with operations (compress, thumbnail, watermark, merge, archive, convert) - Poll status, stream SSE events, or receive webhook callbacks - Download results per operation output **Response envelope:** All mutation and query endpoints return `{ success: true, data: {...} }` on success and `{ success: false, error: \"...\", details: [...] }` on failure. Exceptions: `GET /api/operations/schema` returns raw JSON (CDN-cacheable), health probes return flat objects, and `POST /api/contact` returns 204 with no body.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 2.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface ValidationErrorEnvelopeDetailsInner
|
|
20
|
+
*/
|
|
21
|
+
export interface ValidationErrorEnvelopeDetailsInner {
|
|
22
|
+
/**
|
|
23
|
+
* Operation type where the error occurred
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof ValidationErrorEnvelopeDetailsInner
|
|
26
|
+
*/
|
|
27
|
+
operation?: string;
|
|
28
|
+
/**
|
|
29
|
+
* Option name that failed validation
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof ValidationErrorEnvelopeDetailsInner
|
|
32
|
+
*/
|
|
33
|
+
option?: string;
|
|
34
|
+
/**
|
|
35
|
+
* Field path for non-operation validation errors
|
|
36
|
+
* @type {string}
|
|
37
|
+
* @memberof ValidationErrorEnvelopeDetailsInner
|
|
38
|
+
*/
|
|
39
|
+
field?: string;
|
|
40
|
+
/**
|
|
41
|
+
* Human-readable error message
|
|
42
|
+
* @type {string}
|
|
43
|
+
* @memberof ValidationErrorEnvelopeDetailsInner
|
|
44
|
+
*/
|
|
45
|
+
message: string;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* Check if a given object implements the ValidationErrorEnvelopeDetailsInner interface.
|
|
50
|
+
*/
|
|
51
|
+
export function instanceOfValidationErrorEnvelopeDetailsInner(value: object): value is ValidationErrorEnvelopeDetailsInner {
|
|
52
|
+
if (!('message' in value) || value['message'] === undefined) return false;
|
|
53
|
+
return true;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export function ValidationErrorEnvelopeDetailsInnerFromJSON(json: any): ValidationErrorEnvelopeDetailsInner {
|
|
57
|
+
return ValidationErrorEnvelopeDetailsInnerFromJSONTyped(json, false);
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export function ValidationErrorEnvelopeDetailsInnerFromJSONTyped(json: any, ignoreDiscriminator: boolean): ValidationErrorEnvelopeDetailsInner {
|
|
61
|
+
if (json == null) {
|
|
62
|
+
return json;
|
|
63
|
+
}
|
|
64
|
+
return {
|
|
65
|
+
|
|
66
|
+
'operation': json['operation'] == null ? undefined : json['operation'],
|
|
67
|
+
'option': json['option'] == null ? undefined : json['option'],
|
|
68
|
+
'field': json['field'] == null ? undefined : json['field'],
|
|
69
|
+
'message': json['message'],
|
|
70
|
+
};
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export function ValidationErrorEnvelopeDetailsInnerToJSON(json: any): ValidationErrorEnvelopeDetailsInner {
|
|
74
|
+
return ValidationErrorEnvelopeDetailsInnerToJSONTyped(json, false);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export function ValidationErrorEnvelopeDetailsInnerToJSONTyped(value?: ValidationErrorEnvelopeDetailsInner | null, ignoreDiscriminator: boolean = false): any {
|
|
78
|
+
if (value == null) {
|
|
79
|
+
return value;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
return {
|
|
83
|
+
|
|
84
|
+
'operation': value['operation'],
|
|
85
|
+
'option': value['option'],
|
|
86
|
+
'field': value['field'],
|
|
87
|
+
'message': value['message'],
|
|
88
|
+
};
|
|
89
|
+
}
|
|
90
|
+
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* GISL Compression API
|
|
5
|
+
* REST API for the GISL (Give It Smaller) file compression and processing service. **Architecture:** - Upload files to get a `file_id` - Create workflows referencing uploaded files with operations (compress, thumbnail, watermark, merge, archive, convert) - Poll status, stream SSE events, or receive webhook callbacks - Download results per operation output **Response envelope:** All mutation and query endpoints return `{ success: true, data: {...} }` on success and `{ success: false, error: \"...\", details: [...] }` on failure. Exceptions: `GET /api/operations/schema` returns raw JSON (CDN-cacheable), health probes return flat objects, and `POST /api/contact` returns 204 with no body.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 2.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
* Identifies which operation triggered the callback. Present only for
|
|
18
|
+
* `operation.completed` events; null for workflow-level events.
|
|
19
|
+
*
|
|
20
|
+
* @export
|
|
21
|
+
* @interface WebhookOperationContext
|
|
22
|
+
*/
|
|
23
|
+
export interface WebhookOperationContext {
|
|
24
|
+
/**
|
|
25
|
+
* Reference label of the job containing the operation
|
|
26
|
+
* @type {string}
|
|
27
|
+
* @memberof WebhookOperationContext
|
|
28
|
+
*/
|
|
29
|
+
jobRef: string;
|
|
30
|
+
/**
|
|
31
|
+
* UUID v7 format identifier (time-ordered)
|
|
32
|
+
* @type {string}
|
|
33
|
+
* @memberof WebhookOperationContext
|
|
34
|
+
*/
|
|
35
|
+
operationId: string;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Check if a given object implements the WebhookOperationContext interface.
|
|
40
|
+
*/
|
|
41
|
+
export function instanceOfWebhookOperationContext(value: object): value is WebhookOperationContext {
|
|
42
|
+
if (!('jobRef' in value) || value['jobRef'] === undefined) return false;
|
|
43
|
+
if (!('operationId' in value) || value['operationId'] === undefined) return false;
|
|
44
|
+
return true;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
export function WebhookOperationContextFromJSON(json: any): WebhookOperationContext {
|
|
48
|
+
return WebhookOperationContextFromJSONTyped(json, false);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
export function WebhookOperationContextFromJSONTyped(json: any, ignoreDiscriminator: boolean): WebhookOperationContext {
|
|
52
|
+
if (json == null) {
|
|
53
|
+
return json;
|
|
54
|
+
}
|
|
55
|
+
return {
|
|
56
|
+
|
|
57
|
+
'jobRef': json['job_ref'],
|
|
58
|
+
'operationId': json['operation_id'],
|
|
59
|
+
};
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
export function WebhookOperationContextToJSON(json: any): WebhookOperationContext {
|
|
63
|
+
return WebhookOperationContextToJSONTyped(json, false);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export function WebhookOperationContextToJSONTyped(value?: WebhookOperationContext | null, ignoreDiscriminator: boolean = false): any {
|
|
67
|
+
if (value == null) {
|
|
68
|
+
return value;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
return {
|
|
72
|
+
|
|
73
|
+
'job_ref': value['jobRef'],
|
|
74
|
+
'operation_id': value['operationId'],
|
|
75
|
+
};
|
|
76
|
+
}
|
|
77
|
+
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* GISL Compression API
|
|
5
|
+
* REST API for the GISL (Give It Smaller) file compression and processing service. **Architecture:** - Upload files to get a `file_id` - Create workflows referencing uploaded files with operations (compress, thumbnail, watermark, merge, archive, convert) - Poll status, stream SSE events, or receive webhook callbacks - Download results per operation output **Response envelope:** All mutation and query endpoints return `{ success: true, data: {...} }` on success and `{ success: false, error: \"...\", details: [...] }` on failure. Exceptions: `GET /api/operations/schema` returns raw JSON (CDN-cacheable), health probes return flat objects, and `POST /api/contact` returns 204 with no body.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 2.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { CallbackEventType } from './CallbackEventType';
|
|
17
|
+
import {
|
|
18
|
+
CallbackEventTypeFromJSON,
|
|
19
|
+
CallbackEventTypeFromJSONTyped,
|
|
20
|
+
CallbackEventTypeToJSON,
|
|
21
|
+
CallbackEventTypeToJSONTyped,
|
|
22
|
+
} from './CallbackEventType';
|
|
23
|
+
import type { WebhookOperationContext } from './WebhookOperationContext';
|
|
24
|
+
import {
|
|
25
|
+
WebhookOperationContextFromJSON,
|
|
26
|
+
WebhookOperationContextFromJSONTyped,
|
|
27
|
+
WebhookOperationContextToJSON,
|
|
28
|
+
WebhookOperationContextToJSONTyped,
|
|
29
|
+
} from './WebhookOperationContext';
|
|
30
|
+
import type { WorkflowStatusResponse } from './WorkflowStatusResponse';
|
|
31
|
+
import {
|
|
32
|
+
WorkflowStatusResponseFromJSON,
|
|
33
|
+
WorkflowStatusResponseFromJSONTyped,
|
|
34
|
+
WorkflowStatusResponseToJSON,
|
|
35
|
+
WorkflowStatusResponseToJSONTyped,
|
|
36
|
+
} from './WorkflowStatusResponse';
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Payload POSTed to the `callback_url` when a subscribed event occurs.
|
|
40
|
+
* The `workflow` field contains the full current state including all jobs
|
|
41
|
+
* and their operation results, matching the `WorkflowStatusResponse` shape.
|
|
42
|
+
*
|
|
43
|
+
* For `operation.completed` events, the `operation` field identifies which
|
|
44
|
+
* specific operation triggered the callback, so consumers do not need to
|
|
45
|
+
* scan the entire workflow to find the change.
|
|
46
|
+
*
|
|
47
|
+
* @export
|
|
48
|
+
* @interface WebhookPayload
|
|
49
|
+
*/
|
|
50
|
+
export interface WebhookPayload {
|
|
51
|
+
/**
|
|
52
|
+
*
|
|
53
|
+
* @type {CallbackEventType}
|
|
54
|
+
* @memberof WebhookPayload
|
|
55
|
+
*/
|
|
56
|
+
eventType: CallbackEventType;
|
|
57
|
+
/**
|
|
58
|
+
* UUID v7 format identifier (time-ordered)
|
|
59
|
+
* @type {string}
|
|
60
|
+
* @memberof WebhookPayload
|
|
61
|
+
*/
|
|
62
|
+
deliveryId: string;
|
|
63
|
+
/**
|
|
64
|
+
* ISO 8601 timestamp of when the event occurred
|
|
65
|
+
* @type {Date}
|
|
66
|
+
* @memberof WebhookPayload
|
|
67
|
+
*/
|
|
68
|
+
timestamp: Date;
|
|
69
|
+
/**
|
|
70
|
+
*
|
|
71
|
+
* @type {WorkflowStatusResponse}
|
|
72
|
+
* @memberof WebhookPayload
|
|
73
|
+
*/
|
|
74
|
+
workflow: WorkflowStatusResponse;
|
|
75
|
+
/**
|
|
76
|
+
*
|
|
77
|
+
* @type {WebhookOperationContext}
|
|
78
|
+
* @memberof WebhookPayload
|
|
79
|
+
*/
|
|
80
|
+
operation?: WebhookOperationContext;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
|
|
85
|
+
/**
|
|
86
|
+
* Check if a given object implements the WebhookPayload interface.
|
|
87
|
+
*/
|
|
88
|
+
export function instanceOfWebhookPayload(value: object): value is WebhookPayload {
|
|
89
|
+
if (!('eventType' in value) || value['eventType'] === undefined) return false;
|
|
90
|
+
if (!('deliveryId' in value) || value['deliveryId'] === undefined) return false;
|
|
91
|
+
if (!('timestamp' in value) || value['timestamp'] === undefined) return false;
|
|
92
|
+
if (!('workflow' in value) || value['workflow'] === undefined) return false;
|
|
93
|
+
return true;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
export function WebhookPayloadFromJSON(json: any): WebhookPayload {
|
|
97
|
+
return WebhookPayloadFromJSONTyped(json, false);
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
export function WebhookPayloadFromJSONTyped(json: any, ignoreDiscriminator: boolean): WebhookPayload {
|
|
101
|
+
if (json == null) {
|
|
102
|
+
return json;
|
|
103
|
+
}
|
|
104
|
+
return {
|
|
105
|
+
|
|
106
|
+
'eventType': CallbackEventTypeFromJSON(json['event_type']),
|
|
107
|
+
'deliveryId': json['delivery_id'],
|
|
108
|
+
'timestamp': (new Date(json['timestamp'])),
|
|
109
|
+
'workflow': WorkflowStatusResponseFromJSON(json['workflow']),
|
|
110
|
+
'operation': json['operation'] == null ? undefined : WebhookOperationContextFromJSON(json['operation']),
|
|
111
|
+
};
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
export function WebhookPayloadToJSON(json: any): WebhookPayload {
|
|
115
|
+
return WebhookPayloadToJSONTyped(json, false);
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
export function WebhookPayloadToJSONTyped(value?: WebhookPayload | null, ignoreDiscriminator: boolean = false): any {
|
|
119
|
+
if (value == null) {
|
|
120
|
+
return value;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
return {
|
|
124
|
+
|
|
125
|
+
'event_type': CallbackEventTypeToJSON(value['eventType']),
|
|
126
|
+
'delivery_id': value['deliveryId'],
|
|
127
|
+
'timestamp': ((value['timestamp']).toISOString()),
|
|
128
|
+
'workflow': WorkflowStatusResponseToJSON(value['workflow']),
|
|
129
|
+
'operation': WebhookOperationContextToJSON(value['operation']),
|
|
130
|
+
};
|
|
131
|
+
}
|
|
132
|
+
|