diff --git a/packages/lib-apiclient/src/generated/api.ts b/packages/lib-apiclient/src/generated/api.ts index a0662a2f2..ba77c6b51 100644 --- a/packages/lib-apiclient/src/generated/api.ts +++ b/packages/lib-apiclient/src/generated/api.ts @@ -4,7 +4,7 @@ * Takaro app-api * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * - * The version of the OpenAPI document: development - 6ab7a6f6b7cb278165265c7cafdf2b3c3ca9d90a + * The version of the OpenAPI document: development - fc99f56c09f7f05a31693d60784c28ce6aa08d1e * Contact: support@takaro.io * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -5095,6 +5095,80 @@ export interface LoginOutputDTOAPI { */ meta: MetadataOutput; } +/** + * + * @export + * @interface MapInfoDTO + */ +export interface MapInfoDTO { + /** + * + * @type {boolean} + * @memberof MapInfoDTO + */ + enabled: boolean; + /** + * + * @type {number} + * @memberof MapInfoDTO + */ + mapBlockSize: number; + /** + * + * @type {number} + * @memberof MapInfoDTO + */ + maxZoom: number; + /** + * + * @type {number} + * @memberof MapInfoDTO + */ + mapSizeX: number; + /** + * + * @type {number} + * @memberof MapInfoDTO + */ + mapSizeY: number; + /** + * + * @type {number} + * @memberof MapInfoDTO + */ + mapSizeZ: number; +} +/** + * + * @export + * @interface MapTileInputDTO + */ +export interface MapTileInputDTO { + /** + * + * @type {string} + * @memberof MapTileInputDTO + */ + id: string; + /** + * + * @type {number} + * @memberof MapTileInputDTO + */ + z: number; + /** + * + * @type {number} + * @memberof MapTileInputDTO + */ + x: number; + /** + * + * @type {number} + * @memberof MapTileInputDTO + */ + y: number; +} /** * * @export @@ -14080,6 +14154,91 @@ export const GameServerApiAxiosParamCreator = function (configuration?: Configur options: localVarRequestOptions, }; }, + /** + * Get map metadata for Leaflet + * @summary Get map info + * @param {string} id + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + gameServerControllerGetMapInfo: async (id: string, options: RawAxiosRequestConfig = {}): Promise => { + // verify required parameter 'id' is not null or undefined + assertParamExists('gameServerControllerGetMapInfo', 'id', id); + const localVarPath = `/gameserver/{id}/map/info`.replace(`{${'id'}}`, encodeURIComponent(String(id))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options }; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication domainAuth required + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers }; + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, + /** + * Get a map tile for Leaflet + * @summary Get map tile + * @param {string} id + * @param {string} x + * @param {string} y + * @param {string} z + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + gameServerControllerGetMapTile: async ( + id: string, + x: string, + y: string, + z: string, + options: RawAxiosRequestConfig = {}, + ): Promise => { + // verify required parameter 'id' is not null or undefined + assertParamExists('gameServerControllerGetMapTile', 'id', id); + // verify required parameter 'x' is not null or undefined + assertParamExists('gameServerControllerGetMapTile', 'x', x); + // verify required parameter 'y' is not null or undefined + assertParamExists('gameServerControllerGetMapTile', 'y', y); + // verify required parameter 'z' is not null or undefined + assertParamExists('gameServerControllerGetMapTile', 'z', z); + const localVarPath = `/gameserver/{id}/map/tile/{x}/{y}/{z}` + .replace(`{${'id'}}`, encodeURIComponent(String(id))) + .replace(`{${'x'}}`, encodeURIComponent(String(x))) + .replace(`{${'y'}}`, encodeURIComponent(String(y))) + .replace(`{${'z'}}`, encodeURIComponent(String(z))); + // use dummy base URL string because the URL constructor only accepts absolute URLs. + const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); + let baseOptions; + if (configuration) { + baseOptions = configuration.baseOptions; + } + + const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options }; + const localVarHeaderParameter = {} as any; + const localVarQueryParameter = {} as any; + + // authentication domainAuth required + + setSearchParams(localVarUrlObj, localVarQueryParameter); + let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; + localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers }; + + return { + url: toPathString(localVarUrlObj), + options: localVarRequestOptions, + }; + }, /** * Get a module installation by id * @summary Get module installation @@ -14970,6 +15129,58 @@ export const GameServerApiFp = function (configuration?: Configuration) { configuration, )(axios, localVarOperationServerBasePath || basePath); }, + /** + * Get map metadata for Leaflet + * @summary Get map info + * @param {string} id + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async gameServerControllerGetMapInfo( + id: string, + options?: RawAxiosRequestConfig, + ): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.gameServerControllerGetMapInfo(id, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = + operationServerMap['GameServerApi.gameServerControllerGetMapInfo']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => + createRequestFunction( + localVarAxiosArgs, + globalAxios, + BASE_PATH, + configuration, + )(axios, localVarOperationServerBasePath || basePath); + }, + /** + * Get a map tile for Leaflet + * @summary Get map tile + * @param {string} id + * @param {string} x + * @param {string} y + * @param {string} z + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + async gameServerControllerGetMapTile( + id: string, + x: string, + y: string, + z: string, + options?: RawAxiosRequestConfig, + ): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { + const localVarAxiosArgs = await localVarAxiosParamCreator.gameServerControllerGetMapTile(id, x, y, z, options); + const localVarOperationServerIndex = configuration?.serverIndex ?? 0; + const localVarOperationServerBasePath = + operationServerMap['GameServerApi.gameServerControllerGetMapTile']?.[localVarOperationServerIndex]?.url; + return (axios, basePath) => + createRequestFunction( + localVarAxiosArgs, + globalAxios, + BASE_PATH, + configuration, + )(axios, localVarOperationServerBasePath || basePath); + }, /** * Get a module installation by id * @summary Get module installation @@ -15566,6 +15777,37 @@ export const GameServerApiFactory = function (configuration?: Configuration, bas .gameServerControllerGetInstalledModules(id, options) .then((request) => request(axios, basePath)); }, + /** + * Get map metadata for Leaflet + * @summary Get map info + * @param {string} id + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + gameServerControllerGetMapInfo(id: string, options?: RawAxiosRequestConfig): AxiosPromise { + return localVarFp.gameServerControllerGetMapInfo(id, options).then((request) => request(axios, basePath)); + }, + /** + * Get a map tile for Leaflet + * @summary Get map tile + * @param {string} id + * @param {string} x + * @param {string} y + * @param {string} z + * @param {*} [options] Override http request option. + * @throws {RequiredError} + */ + gameServerControllerGetMapTile( + id: string, + x: string, + y: string, + z: string, + options?: RawAxiosRequestConfig, + ): AxiosPromise { + return localVarFp + .gameServerControllerGetMapTile(id, x, y, z, options) + .then((request) => request(axios, basePath)); + }, /** * Get a module installation by id * @summary Get module installation @@ -15938,6 +16180,37 @@ export class GameServerApi extends BaseAPI { .then((request) => request(this.axios, this.basePath)); } + /** + * Get map metadata for Leaflet + * @summary Get map info + * @param {string} id + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof GameServerApi + */ + public gameServerControllerGetMapInfo(id: string, options?: RawAxiosRequestConfig) { + return GameServerApiFp(this.configuration) + .gameServerControllerGetMapInfo(id, options) + .then((request) => request(this.axios, this.basePath)); + } + + /** + * Get a map tile for Leaflet + * @summary Get map tile + * @param {string} id + * @param {string} x + * @param {string} y + * @param {string} z + * @param {*} [options] Override http request option. + * @throws {RequiredError} + * @memberof GameServerApi + */ + public gameServerControllerGetMapTile(id: string, x: string, y: string, z: string, options?: RawAxiosRequestConfig) { + return GameServerApiFp(this.configuration) + .gameServerControllerGetMapTile(id, x, y, z, options) + .then((request) => request(this.axios, this.basePath)); + } + /** * Get a module installation by id * @summary Get module installation diff --git a/packages/lib-apiclient/src/generated/base.ts b/packages/lib-apiclient/src/generated/base.ts index f14631c0c..02138c10b 100644 --- a/packages/lib-apiclient/src/generated/base.ts +++ b/packages/lib-apiclient/src/generated/base.ts @@ -4,7 +4,7 @@ * Takaro app-api * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * - * The version of the OpenAPI document: development - 6ab7a6f6b7cb278165265c7cafdf2b3c3ca9d90a + * The version of the OpenAPI document: development - fc99f56c09f7f05a31693d60784c28ce6aa08d1e * Contact: support@takaro.io * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/packages/lib-apiclient/src/generated/common.ts b/packages/lib-apiclient/src/generated/common.ts index 53a2ce161..5e5a2a0af 100644 --- a/packages/lib-apiclient/src/generated/common.ts +++ b/packages/lib-apiclient/src/generated/common.ts @@ -4,7 +4,7 @@ * Takaro app-api * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * - * The version of the OpenAPI document: development - 6ab7a6f6b7cb278165265c7cafdf2b3c3ca9d90a + * The version of the OpenAPI document: development - fc99f56c09f7f05a31693d60784c28ce6aa08d1e * Contact: support@takaro.io * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/packages/lib-apiclient/src/generated/configuration.ts b/packages/lib-apiclient/src/generated/configuration.ts index bc08375ce..6ddb48c16 100644 --- a/packages/lib-apiclient/src/generated/configuration.ts +++ b/packages/lib-apiclient/src/generated/configuration.ts @@ -4,7 +4,7 @@ * Takaro app-api * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * - * The version of the OpenAPI document: development - 6ab7a6f6b7cb278165265c7cafdf2b3c3ca9d90a + * The version of the OpenAPI document: development - fc99f56c09f7f05a31693d60784c28ce6aa08d1e * Contact: support@takaro.io * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/packages/lib-apiclient/src/generated/index.ts b/packages/lib-apiclient/src/generated/index.ts index ffbb487f4..5f90cd87c 100644 --- a/packages/lib-apiclient/src/generated/index.ts +++ b/packages/lib-apiclient/src/generated/index.ts @@ -4,7 +4,7 @@ * Takaro app-api * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * - * The version of the OpenAPI document: development - 6ab7a6f6b7cb278165265c7cafdf2b3c3ca9d90a + * The version of the OpenAPI document: development - fc99f56c09f7f05a31693d60784c28ce6aa08d1e * Contact: support@takaro.io * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).