From be57ff498530b2b3dc7ad16fc79e9019a1619858 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=8B=E3=81=A3=E3=81=93=E3=81=8B=E3=82=8A?= <67428053+kakkokari-gtyih@users.noreply.github.com> Date: Thu, 11 Jan 2024 23:41:22 +0900 Subject: [PATCH] run `pnpm build-misskey-js-with-types` (#12972) --- .../api/endpoints/bubble-game/ranking.ts | 2 - .../api/endpoints/bubble-game/register.ts | 2 - packages/misskey-js/etc/misskey-js.api.md | 16 ++ .../misskey-js/src/autogen/apiClientJSDoc.ts | 24 ++- packages/misskey-js/src/autogen/endpoint.ts | 8 +- packages/misskey-js/src/autogen/entities.ts | 6 +- packages/misskey-js/src/autogen/models.ts | 2 +- packages/misskey-js/src/autogen/types.ts | 148 +++++++++++++++++- 8 files changed, 199 insertions(+), 9 deletions(-) diff --git a/packages/backend/src/server/api/endpoints/bubble-game/ranking.ts b/packages/backend/src/server/api/endpoints/bubble-game/ranking.ts index 0cba129a09..9c057760ca 100644 --- a/packages/backend/src/server/api/endpoints/bubble-game/ranking.ts +++ b/packages/backend/src/server/api/endpoints/bubble-game/ranking.ts @@ -11,8 +11,6 @@ import { DI } from '@/di-symbols.js'; import { UserEntityService } from '@/core/entities/UserEntityService.js'; export const meta = { - tags: [], - allowGet: true, cacheSec: 60, diff --git a/packages/backend/src/server/api/endpoints/bubble-game/register.ts b/packages/backend/src/server/api/endpoints/bubble-game/register.ts index af0f69e4ad..f092d16a70 100644 --- a/packages/backend/src/server/api/endpoints/bubble-game/register.ts +++ b/packages/backend/src/server/api/endpoints/bubble-game/register.ts @@ -12,8 +12,6 @@ import { DI } from '@/di-symbols.js'; import { ApiError } from '../../error.js'; export const meta = { - tags: [], - requireCredential: true, kind: 'write:account', diff --git a/packages/misskey-js/etc/misskey-js.api.md b/packages/misskey-js/etc/misskey-js.api.md index a79ea1b420..f955cc5cc1 100644 --- a/packages/misskey-js/etc/misskey-js.api.md +++ b/packages/misskey-js/etc/misskey-js.api.md @@ -473,6 +473,18 @@ type BlockingListRequest = operations['blocking/list']['requestBody']['content'] // @public (undocumented) type BlockingListResponse = operations['blocking/list']['responses']['200']['content']['application/json']; +// @public (undocumented) +type BubbleGameRankingRequest = operations['bubble-game/ranking']['requestBody']['content']['application/json']; + +// @public (undocumented) +type BubbleGameRankingResponse = operations['bubble-game/ranking']['responses']['200']['content']['application/json']; + +// @public (undocumented) +type BubbleGameRegisterRequest = operations['bubble-game/register']['requestBody']['content']['application/json']; + +// @public (undocumented) +type BubbleGameRegisterResponse = operations['bubble-game/register']['responses']['200']['content']['application/json']; + // @public (undocumented) type Channel = components['schemas']['Channel']; @@ -1607,6 +1619,10 @@ declare namespace entities { FetchExternalResourcesRequest, FetchExternalResourcesResponse, RetentionResponse, + BubbleGameRegisterRequest, + BubbleGameRegisterResponse, + BubbleGameRankingRequest, + BubbleGameRankingResponse, Error_2 as Error, UserLite, UserDetailedNotMeOnly, diff --git a/packages/misskey-js/src/autogen/apiClientJSDoc.ts b/packages/misskey-js/src/autogen/apiClientJSDoc.ts index 9d0343c1e8..34fe50e948 100644 --- a/packages/misskey-js/src/autogen/apiClientJSDoc.ts +++ b/packages/misskey-js/src/autogen/apiClientJSDoc.ts @@ -1,6 +1,6 @@ /* * version: 2023.12.2 - * generatedAt: 2024-01-07T15:22:15.630Z + * generatedAt: 2024-01-11T14:29:04.817Z */ import type { SwitchCaseResponseType } from '../api.js'; @@ -3985,5 +3985,27 @@ declare module '../api.js' { params: P, credential?: string | null, ): Promise>; + + /** + * No description provided. + * + * **Credential required**: *Yes* / **Permission**: *write:account* + */ + request( + endpoint: E, + params: P, + credential?: string | null, + ): Promise>; + + /** + * No description provided. + * + * **Credential required**: *No* + */ + request( + endpoint: E, + params: P, + credential?: string | null, + ): Promise>; } } diff --git a/packages/misskey-js/src/autogen/endpoint.ts b/packages/misskey-js/src/autogen/endpoint.ts index cc4d251f4d..8208c200dc 100644 --- a/packages/misskey-js/src/autogen/endpoint.ts +++ b/packages/misskey-js/src/autogen/endpoint.ts @@ -1,6 +1,6 @@ /* * version: 2023.12.2 - * generatedAt: 2024-01-07T15:22:15.626Z + * generatedAt: 2024-01-11T14:29:04.814Z */ import type { @@ -540,6 +540,10 @@ import type { FetchExternalResourcesRequest, FetchExternalResourcesResponse, RetentionResponse, + BubbleGameRegisterRequest, + BubbleGameRegisterResponse, + BubbleGameRankingRequest, + BubbleGameRankingResponse, } from './entities.js'; export type Endpoints = { @@ -901,4 +905,6 @@ export type Endpoints = { 'fetch-rss': { req: FetchRssRequest; res: FetchRssResponse }; 'fetch-external-resources': { req: FetchExternalResourcesRequest; res: FetchExternalResourcesResponse }; 'retention': { req: EmptyRequest; res: RetentionResponse }; + 'bubble-game/register': { req: BubbleGameRegisterRequest; res: BubbleGameRegisterResponse }; + 'bubble-game/ranking': { req: BubbleGameRankingRequest; res: BubbleGameRankingResponse }; } diff --git a/packages/misskey-js/src/autogen/entities.ts b/packages/misskey-js/src/autogen/entities.ts index 1f3f55b2fd..5bac5ac270 100644 --- a/packages/misskey-js/src/autogen/entities.ts +++ b/packages/misskey-js/src/autogen/entities.ts @@ -1,6 +1,6 @@ /* * version: 2023.12.2 - * generatedAt: 2024-01-07T15:22:15.624Z + * generatedAt: 2024-01-11T14:29:04.811Z */ import { operations } from './types.js'; @@ -542,3 +542,7 @@ export type FetchRssResponse = operations['fetch-rss']['responses']['200']['cont export type FetchExternalResourcesRequest = operations['fetch-external-resources']['requestBody']['content']['application/json']; export type FetchExternalResourcesResponse = operations['fetch-external-resources']['responses']['200']['content']['application/json']; export type RetentionResponse = operations['retention']['responses']['200']['content']['application/json']; +export type BubbleGameRegisterRequest = operations['bubble-game/register']['requestBody']['content']['application/json']; +export type BubbleGameRegisterResponse = operations['bubble-game/register']['responses']['200']['content']['application/json']; +export type BubbleGameRankingRequest = operations['bubble-game/ranking']['requestBody']['content']['application/json']; +export type BubbleGameRankingResponse = operations['bubble-game/ranking']['responses']['200']['content']['application/json']; diff --git a/packages/misskey-js/src/autogen/models.ts b/packages/misskey-js/src/autogen/models.ts index 90e2bf660b..518f6a8635 100644 --- a/packages/misskey-js/src/autogen/models.ts +++ b/packages/misskey-js/src/autogen/models.ts @@ -1,6 +1,6 @@ /* * version: 2023.12.2 - * generatedAt: 2024-01-07T15:22:15.623Z + * generatedAt: 2024-01-11T14:29:04.810Z */ import { components } from './types.js'; diff --git a/packages/misskey-js/src/autogen/types.ts b/packages/misskey-js/src/autogen/types.ts index b2c34abf7b..d0aa240907 100644 --- a/packages/misskey-js/src/autogen/types.ts +++ b/packages/misskey-js/src/autogen/types.ts @@ -3,7 +3,7 @@ /* * version: 2023.12.2 - * generatedAt: 2024-01-07T15:22:15.494Z + * generatedAt: 2024-01-11T14:29:04.681Z */ /** @@ -3447,6 +3447,31 @@ export type paths = { */ post: operations['retention']; }; + '/bubble-game/register': { + /** + * bubble-game/register + * @description No description provided. + * + * **Credential required**: *Yes* / **Permission**: *write:account* + */ + post: operations['bubble-game/register']; + }; + '/bubble-game/ranking': { + /** + * bubble-game/ranking + * @description No description provided. + * + * **Credential required**: *No* + */ + get: operations['bubble-game/ranking']; + /** + * bubble-game/ranking + * @description No description provided. + * + * **Credential required**: *No* + */ + post: operations['bubble-game/ranking']; + }; }; export type webhooks = Record; @@ -25396,5 +25421,126 @@ export type operations = { }; }; }; + /** + * bubble-game/register + * @description No description provided. + * + * **Credential required**: *Yes* / **Permission**: *write:account* + */ + 'bubble-game/register': { + requestBody: { + content: { + 'application/json': { + score: number; + seed: string; + logs: unknown[]; + gameMode: string; + gameVersion: number; + }; + }; + }; + responses: { + /** @description OK (with results) */ + 200: { + content: { + 'application/json': unknown; + }; + }; + /** @description Client error */ + 400: { + content: { + 'application/json': components['schemas']['Error']; + }; + }; + /** @description Authentication error */ + 401: { + content: { + 'application/json': components['schemas']['Error']; + }; + }; + /** @description Forbidden error */ + 403: { + content: { + 'application/json': components['schemas']['Error']; + }; + }; + /** @description I'm Ai */ + 418: { + content: { + 'application/json': components['schemas']['Error']; + }; + }; + /** @description To many requests */ + 429: { + content: { + 'application/json': components['schemas']['Error']; + }; + }; + /** @description Internal server error */ + 500: { + content: { + 'application/json': components['schemas']['Error']; + }; + }; + }; + }; + /** + * bubble-game/ranking + * @description No description provided. + * + * **Credential required**: *No* + */ + 'bubble-game/ranking': { + requestBody: { + content: { + 'application/json': { + gameMode: string; + }; + }; + }; + responses: { + /** @description OK (with results) */ + 200: { + content: { + 'application/json': { + /** Format: misskey:id */ + id: string; + score: number; + user: components['schemas']['UserLite']; + }[]; + }; + }; + /** @description Client error */ + 400: { + content: { + 'application/json': components['schemas']['Error']; + }; + }; + /** @description Authentication error */ + 401: { + content: { + 'application/json': components['schemas']['Error']; + }; + }; + /** @description Forbidden error */ + 403: { + content: { + 'application/json': components['schemas']['Error']; + }; + }; + /** @description I'm Ai */ + 418: { + content: { + 'application/json': components['schemas']['Error']; + }; + }; + /** @description Internal server error */ + 500: { + content: { + 'application/json': components['schemas']['Error']; + }; + }; + }; + }; };