Skip to content

Commit

Permalink
feat: update openapi definition
Browse files Browse the repository at this point in the history
  • Loading branch information
task4233 committed Sep 8, 2022
1 parent accc306 commit 6d34218
Show file tree
Hide file tree
Showing 25 changed files with 334 additions and 152 deletions.
2 changes: 1 addition & 1 deletion openapi.json

Large diffs are not rendered by default.

47 changes: 24 additions & 23 deletions src/openapi/.openapi-generator/FILES
Original file line number Diff line number Diff line change
@@ -1,23 +1,24 @@
apis/DefaultApi.ts
apis/index.ts
index.ts
models/AccentPhrase.ts
models/AudioQuery.ts
models/DownloadableLibrary.ts
models/EngineManifest.ts
models/HTTPValidationError.ts
models/LicenseInfo.ts
models/Mora.ts
models/ParseKanaBadRequest.ts
models/Preset.ts
models/Speaker.ts
models/SpeakerInfo.ts
models/SpeakerStyle.ts
models/StyleInfo.ts
models/SupportedDevicesInfo.ts
models/UpdateInfo.ts
models/UserDictWord.ts
models/ValidationError.ts
models/WordTypes.ts
models/index.ts
runtime.ts
apis/DefaultApi.ts
apis/SVModelApi.ts
apis/index.ts
index.ts
models/AccentPhrase.ts
models/AudioQuery.ts
models/EngineManifest.ts
models/HTTPValidationError.ts
models/LicenseInfo.ts
models/Mora.ts
models/ParseKanaBadRequest.ts
models/Preset.ts
models/SVModelInfo.ts
models/Speaker.ts
models/SpeakerInfo.ts
models/SpeakerStyle.ts
models/StyleInfo.ts
models/SupportedDevicesInfo.ts
models/UpdateInfo.ts
models/UserDictWord.ts
models/ValidationError.ts
models/WordTypes.ts
models/index.ts
runtime.ts
52 changes: 3 additions & 49 deletions src/openapi/apis/DefaultApi.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
/* tslint:disable */
/* eslint-disable */
/**
* VOICEVOX ENGINE
* VOICEVOXの音声合成エンジンです
* SHAREVOX ENGINE
* SHAREVOXの音声合成エンジンです
*
* The version of the OpenAPI document: 0.13.0
* The version of the OpenAPI document: latest
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand All @@ -21,9 +21,6 @@ import {
AudioQuery,
AudioQueryFromJSON,
AudioQueryToJSON,
DownloadableLibrary,
DownloadableLibraryFromJSON,
DownloadableLibraryToJSON,
EngineManifest,
EngineManifestFromJSON,
EngineManifestToJSON,
Expand Down Expand Up @@ -315,21 +312,6 @@ export interface DefaultApiInterface {
*/
deleteUserDictWordUserDictWordWordUuidDelete(requestParameters: DeleteUserDictWordUserDictWordWordUuidDeleteRequest, initOverrides?: RequestInit): Promise<void>;

/**
* ダウンロード可能なモデル情報を返します。 Returns ------- ret_data: List[DownloadableLibrary]
* @summary Downloadable Libraries
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof DefaultApiInterface
*/
downloadableLibrariesDownloadableLibrariesGetRaw(initOverrides?: RequestInit): Promise<runtime.ApiResponse<Array<DownloadableLibrary>>>;

/**
* ダウンロード可能なモデル情報を返します。 Returns ------- ret_data: List[DownloadableLibrary]
* Downloadable Libraries
*/
downloadableLibrariesDownloadableLibrariesGet(initOverrides?: RequestInit): Promise<Array<DownloadableLibrary>>;

/**
*
* @summary Engine Manifest
Expand Down Expand Up @@ -965,34 +947,6 @@ export class DefaultApi extends runtime.BaseAPI implements DefaultApiInterface {
await this.deleteUserDictWordUserDictWordWordUuidDeleteRaw(requestParameters, initOverrides);
}

/**
* ダウンロード可能なモデル情報を返します。 Returns ------- ret_data: List[DownloadableLibrary]
* Downloadable Libraries
*/
async downloadableLibrariesDownloadableLibrariesGetRaw(initOverrides?: RequestInit): Promise<runtime.ApiResponse<Array<DownloadableLibrary>>> {
const queryParameters: any = {};

const headerParameters: runtime.HTTPHeaders = {};

const response = await this.request({
path: `/downloadable_libraries`,
method: 'GET',
headers: headerParameters,
query: queryParameters,
}, initOverrides);

return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(DownloadableLibraryFromJSON));
}

/**
* ダウンロード可能なモデル情報を返します。 Returns ------- ret_data: List[DownloadableLibrary]
* Downloadable Libraries
*/
async downloadableLibrariesDownloadableLibrariesGet(initOverrides?: RequestInit): Promise<Array<DownloadableLibrary>> {
const response = await this.downloadableLibrariesDownloadableLibrariesGetRaw(initOverrides);
return await response.value();
}

