1
0
mirror of https://github.com/immich-app/immich.git synced 2024-12-26 10:50:29 +02:00

chore: open api

This commit is contained in:
Jason Rasmussen 2023-07-10 15:12:53 -04:00
parent 120727889f
commit 706e3687ff
No known key found for this signature in database
GPG Key ID: 75AD31BF84C94773
8 changed files with 11 additions and 89 deletions

View File

@ -1340,12 +1340,6 @@ export interface GetAssetCountByTimeBucketDto {
* @interface ImportAssetDto * @interface ImportAssetDto
*/ */
export interface ImportAssetDto { export interface ImportAssetDto {
/**
*
* @type {AssetTypeEnum}
* @memberof ImportAssetDto
*/
'assetType': AssetTypeEnum;
/** /**
* *
* @type {boolean} * @type {boolean}
@ -1413,8 +1407,6 @@ export interface ImportAssetDto {
*/ */
'duration'?: string; 'duration'?: string;
} }
/** /**
* *
* @export * @export
@ -5642,9 +5634,7 @@ export const AssetApiAxiosParamCreator = function (configuration?: Configuration
}, },
/** /**
* *
* @param {AssetTypeEnum} assetType
* @param {File} assetData * @param {File} assetData
* @param {string} fileExtension
* @param {string} deviceAssetId * @param {string} deviceAssetId
* @param {string} deviceId * @param {string} deviceId
* @param {string} fileCreatedAt * @param {string} fileCreatedAt
@ -5660,13 +5650,9 @@ export const AssetApiAxiosParamCreator = function (configuration?: Configuration
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
uploadFile: async (assetType: AssetTypeEnum, assetData: File, fileExtension: string, deviceAssetId: string, deviceId: string, fileCreatedAt: string, fileModifiedAt: string, isFavorite: boolean, key?: string, livePhotoData?: File, sidecarData?: File, isReadOnly?: boolean, isArchived?: boolean, isVisible?: boolean, duration?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => { uploadFile: async (assetData: File, deviceAssetId: string, deviceId: string, fileCreatedAt: string, fileModifiedAt: string, isFavorite: boolean, key?: string, livePhotoData?: File, sidecarData?: File, isReadOnly?: boolean, isArchived?: boolean, isVisible?: boolean, duration?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
// verify required parameter 'assetType' is not null or undefined
assertParamExists('uploadFile', 'assetType', assetType)
// verify required parameter 'assetData' is not null or undefined // verify required parameter 'assetData' is not null or undefined
assertParamExists('uploadFile', 'assetData', assetData) assertParamExists('uploadFile', 'assetData', assetData)
// verify required parameter 'fileExtension' is not null or undefined
assertParamExists('uploadFile', 'fileExtension', fileExtension)
// verify required parameter 'deviceAssetId' is not null or undefined // verify required parameter 'deviceAssetId' is not null or undefined
assertParamExists('uploadFile', 'deviceAssetId', deviceAssetId) assertParamExists('uploadFile', 'deviceAssetId', deviceAssetId)
// verify required parameter 'deviceId' is not null or undefined // verify required parameter 'deviceId' is not null or undefined
@ -5704,10 +5690,6 @@ export const AssetApiAxiosParamCreator = function (configuration?: Configuration
} }
if (assetType !== undefined) {
localVarFormParams.append('assetType', new Blob([JSON.stringify(assetType)], { type: "application/json", }));
}
if (assetData !== undefined) { if (assetData !== undefined) {
localVarFormParams.append('assetData', assetData as any); localVarFormParams.append('assetData', assetData as any);
} }
@ -5724,10 +5706,6 @@ export const AssetApiAxiosParamCreator = function (configuration?: Configuration
localVarFormParams.append('isReadOnly', isReadOnly as any); localVarFormParams.append('isReadOnly', isReadOnly as any);
} }
if (fileExtension !== undefined) {
localVarFormParams.append('fileExtension', fileExtension as any);
}
if (deviceAssetId !== undefined) { if (deviceAssetId !== undefined) {
localVarFormParams.append('deviceAssetId', deviceAssetId as any); localVarFormParams.append('deviceAssetId', deviceAssetId as any);
} }
@ -6041,9 +6019,7 @@ export const AssetApiFp = function(configuration?: Configuration) {
}, },
/** /**
* *
* @param {AssetTypeEnum} assetType
* @param {File} assetData * @param {File} assetData
* @param {string} fileExtension
* @param {string} deviceAssetId * @param {string} deviceAssetId
* @param {string} deviceId * @param {string} deviceId
* @param {string} fileCreatedAt * @param {string} fileCreatedAt
@ -6059,8 +6035,8 @@ export const AssetApiFp = function(configuration?: Configuration) {
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
async uploadFile(assetType: AssetTypeEnum, assetData: File, fileExtension: string, deviceAssetId: string, deviceId: string, fileCreatedAt: string, fileModifiedAt: string, isFavorite: boolean, key?: string, livePhotoData?: File, sidecarData?: File, isReadOnly?: boolean, isArchived?: boolean, isVisible?: boolean, duration?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AssetFileUploadResponseDto>> { async uploadFile(assetData: File, deviceAssetId: string, deviceId: string, fileCreatedAt: string, fileModifiedAt: string, isFavorite: boolean, key?: string, livePhotoData?: File, sidecarData?: File, isReadOnly?: boolean, isArchived?: boolean, isVisible?: boolean, duration?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AssetFileUploadResponseDto>> {
const localVarAxiosArgs = await localVarAxiosParamCreator.uploadFile(assetType, assetData, fileExtension, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, isFavorite, key, livePhotoData, sidecarData, isReadOnly, isArchived, isVisible, duration, options); const localVarAxiosArgs = await localVarAxiosParamCreator.uploadFile(assetData, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, isFavorite, key, livePhotoData, sidecarData, isReadOnly, isArchived, isVisible, duration, options);
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
}, },
} }
@ -6291,7 +6267,7 @@ export const AssetApiFactory = function (configuration?: Configuration, basePath
* @throws {RequiredError} * @throws {RequiredError}
*/ */
uploadFile(requestParameters: AssetApiUploadFileRequest, options?: AxiosRequestConfig): AxiosPromise<AssetFileUploadResponseDto> { uploadFile(requestParameters: AssetApiUploadFileRequest, options?: AxiosRequestConfig): AxiosPromise<AssetFileUploadResponseDto> {
return localVarFp.uploadFile(requestParameters.assetType, requestParameters.assetData, requestParameters.fileExtension, requestParameters.deviceAssetId, requestParameters.deviceId, requestParameters.fileCreatedAt, requestParameters.fileModifiedAt, requestParameters.isFavorite, requestParameters.key, requestParameters.livePhotoData, requestParameters.sidecarData, requestParameters.isReadOnly, requestParameters.isArchived, requestParameters.isVisible, requestParameters.duration, options).then((request) => request(axios, basePath)); return localVarFp.uploadFile(requestParameters.assetData, requestParameters.deviceAssetId, requestParameters.deviceId, requestParameters.fileCreatedAt, requestParameters.fileModifiedAt, requestParameters.isFavorite, requestParameters.key, requestParameters.livePhotoData, requestParameters.sidecarData, requestParameters.isReadOnly, requestParameters.isArchived, requestParameters.isVisible, requestParameters.duration, options).then((request) => request(axios, basePath));
}, },
}; };
}; };
@ -6715,13 +6691,6 @@ export interface AssetApiUpdateAssetRequest {
* @interface AssetApiUploadFileRequest * @interface AssetApiUploadFileRequest
*/ */
export interface AssetApiUploadFileRequest { export interface AssetApiUploadFileRequest {
/**
*
* @type {AssetTypeEnum}
* @memberof AssetApiUploadFile
*/
readonly assetType: AssetTypeEnum
/** /**
* *
* @type {File} * @type {File}
@ -6729,13 +6698,6 @@ export interface AssetApiUploadFileRequest {
*/ */
readonly assetData: File readonly assetData: File
/**
*
* @type {string}
* @memberof AssetApiUploadFile
*/
readonly fileExtension: string
/** /**
* *
* @type {string} * @type {string}
@ -7095,7 +7057,7 @@ export class AssetApi extends BaseAPI {
* @memberof AssetApi * @memberof AssetApi
*/ */
public uploadFile(requestParameters: AssetApiUploadFileRequest, options?: AxiosRequestConfig) { public uploadFile(requestParameters: AssetApiUploadFileRequest, options?: AxiosRequestConfig) {
return AssetApiFp(this.configuration).uploadFile(requestParameters.assetType, requestParameters.assetData, requestParameters.fileExtension, requestParameters.deviceAssetId, requestParameters.deviceId, requestParameters.fileCreatedAt, requestParameters.fileModifiedAt, requestParameters.isFavorite, requestParameters.key, requestParameters.livePhotoData, requestParameters.sidecarData, requestParameters.isReadOnly, requestParameters.isArchived, requestParameters.isVisible, requestParameters.duration, options).then((request) => request(this.axios, this.basePath)); return AssetApiFp(this.configuration).uploadFile(requestParameters.assetData, requestParameters.deviceAssetId, requestParameters.deviceId, requestParameters.fileCreatedAt, requestParameters.fileModifiedAt, requestParameters.isFavorite, requestParameters.key, requestParameters.livePhotoData, requestParameters.sidecarData, requestParameters.isReadOnly, requestParameters.isArchived, requestParameters.isVisible, requestParameters.duration, options).then((request) => request(this.axios, this.basePath));
} }
} }

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -1340,12 +1340,6 @@ export interface GetAssetCountByTimeBucketDto {
* @interface ImportAssetDto * @interface ImportAssetDto
*/ */
export interface ImportAssetDto { export interface ImportAssetDto {
/**
*
* @type {AssetTypeEnum}
* @memberof ImportAssetDto
*/
'assetType': AssetTypeEnum;
/** /**
* *
* @type {boolean} * @type {boolean}
@ -1413,8 +1407,6 @@ export interface ImportAssetDto {
*/ */
'duration'?: string; 'duration'?: string;
} }
/** /**
* *
* @export * @export
@ -5651,9 +5643,7 @@ export const AssetApiAxiosParamCreator = function (configuration?: Configuration
}, },
/** /**
* *
* @param {AssetTypeEnum} assetType
* @param {File} assetData * @param {File} assetData
* @param {string} fileExtension
* @param {string} deviceAssetId * @param {string} deviceAssetId
* @param {string} deviceId * @param {string} deviceId
* @param {string} fileCreatedAt * @param {string} fileCreatedAt
@ -5669,13 +5659,9 @@ export const AssetApiAxiosParamCreator = function (configuration?: Configuration
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
uploadFile: async (assetType: AssetTypeEnum, assetData: File, fileExtension: string, deviceAssetId: string, deviceId: string, fileCreatedAt: string, fileModifiedAt: string, isFavorite: boolean, key?: string, livePhotoData?: File, sidecarData?: File, isReadOnly?: boolean, isArchived?: boolean, isVisible?: boolean, duration?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => { uploadFile: async (assetData: File, deviceAssetId: string, deviceId: string, fileCreatedAt: string, fileModifiedAt: string, isFavorite: boolean, key?: string, livePhotoData?: File, sidecarData?: File, isReadOnly?: boolean, isArchived?: boolean, isVisible?: boolean, duration?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
// verify required parameter 'assetType' is not null or undefined
assertParamExists('uploadFile', 'assetType', assetType)
// verify required parameter 'assetData' is not null or undefined // verify required parameter 'assetData' is not null or undefined
assertParamExists('uploadFile', 'assetData', assetData) assertParamExists('uploadFile', 'assetData', assetData)
// verify required parameter 'fileExtension' is not null or undefined
assertParamExists('uploadFile', 'fileExtension', fileExtension)
// verify required parameter 'deviceAssetId' is not null or undefined // verify required parameter 'deviceAssetId' is not null or undefined
assertParamExists('uploadFile', 'deviceAssetId', deviceAssetId) assertParamExists('uploadFile', 'deviceAssetId', deviceAssetId)
// verify required parameter 'deviceId' is not null or undefined // verify required parameter 'deviceId' is not null or undefined
@ -5713,10 +5699,6 @@ export const AssetApiAxiosParamCreator = function (configuration?: Configuration
} }
if (assetType !== undefined) {
localVarFormParams.append('assetType', new Blob([JSON.stringify(assetType)], { type: "application/json", }));
}
if (assetData !== undefined) { if (assetData !== undefined) {
localVarFormParams.append('assetData', assetData as any); localVarFormParams.append('assetData', assetData as any);
} }
@ -5733,10 +5715,6 @@ export const AssetApiAxiosParamCreator = function (configuration?: Configuration
localVarFormParams.append('isReadOnly', isReadOnly as any); localVarFormParams.append('isReadOnly', isReadOnly as any);
} }
if (fileExtension !== undefined) {
localVarFormParams.append('fileExtension', fileExtension as any);
}
if (deviceAssetId !== undefined) { if (deviceAssetId !== undefined) {
localVarFormParams.append('deviceAssetId', deviceAssetId as any); localVarFormParams.append('deviceAssetId', deviceAssetId as any);
} }
@ -6050,9 +6028,7 @@ export const AssetApiFp = function(configuration?: Configuration) {
}, },
/** /**
* *
* @param {AssetTypeEnum} assetType
* @param {File} assetData * @param {File} assetData
* @param {string} fileExtension
* @param {string} deviceAssetId * @param {string} deviceAssetId
* @param {string} deviceId * @param {string} deviceId
* @param {string} fileCreatedAt * @param {string} fileCreatedAt
@ -6068,8 +6044,8 @@ export const AssetApiFp = function(configuration?: Configuration) {
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
async uploadFile(assetType: AssetTypeEnum, assetData: File, fileExtension: string, deviceAssetId: string, deviceId: string, fileCreatedAt: string, fileModifiedAt: string, isFavorite: boolean, key?: string, livePhotoData?: File, sidecarData?: File, isReadOnly?: boolean, isArchived?: boolean, isVisible?: boolean, duration?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AssetFileUploadResponseDto>> { async uploadFile(assetData: File, deviceAssetId: string, deviceId: string, fileCreatedAt: string, fileModifiedAt: string, isFavorite: boolean, key?: string, livePhotoData?: File, sidecarData?: File, isReadOnly?: boolean, isArchived?: boolean, isVisible?: boolean, duration?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AssetFileUploadResponseDto>> {
const localVarAxiosArgs = await localVarAxiosParamCreator.uploadFile(assetType, assetData, fileExtension, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, isFavorite, key, livePhotoData, sidecarData, isReadOnly, isArchived, isVisible, duration, options); const localVarAxiosArgs = await localVarAxiosParamCreator.uploadFile(assetData, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, isFavorite, key, livePhotoData, sidecarData, isReadOnly, isArchived, isVisible, duration, options);
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
}, },
} }
@ -6316,9 +6292,7 @@ export const AssetApiFactory = function (configuration?: Configuration, basePath
}, },
/** /**
* *
* @param {AssetTypeEnum} assetType
* @param {File} assetData * @param {File} assetData
* @param {string} fileExtension
* @param {string} deviceAssetId * @param {string} deviceAssetId
* @param {string} deviceId * @param {string} deviceId
* @param {string} fileCreatedAt * @param {string} fileCreatedAt
@ -6334,8 +6308,8 @@ export const AssetApiFactory = function (configuration?: Configuration, basePath
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
uploadFile(assetType: AssetTypeEnum, assetData: File, fileExtension: string, deviceAssetId: string, deviceId: string, fileCreatedAt: string, fileModifiedAt: string, isFavorite: boolean, key?: string, livePhotoData?: File, sidecarData?: File, isReadOnly?: boolean, isArchived?: boolean, isVisible?: boolean, duration?: string, options?: any): AxiosPromise<AssetFileUploadResponseDto> { uploadFile(assetData: File, deviceAssetId: string, deviceId: string, fileCreatedAt: string, fileModifiedAt: string, isFavorite: boolean, key?: string, livePhotoData?: File, sidecarData?: File, isReadOnly?: boolean, isArchived?: boolean, isVisible?: boolean, duration?: string, options?: any): AxiosPromise<AssetFileUploadResponseDto> {
return localVarFp.uploadFile(assetType, assetData, fileExtension, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, isFavorite, key, livePhotoData, sidecarData, isReadOnly, isArchived, isVisible, duration, options).then((request) => request(axios, basePath)); return localVarFp.uploadFile(assetData, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, isFavorite, key, livePhotoData, sidecarData, isReadOnly, isArchived, isVisible, duration, options).then((request) => request(axios, basePath));
}, },
}; };
}; };
@ -6759,13 +6733,6 @@ export interface AssetApiUpdateAssetRequest {
* @interface AssetApiUploadFileRequest * @interface AssetApiUploadFileRequest
*/ */
export interface AssetApiUploadFileRequest { export interface AssetApiUploadFileRequest {
/**
*
* @type {AssetTypeEnum}
* @memberof AssetApiUploadFile
*/
readonly assetType: AssetTypeEnum
/** /**
* *
* @type {File} * @type {File}
@ -6773,13 +6740,6 @@ export interface AssetApiUploadFileRequest {
*/ */
readonly assetData: File readonly assetData: File
/**
*
* @type {string}
* @memberof AssetApiUploadFile
*/
readonly fileExtension: string
/** /**
* *
* @type {string} * @type {string}
@ -7139,7 +7099,7 @@ export class AssetApi extends BaseAPI {
* @memberof AssetApi * @memberof AssetApi
*/ */
public uploadFile(requestParameters: AssetApiUploadFileRequest, options?: AxiosRequestConfig) { public uploadFile(requestParameters: AssetApiUploadFileRequest, options?: AxiosRequestConfig) {
return AssetApiFp(this.configuration).uploadFile(requestParameters.assetType, requestParameters.assetData, requestParameters.fileExtension, requestParameters.deviceAssetId, requestParameters.deviceId, requestParameters.fileCreatedAt, requestParameters.fileModifiedAt, requestParameters.isFavorite, requestParameters.key, requestParameters.livePhotoData, requestParameters.sidecarData, requestParameters.isReadOnly, requestParameters.isArchived, requestParameters.isVisible, requestParameters.duration, options).then((request) => request(this.axios, this.basePath)); return AssetApiFp(this.configuration).uploadFile(requestParameters.assetData, requestParameters.deviceAssetId, requestParameters.deviceId, requestParameters.fileCreatedAt, requestParameters.fileModifiedAt, requestParameters.isFavorite, requestParameters.key, requestParameters.livePhotoData, requestParameters.sidecarData, requestParameters.isReadOnly, requestParameters.isArchived, requestParameters.isVisible, requestParameters.duration, options).then((request) => request(this.axios, this.basePath));
} }
} }