@liqhtworks/sophon-sdk 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/.github/workflows/publish.yml +56 -0
- package/.openapi-generator/FILES +73 -0
- package/.openapi-generator/VERSION +1 -0
- package/.openapi-generator-ignore +23 -0
- package/LICENSE +12 -0
- package/README.md +164 -0
- package/dist/apis/DownloadsApi.d.ts +63 -0
- package/dist/apis/DownloadsApi.js +58 -0
- package/dist/apis/HealthApi.d.ts +92 -0
- package/dist/apis/HealthApi.js +85 -0
- package/dist/apis/JobsApi.d.ts +225 -0
- package/dist/apis/JobsApi.js +245 -0
- package/dist/apis/UploadsApi.d.ts +228 -0
- package/dist/apis/UploadsApi.js +255 -0
- package/dist/apis/WebhooksApi.d.ts +138 -0
- package/dist/apis/WebhooksApi.js +152 -0
- package/dist/apis/index.d.ts +5 -0
- package/dist/apis/index.js +23 -0
- package/dist/esm/apis/DownloadsApi.d.ts +63 -0
- package/dist/esm/apis/DownloadsApi.js +54 -0
- package/dist/esm/apis/HealthApi.d.ts +92 -0
- package/dist/esm/apis/HealthApi.js +81 -0
- package/dist/esm/apis/JobsApi.d.ts +225 -0
- package/dist/esm/apis/JobsApi.js +241 -0
- package/dist/esm/apis/UploadsApi.d.ts +228 -0
- package/dist/esm/apis/UploadsApi.js +251 -0
- package/dist/esm/apis/WebhooksApi.d.ts +138 -0
- package/dist/esm/apis/WebhooksApi.js +148 -0
- package/dist/esm/apis/index.d.ts +5 -0
- package/dist/esm/apis/index.js +7 -0
- package/dist/esm/helpers/index.d.ts +3 -0
- package/dist/esm/helpers/index.js +3 -0
- package/dist/esm/helpers/jobs.d.ts +48 -0
- package/dist/esm/helpers/jobs.js +61 -0
- package/dist/esm/helpers/uploads.d.ts +71 -0
- package/dist/esm/helpers/uploads.js +146 -0
- package/dist/esm/helpers/webhooks.d.ts +23 -0
- package/dist/esm/helpers/webhooks.js +84 -0
- package/dist/esm/index.d.ts +4 -0
- package/dist/esm/index.js +6 -0
- package/dist/esm/models/CompleteUploadResponse.d.ts +57 -0
- package/dist/esm/models/CompleteUploadResponse.js +63 -0
- package/dist/esm/models/CreateJobOutputOptions.d.ts +55 -0
- package/dist/esm/models/CreateJobOutputOptions.js +46 -0
- package/dist/esm/models/CreateJobRequest.d.ts +61 -0
- package/dist/esm/models/CreateJobRequest.js +56 -0
- package/dist/esm/models/CreateUploadRequest.d.ts +44 -0
- package/dist/esm/models/CreateUploadRequest.js +51 -0
- package/dist/esm/models/CreateUploadResponse.d.ts +52 -0
- package/dist/esm/models/CreateUploadResponse.js +55 -0
- package/dist/esm/models/CreateWebhookRequest.d.ts +40 -0
- package/dist/esm/models/CreateWebhookRequest.js +45 -0
- package/dist/esm/models/ErrorBody.d.ts +72 -0
- package/dist/esm/models/ErrorBody.js +74 -0
- package/dist/esm/models/ErrorEnvelope.d.ts +33 -0
- package/dist/esm/models/ErrorEnvelope.js +44 -0
- package/dist/esm/models/JobOutputInfo.d.ts +95 -0
- package/dist/esm/models/JobOutputInfo.js +72 -0
- package/dist/esm/models/JobProfile.d.ts +49 -0
- package/dist/esm/models/JobProfile.js +69 -0
- package/dist/esm/models/JobProgress.d.ts +75 -0
- package/dist/esm/models/JobProgress.js +60 -0
- package/dist/esm/models/JobResponse.d.ts +134 -0
- package/dist/esm/models/JobResponse.js +94 -0
- package/dist/esm/models/JobSourceInfo.d.ts +62 -0
- package/dist/esm/models/JobSourceInfo.js +53 -0
- package/dist/esm/models/JobSourceType.d.ts +24 -0
- package/dist/esm/models/JobSourceType.js +44 -0
- package/dist/esm/models/JobStatus.d.ts +31 -0
- package/dist/esm/models/JobStatus.js +51 -0
- package/dist/esm/models/ListJobsResponse.d.ts +45 -0
- package/dist/esm/models/ListJobsResponse.js +50 -0
- package/dist/esm/models/OutputContainer.d.ts +27 -0
- package/dist/esm/models/OutputContainer.js +47 -0
- package/dist/esm/models/ReadyResponse.d.ts +38 -0
- package/dist/esm/models/ReadyResponse.js +45 -0
- package/dist/esm/models/UploadJobSource.d.ts +39 -0
- package/dist/esm/models/UploadJobSource.js +48 -0
- package/dist/esm/models/UploadPartResponse.d.ts +38 -0
- package/dist/esm/models/UploadPartResponse.js +47 -0
- package/dist/esm/models/UploadStatusResponse.d.ts +96 -0
- package/dist/esm/models/UploadStatusResponse.js +80 -0
- package/dist/esm/models/WebhookDeliveryPayload.d.ts +85 -0
- package/dist/esm/models/WebhookDeliveryPayload.js +83 -0
- package/dist/esm/models/WebhookListItem.d.ts +50 -0
- package/dist/esm/models/WebhookListItem.js +55 -0
- package/dist/esm/models/WebhookListResponse.d.ts +33 -0
- package/dist/esm/models/WebhookListResponse.js +44 -0
- package/dist/esm/models/WebhookResponse.d.ts +58 -0
- package/dist/esm/models/WebhookResponse.js +59 -0
- package/dist/esm/models/index.d.ts +25 -0
- package/dist/esm/models/index.js +27 -0
- package/dist/esm/runtime.d.ts +184 -0
- package/dist/esm/runtime.js +348 -0
- package/dist/helpers/index.d.ts +3 -0
- package/dist/helpers/index.js +19 -0
- package/dist/helpers/jobs.d.ts +48 -0
- package/dist/helpers/jobs.js +67 -0
- package/dist/helpers/uploads.d.ts +71 -0
- package/dist/helpers/uploads.js +149 -0
- package/dist/helpers/webhooks.d.ts +23 -0
- package/dist/helpers/webhooks.js +89 -0
- package/dist/index.d.ts +4 -0
- package/dist/index.js +22 -0
- package/dist/models/CompleteUploadResponse.d.ts +57 -0
- package/dist/models/CompleteUploadResponse.js +71 -0
- package/dist/models/CreateJobOutputOptions.d.ts +55 -0
- package/dist/models/CreateJobOutputOptions.js +53 -0
- package/dist/models/CreateJobRequest.d.ts +61 -0
- package/dist/models/CreateJobRequest.js +63 -0
- package/dist/models/CreateUploadRequest.d.ts +44 -0
- package/dist/models/CreateUploadRequest.js +58 -0
- package/dist/models/CreateUploadResponse.d.ts +52 -0
- package/dist/models/CreateUploadResponse.js +62 -0
- package/dist/models/CreateWebhookRequest.d.ts +40 -0
- package/dist/models/CreateWebhookRequest.js +52 -0
- package/dist/models/ErrorBody.d.ts +72 -0
- package/dist/models/ErrorBody.js +82 -0
- package/dist/models/ErrorEnvelope.d.ts +33 -0
- package/dist/models/ErrorEnvelope.js +51 -0
- package/dist/models/JobOutputInfo.d.ts +95 -0
- package/dist/models/JobOutputInfo.js +80 -0
- package/dist/models/JobProfile.d.ts +49 -0
- package/dist/models/JobProfile.js +77 -0
- package/dist/models/JobProgress.d.ts +75 -0
- package/dist/models/JobProgress.js +67 -0
- package/dist/models/JobResponse.d.ts +134 -0
- package/dist/models/JobResponse.js +101 -0
- package/dist/models/JobSourceInfo.d.ts +62 -0
- package/dist/models/JobSourceInfo.js +60 -0
- package/dist/models/JobSourceType.d.ts +24 -0
- package/dist/models/JobSourceType.js +52 -0
- package/dist/models/JobStatus.d.ts +31 -0
- package/dist/models/JobStatus.js +59 -0
- package/dist/models/ListJobsResponse.d.ts +45 -0
- package/dist/models/ListJobsResponse.js +57 -0
- package/dist/models/OutputContainer.d.ts +27 -0
- package/dist/models/OutputContainer.js +55 -0
- package/dist/models/ReadyResponse.d.ts +38 -0
- package/dist/models/ReadyResponse.js +52 -0
- package/dist/models/UploadJobSource.d.ts +39 -0
- package/dist/models/UploadJobSource.js +55 -0
- package/dist/models/UploadPartResponse.d.ts +38 -0
- package/dist/models/UploadPartResponse.js +54 -0
- package/dist/models/UploadStatusResponse.d.ts +96 -0
- package/dist/models/UploadStatusResponse.js +88 -0
- package/dist/models/WebhookDeliveryPayload.d.ts +85 -0
- package/dist/models/WebhookDeliveryPayload.js +91 -0
- package/dist/models/WebhookListItem.d.ts +50 -0
- package/dist/models/WebhookListItem.js +62 -0
- package/dist/models/WebhookListResponse.d.ts +33 -0
- package/dist/models/WebhookListResponse.js +51 -0
- package/dist/models/WebhookResponse.d.ts +58 -0
- package/dist/models/WebhookResponse.js +66 -0
- package/dist/models/index.d.ts +25 -0
- package/dist/models/index.js +43 -0
- package/dist/runtime.d.ts +184 -0
- package/dist/runtime.js +364 -0
- package/docs/CompleteUploadResponse.md +40 -0
- package/docs/CreateJobOutputOptions.md +39 -0
- package/docs/CreateJobRequest.md +42 -0
- package/docs/CreateUploadRequest.md +38 -0
- package/docs/CreateUploadResponse.md +40 -0
- package/docs/CreateWebhookRequest.md +36 -0
- package/docs/DownloadsApi.md +78 -0
- package/docs/ErrorBody.md +40 -0
- package/docs/ErrorEnvelope.md +34 -0
- package/docs/HealthApi.md +129 -0
- package/docs/JobOutputInfo.md +50 -0
- package/docs/JobProfile.md +33 -0
- package/docs/JobProgress.md +48 -0
- package/docs/JobResponse.md +62 -0
- package/docs/JobSourceInfo.md +44 -0
- package/docs/JobSourceType.md +33 -0
- package/docs/JobStatus.md +33 -0
- package/docs/JobsApi.md +407 -0
- package/docs/ListJobsResponse.md +38 -0
- package/docs/OutputContainer.md +33 -0
- package/docs/ReadyResponse.md +36 -0
- package/docs/UploadJobSource.md +37 -0
- package/docs/UploadPartResponse.md +36 -0
- package/docs/UploadStatusResponse.md +50 -0
- package/docs/UploadsApi.md +415 -0
- package/docs/WebhookDeliveryPayload.md +45 -0
- package/docs/WebhookEventsApi.md +91 -0
- package/docs/WebhookListItem.md +40 -0
- package/docs/WebhookListResponse.md +34 -0
- package/docs/WebhookResponse.md +42 -0
- package/docs/WebhooksApi.md +235 -0
- package/package.json +24 -0
- package/src/apis/DownloadsApi.ts +114 -0
- package/src/apis/HealthApi.ts +160 -0
- package/src/apis/JobsApi.ts +491 -0
- package/src/apis/UploadsApi.ts +522 -0
- package/src/apis/WebhooksApi.ts +298 -0
- package/src/apis/index.ts +7 -0
- package/src/helpers/index.ts +3 -0
- package/src/helpers/jobs.ts +112 -0
- package/src/helpers/uploads.ts +243 -0
- package/src/helpers/webhooks.ts +134 -0
- package/src/index.ts +7 -0
- package/src/models/CompleteUploadResponse.ts +102 -0
- package/src/models/CreateJobOutputOptions.ts +101 -0
- package/src/models/CreateJobRequest.ts +123 -0
- package/src/models/CreateUploadRequest.ts +84 -0
- package/src/models/CreateUploadResponse.ts +95 -0
- package/src/models/CreateWebhookRequest.ts +76 -0
- package/src/models/ErrorBody.ts +116 -0
- package/src/models/ErrorEnvelope.ts +74 -0
- package/src/models/JobOutputInfo.ts +149 -0
- package/src/models/JobProfile.ts +76 -0
- package/src/models/JobProgress.ts +133 -0
- package/src/models/JobResponse.ts +236 -0
- package/src/models/JobSourceInfo.ts +106 -0
- package/src/models/JobSourceType.ts +51 -0
- package/src/models/JobStatus.ts +58 -0
- package/src/models/ListJobsResponse.ts +91 -0
- package/src/models/OutputContainer.ts +54 -0
- package/src/models/ReadyResponse.ts +74 -0
- package/src/models/UploadJobSource.ts +85 -0
- package/src/models/UploadPartResponse.ts +75 -0
- package/src/models/UploadStatusResponse.ts +153 -0
- package/src/models/WebhookDeliveryPayload.ts +134 -0
- package/src/models/WebhookListItem.ts +93 -0
- package/src/models/WebhookListResponse.ts +74 -0
- package/src/models/WebhookResponse.ts +104 -0
- package/src/models/index.ts +27 -0
- package/src/runtime.ts +450 -0
- package/tsconfig.esm.json +7 -0
- package/tsconfig.json +20 -0
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* SOPHON Encoding API
|
|
5
|
+
* REST API for submitting, monitoring, and retrieving SOPHON encoding jobs. Authentication is via Bearer API key or session cookie. All POST endpoints require an Idempotency-Key header. List endpoints use opaque cursor-based pagination.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.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
|
+
* Check if a given object implements the WebhookListItem interface.
|
|
16
|
+
*/
|
|
17
|
+
export function instanceOfWebhookListItem(value) {
|
|
18
|
+
if (!('id' in value) || value['id'] === undefined)
|
|
19
|
+
return false;
|
|
20
|
+
if (!('url' in value) || value['url'] === undefined)
|
|
21
|
+
return false;
|
|
22
|
+
if (!('active' in value) || value['active'] === undefined)
|
|
23
|
+
return false;
|
|
24
|
+
if (!('created_at' in value) || value['created_at'] === undefined)
|
|
25
|
+
return false;
|
|
26
|
+
return true;
|
|
27
|
+
}
|
|
28
|
+
export function WebhookListItemFromJSON(json) {
|
|
29
|
+
return WebhookListItemFromJSONTyped(json, false);
|
|
30
|
+
}
|
|
31
|
+
export function WebhookListItemFromJSONTyped(json, ignoreDiscriminator) {
|
|
32
|
+
if (json == null) {
|
|
33
|
+
return json;
|
|
34
|
+
}
|
|
35
|
+
return {
|
|
36
|
+
'id': json['id'],
|
|
37
|
+
'url': json['url'],
|
|
38
|
+
'active': json['active'],
|
|
39
|
+
'created_at': (new Date(json['created_at'])),
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
export function WebhookListItemToJSON(json) {
|
|
43
|
+
return WebhookListItemToJSONTyped(json, false);
|
|
44
|
+
}
|
|
45
|
+
export function WebhookListItemToJSONTyped(value, ignoreDiscriminator = false) {
|
|
46
|
+
if (value == null) {
|
|
47
|
+
return value;
|
|
48
|
+
}
|
|
49
|
+
return {
|
|
50
|
+
'id': value['id'],
|
|
51
|
+
'url': value['url'],
|
|
52
|
+
'active': value['active'],
|
|
53
|
+
'created_at': value['created_at'].toISOString(),
|
|
54
|
+
};
|
|
55
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* SOPHON Encoding API
|
|
3
|
+
* REST API for submitting, monitoring, and retrieving SOPHON encoding jobs. Authentication is via Bearer API key or session cookie. All POST endpoints require an Idempotency-Key header. List endpoints use opaque cursor-based pagination.
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
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 { WebhookListItem } from './WebhookListItem';
|
|
13
|
+
/**
|
|
14
|
+
*
|
|
15
|
+
* @export
|
|
16
|
+
* @interface WebhookListResponse
|
|
17
|
+
*/
|
|
18
|
+
export interface WebhookListResponse {
|
|
19
|
+
/**
|
|
20
|
+
*
|
|
21
|
+
* @type {Array<WebhookListItem>}
|
|
22
|
+
* @memberof WebhookListResponse
|
|
23
|
+
*/
|
|
24
|
+
webhooks: Array<WebhookListItem>;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Check if a given object implements the WebhookListResponse interface.
|
|
28
|
+
*/
|
|
29
|
+
export declare function instanceOfWebhookListResponse(value: object): value is WebhookListResponse;
|
|
30
|
+
export declare function WebhookListResponseFromJSON(json: any): WebhookListResponse;
|
|
31
|
+
export declare function WebhookListResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): WebhookListResponse;
|
|
32
|
+
export declare function WebhookListResponseToJSON(json: any): WebhookListResponse;
|
|
33
|
+
export declare function WebhookListResponseToJSONTyped(value?: WebhookListResponse | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* SOPHON Encoding API
|
|
5
|
+
* REST API for submitting, monitoring, and retrieving SOPHON encoding jobs. Authentication is via Bearer API key or session cookie. All POST endpoints require an Idempotency-Key header. List endpoints use opaque cursor-based pagination.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.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
|
+
import { WebhookListItemFromJSON, WebhookListItemToJSON, } from './WebhookListItem';
|
|
15
|
+
/**
|
|
16
|
+
* Check if a given object implements the WebhookListResponse interface.
|
|
17
|
+
*/
|
|
18
|
+
export function instanceOfWebhookListResponse(value) {
|
|
19
|
+
if (!('webhooks' in value) || value['webhooks'] === undefined)
|
|
20
|
+
return false;
|
|
21
|
+
return true;
|
|
22
|
+
}
|
|
23
|
+
export function WebhookListResponseFromJSON(json) {
|
|
24
|
+
return WebhookListResponseFromJSONTyped(json, false);
|
|
25
|
+
}
|
|
26
|
+
export function WebhookListResponseFromJSONTyped(json, ignoreDiscriminator) {
|
|
27
|
+
if (json == null) {
|
|
28
|
+
return json;
|
|
29
|
+
}
|
|
30
|
+
return {
|
|
31
|
+
'webhooks': (json['webhooks'].map(WebhookListItemFromJSON)),
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
export function WebhookListResponseToJSON(json) {
|
|
35
|
+
return WebhookListResponseToJSONTyped(json, false);
|
|
36
|
+
}
|
|
37
|
+
export function WebhookListResponseToJSONTyped(value, ignoreDiscriminator = false) {
|
|
38
|
+
if (value == null) {
|
|
39
|
+
return value;
|
|
40
|
+
}
|
|
41
|
+
return {
|
|
42
|
+
'webhooks': (value['webhooks'].map(WebhookListItemToJSON)),
|
|
43
|
+
};
|
|
44
|
+
}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* SOPHON Encoding API
|
|
3
|
+
* REST API for submitting, monitoring, and retrieving SOPHON encoding jobs. Authentication is via Bearer API key or session cookie. All POST endpoints require an Idempotency-Key header. List endpoints use opaque cursor-based pagination.
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
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
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface WebhookResponse
|
|
16
|
+
*/
|
|
17
|
+
export interface WebhookResponse {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof WebhookResponse
|
|
22
|
+
*/
|
|
23
|
+
id: string;
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @type {string}
|
|
27
|
+
* @memberof WebhookResponse
|
|
28
|
+
*/
|
|
29
|
+
url: string;
|
|
30
|
+
/**
|
|
31
|
+
* HMAC signing secret (64-char hex string, 32 random bytes).
|
|
32
|
+
* Only returned on creation. Use to verify webhook delivery signatures.
|
|
33
|
+
*
|
|
34
|
+
* @type {string}
|
|
35
|
+
* @memberof WebhookResponse
|
|
36
|
+
*/
|
|
37
|
+
secret: string;
|
|
38
|
+
/**
|
|
39
|
+
*
|
|
40
|
+
* @type {boolean}
|
|
41
|
+
* @memberof WebhookResponse
|
|
42
|
+
*/
|
|
43
|
+
active: boolean;
|
|
44
|
+
/**
|
|
45
|
+
*
|
|
46
|
+
* @type {Date}
|
|
47
|
+
* @memberof WebhookResponse
|
|
48
|
+
*/
|
|
49
|
+
created_at: Date;
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Check if a given object implements the WebhookResponse interface.
|
|
53
|
+
*/
|
|
54
|
+
export declare function instanceOfWebhookResponse(value: object): value is WebhookResponse;
|
|
55
|
+
export declare function WebhookResponseFromJSON(json: any): WebhookResponse;
|
|
56
|
+
export declare function WebhookResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): WebhookResponse;
|
|
57
|
+
export declare function WebhookResponseToJSON(json: any): WebhookResponse;
|
|
58
|
+
export declare function WebhookResponseToJSONTyped(value?: WebhookResponse | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* SOPHON Encoding API
|
|
5
|
+
* REST API for submitting, monitoring, and retrieving SOPHON encoding jobs. Authentication is via Bearer API key or session cookie. All POST endpoints require an Idempotency-Key header. List endpoints use opaque cursor-based pagination.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.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
|
+
* Check if a given object implements the WebhookResponse interface.
|
|
16
|
+
*/
|
|
17
|
+
export function instanceOfWebhookResponse(value) {
|
|
18
|
+
if (!('id' in value) || value['id'] === undefined)
|
|
19
|
+
return false;
|
|
20
|
+
if (!('url' in value) || value['url'] === undefined)
|
|
21
|
+
return false;
|
|
22
|
+
if (!('secret' in value) || value['secret'] === undefined)
|
|
23
|
+
return false;
|
|
24
|
+
if (!('active' in value) || value['active'] === undefined)
|
|
25
|
+
return false;
|
|
26
|
+
if (!('created_at' in value) || value['created_at'] === undefined)
|
|
27
|
+
return false;
|
|
28
|
+
return true;
|
|
29
|
+
}
|
|
30
|
+
export function WebhookResponseFromJSON(json) {
|
|
31
|
+
return WebhookResponseFromJSONTyped(json, false);
|
|
32
|
+
}
|
|
33
|
+
export function WebhookResponseFromJSONTyped(json, ignoreDiscriminator) {
|
|
34
|
+
if (json == null) {
|
|
35
|
+
return json;
|
|
36
|
+
}
|
|
37
|
+
return {
|
|
38
|
+
'id': json['id'],
|
|
39
|
+
'url': json['url'],
|
|
40
|
+
'secret': json['secret'],
|
|
41
|
+
'active': json['active'],
|
|
42
|
+
'created_at': (new Date(json['created_at'])),
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
export function WebhookResponseToJSON(json) {
|
|
46
|
+
return WebhookResponseToJSONTyped(json, false);
|
|
47
|
+
}
|
|
48
|
+
export function WebhookResponseToJSONTyped(value, ignoreDiscriminator = false) {
|
|
49
|
+
if (value == null) {
|
|
50
|
+
return value;
|
|
51
|
+
}
|
|
52
|
+
return {
|
|
53
|
+
'id': value['id'],
|
|
54
|
+
'url': value['url'],
|
|
55
|
+
'secret': value['secret'],
|
|
56
|
+
'active': value['active'],
|
|
57
|
+
'created_at': value['created_at'].toISOString(),
|
|
58
|
+
};
|
|
59
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export * from './CompleteUploadResponse';
|
|
2
|
+
export * from './CreateJobOutputOptions';
|
|
3
|
+
export * from './CreateJobRequest';
|
|
4
|
+
export * from './CreateUploadRequest';
|
|
5
|
+
export * from './CreateUploadResponse';
|
|
6
|
+
export * from './CreateWebhookRequest';
|
|
7
|
+
export * from './ErrorBody';
|
|
8
|
+
export * from './ErrorEnvelope';
|
|
9
|
+
export * from './JobOutputInfo';
|
|
10
|
+
export * from './JobProfile';
|
|
11
|
+
export * from './JobProgress';
|
|
12
|
+
export * from './JobResponse';
|
|
13
|
+
export * from './JobSourceInfo';
|
|
14
|
+
export * from './JobSourceType';
|
|
15
|
+
export * from './JobStatus';
|
|
16
|
+
export * from './ListJobsResponse';
|
|
17
|
+
export * from './OutputContainer';
|
|
18
|
+
export * from './ReadyResponse';
|
|
19
|
+
export * from './UploadJobSource';
|
|
20
|
+
export * from './UploadPartResponse';
|
|
21
|
+
export * from './UploadStatusResponse';
|
|
22
|
+
export * from './WebhookDeliveryPayload';
|
|
23
|
+
export * from './WebhookListItem';
|
|
24
|
+
export * from './WebhookListResponse';
|
|
25
|
+
export * from './WebhookResponse';
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
export * from './CompleteUploadResponse';
|
|
4
|
+
export * from './CreateJobOutputOptions';
|
|
5
|
+
export * from './CreateJobRequest';
|
|
6
|
+
export * from './CreateUploadRequest';
|
|
7
|
+
export * from './CreateUploadResponse';
|
|
8
|
+
export * from './CreateWebhookRequest';
|
|
9
|
+
export * from './ErrorBody';
|
|
10
|
+
export * from './ErrorEnvelope';
|
|
11
|
+
export * from './JobOutputInfo';
|
|
12
|
+
export * from './JobProfile';
|
|
13
|
+
export * from './JobProgress';
|
|
14
|
+
export * from './JobResponse';
|
|
15
|
+
export * from './JobSourceInfo';
|
|
16
|
+
export * from './JobSourceType';
|
|
17
|
+
export * from './JobStatus';
|
|
18
|
+
export * from './ListJobsResponse';
|
|
19
|
+
export * from './OutputContainer';
|
|
20
|
+
export * from './ReadyResponse';
|
|
21
|
+
export * from './UploadJobSource';
|
|
22
|
+
export * from './UploadPartResponse';
|
|
23
|
+
export * from './UploadStatusResponse';
|
|
24
|
+
export * from './WebhookDeliveryPayload';
|
|
25
|
+
export * from './WebhookListItem';
|
|
26
|
+
export * from './WebhookListResponse';
|
|
27
|
+
export * from './WebhookResponse';
|
|
@@ -0,0 +1,184 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* SOPHON Encoding API
|
|
3
|
+
* REST API for submitting, monitoring, and retrieving SOPHON encoding jobs. Authentication is via Bearer API key or session cookie. All POST endpoints require an Idempotency-Key header. List endpoints use opaque cursor-based pagination.
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
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
|
+
}
|