/**
* Engine Manifest
*/
Expand Down
135 changes: 135 additions & 0 deletions src/openapi/apis/SVModelApi.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,135 @@
/* tslint:disable */
/* eslint-disable */
/**
* SHAREVOX ENGINE
* SHAREVOXの音声合成エンジンです。
*
* The version of the OpenAPI document: latest
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/


import * as runtime from '../runtime';
import {
HTTPValidationError,
HTTPValidationErrorFromJSON,
HTTPValidationErrorToJSON,
SVModelInfo,
SVModelInfoFromJSON,
SVModelInfoToJSON,
} from '../models';

export interface PostSvModelSvModelPostRequest {
sVModelInfo: SVModelInfo;
}

/**
* SVModelApi - interface
*
* @export
* @interface SVModelApiInterface
*/
export interface SVModelApiInterface {
/**
*
* @summary Get Sv Models
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof SVModelApiInterface
*/
getSvModelsSvModelsGetRaw(initOverrides?: RequestInit): Promise<runtime.ApiResponse<Array<string>>>;

/**
* Get Sv Models
*/
getSvModelsSvModelsGet(initOverrides?: RequestInit): Promise<Array<string>>;

/**
* svモデルを登録します。 Parameters ---------- uuid: str モデル固有のUUID variance_model: str variance_model.onnxをbase64エンコードした文字列 embedder_model: str embedder_model.onnxをbase64エンコードした文字列 decoder_model: str decoder_model.onnxをbase64エンコードした文字列 metas: List[Speakers] モデルのメタ情報 metas.jsonをlistにしたもの speaker_infos: Dict[str, SpeakerInfo] keyをspeakerInfoのUUIDとした複数のspeaker情報
* @summary Post Sv Model
* @param {SVModelInfo} sVModelInfo
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof SVModelApiInterface
*/
postSvModelSvModelPostRaw(requestParameters: PostSvModelSvModelPostRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<any>>;

/**
* svモデルを登録します。 Parameters ---------- uuid: str モデル固有のUUID variance_model: str variance_model.onnxをbase64エンコードした文字列 embedder_model: str embedder_model.onnxをbase64エンコードした文字列 decoder_model: str decoder_model.onnxをbase64エンコードした文字列 metas: List[Speakers] モデルのメタ情報 metas.jsonをlistにしたもの speaker_infos: Dict[str, SpeakerInfo] keyをspeakerInfoのUUIDとした複数のspeaker情報
* Post Sv Model
*/
postSvModelSvModelPost(requestParameters: PostSvModelSvModelPostRequest, initOverrides?: RequestInit): Promise<any>;

}

/**
*
*/
export class SVModelApi extends runtime.BaseAPI implements SVModelApiInterface {

/**
* Get Sv Models
*/
async getSvModelsSvModelsGetRaw(initOverrides?: RequestInit): Promise<runtime.ApiResponse<Array<string>>> {
const queryParameters: any = {};

const headerParameters: runtime.HTTPHeaders = {};

const response = await this.request({
path: `/sv_models`,
method: 'GET',
headers: headerParameters,
query: queryParameters,
}, initOverrides);

return new runtime.JSONApiResponse<any>(response);
}

/**
* Get Sv Models
*/
async getSvModelsSvModelsGet(initOverrides?: RequestInit): Promise<Array<string>> {
const response = await this.getSvModelsSvModelsGetRaw(initOverrides);
return await response.value();
}

/**
* svモデルを登録します。 Parameters ---------- uuid: str モデル固有のUUID variance_model: str variance_model.onnxをbase64エンコードした文字列 embedder_model: str embedder_model.onnxをbase64エンコードした文字列 decoder_model: str decoder_model.onnxをbase64エンコードした文字列 metas: List[Speakers] モデルのメタ情報 metas.jsonをlistにしたもの speaker_infos: Dict[str, SpeakerInfo] keyをspeakerInfoのUUIDとした複数のspeaker情報
* Post Sv Model
*/
async postSvModelSvModelPostRaw(requestParameters: PostSvModelSvModelPostRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<any>> {
if (requestParameters.sVModelInfo === null || requestParameters.sVModelInfo === undefined) {
throw new runtime.RequiredError('sVModelInfo','Required parameter requestParameters.sVModelInfo was null or undefined when calling postSvModelSvModelPost.');
}

const queryParameters: any = {};

const headerParameters: runtime.HTTPHeaders = {};

headerParameters['Content-Type'] = 'application/json';

const response = await this.request({
path: `/sv_model`,
method: 'POST',
headers: headerParameters,
query: queryParameters,
body: SVModelInfoToJSON(requestParameters.sVModelInfo),
}, initOverrides);

return new runtime.TextApiResponse(response) as any;
}

/**
* svモデルを登録します。 Parameters ---------- uuid: str モデル固有のUUID variance_model: str variance_model.onnxをbase64エンコードした文字列 embedder_model: str embedder_model.onnxをbase64エンコードした文字列 decoder_model: str decoder_model.onnxをbase64エンコードした文字列 metas: List[Speakers] モデルのメタ情報 metas.jsonをlistにしたもの speaker_infos: Dict[str, SpeakerInfo] keyをspeakerInfoのUUIDとした複数のspeaker情報
* Post Sv Model
*/
async postSvModelSvModelPost(requestParameters: PostSvModelSvModelPostRequest, initOverrides?: RequestInit): Promise<any> {
const response = await this.postSvModelSvModelPostRaw(requestParameters, initOverrides);
return await response.value();
}

}
1 change: 1 addition & 0 deletions src/openapi/apis/index.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/* tslint:disable */
/* eslint-disable */
export * from './DefaultApi';
export * from './SVModelApi';
6 changes: 3 additions & 3 deletions src/openapi/models/AccentPhrase.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
/* tslint:disable */
/* eslint-disable */
/**
* VOICEVOX ENGINE
* VOICEVOXの音声合成エンジンです
* SHAREVOX ENGINE
* SHAREVOXの音声合成エンジンです
*
* The version of the OpenAPI document: 0.13.0
* The version of the OpenAPI document: latest
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
6 changes: 3 additions & 3 deletions src/openapi/models/AudioQuery.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
/* tslint:disable */
/* eslint-disable */
/**
* VOICEVOX ENGINE
* VOICEVOXの音声合成エンジンです
* SHAREVOX ENGINE
* SHAREVOXの音声合成エンジンです
*
* The version of the OpenAPI document: 0.13.0
* The version of the OpenAPI document: latest
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
22 changes: 3 additions & 19 deletions src/openapi/models/EngineManifest.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
/* tslint:disable */
/* eslint-disable */
/**
* VOICEVOX ENGINE
* VOICEVOXの音声合成エンジンです
* SHAREVOX ENGINE
* SHAREVOXの音声合成エンジンです
*
* The version of the OpenAPI document: 0.13.0
* The version of the OpenAPI document: latest
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down Expand Up @@ -84,18 +84,6 @@ export interface EngineManifest {
* @memberof EngineManifest
*/
dependencyLicenses: Array<LicenseInfo>;
/**
*
* @type {string}
* @memberof EngineManifest
*/
downloadableLibrariesPath?: string;
/**
*
* @type {string}
* @memberof EngineManifest
*/
downloadableLibrariesUrl?: string;
}

export function EngineManifestFromJSON(json: any): EngineManifest {
Expand All @@ -117,8 +105,6 @@ export function EngineManifestFromJSONTyped(json: any, ignoreDiscriminator: bool
'termsOfService': json['terms_of_service'],
'updateInfos': ((json['update_infos'] as Array<any>).map(UpdateInfoFromJSON)),
'dependencyLicenses': ((json['dependency_licenses'] as Array<any>).map(LicenseInfoFromJSON)),
'downloadableLibrariesPath': !exists(json, 'downloadable_libraries_path') ? undefined : json['downloadable_libraries_path'],
'downloadableLibrariesUrl': !exists(json, 'downloadable_libraries_url') ? undefined : json['downloadable_libraries_url'],
};
}

Expand All @@ -140,8 +126,6 @@ export function EngineManifestToJSON(value?: EngineManifest | null): any {
'terms_of_service': value.termsOfService,
'update_infos': ((value.updateInfos as Array<any>).map(UpdateInfoToJSON)),
'dependency_licenses': ((value.dependencyLicenses as Array<any>).map(LicenseInfoToJSON)),
'downloadable_libraries_path': value.downloadableLibrariesPath,
'downloadable_libraries_url': value.downloadableLibrariesUrl,
};
}

6 changes: 3 additions & 3 deletions src/openapi/models/HTTPValidationError.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
/* tslint:disable */
/* eslint-disable */
/**
* VOICEVOX ENGINE
* VOICEVOXの音声合成エンジンです
* SHAREVOX ENGINE
* SHAREVOXの音声合成エンジンです
*
* The version of the OpenAPI document: 0.13.0
* The version of the OpenAPI document: latest
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
6 changes: 3 additions & 3 deletions src/openapi/models/LicenseInfo.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
/* tslint:disable */
/* eslint-disable */
/**
* VOICEVOX ENGINE
* VOICEVOXの音声合成エンジンです
* SHAREVOX ENGINE
* SHAREVOXの音声合成エンジンです
*
* The version of the OpenAPI document: 0.13.0
* The version of the OpenAPI document: latest
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
6 changes: 3 additions & 3 deletions src/openapi/models/Mora.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
/* tslint:disable */
/* eslint-disable */
/**
* VOICEVOX ENGINE
* VOICEVOXの音声合成エンジンです
* SHAREVOX ENGINE
* SHAREVOXの音声合成エンジンです
*
* The version of the OpenAPI document: 0.13.0
* The version of the OpenAPI document: latest
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
Loading

0 comments on commit 6d34218

Please sign in to comment.