From fcfb5ef0a3c2a674890e88291bb9db89c95c3a9f Mon Sep 17 00:00:00 2001 From: tamaina Date: Sun, 20 Feb 2022 13:15:40 +0900 Subject: [PATCH] Fix ajv (#8333) * wip * :v: * use ajv/dist/core * revert try * clean up --- packages/backend/src/server/api/call.ts | 4 ++-- packages/backend/src/server/api/define.ts | 4 ++-- .../src/server/api/endpoints/admin/abuse-user-reports.ts | 2 +- .../backend/src/server/api/endpoints/admin/accounts/create.ts | 2 +- .../backend/src/server/api/endpoints/admin/accounts/delete.ts | 2 +- packages/backend/src/server/api/endpoints/admin/ad/create.ts | 2 +- packages/backend/src/server/api/endpoints/admin/ad/delete.ts | 2 +- packages/backend/src/server/api/endpoints/admin/ad/list.ts | 2 +- packages/backend/src/server/api/endpoints/admin/ad/update.ts | 2 +- .../src/server/api/endpoints/admin/announcements/create.ts | 2 +- .../src/server/api/endpoints/admin/announcements/delete.ts | 2 +- .../src/server/api/endpoints/admin/announcements/list.ts | 2 +- .../src/server/api/endpoints/admin/announcements/update.ts | 2 +- .../server/api/endpoints/admin/delete-all-files-of-a-user.ts | 2 +- .../server/api/endpoints/admin/drive/clean-remote-files.ts | 2 +- .../backend/src/server/api/endpoints/admin/drive/cleanup.ts | 2 +- .../backend/src/server/api/endpoints/admin/drive/files.ts | 2 +- .../backend/src/server/api/endpoints/admin/drive/show-file.ts | 2 +- .../src/server/api/endpoints/admin/emoji/add-aliases-bulk.ts | 2 +- packages/backend/src/server/api/endpoints/admin/emoji/add.ts | 2 +- packages/backend/src/server/api/endpoints/admin/emoji/copy.ts | 2 +- .../src/server/api/endpoints/admin/emoji/delete-bulk.ts | 2 +- .../backend/src/server/api/endpoints/admin/emoji/delete.ts | 2 +- .../src/server/api/endpoints/admin/emoji/import-zip.ts | 2 +- .../src/server/api/endpoints/admin/emoji/list-remote.ts | 2 +- packages/backend/src/server/api/endpoints/admin/emoji/list.ts | 2 +- .../server/api/endpoints/admin/emoji/remove-aliases-bulk.ts | 2 +- .../src/server/api/endpoints/admin/emoji/set-aliases-bulk.ts | 2 +- .../src/server/api/endpoints/admin/emoji/set-category-bulk.ts | 2 +- .../backend/src/server/api/endpoints/admin/emoji/update.ts | 2 +- .../server/api/endpoints/admin/federation/delete-all-files.ts | 2 +- .../admin/federation/refresh-remote-instance-metadata.ts | 2 +- .../api/endpoints/admin/federation/remove-all-following.ts | 2 +- .../server/api/endpoints/admin/federation/update-instance.ts | 2 +- .../backend/src/server/api/endpoints/admin/get-index-stats.ts | 2 +- .../backend/src/server/api/endpoints/admin/get-table-stats.ts | 2 +- packages/backend/src/server/api/endpoints/admin/invite.ts | 2 +- .../backend/src/server/api/endpoints/admin/moderators/add.ts | 2 +- .../src/server/api/endpoints/admin/moderators/remove.ts | 2 +- .../backend/src/server/api/endpoints/admin/promo/create.ts | 2 +- .../backend/src/server/api/endpoints/admin/queue/clear.ts | 2 +- .../src/server/api/endpoints/admin/queue/deliver-delayed.ts | 2 +- .../src/server/api/endpoints/admin/queue/inbox-delayed.ts | 2 +- .../backend/src/server/api/endpoints/admin/queue/stats.ts | 2 +- packages/backend/src/server/api/endpoints/admin/relays/add.ts | 2 +- .../backend/src/server/api/endpoints/admin/relays/list.ts | 2 +- .../backend/src/server/api/endpoints/admin/relays/remove.ts | 2 +- .../backend/src/server/api/endpoints/admin/reset-password.ts | 2 +- .../server/api/endpoints/admin/resolve-abuse-user-report.ts | 2 +- packages/backend/src/server/api/endpoints/admin/send-email.ts | 2 +- .../backend/src/server/api/endpoints/admin/server-info.ts | 2 +- .../src/server/api/endpoints/admin/show-moderation-logs.ts | 2 +- packages/backend/src/server/api/endpoints/admin/show-user.ts | 2 +- packages/backend/src/server/api/endpoints/admin/show-users.ts | 2 +- .../backend/src/server/api/endpoints/admin/silence-user.ts | 2 +- .../backend/src/server/api/endpoints/admin/suspend-user.ts | 2 +- .../backend/src/server/api/endpoints/admin/unsilence-user.ts | 2 +- .../backend/src/server/api/endpoints/admin/unsuspend-user.ts | 2 +- .../backend/src/server/api/endpoints/admin/update-meta.ts | 2 +- packages/backend/src/server/api/endpoints/admin/vacuum.ts | 2 +- packages/backend/src/server/api/endpoints/announcements.ts | 2 +- packages/backend/src/server/api/endpoints/antennas/create.ts | 2 +- packages/backend/src/server/api/endpoints/antennas/delete.ts | 2 +- packages/backend/src/server/api/endpoints/antennas/list.ts | 2 +- packages/backend/src/server/api/endpoints/antennas/notes.ts | 2 +- packages/backend/src/server/api/endpoints/antennas/show.ts | 2 +- packages/backend/src/server/api/endpoints/antennas/update.ts | 2 +- packages/backend/src/server/api/endpoints/ap/get.ts | 2 +- packages/backend/src/server/api/endpoints/ap/show.ts | 2 +- packages/backend/src/server/api/endpoints/app/create.ts | 2 +- packages/backend/src/server/api/endpoints/app/show.ts | 2 +- packages/backend/src/server/api/endpoints/auth/accept.ts | 2 +- .../backend/src/server/api/endpoints/auth/session/generate.ts | 2 +- .../backend/src/server/api/endpoints/auth/session/show.ts | 2 +- .../backend/src/server/api/endpoints/auth/session/userkey.ts | 2 +- packages/backend/src/server/api/endpoints/blocking/create.ts | 2 +- packages/backend/src/server/api/endpoints/blocking/delete.ts | 2 +- packages/backend/src/server/api/endpoints/blocking/list.ts | 2 +- packages/backend/src/server/api/endpoints/channels/create.ts | 2 +- .../backend/src/server/api/endpoints/channels/featured.ts | 2 +- packages/backend/src/server/api/endpoints/channels/follow.ts | 2 +- .../backend/src/server/api/endpoints/channels/followed.ts | 2 +- packages/backend/src/server/api/endpoints/channels/owned.ts | 2 +- packages/backend/src/server/api/endpoints/channels/show.ts | 2 +- .../backend/src/server/api/endpoints/channels/timeline.ts | 2 +- .../backend/src/server/api/endpoints/channels/unfollow.ts | 2 +- packages/backend/src/server/api/endpoints/channels/update.ts | 2 +- .../backend/src/server/api/endpoints/charts/active-users.ts | 2 +- .../backend/src/server/api/endpoints/charts/ap-request.ts | 2 +- packages/backend/src/server/api/endpoints/charts/drive.ts | 2 +- .../backend/src/server/api/endpoints/charts/federation.ts | 2 +- packages/backend/src/server/api/endpoints/charts/hashtag.ts | 2 +- packages/backend/src/server/api/endpoints/charts/instance.ts | 2 +- packages/backend/src/server/api/endpoints/charts/notes.ts | 2 +- .../backend/src/server/api/endpoints/charts/user/drive.ts | 2 +- .../backend/src/server/api/endpoints/charts/user/following.ts | 2 +- .../backend/src/server/api/endpoints/charts/user/notes.ts | 2 +- .../backend/src/server/api/endpoints/charts/user/reactions.ts | 2 +- packages/backend/src/server/api/endpoints/charts/users.ts | 2 +- packages/backend/src/server/api/endpoints/clips/add-note.ts | 2 +- packages/backend/src/server/api/endpoints/clips/create.ts | 2 +- packages/backend/src/server/api/endpoints/clips/delete.ts | 2 +- packages/backend/src/server/api/endpoints/clips/list.ts | 2 +- packages/backend/src/server/api/endpoints/clips/notes.ts | 2 +- packages/backend/src/server/api/endpoints/clips/show.ts | 2 +- packages/backend/src/server/api/endpoints/clips/update.ts | 2 +- packages/backend/src/server/api/endpoints/drive.ts | 2 +- packages/backend/src/server/api/endpoints/drive/files.ts | 2 +- .../src/server/api/endpoints/drive/files/attached-notes.ts | 2 +- .../src/server/api/endpoints/drive/files/check-existence.ts | 2 +- .../backend/src/server/api/endpoints/drive/files/create.ts | 3 ++- .../backend/src/server/api/endpoints/drive/files/delete.ts | 2 +- .../src/server/api/endpoints/drive/files/find-by-hash.ts | 2 +- packages/backend/src/server/api/endpoints/drive/files/find.ts | 2 +- packages/backend/src/server/api/endpoints/drive/files/show.ts | 2 +- .../backend/src/server/api/endpoints/drive/files/update.ts | 2 +- .../src/server/api/endpoints/drive/files/upload-from-url.ts | 2 +- packages/backend/src/server/api/endpoints/drive/folders.ts | 2 +- .../backend/src/server/api/endpoints/drive/folders/create.ts | 2 +- .../backend/src/server/api/endpoints/drive/folders/delete.ts | 2 +- .../backend/src/server/api/endpoints/drive/folders/find.ts | 2 +- .../backend/src/server/api/endpoints/drive/folders/show.ts | 2 +- .../backend/src/server/api/endpoints/drive/folders/update.ts | 2 +- packages/backend/src/server/api/endpoints/drive/stream.ts | 2 +- .../src/server/api/endpoints/email-address/available.ts | 2 +- packages/backend/src/server/api/endpoints/endpoint.ts | 2 +- packages/backend/src/server/api/endpoints/endpoints.ts | 2 +- .../backend/src/server/api/endpoints/export-custom-emojis.ts | 2 +- .../backend/src/server/api/endpoints/federation/followers.ts | 2 +- .../backend/src/server/api/endpoints/federation/following.ts | 2 +- .../backend/src/server/api/endpoints/federation/instances.ts | 2 +- .../src/server/api/endpoints/federation/show-instance.ts | 2 +- .../src/server/api/endpoints/federation/update-remote-user.ts | 2 +- packages/backend/src/server/api/endpoints/federation/users.ts | 2 +- packages/backend/src/server/api/endpoints/following/create.ts | 2 +- packages/backend/src/server/api/endpoints/following/delete.ts | 2 +- .../backend/src/server/api/endpoints/following/invalidate.ts | 2 +- .../src/server/api/endpoints/following/requests/accept.ts | 2 +- .../src/server/api/endpoints/following/requests/cancel.ts | 2 +- .../src/server/api/endpoints/following/requests/list.ts | 2 +- .../src/server/api/endpoints/following/requests/reject.ts | 2 +- packages/backend/src/server/api/endpoints/gallery/featured.ts | 2 +- packages/backend/src/server/api/endpoints/gallery/popular.ts | 2 +- packages/backend/src/server/api/endpoints/gallery/posts.ts | 2 +- .../backend/src/server/api/endpoints/gallery/posts/create.ts | 2 +- .../backend/src/server/api/endpoints/gallery/posts/delete.ts | 2 +- .../backend/src/server/api/endpoints/gallery/posts/like.ts | 2 +- .../backend/src/server/api/endpoints/gallery/posts/show.ts | 2 +- .../backend/src/server/api/endpoints/gallery/posts/unlike.ts | 2 +- .../backend/src/server/api/endpoints/gallery/posts/update.ts | 2 +- .../src/server/api/endpoints/get-online-users-count.ts | 2 +- packages/backend/src/server/api/endpoints/hashtags/list.ts | 2 +- packages/backend/src/server/api/endpoints/hashtags/search.ts | 2 +- packages/backend/src/server/api/endpoints/hashtags/show.ts | 2 +- packages/backend/src/server/api/endpoints/hashtags/trend.ts | 2 +- packages/backend/src/server/api/endpoints/hashtags/users.ts | 2 +- packages/backend/src/server/api/endpoints/i.ts | 2 +- packages/backend/src/server/api/endpoints/i/2fa/done.ts | 2 +- packages/backend/src/server/api/endpoints/i/2fa/key-done.ts | 2 +- .../backend/src/server/api/endpoints/i/2fa/password-less.ts | 2 +- .../backend/src/server/api/endpoints/i/2fa/register-key.ts | 2 +- packages/backend/src/server/api/endpoints/i/2fa/register.ts | 2 +- packages/backend/src/server/api/endpoints/i/2fa/remove-key.ts | 2 +- packages/backend/src/server/api/endpoints/i/2fa/unregister.ts | 2 +- packages/backend/src/server/api/endpoints/i/apps.ts | 2 +- .../backend/src/server/api/endpoints/i/authorized-apps.ts | 2 +- .../backend/src/server/api/endpoints/i/change-password.ts | 2 +- packages/backend/src/server/api/endpoints/i/delete-account.ts | 2 +- .../backend/src/server/api/endpoints/i/export-blocking.ts | 2 +- .../backend/src/server/api/endpoints/i/export-following.ts | 2 +- packages/backend/src/server/api/endpoints/i/export-mute.ts | 2 +- packages/backend/src/server/api/endpoints/i/export-notes.ts | 2 +- .../backend/src/server/api/endpoints/i/export-user-lists.ts | 2 +- packages/backend/src/server/api/endpoints/i/favorites.ts | 2 +- packages/backend/src/server/api/endpoints/i/gallery/likes.ts | 2 +- packages/backend/src/server/api/endpoints/i/gallery/posts.ts | 2 +- .../src/server/api/endpoints/i/get-word-muted-notes-count.ts | 2 +- .../backend/src/server/api/endpoints/i/import-blocking.ts | 2 +- .../backend/src/server/api/endpoints/i/import-following.ts | 2 +- packages/backend/src/server/api/endpoints/i/import-muting.ts | 2 +- .../backend/src/server/api/endpoints/i/import-user-lists.ts | 2 +- packages/backend/src/server/api/endpoints/i/notifications.ts | 2 +- packages/backend/src/server/api/endpoints/i/page-likes.ts | 2 +- packages/backend/src/server/api/endpoints/i/pages.ts | 2 +- packages/backend/src/server/api/endpoints/i/pin.ts | 2 +- .../src/server/api/endpoints/i/read-all-messaging-messages.ts | 2 +- .../src/server/api/endpoints/i/read-all-unread-notes.ts | 2 +- .../backend/src/server/api/endpoints/i/read-announcement.ts | 2 +- .../backend/src/server/api/endpoints/i/regenerate-token.ts | 2 +- .../backend/src/server/api/endpoints/i/registry/get-all.ts | 2 +- .../backend/src/server/api/endpoints/i/registry/get-detail.ts | 2 +- packages/backend/src/server/api/endpoints/i/registry/get.ts | 2 +- .../src/server/api/endpoints/i/registry/keys-with-type.ts | 2 +- packages/backend/src/server/api/endpoints/i/registry/keys.ts | 2 +- .../backend/src/server/api/endpoints/i/registry/remove.ts | 2 +- .../backend/src/server/api/endpoints/i/registry/scopes.ts | 2 +- packages/backend/src/server/api/endpoints/i/registry/set.ts | 2 +- packages/backend/src/server/api/endpoints/i/revoke-token.ts | 2 +- packages/backend/src/server/api/endpoints/i/signin-history.ts | 2 +- packages/backend/src/server/api/endpoints/i/unpin.ts | 2 +- packages/backend/src/server/api/endpoints/i/update-email.ts | 2 +- packages/backend/src/server/api/endpoints/i/update.ts | 2 +- .../backend/src/server/api/endpoints/i/user-group-invites.ts | 2 +- .../backend/src/server/api/endpoints/messaging/history.ts | 2 +- .../backend/src/server/api/endpoints/messaging/messages.ts | 2 +- .../src/server/api/endpoints/messaging/messages/create.ts | 2 +- .../src/server/api/endpoints/messaging/messages/delete.ts | 2 +- .../src/server/api/endpoints/messaging/messages/read.ts | 2 +- packages/backend/src/server/api/endpoints/meta.ts | 2 +- packages/backend/src/server/api/endpoints/miauth/gen-token.ts | 2 +- packages/backend/src/server/api/endpoints/mute/create.ts | 2 +- packages/backend/src/server/api/endpoints/mute/delete.ts | 2 +- packages/backend/src/server/api/endpoints/mute/list.ts | 2 +- packages/backend/src/server/api/endpoints/my/apps.ts | 2 +- packages/backend/src/server/api/endpoints/notes.ts | 2 +- packages/backend/src/server/api/endpoints/notes/children.ts | 2 +- packages/backend/src/server/api/endpoints/notes/clips.ts | 2 +- .../backend/src/server/api/endpoints/notes/conversation.ts | 2 +- packages/backend/src/server/api/endpoints/notes/create.ts | 2 +- packages/backend/src/server/api/endpoints/notes/delete.ts | 2 +- .../src/server/api/endpoints/notes/favorites/create.ts | 2 +- .../src/server/api/endpoints/notes/favorites/delete.ts | 2 +- packages/backend/src/server/api/endpoints/notes/featured.ts | 2 +- .../backend/src/server/api/endpoints/notes/global-timeline.ts | 2 +- .../backend/src/server/api/endpoints/notes/hybrid-timeline.ts | 2 +- .../backend/src/server/api/endpoints/notes/local-timeline.ts | 2 +- packages/backend/src/server/api/endpoints/notes/mentions.ts | 2 +- .../src/server/api/endpoints/notes/polls/recommendation.ts | 2 +- packages/backend/src/server/api/endpoints/notes/polls/vote.ts | 2 +- packages/backend/src/server/api/endpoints/notes/reactions.ts | 2 +- .../src/server/api/endpoints/notes/reactions/create.ts | 2 +- .../src/server/api/endpoints/notes/reactions/delete.ts | 2 +- packages/backend/src/server/api/endpoints/notes/renotes.ts | 2 +- packages/backend/src/server/api/endpoints/notes/replies.ts | 2 +- .../backend/src/server/api/endpoints/notes/search-by-tag.ts | 2 +- packages/backend/src/server/api/endpoints/notes/search.ts | 2 +- packages/backend/src/server/api/endpoints/notes/show.ts | 2 +- packages/backend/src/server/api/endpoints/notes/state.ts | 2 +- .../src/server/api/endpoints/notes/thread-muting/create.ts | 2 +- .../src/server/api/endpoints/notes/thread-muting/delete.ts | 2 +- packages/backend/src/server/api/endpoints/notes/timeline.ts | 2 +- packages/backend/src/server/api/endpoints/notes/translate.ts | 2 +- packages/backend/src/server/api/endpoints/notes/unrenote.ts | 2 +- .../src/server/api/endpoints/notes/user-list-timeline.ts | 2 +- .../backend/src/server/api/endpoints/notes/watching/create.ts | 2 +- .../backend/src/server/api/endpoints/notes/watching/delete.ts | 2 +- .../backend/src/server/api/endpoints/notifications/create.ts | 2 +- .../server/api/endpoints/notifications/mark-all-as-read.ts | 2 +- .../backend/src/server/api/endpoints/notifications/read.ts | 2 +- packages/backend/src/server/api/endpoints/page-push.ts | 2 +- packages/backend/src/server/api/endpoints/pages/create.ts | 2 +- packages/backend/src/server/api/endpoints/pages/delete.ts | 2 +- packages/backend/src/server/api/endpoints/pages/featured.ts | 2 +- packages/backend/src/server/api/endpoints/pages/like.ts | 2 +- packages/backend/src/server/api/endpoints/pages/show.ts | 2 +- packages/backend/src/server/api/endpoints/pages/unlike.ts | 2 +- packages/backend/src/server/api/endpoints/pages/update.ts | 2 +- packages/backend/src/server/api/endpoints/ping.ts | 2 +- packages/backend/src/server/api/endpoints/pinned-users.ts | 2 +- packages/backend/src/server/api/endpoints/promo/read.ts | 2 +- .../src/server/api/endpoints/request-reset-password.ts | 2 +- packages/backend/src/server/api/endpoints/reset-db.ts | 2 +- packages/backend/src/server/api/endpoints/reset-password.ts | 2 +- packages/backend/src/server/api/endpoints/server-info.ts | 2 +- packages/backend/src/server/api/endpoints/stats.ts | 2 +- packages/backend/src/server/api/endpoints/sw/register.ts | 2 +- packages/backend/src/server/api/endpoints/sw/unregister.ts | 2 +- packages/backend/src/server/api/endpoints/test.ts | 2 +- .../backend/src/server/api/endpoints/username/available.ts | 2 +- packages/backend/src/server/api/endpoints/users.ts | 2 +- packages/backend/src/server/api/endpoints/users/clips.ts | 2 +- packages/backend/src/server/api/endpoints/users/followers.ts | 2 +- packages/backend/src/server/api/endpoints/users/following.ts | 2 +- .../backend/src/server/api/endpoints/users/gallery/posts.ts | 2 +- .../api/endpoints/users/get-frequently-replied-users.ts | 2 +- .../backend/src/server/api/endpoints/users/groups/create.ts | 2 +- .../backend/src/server/api/endpoints/users/groups/delete.ts | 2 +- .../server/api/endpoints/users/groups/invitations/accept.ts | 2 +- .../server/api/endpoints/users/groups/invitations/reject.ts | 2 +- .../backend/src/server/api/endpoints/users/groups/invite.ts | 2 +- .../backend/src/server/api/endpoints/users/groups/joined.ts | 2 +- .../backend/src/server/api/endpoints/users/groups/leave.ts | 2 +- .../backend/src/server/api/endpoints/users/groups/owned.ts | 2 +- .../backend/src/server/api/endpoints/users/groups/pull.ts | 2 +- .../backend/src/server/api/endpoints/users/groups/show.ts | 2 +- .../backend/src/server/api/endpoints/users/groups/transfer.ts | 2 +- .../backend/src/server/api/endpoints/users/groups/update.ts | 2 +- .../backend/src/server/api/endpoints/users/lists/create.ts | 2 +- .../backend/src/server/api/endpoints/users/lists/delete.ts | 2 +- packages/backend/src/server/api/endpoints/users/lists/list.ts | 2 +- packages/backend/src/server/api/endpoints/users/lists/pull.ts | 2 +- packages/backend/src/server/api/endpoints/users/lists/push.ts | 2 +- packages/backend/src/server/api/endpoints/users/lists/show.ts | 2 +- .../backend/src/server/api/endpoints/users/lists/update.ts | 2 +- packages/backend/src/server/api/endpoints/users/notes.ts | 2 +- packages/backend/src/server/api/endpoints/users/pages.ts | 2 +- packages/backend/src/server/api/endpoints/users/reactions.ts | 2 +- .../backend/src/server/api/endpoints/users/recommendation.ts | 2 +- packages/backend/src/server/api/endpoints/users/relation.ts | 2 +- .../backend/src/server/api/endpoints/users/report-abuse.ts | 2 +- .../server/api/endpoints/users/search-by-username-and-host.ts | 2 +- packages/backend/src/server/api/endpoints/users/search.ts | 2 +- packages/backend/src/server/api/endpoints/users/show.ts | 2 +- packages/backend/src/server/api/endpoints/users/stats.ts | 2 +- 304 files changed, 307 insertions(+), 306 deletions(-) diff --git a/packages/backend/src/server/api/call.ts b/packages/backend/src/server/api/call.ts index ea457d9556..e767b15417 100644 --- a/packages/backend/src/server/api/call.ts +++ b/packages/backend/src/server/api/call.ts @@ -78,8 +78,8 @@ export default async (endpoint: string, user: User | null | undefined, token: Ac } // Cast non JSON input - if (ep.meta.requireFile) { - for (const k of Object.keys(ep.params)) { + if (ep.meta.requireFile && ep.params.properties) { + for (const k of Object.keys(ep.params.properties)) { const param = ep.params.properties![k]; if (['boolean', 'number', 'integer'].includes(param.type ?? '') && typeof data[k] === 'string') { try { diff --git a/packages/backend/src/server/api/define.ts b/packages/backend/src/server/api/define.ts index 061ade17bf..83fc1e8d4f 100644 --- a/packages/backend/src/server/api/define.ts +++ b/packages/backend/src/server/api/define.ts @@ -1,5 +1,5 @@ import * as fs from 'fs'; -import * as Ajv from 'ajv'; +import Ajv from 'ajv'; import { ILocalUser } from '@/models/entities/user'; import { IEndpointMeta } from './endpoints'; import { ApiError } from './error'; @@ -65,6 +65,6 @@ export default function (meta: T, pa return Promise.reject(err); } - return cb(params, user, token, file, cleanup); + return cb(params as SchemaType, user, token, file, cleanup); }; } diff --git a/packages/backend/src/server/api/endpoints/admin/abuse-user-reports.ts b/packages/backend/src/server/api/endpoints/admin/abuse-user-reports.ts index 97b7bc7dba..6ab9c87e3c 100644 --- a/packages/backend/src/server/api/endpoints/admin/abuse-user-reports.ts +++ b/packages/backend/src/server/api/endpoints/admin/abuse-user-reports.ts @@ -70,7 +70,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/admin/accounts/create.ts b/packages/backend/src/server/api/endpoints/admin/accounts/create.ts index 50b2eb0427..421726d60f 100644 --- a/packages/backend/src/server/api/endpoints/admin/accounts/create.ts +++ b/packages/backend/src/server/api/endpoints/admin/accounts/create.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { username: Users.localUsernameSchema, diff --git a/packages/backend/src/server/api/endpoints/admin/accounts/delete.ts b/packages/backend/src/server/api/endpoints/admin/accounts/delete.ts index 99d61b2f32..cf48a906f0 100644 --- a/packages/backend/src/server/api/endpoints/admin/accounts/delete.ts +++ b/packages/backend/src/server/api/endpoints/admin/accounts/delete.ts @@ -11,7 +11,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/ad/create.ts b/packages/backend/src/server/api/endpoints/admin/ad/create.ts index 9883efefe7..c1efaf6314 100644 --- a/packages/backend/src/server/api/endpoints/admin/ad/create.ts +++ b/packages/backend/src/server/api/endpoints/admin/ad/create.ts @@ -9,7 +9,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { url: { type: 'string', minLength: 1 }, diff --git a/packages/backend/src/server/api/endpoints/admin/ad/delete.ts b/packages/backend/src/server/api/endpoints/admin/ad/delete.ts index dfd873f016..1b9607b5aa 100644 --- a/packages/backend/src/server/api/endpoints/admin/ad/delete.ts +++ b/packages/backend/src/server/api/endpoints/admin/ad/delete.ts @@ -17,7 +17,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { id: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/ad/list.ts b/packages/backend/src/server/api/endpoints/admin/ad/list.ts index 83fdedef77..5b72f72937 100644 --- a/packages/backend/src/server/api/endpoints/admin/ad/list.ts +++ b/packages/backend/src/server/api/endpoints/admin/ad/list.ts @@ -9,7 +9,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/admin/ad/update.ts b/packages/backend/src/server/api/endpoints/admin/ad/update.ts index bf4bce5150..93902e79c1 100644 --- a/packages/backend/src/server/api/endpoints/admin/ad/update.ts +++ b/packages/backend/src/server/api/endpoints/admin/ad/update.ts @@ -17,7 +17,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { id: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/announcements/create.ts b/packages/backend/src/server/api/endpoints/admin/announcements/create.ts index 295d99513d..884dd5e280 100644 --- a/packages/backend/src/server/api/endpoints/admin/announcements/create.ts +++ b/packages/backend/src/server/api/endpoints/admin/announcements/create.ts @@ -44,7 +44,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { title: { type: 'string', minLength: 1 }, diff --git a/packages/backend/src/server/api/endpoints/admin/announcements/delete.ts b/packages/backend/src/server/api/endpoints/admin/announcements/delete.ts index f0141ca595..c09307193f 100644 --- a/packages/backend/src/server/api/endpoints/admin/announcements/delete.ts +++ b/packages/backend/src/server/api/endpoints/admin/announcements/delete.ts @@ -17,7 +17,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { id: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/announcements/list.ts b/packages/backend/src/server/api/endpoints/admin/announcements/list.ts index 993f9877d2..af48925ec1 100644 --- a/packages/backend/src/server/api/endpoints/admin/announcements/list.ts +++ b/packages/backend/src/server/api/endpoints/admin/announcements/list.ts @@ -52,7 +52,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/admin/announcements/update.ts b/packages/backend/src/server/api/endpoints/admin/announcements/update.ts index f905616b3e..fb4d5e95ba 100644 --- a/packages/backend/src/server/api/endpoints/admin/announcements/update.ts +++ b/packages/backend/src/server/api/endpoints/admin/announcements/update.ts @@ -17,7 +17,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { id: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/delete-all-files-of-a-user.ts b/packages/backend/src/server/api/endpoints/admin/delete-all-files-of-a-user.ts index 41e2c23488..dde84ae45e 100644 --- a/packages/backend/src/server/api/endpoints/admin/delete-all-files-of-a-user.ts +++ b/packages/backend/src/server/api/endpoints/admin/delete-all-files-of-a-user.ts @@ -9,7 +9,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/drive/clean-remote-files.ts b/packages/backend/src/server/api/endpoints/admin/drive/clean-remote-files.ts index 9b127eb5d3..c42b5caac2 100644 --- a/packages/backend/src/server/api/endpoints/admin/drive/clean-remote-files.ts +++ b/packages/backend/src/server/api/endpoints/admin/drive/clean-remote-files.ts @@ -8,7 +8,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/admin/drive/cleanup.ts b/packages/backend/src/server/api/endpoints/admin/drive/cleanup.ts index 1c63af6a17..a7ce154cf2 100644 --- a/packages/backend/src/server/api/endpoints/admin/drive/cleanup.ts +++ b/packages/backend/src/server/api/endpoints/admin/drive/cleanup.ts @@ -10,7 +10,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/admin/drive/files.ts b/packages/backend/src/server/api/endpoints/admin/drive/files.ts index 56a8c1c642..0b5544ce28 100644 --- a/packages/backend/src/server/api/endpoints/admin/drive/files.ts +++ b/packages/backend/src/server/api/endpoints/admin/drive/files.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/admin/drive/show-file.ts b/packages/backend/src/server/api/endpoints/admin/drive/show-file.ts index bb1ed1072a..efd4a8e4aa 100644 --- a/packages/backend/src/server/api/endpoints/admin/drive/show-file.ts +++ b/packages/backend/src/server/api/endpoints/admin/drive/show-file.ts @@ -149,7 +149,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { fileId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/emoji/add-aliases-bulk.ts b/packages/backend/src/server/api/endpoints/admin/emoji/add-aliases-bulk.ts index 9aeb04d247..4ddea09b1c 100644 --- a/packages/backend/src/server/api/endpoints/admin/emoji/add-aliases-bulk.ts +++ b/packages/backend/src/server/api/endpoints/admin/emoji/add-aliases-bulk.ts @@ -10,7 +10,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { ids: { type: 'array', items: { diff --git a/packages/backend/src/server/api/endpoints/admin/emoji/add.ts b/packages/backend/src/server/api/endpoints/admin/emoji/add.ts index 718ecae4b1..2ca3aade99 100644 --- a/packages/backend/src/server/api/endpoints/admin/emoji/add.ts +++ b/packages/backend/src/server/api/endpoints/admin/emoji/add.ts @@ -22,7 +22,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { fileId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/emoji/copy.ts b/packages/backend/src/server/api/endpoints/admin/emoji/copy.ts index fc20ff0a84..f2dc11f664 100644 --- a/packages/backend/src/server/api/endpoints/admin/emoji/copy.ts +++ b/packages/backend/src/server/api/endpoints/admin/emoji/copy.ts @@ -34,7 +34,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { emojiId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/emoji/delete-bulk.ts b/packages/backend/src/server/api/endpoints/admin/emoji/delete-bulk.ts index 792e72ff97..d35ef660e4 100644 --- a/packages/backend/src/server/api/endpoints/admin/emoji/delete-bulk.ts +++ b/packages/backend/src/server/api/endpoints/admin/emoji/delete-bulk.ts @@ -11,7 +11,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { ids: { type: 'array', items: { diff --git a/packages/backend/src/server/api/endpoints/admin/emoji/delete.ts b/packages/backend/src/server/api/endpoints/admin/emoji/delete.ts index 15d44b3a0e..2dabd60a0f 100644 --- a/packages/backend/src/server/api/endpoints/admin/emoji/delete.ts +++ b/packages/backend/src/server/api/endpoints/admin/emoji/delete.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { id: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/emoji/import-zip.ts b/packages/backend/src/server/api/endpoints/admin/emoji/import-zip.ts index 5ee6dd4c8d..98d8d4fef9 100644 --- a/packages/backend/src/server/api/endpoints/admin/emoji/import-zip.ts +++ b/packages/backend/src/server/api/endpoints/admin/emoji/import-zip.ts @@ -8,7 +8,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { fileId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/emoji/list-remote.ts b/packages/backend/src/server/api/endpoints/admin/emoji/list-remote.ts index 865715968a..e519f64ff0 100644 --- a/packages/backend/src/server/api/endpoints/admin/emoji/list-remote.ts +++ b/packages/backend/src/server/api/endpoints/admin/emoji/list-remote.ts @@ -50,7 +50,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { query: { type: 'string', nullable: true, default: null }, diff --git a/packages/backend/src/server/api/endpoints/admin/emoji/list.ts b/packages/backend/src/server/api/endpoints/admin/emoji/list.ts index 0e23132d99..8e26da3d64 100644 --- a/packages/backend/src/server/api/endpoints/admin/emoji/list.ts +++ b/packages/backend/src/server/api/endpoints/admin/emoji/list.ts @@ -50,7 +50,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { query: { type: 'string', nullable: true, default: null }, diff --git a/packages/backend/src/server/api/endpoints/admin/emoji/remove-aliases-bulk.ts b/packages/backend/src/server/api/endpoints/admin/emoji/remove-aliases-bulk.ts index e6ccbf684d..e619053e58 100644 --- a/packages/backend/src/server/api/endpoints/admin/emoji/remove-aliases-bulk.ts +++ b/packages/backend/src/server/api/endpoints/admin/emoji/remove-aliases-bulk.ts @@ -10,7 +10,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { ids: { type: 'array', items: { diff --git a/packages/backend/src/server/api/endpoints/admin/emoji/set-aliases-bulk.ts b/packages/backend/src/server/api/endpoints/admin/emoji/set-aliases-bulk.ts index 30a1c28af6..dff90193e7 100644 --- a/packages/backend/src/server/api/endpoints/admin/emoji/set-aliases-bulk.ts +++ b/packages/backend/src/server/api/endpoints/admin/emoji/set-aliases-bulk.ts @@ -10,7 +10,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { ids: { type: 'array', items: { diff --git a/packages/backend/src/server/api/endpoints/admin/emoji/set-category-bulk.ts b/packages/backend/src/server/api/endpoints/admin/emoji/set-category-bulk.ts index 9679e4a369..462e7a742c 100644 --- a/packages/backend/src/server/api/endpoints/admin/emoji/set-category-bulk.ts +++ b/packages/backend/src/server/api/endpoints/admin/emoji/set-category-bulk.ts @@ -10,7 +10,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { ids: { type: 'array', items: { diff --git a/packages/backend/src/server/api/endpoints/admin/emoji/update.ts b/packages/backend/src/server/api/endpoints/admin/emoji/update.ts index da5a5f005e..870d568311 100644 --- a/packages/backend/src/server/api/endpoints/admin/emoji/update.ts +++ b/packages/backend/src/server/api/endpoints/admin/emoji/update.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { id: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/federation/delete-all-files.ts b/packages/backend/src/server/api/endpoints/admin/federation/delete-all-files.ts index e98de40ff8..71c1c41cf6 100644 --- a/packages/backend/src/server/api/endpoints/admin/federation/delete-all-files.ts +++ b/packages/backend/src/server/api/endpoints/admin/federation/delete-all-files.ts @@ -9,7 +9,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { host: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/admin/federation/refresh-remote-instance-metadata.ts b/packages/backend/src/server/api/endpoints/admin/federation/refresh-remote-instance-metadata.ts index d6e3a15c61..df73453f78 100644 --- a/packages/backend/src/server/api/endpoints/admin/federation/refresh-remote-instance-metadata.ts +++ b/packages/backend/src/server/api/endpoints/admin/federation/refresh-remote-instance-metadata.ts @@ -10,7 +10,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { host: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/admin/federation/remove-all-following.ts b/packages/backend/src/server/api/endpoints/admin/federation/remove-all-following.ts index 7c2d6dc391..0ae58de534 100644 --- a/packages/backend/src/server/api/endpoints/admin/federation/remove-all-following.ts +++ b/packages/backend/src/server/api/endpoints/admin/federation/remove-all-following.ts @@ -9,7 +9,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { host: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/admin/federation/update-instance.ts b/packages/backend/src/server/api/endpoints/admin/federation/update-instance.ts index 04cad3b9f7..9a3c35d055 100644 --- a/packages/backend/src/server/api/endpoints/admin/federation/update-instance.ts +++ b/packages/backend/src/server/api/endpoints/admin/federation/update-instance.ts @@ -9,7 +9,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { host: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/admin/get-index-stats.ts b/packages/backend/src/server/api/endpoints/admin/get-index-stats.ts index 9379379aef..17ce1bfce9 100644 --- a/packages/backend/src/server/api/endpoints/admin/get-index-stats.ts +++ b/packages/backend/src/server/api/endpoints/admin/get-index-stats.ts @@ -8,7 +8,7 @@ export const meta = { tags: ['admin'], } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/admin/get-table-stats.ts b/packages/backend/src/server/api/endpoints/admin/get-table-stats.ts index 28856cd41c..e980ca96ef 100644 --- a/packages/backend/src/server/api/endpoints/admin/get-table-stats.ts +++ b/packages/backend/src/server/api/endpoints/admin/get-table-stats.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/admin/invite.ts b/packages/backend/src/server/api/endpoints/admin/invite.ts index a21777937c..45392f85c7 100644 --- a/packages/backend/src/server/api/endpoints/admin/invite.ts +++ b/packages/backend/src/server/api/endpoints/admin/invite.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/admin/moderators/add.ts b/packages/backend/src/server/api/endpoints/admin/moderators/add.ts index 6b7e549c35..3bf66f3c86 100644 --- a/packages/backend/src/server/api/endpoints/admin/moderators/add.ts +++ b/packages/backend/src/server/api/endpoints/admin/moderators/add.ts @@ -8,7 +8,7 @@ export const meta = { requireAdmin: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/moderators/remove.ts b/packages/backend/src/server/api/endpoints/admin/moderators/remove.ts index 585d6fbfa7..e2e96de3c1 100644 --- a/packages/backend/src/server/api/endpoints/admin/moderators/remove.ts +++ b/packages/backend/src/server/api/endpoints/admin/moderators/remove.ts @@ -8,7 +8,7 @@ export const meta = { requireAdmin: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/promo/create.ts b/packages/backend/src/server/api/endpoints/admin/promo/create.ts index 16f522729b..4f714c579c 100644 --- a/packages/backend/src/server/api/endpoints/admin/promo/create.ts +++ b/packages/backend/src/server/api/endpoints/admin/promo/create.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/queue/clear.ts b/packages/backend/src/server/api/endpoints/admin/queue/clear.ts index 27bb9cc858..fd1dba8e50 100644 --- a/packages/backend/src/server/api/endpoints/admin/queue/clear.ts +++ b/packages/backend/src/server/api/endpoints/admin/queue/clear.ts @@ -9,7 +9,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/admin/queue/deliver-delayed.ts b/packages/backend/src/server/api/endpoints/admin/queue/deliver-delayed.ts index 38eac5a135..080a7da04f 100644 --- a/packages/backend/src/server/api/endpoints/admin/queue/deliver-delayed.ts +++ b/packages/backend/src/server/api/endpoints/admin/queue/deliver-delayed.ts @@ -32,7 +32,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/admin/queue/inbox-delayed.ts b/packages/backend/src/server/api/endpoints/admin/queue/inbox-delayed.ts index 9669cfd3b8..c452b620ec 100644 --- a/packages/backend/src/server/api/endpoints/admin/queue/inbox-delayed.ts +++ b/packages/backend/src/server/api/endpoints/admin/queue/inbox-delayed.ts @@ -32,7 +32,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/admin/queue/stats.ts b/packages/backend/src/server/api/endpoints/admin/queue/stats.ts index 3f7e6be5fb..6b883aebee 100644 --- a/packages/backend/src/server/api/endpoints/admin/queue/stats.ts +++ b/packages/backend/src/server/api/endpoints/admin/queue/stats.ts @@ -31,7 +31,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/admin/relays/add.ts b/packages/backend/src/server/api/endpoints/admin/relays/add.ts index ecf77b87df..e8eb249f93 100644 --- a/packages/backend/src/server/api/endpoints/admin/relays/add.ts +++ b/packages/backend/src/server/api/endpoints/admin/relays/add.ts @@ -45,7 +45,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { inbox: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/admin/relays/list.ts b/packages/backend/src/server/api/endpoints/admin/relays/list.ts index 6cdaa418a7..da2c32ce4f 100644 --- a/packages/backend/src/server/api/endpoints/admin/relays/list.ts +++ b/packages/backend/src/server/api/endpoints/admin/relays/list.ts @@ -39,7 +39,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/admin/relays/remove.ts b/packages/backend/src/server/api/endpoints/admin/relays/remove.ts index d452c2e6a5..26a16284db 100644 --- a/packages/backend/src/server/api/endpoints/admin/relays/remove.ts +++ b/packages/backend/src/server/api/endpoints/admin/relays/remove.ts @@ -8,7 +8,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { inbox: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/admin/reset-password.ts b/packages/backend/src/server/api/endpoints/admin/reset-password.ts index 87424782c5..5036d76d1f 100644 --- a/packages/backend/src/server/api/endpoints/admin/reset-password.ts +++ b/packages/backend/src/server/api/endpoints/admin/reset-password.ts @@ -23,7 +23,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/resolve-abuse-user-report.ts b/packages/backend/src/server/api/endpoints/admin/resolve-abuse-user-report.ts index 4139f77614..ec8b56083c 100644 --- a/packages/backend/src/server/api/endpoints/admin/resolve-abuse-user-report.ts +++ b/packages/backend/src/server/api/endpoints/admin/resolve-abuse-user-report.ts @@ -12,7 +12,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { reportId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/send-email.ts b/packages/backend/src/server/api/endpoints/admin/send-email.ts index 2ebe7e0bc9..819ff8fd03 100644 --- a/packages/backend/src/server/api/endpoints/admin/send-email.ts +++ b/packages/backend/src/server/api/endpoints/admin/send-email.ts @@ -8,7 +8,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { to: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/admin/server-info.ts b/packages/backend/src/server/api/endpoints/admin/server-info.ts index 44e069d603..ece9bff53e 100644 --- a/packages/backend/src/server/api/endpoints/admin/server-info.ts +++ b/packages/backend/src/server/api/endpoints/admin/server-info.ts @@ -87,7 +87,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/admin/show-moderation-logs.ts b/packages/backend/src/server/api/endpoints/admin/show-moderation-logs.ts index c08acaeca9..1688a1fc53 100644 --- a/packages/backend/src/server/api/endpoints/admin/show-moderation-logs.ts +++ b/packages/backend/src/server/api/endpoints/admin/show-moderation-logs.ts @@ -48,7 +48,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/admin/show-user.ts b/packages/backend/src/server/api/endpoints/admin/show-user.ts index b883aff494..46b6609869 100644 --- a/packages/backend/src/server/api/endpoints/admin/show-user.ts +++ b/packages/backend/src/server/api/endpoints/admin/show-user.ts @@ -13,7 +13,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/show-users.ts b/packages/backend/src/server/api/endpoints/admin/show-users.ts index c373021d0e..bc4b319e17 100644 --- a/packages/backend/src/server/api/endpoints/admin/show-users.ts +++ b/packages/backend/src/server/api/endpoints/admin/show-users.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/admin/silence-user.ts b/packages/backend/src/server/api/endpoints/admin/silence-user.ts index df547184ad..54ef60f7fe 100644 --- a/packages/backend/src/server/api/endpoints/admin/silence-user.ts +++ b/packages/backend/src/server/api/endpoints/admin/silence-user.ts @@ -9,7 +9,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/suspend-user.ts b/packages/backend/src/server/api/endpoints/admin/suspend-user.ts index 31867a4055..c2f3d72438 100644 --- a/packages/backend/src/server/api/endpoints/admin/suspend-user.ts +++ b/packages/backend/src/server/api/endpoints/admin/suspend-user.ts @@ -13,7 +13,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/unsilence-user.ts b/packages/backend/src/server/api/endpoints/admin/unsilence-user.ts index 42c7e776a8..ddda5f48ab 100644 --- a/packages/backend/src/server/api/endpoints/admin/unsilence-user.ts +++ b/packages/backend/src/server/api/endpoints/admin/unsilence-user.ts @@ -9,7 +9,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/unsuspend-user.ts b/packages/backend/src/server/api/endpoints/admin/unsuspend-user.ts index 011f485277..25a8f1a00a 100644 --- a/packages/backend/src/server/api/endpoints/admin/unsuspend-user.ts +++ b/packages/backend/src/server/api/endpoints/admin/unsuspend-user.ts @@ -10,7 +10,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/admin/update-meta.ts b/packages/backend/src/server/api/endpoints/admin/update-meta.ts index b845eb4d5b..ecede8a049 100644 --- a/packages/backend/src/server/api/endpoints/admin/update-meta.ts +++ b/packages/backend/src/server/api/endpoints/admin/update-meta.ts @@ -11,7 +11,7 @@ export const meta = { requireAdmin: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { disableRegistration: { type: 'boolean', nullable: true }, diff --git a/packages/backend/src/server/api/endpoints/admin/vacuum.ts b/packages/backend/src/server/api/endpoints/admin/vacuum.ts index 07a4517bd4..8ce352bffd 100644 --- a/packages/backend/src/server/api/endpoints/admin/vacuum.ts +++ b/packages/backend/src/server/api/endpoints/admin/vacuum.ts @@ -9,7 +9,7 @@ export const meta = { requireModerator: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { full: { type: 'boolean' }, diff --git a/packages/backend/src/server/api/endpoints/announcements.ts b/packages/backend/src/server/api/endpoints/announcements.ts index bea3a287fc..78a924fe5e 100644 --- a/packages/backend/src/server/api/endpoints/announcements.ts +++ b/packages/backend/src/server/api/endpoints/announcements.ts @@ -51,7 +51,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/antennas/create.ts b/packages/backend/src/server/api/endpoints/antennas/create.ts index 16ba065b9d..272ebddd4b 100644 --- a/packages/backend/src/server/api/endpoints/antennas/create.ts +++ b/packages/backend/src/server/api/endpoints/antennas/create.ts @@ -32,7 +32,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { name: { type: 'string', minLength: 1, maxLength: 100 }, diff --git a/packages/backend/src/server/api/endpoints/antennas/delete.ts b/packages/backend/src/server/api/endpoints/antennas/delete.ts index c140084778..247d4af16c 100644 --- a/packages/backend/src/server/api/endpoints/antennas/delete.ts +++ b/packages/backend/src/server/api/endpoints/antennas/delete.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { antennaId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/antennas/list.ts b/packages/backend/src/server/api/endpoints/antennas/list.ts index 6910c07291..59d75d80f5 100644 --- a/packages/backend/src/server/api/endpoints/antennas/list.ts +++ b/packages/backend/src/server/api/endpoints/antennas/list.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/antennas/notes.ts b/packages/backend/src/server/api/endpoints/antennas/notes.ts index 283c01c2c7..74f0d8d88f 100644 --- a/packages/backend/src/server/api/endpoints/antennas/notes.ts +++ b/packages/backend/src/server/api/endpoints/antennas/notes.ts @@ -33,7 +33,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { antennaId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/antennas/show.ts b/packages/backend/src/server/api/endpoints/antennas/show.ts index d8c08f2777..8428844c15 100644 --- a/packages/backend/src/server/api/endpoints/antennas/show.ts +++ b/packages/backend/src/server/api/endpoints/antennas/show.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { antennaId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/antennas/update.ts b/packages/backend/src/server/api/endpoints/antennas/update.ts index 9f8564c2c0..0b8e864b4d 100644 --- a/packages/backend/src/server/api/endpoints/antennas/update.ts +++ b/packages/backend/src/server/api/endpoints/antennas/update.ts @@ -37,7 +37,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { antennaId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/ap/get.ts b/packages/backend/src/server/api/endpoints/ap/get.ts index c62ca6088b..a60ff00ecd 100644 --- a/packages/backend/src/server/api/endpoints/ap/get.ts +++ b/packages/backend/src/server/api/endpoints/ap/get.ts @@ -22,7 +22,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { uri: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/ap/show.ts b/packages/backend/src/server/api/endpoints/ap/show.ts index e0b53403bb..8f71e84a15 100644 --- a/packages/backend/src/server/api/endpoints/ap/show.ts +++ b/packages/backend/src/server/api/endpoints/ap/show.ts @@ -68,7 +68,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { uri: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/app/create.ts b/packages/backend/src/server/api/endpoints/app/create.ts index 0f9610d2a9..6e8d2b2abd 100644 --- a/packages/backend/src/server/api/endpoints/app/create.ts +++ b/packages/backend/src/server/api/endpoints/app/create.ts @@ -16,7 +16,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { name: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/app/show.ts b/packages/backend/src/server/api/endpoints/app/show.ts index 0ca7fcc2a8..6d75294e84 100644 --- a/packages/backend/src/server/api/endpoints/app/show.ts +++ b/packages/backend/src/server/api/endpoints/app/show.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { appId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/auth/accept.ts b/packages/backend/src/server/api/endpoints/auth/accept.ts index 4429119b1f..775c26818b 100644 --- a/packages/backend/src/server/api/endpoints/auth/accept.ts +++ b/packages/backend/src/server/api/endpoints/auth/accept.ts @@ -21,7 +21,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { token: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/auth/session/generate.ts b/packages/backend/src/server/api/endpoints/auth/session/generate.ts index 8d5c14e2f7..ba0356431f 100644 --- a/packages/backend/src/server/api/endpoints/auth/session/generate.ts +++ b/packages/backend/src/server/api/endpoints/auth/session/generate.ts @@ -35,7 +35,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { appSecret: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/auth/session/show.ts b/packages/backend/src/server/api/endpoints/auth/session/show.ts index dfc1c06ee6..701cc9237d 100644 --- a/packages/backend/src/server/api/endpoints/auth/session/show.ts +++ b/packages/backend/src/server/api/endpoints/auth/session/show.ts @@ -37,7 +37,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { token: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/auth/session/userkey.ts b/packages/backend/src/server/api/endpoints/auth/session/userkey.ts index 397d1e687b..fa04610ce0 100644 --- a/packages/backend/src/server/api/endpoints/auth/session/userkey.ts +++ b/packages/backend/src/server/api/endpoints/auth/session/userkey.ts @@ -45,7 +45,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { appSecret: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/blocking/create.ts b/packages/backend/src/server/api/endpoints/blocking/create.ts index 8fd8f33338..cf09ca00ba 100644 --- a/packages/backend/src/server/api/endpoints/blocking/create.ts +++ b/packages/backend/src/server/api/endpoints/blocking/create.ts @@ -44,7 +44,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/blocking/delete.ts b/packages/backend/src/server/api/endpoints/blocking/delete.ts index ad00fd1e0b..6e9fead113 100644 --- a/packages/backend/src/server/api/endpoints/blocking/delete.ts +++ b/packages/backend/src/server/api/endpoints/blocking/delete.ts @@ -44,7 +44,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/blocking/list.ts b/packages/backend/src/server/api/endpoints/blocking/list.ts index a315ccde9e..bbae0fe661 100644 --- a/packages/backend/src/server/api/endpoints/blocking/list.ts +++ b/packages/backend/src/server/api/endpoints/blocking/list.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 30 }, diff --git a/packages/backend/src/server/api/endpoints/channels/create.ts b/packages/backend/src/server/api/endpoints/channels/create.ts index dc7afadfa2..0491f7638f 100644 --- a/packages/backend/src/server/api/endpoints/channels/create.ts +++ b/packages/backend/src/server/api/endpoints/channels/create.ts @@ -26,7 +26,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { name: { type: 'string', minLength: 1, maxLength: 128 }, diff --git a/packages/backend/src/server/api/endpoints/channels/featured.ts b/packages/backend/src/server/api/endpoints/channels/featured.ts index 4d07e720a9..c1e4ba2dec 100644 --- a/packages/backend/src/server/api/endpoints/channels/featured.ts +++ b/packages/backend/src/server/api/endpoints/channels/featured.ts @@ -17,7 +17,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/channels/follow.ts b/packages/backend/src/server/api/endpoints/channels/follow.ts index 01156d1c2c..c831db4b8c 100644 --- a/packages/backend/src/server/api/endpoints/channels/follow.ts +++ b/packages/backend/src/server/api/endpoints/channels/follow.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { channelId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/channels/followed.ts b/packages/backend/src/server/api/endpoints/channels/followed.ts index 0e75f06f47..79b12514ff 100644 --- a/packages/backend/src/server/api/endpoints/channels/followed.ts +++ b/packages/backend/src/server/api/endpoints/channels/followed.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { sinceId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/channels/owned.ts b/packages/backend/src/server/api/endpoints/channels/owned.ts index f8acae836b..c4c250fab1 100644 --- a/packages/backend/src/server/api/endpoints/channels/owned.ts +++ b/packages/backend/src/server/api/endpoints/channels/owned.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { sinceId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/channels/show.ts b/packages/backend/src/server/api/endpoints/channels/show.ts index fb2c7b5adf..48d9fe29c1 100644 --- a/packages/backend/src/server/api/endpoints/channels/show.ts +++ b/packages/backend/src/server/api/endpoints/channels/show.ts @@ -22,7 +22,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { channelId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/channels/timeline.ts b/packages/backend/src/server/api/endpoints/channels/timeline.ts index a870ecccbb..6f35fd966c 100644 --- a/packages/backend/src/server/api/endpoints/channels/timeline.ts +++ b/packages/backend/src/server/api/endpoints/channels/timeline.ts @@ -28,7 +28,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { channelId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/channels/unfollow.ts b/packages/backend/src/server/api/endpoints/channels/unfollow.ts index 42a0eb0a5a..e6524bf555 100644 --- a/packages/backend/src/server/api/endpoints/channels/unfollow.ts +++ b/packages/backend/src/server/api/endpoints/channels/unfollow.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { channelId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/channels/update.ts b/packages/backend/src/server/api/endpoints/channels/update.ts index 5a593c62e0..3ee36d97ec 100644 --- a/packages/backend/src/server/api/endpoints/channels/update.ts +++ b/packages/backend/src/server/api/endpoints/channels/update.ts @@ -36,7 +36,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { channelId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/charts/active-users.ts b/packages/backend/src/server/api/endpoints/charts/active-users.ts index a99269da0c..dcb155b937 100644 --- a/packages/backend/src/server/api/endpoints/charts/active-users.ts +++ b/packages/backend/src/server/api/endpoints/charts/active-users.ts @@ -8,7 +8,7 @@ export const meta = { res: getJsonSchema(activeUsersChart.schema), } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { span: { type: 'string', enum: ['day', 'hour'] }, diff --git a/packages/backend/src/server/api/endpoints/charts/ap-request.ts b/packages/backend/src/server/api/endpoints/charts/ap-request.ts index 403a933807..cb8046236a 100644 --- a/packages/backend/src/server/api/endpoints/charts/ap-request.ts +++ b/packages/backend/src/server/api/endpoints/charts/ap-request.ts @@ -8,7 +8,7 @@ export const meta = { res: getJsonSchema(apRequestChart.schema), } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { span: { type: 'string', enum: ['day', 'hour'] }, diff --git a/packages/backend/src/server/api/endpoints/charts/drive.ts b/packages/backend/src/server/api/endpoints/charts/drive.ts index 2c815367f6..35ec62e671 100644 --- a/packages/backend/src/server/api/endpoints/charts/drive.ts +++ b/packages/backend/src/server/api/endpoints/charts/drive.ts @@ -8,7 +8,7 @@ export const meta = { res: getJsonSchema(driveChart.schema), } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { span: { type: 'string', enum: ['day', 'hour'] }, diff --git a/packages/backend/src/server/api/endpoints/charts/federation.ts b/packages/backend/src/server/api/endpoints/charts/federation.ts index c48613ffac..07492cf6c2 100644 --- a/packages/backend/src/server/api/endpoints/charts/federation.ts +++ b/packages/backend/src/server/api/endpoints/charts/federation.ts @@ -8,7 +8,7 @@ export const meta = { res: getJsonSchema(federationChart.schema), } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { span: { type: 'string', enum: ['day', 'hour'] }, diff --git a/packages/backend/src/server/api/endpoints/charts/hashtag.ts b/packages/backend/src/server/api/endpoints/charts/hashtag.ts index 3cb0784ba4..537bb45bf1 100644 --- a/packages/backend/src/server/api/endpoints/charts/hashtag.ts +++ b/packages/backend/src/server/api/endpoints/charts/hashtag.ts @@ -8,7 +8,7 @@ export const meta = { res: getJsonSchema(hashtagChart.schema), } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { span: { type: 'string', enum: ['day', 'hour'] }, diff --git a/packages/backend/src/server/api/endpoints/charts/instance.ts b/packages/backend/src/server/api/endpoints/charts/instance.ts index 2da3cd3c3a..cd5c044ad9 100644 --- a/packages/backend/src/server/api/endpoints/charts/instance.ts +++ b/packages/backend/src/server/api/endpoints/charts/instance.ts @@ -8,7 +8,7 @@ export const meta = { res: getJsonSchema(instanceChart.schema), } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { span: { type: 'string', enum: ['day', 'hour'] }, diff --git a/packages/backend/src/server/api/endpoints/charts/notes.ts b/packages/backend/src/server/api/endpoints/charts/notes.ts index c48bc67e1c..b30f0894c2 100644 --- a/packages/backend/src/server/api/endpoints/charts/notes.ts +++ b/packages/backend/src/server/api/endpoints/charts/notes.ts @@ -8,7 +8,7 @@ export const meta = { res: getJsonSchema(notesChart.schema), } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { span: { type: 'string', enum: ['day', 'hour'] }, diff --git a/packages/backend/src/server/api/endpoints/charts/user/drive.ts b/packages/backend/src/server/api/endpoints/charts/user/drive.ts index 62f7afa435..cc1aac5fea 100644 --- a/packages/backend/src/server/api/endpoints/charts/user/drive.ts +++ b/packages/backend/src/server/api/endpoints/charts/user/drive.ts @@ -8,7 +8,7 @@ export const meta = { res: getJsonSchema(perUserDriveChart.schema), } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { span: { type: 'string', enum: ['day', 'hour'] }, diff --git a/packages/backend/src/server/api/endpoints/charts/user/following.ts b/packages/backend/src/server/api/endpoints/charts/user/following.ts index d6d2d5e3ee..1b68bdca1c 100644 --- a/packages/backend/src/server/api/endpoints/charts/user/following.ts +++ b/packages/backend/src/server/api/endpoints/charts/user/following.ts @@ -8,7 +8,7 @@ export const meta = { res: getJsonSchema(perUserFollowingChart.schema), } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { span: { type: 'string', enum: ['day', 'hour'] }, diff --git a/packages/backend/src/server/api/endpoints/charts/user/notes.ts b/packages/backend/src/server/api/endpoints/charts/user/notes.ts index becde8b1df..55e6368187 100644 --- a/packages/backend/src/server/api/endpoints/charts/user/notes.ts +++ b/packages/backend/src/server/api/endpoints/charts/user/notes.ts @@ -8,7 +8,7 @@ export const meta = { res: getJsonSchema(perUserNotesChart.schema), } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { span: { type: 'string', enum: ['day', 'hour'] }, diff --git a/packages/backend/src/server/api/endpoints/charts/user/reactions.ts b/packages/backend/src/server/api/endpoints/charts/user/reactions.ts index 8f4d9a812a..f72424d2cf 100644 --- a/packages/backend/src/server/api/endpoints/charts/user/reactions.ts +++ b/packages/backend/src/server/api/endpoints/charts/user/reactions.ts @@ -8,7 +8,7 @@ export const meta = { res: getJsonSchema(perUserReactionsChart.schema), } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { span: { type: 'string', enum: ['day', 'hour'] }, diff --git a/packages/backend/src/server/api/endpoints/charts/users.ts b/packages/backend/src/server/api/endpoints/charts/users.ts index 855fc6cd07..2dfdfefd78 100644 --- a/packages/backend/src/server/api/endpoints/charts/users.ts +++ b/packages/backend/src/server/api/endpoints/charts/users.ts @@ -8,7 +8,7 @@ export const meta = { res: getJsonSchema(usersChart.schema), } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { span: { type: 'string', enum: ['day', 'hour'] }, diff --git a/packages/backend/src/server/api/endpoints/clips/add-note.ts b/packages/backend/src/server/api/endpoints/clips/add-note.ts index e7dc25fe40..7700382bd3 100644 --- a/packages/backend/src/server/api/endpoints/clips/add-note.ts +++ b/packages/backend/src/server/api/endpoints/clips/add-note.ts @@ -32,7 +32,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { clipId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/clips/create.ts b/packages/backend/src/server/api/endpoints/clips/create.ts index b6ebf866b8..86164e69af 100644 --- a/packages/backend/src/server/api/endpoints/clips/create.ts +++ b/packages/backend/src/server/api/endpoints/clips/create.ts @@ -16,7 +16,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { name: { type: 'string', minLength: 1, maxLength: 100 }, diff --git a/packages/backend/src/server/api/endpoints/clips/delete.ts b/packages/backend/src/server/api/endpoints/clips/delete.ts index a263e10521..7f712450ae 100644 --- a/packages/backend/src/server/api/endpoints/clips/delete.ts +++ b/packages/backend/src/server/api/endpoints/clips/delete.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { clipId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/clips/list.ts b/packages/backend/src/server/api/endpoints/clips/list.ts index 959b60e6f9..b8ee72af7c 100644 --- a/packages/backend/src/server/api/endpoints/clips/list.ts +++ b/packages/backend/src/server/api/endpoints/clips/list.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/clips/notes.ts b/packages/backend/src/server/api/endpoints/clips/notes.ts index dd76e396bf..698b9d428d 100644 --- a/packages/backend/src/server/api/endpoints/clips/notes.ts +++ b/packages/backend/src/server/api/endpoints/clips/notes.ts @@ -32,7 +32,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { clipId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/clips/show.ts b/packages/backend/src/server/api/endpoints/clips/show.ts index 7fe827a967..e1add3a0a6 100644 --- a/packages/backend/src/server/api/endpoints/clips/show.ts +++ b/packages/backend/src/server/api/endpoints/clips/show.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { clipId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/clips/update.ts b/packages/backend/src/server/api/endpoints/clips/update.ts index b864497349..97134ac79a 100644 --- a/packages/backend/src/server/api/endpoints/clips/update.ts +++ b/packages/backend/src/server/api/endpoints/clips/update.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { clipId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/drive.ts b/packages/backend/src/server/api/endpoints/drive.ts index 5fc1f64cf0..5ff383f0f4 100644 --- a/packages/backend/src/server/api/endpoints/drive.ts +++ b/packages/backend/src/server/api/endpoints/drive.ts @@ -25,7 +25,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/drive/files.ts b/packages/backend/src/server/api/endpoints/drive/files.ts index 8ca9daed4d..998d964bc3 100644 --- a/packages/backend/src/server/api/endpoints/drive/files.ts +++ b/packages/backend/src/server/api/endpoints/drive/files.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/drive/files/attached-notes.ts b/packages/backend/src/server/api/endpoints/drive/files/attached-notes.ts index 20238c1b96..440dc856fd 100644 --- a/packages/backend/src/server/api/endpoints/drive/files/attached-notes.ts +++ b/packages/backend/src/server/api/endpoints/drive/files/attached-notes.ts @@ -28,7 +28,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { fileId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/drive/files/check-existence.ts b/packages/backend/src/server/api/endpoints/drive/files/check-existence.ts index 8b7af3e54a..853723016e 100644 --- a/packages/backend/src/server/api/endpoints/drive/files/check-existence.ts +++ b/packages/backend/src/server/api/endpoints/drive/files/check-existence.ts @@ -14,7 +14,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { md5: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/drive/files/create.ts b/packages/backend/src/server/api/endpoints/drive/files/create.ts index f5791f6ec7..89c6c99f36 100644 --- a/packages/backend/src/server/api/endpoints/drive/files/create.ts +++ b/packages/backend/src/server/api/endpoints/drive/files/create.ts @@ -35,7 +35,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { folderId: { type: 'string', format: 'misskey:id', nullable: true, default: null }, @@ -48,6 +48,7 @@ const paramDef = { } as const; // eslint-disable-next-line import/no-default-export +// @ts-ignore export default define(meta, paramDef, async (ps, user, _, file, cleanup) => { // Get 'name' parameter let name = ps.name || file.originalname; diff --git a/packages/backend/src/server/api/endpoints/drive/files/delete.ts b/packages/backend/src/server/api/endpoints/drive/files/delete.ts index 664637a68f..8ae7e7effe 100644 --- a/packages/backend/src/server/api/endpoints/drive/files/delete.ts +++ b/packages/backend/src/server/api/endpoints/drive/files/delete.ts @@ -26,7 +26,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { fileId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/drive/files/find-by-hash.ts b/packages/backend/src/server/api/endpoints/drive/files/find-by-hash.ts index 98de790c0d..feb738be0d 100644 --- a/packages/backend/src/server/api/endpoints/drive/files/find-by-hash.ts +++ b/packages/backend/src/server/api/endpoints/drive/files/find-by-hash.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { md5: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/drive/files/find.ts b/packages/backend/src/server/api/endpoints/drive/files/find.ts index 8d30c29da6..5419ba9196 100644 --- a/packages/backend/src/server/api/endpoints/drive/files/find.ts +++ b/packages/backend/src/server/api/endpoints/drive/files/find.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { name: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/drive/files/show.ts b/packages/backend/src/server/api/endpoints/drive/files/show.ts index 8edb8785bc..932e692c4c 100644 --- a/packages/backend/src/server/api/endpoints/drive/files/show.ts +++ b/packages/backend/src/server/api/endpoints/drive/files/show.ts @@ -37,7 +37,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { fileId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/drive/files/update.ts b/packages/backend/src/server/api/endpoints/drive/files/update.ts index d77deea7db..3972e56084 100644 --- a/packages/backend/src/server/api/endpoints/drive/files/update.ts +++ b/packages/backend/src/server/api/endpoints/drive/files/update.ts @@ -44,7 +44,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { fileId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/drive/files/upload-from-url.ts b/packages/backend/src/server/api/endpoints/drive/files/upload-from-url.ts index a4619ebf36..5c688e883a 100644 --- a/packages/backend/src/server/api/endpoints/drive/files/upload-from-url.ts +++ b/packages/backend/src/server/api/endpoints/drive/files/upload-from-url.ts @@ -18,7 +18,7 @@ export const meta = { kind: 'write:drive', } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { url: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/drive/folders.ts b/packages/backend/src/server/api/endpoints/drive/folders.ts index a543ae27df..4d8bc32dd7 100644 --- a/packages/backend/src/server/api/endpoints/drive/folders.ts +++ b/packages/backend/src/server/api/endpoints/drive/folders.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/drive/folders/create.ts b/packages/backend/src/server/api/endpoints/drive/folders/create.ts index ab48d5599e..994c537f9f 100644 --- a/packages/backend/src/server/api/endpoints/drive/folders/create.ts +++ b/packages/backend/src/server/api/endpoints/drive/folders/create.ts @@ -26,7 +26,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { name: { type: 'string', default: "Untitled", maxLength: 200 }, diff --git a/packages/backend/src/server/api/endpoints/drive/folders/delete.ts b/packages/backend/src/server/api/endpoints/drive/folders/delete.ts index 51c0340529..58b9919595 100644 --- a/packages/backend/src/server/api/endpoints/drive/folders/delete.ts +++ b/packages/backend/src/server/api/endpoints/drive/folders/delete.ts @@ -25,7 +25,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { folderId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/drive/folders/find.ts b/packages/backend/src/server/api/endpoints/drive/folders/find.ts index 057f40b1cc..333502f706 100644 --- a/packages/backend/src/server/api/endpoints/drive/folders/find.ts +++ b/packages/backend/src/server/api/endpoints/drive/folders/find.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { name: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/drive/folders/show.ts b/packages/backend/src/server/api/endpoints/drive/folders/show.ts index d31d7a4276..4bbd2dcf11 100644 --- a/packages/backend/src/server/api/endpoints/drive/folders/show.ts +++ b/packages/backend/src/server/api/endpoints/drive/folders/show.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { folderId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/drive/folders/update.ts b/packages/backend/src/server/api/endpoints/drive/folders/update.ts index c70b5a0d54..a4393d99b0 100644 --- a/packages/backend/src/server/api/endpoints/drive/folders/update.ts +++ b/packages/backend/src/server/api/endpoints/drive/folders/update.ts @@ -37,7 +37,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { folderId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/drive/stream.ts b/packages/backend/src/server/api/endpoints/drive/stream.ts index 921ae4c221..9d5cb02c70 100644 --- a/packages/backend/src/server/api/endpoints/drive/stream.ts +++ b/packages/backend/src/server/api/endpoints/drive/stream.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/email-address/available.ts b/packages/backend/src/server/api/endpoints/email-address/available.ts index cb740ffae7..8fee4ce509 100644 --- a/packages/backend/src/server/api/endpoints/email-address/available.ts +++ b/packages/backend/src/server/api/endpoints/email-address/available.ts @@ -22,7 +22,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { emailAddress: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/endpoint.ts b/packages/backend/src/server/api/endpoints/endpoint.ts index b8fe030e8c..7c528114f2 100644 --- a/packages/backend/src/server/api/endpoints/endpoint.ts +++ b/packages/backend/src/server/api/endpoints/endpoint.ts @@ -7,7 +7,7 @@ export const meta = { tags: ['meta'], } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { endpoint: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/endpoints.ts b/packages/backend/src/server/api/endpoints/endpoints.ts index b090e0dced..ef6efc6fb3 100644 --- a/packages/backend/src/server/api/endpoints/endpoints.ts +++ b/packages/backend/src/server/api/endpoints/endpoints.ts @@ -22,7 +22,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/export-custom-emojis.ts b/packages/backend/src/server/api/endpoints/export-custom-emojis.ts index f0ab63f74b..3bffbc82bd 100644 --- a/packages/backend/src/server/api/endpoints/export-custom-emojis.ts +++ b/packages/backend/src/server/api/endpoints/export-custom-emojis.ts @@ -11,7 +11,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/federation/followers.ts b/packages/backend/src/server/api/endpoints/federation/followers.ts index 5960e482c0..b716552322 100644 --- a/packages/backend/src/server/api/endpoints/federation/followers.ts +++ b/packages/backend/src/server/api/endpoints/federation/followers.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { host: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/federation/following.ts b/packages/backend/src/server/api/endpoints/federation/following.ts index 4f139b0c45..373c432be5 100644 --- a/packages/backend/src/server/api/endpoints/federation/following.ts +++ b/packages/backend/src/server/api/endpoints/federation/following.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { host: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/federation/instances.ts b/packages/backend/src/server/api/endpoints/federation/instances.ts index 494b5120ab..fb25199c73 100644 --- a/packages/backend/src/server/api/endpoints/federation/instances.ts +++ b/packages/backend/src/server/api/endpoints/federation/instances.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { host: { type: 'string', nullable: true }, diff --git a/packages/backend/src/server/api/endpoints/federation/show-instance.ts b/packages/backend/src/server/api/endpoints/federation/show-instance.ts index cead515d81..590f8a7e86 100644 --- a/packages/backend/src/server/api/endpoints/federation/show-instance.ts +++ b/packages/backend/src/server/api/endpoints/federation/show-instance.ts @@ -17,7 +17,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { host: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/federation/update-remote-user.ts b/packages/backend/src/server/api/endpoints/federation/update-remote-user.ts index ebdc54d0a6..59661ea7c0 100644 --- a/packages/backend/src/server/api/endpoints/federation/update-remote-user.ts +++ b/packages/backend/src/server/api/endpoints/federation/update-remote-user.ts @@ -8,7 +8,7 @@ export const meta = { requireCredential: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/federation/users.ts b/packages/backend/src/server/api/endpoints/federation/users.ts index 294894cd92..f35471f062 100644 --- a/packages/backend/src/server/api/endpoints/federation/users.ts +++ b/packages/backend/src/server/api/endpoints/federation/users.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { host: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/following/create.ts b/packages/backend/src/server/api/endpoints/following/create.ts index 1edb3517a0..a18c44a1d8 100644 --- a/packages/backend/src/server/api/endpoints/following/create.ts +++ b/packages/backend/src/server/api/endpoints/following/create.ts @@ -57,7 +57,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/following/delete.ts b/packages/backend/src/server/api/endpoints/following/delete.ts index 2eb8636816..ec32c2c888 100644 --- a/packages/backend/src/server/api/endpoints/following/delete.ts +++ b/packages/backend/src/server/api/endpoints/following/delete.ts @@ -44,7 +44,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/following/invalidate.ts b/packages/backend/src/server/api/endpoints/following/invalidate.ts index 8a1da3d299..137d366fce 100644 --- a/packages/backend/src/server/api/endpoints/following/invalidate.ts +++ b/packages/backend/src/server/api/endpoints/following/invalidate.ts @@ -44,7 +44,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/following/requests/accept.ts b/packages/backend/src/server/api/endpoints/following/requests/accept.ts index 7040efcc80..adbbb3404a 100644 --- a/packages/backend/src/server/api/endpoints/following/requests/accept.ts +++ b/packages/backend/src/server/api/endpoints/following/requests/accept.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/following/requests/cancel.ts b/packages/backend/src/server/api/endpoints/following/requests/cancel.ts index 4204f8526a..5e949af9de 100644 --- a/packages/backend/src/server/api/endpoints/following/requests/cancel.ts +++ b/packages/backend/src/server/api/endpoints/following/requests/cancel.ts @@ -33,7 +33,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/following/requests/list.ts b/packages/backend/src/server/api/endpoints/following/requests/list.ts index 17d576d1c0..563223fcae 100644 --- a/packages/backend/src/server/api/endpoints/following/requests/list.ts +++ b/packages/backend/src/server/api/endpoints/following/requests/list.ts @@ -35,7 +35,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/following/requests/reject.ts b/packages/backend/src/server/api/endpoints/following/requests/reject.ts index 9e345aa15f..f1502eba13 100644 --- a/packages/backend/src/server/api/endpoints/following/requests/reject.ts +++ b/packages/backend/src/server/api/endpoints/following/requests/reject.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/gallery/featured.ts b/packages/backend/src/server/api/endpoints/gallery/featured.ts index 6b347f9dea..ad994c386a 100644 --- a/packages/backend/src/server/api/endpoints/gallery/featured.ts +++ b/packages/backend/src/server/api/endpoints/gallery/featured.ts @@ -17,7 +17,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/gallery/popular.ts b/packages/backend/src/server/api/endpoints/gallery/popular.ts index 57ead79826..9e5019ddef 100644 --- a/packages/backend/src/server/api/endpoints/gallery/popular.ts +++ b/packages/backend/src/server/api/endpoints/gallery/popular.ts @@ -17,7 +17,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/gallery/posts.ts b/packages/backend/src/server/api/endpoints/gallery/posts.ts index c36e80b83c..40c9efaf51 100644 --- a/packages/backend/src/server/api/endpoints/gallery/posts.ts +++ b/packages/backend/src/server/api/endpoints/gallery/posts.ts @@ -16,7 +16,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/gallery/posts/create.ts b/packages/backend/src/server/api/endpoints/gallery/posts/create.ts index d64937d0bc..c963dc86d1 100644 --- a/packages/backend/src/server/api/endpoints/gallery/posts/create.ts +++ b/packages/backend/src/server/api/endpoints/gallery/posts/create.ts @@ -29,7 +29,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { title: { type: 'string', minLength: 1 }, diff --git a/packages/backend/src/server/api/endpoints/gallery/posts/delete.ts b/packages/backend/src/server/api/endpoints/gallery/posts/delete.ts index 82ffd62d60..7fafc9288a 100644 --- a/packages/backend/src/server/api/endpoints/gallery/posts/delete.ts +++ b/packages/backend/src/server/api/endpoints/gallery/posts/delete.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { postId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/gallery/posts/like.ts b/packages/backend/src/server/api/endpoints/gallery/posts/like.ts index 73d5a0ea99..ca6c06cf9e 100644 --- a/packages/backend/src/server/api/endpoints/gallery/posts/like.ts +++ b/packages/backend/src/server/api/endpoints/gallery/posts/like.ts @@ -31,7 +31,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { postId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/gallery/posts/show.ts b/packages/backend/src/server/api/endpoints/gallery/posts/show.ts index 819d360b14..0f8f3a6068 100644 --- a/packages/backend/src/server/api/endpoints/gallery/posts/show.ts +++ b/packages/backend/src/server/api/endpoints/gallery/posts/show.ts @@ -22,7 +22,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { postId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/gallery/posts/unlike.ts b/packages/backend/src/server/api/endpoints/gallery/posts/unlike.ts index fc38174810..30ccaf167e 100644 --- a/packages/backend/src/server/api/endpoints/gallery/posts/unlike.ts +++ b/packages/backend/src/server/api/endpoints/gallery/posts/unlike.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { postId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/gallery/posts/update.ts b/packages/backend/src/server/api/endpoints/gallery/posts/update.ts index 1a86b56bc6..2b2e26aa5d 100644 --- a/packages/backend/src/server/api/endpoints/gallery/posts/update.ts +++ b/packages/backend/src/server/api/endpoints/gallery/posts/update.ts @@ -28,7 +28,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { postId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/get-online-users-count.ts b/packages/backend/src/server/api/endpoints/get-online-users-count.ts index 855b9fc342..374d819ce7 100644 --- a/packages/backend/src/server/api/endpoints/get-online-users-count.ts +++ b/packages/backend/src/server/api/endpoints/get-online-users-count.ts @@ -9,7 +9,7 @@ export const meta = { requireCredential: false, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/hashtags/list.ts b/packages/backend/src/server/api/endpoints/hashtags/list.ts index 68f2b2bf57..3bd5305bd4 100644 --- a/packages/backend/src/server/api/endpoints/hashtags/list.ts +++ b/packages/backend/src/server/api/endpoints/hashtags/list.ts @@ -17,7 +17,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/hashtags/search.ts b/packages/backend/src/server/api/endpoints/hashtags/search.ts index 9aa08ed28e..2af6b6d77c 100644 --- a/packages/backend/src/server/api/endpoints/hashtags/search.ts +++ b/packages/backend/src/server/api/endpoints/hashtags/search.ts @@ -16,7 +16,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/hashtags/show.ts b/packages/backend/src/server/api/endpoints/hashtags/show.ts index 79b9613086..0770882141 100644 --- a/packages/backend/src/server/api/endpoints/hashtags/show.ts +++ b/packages/backend/src/server/api/endpoints/hashtags/show.ts @@ -23,7 +23,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { tag: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/hashtags/trend.ts b/packages/backend/src/server/api/endpoints/hashtags/trend.ts index de3e453c3e..6da5b90b28 100644 --- a/packages/backend/src/server/api/endpoints/hashtags/trend.ts +++ b/packages/backend/src/server/api/endpoints/hashtags/trend.ts @@ -53,7 +53,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/hashtags/users.ts b/packages/backend/src/server/api/endpoints/hashtags/users.ts index 1760732c1a..ff06d925dd 100644 --- a/packages/backend/src/server/api/endpoints/hashtags/users.ts +++ b/packages/backend/src/server/api/endpoints/hashtags/users.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { tag: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/i.ts b/packages/backend/src/server/api/endpoints/i.ts index 091276ea27..f9c58c2479 100644 --- a/packages/backend/src/server/api/endpoints/i.ts +++ b/packages/backend/src/server/api/endpoints/i.ts @@ -13,7 +13,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/i/2fa/done.ts b/packages/backend/src/server/api/endpoints/i/2fa/done.ts index 8d82ab3886..1646b7bd89 100644 --- a/packages/backend/src/server/api/endpoints/i/2fa/done.ts +++ b/packages/backend/src/server/api/endpoints/i/2fa/done.ts @@ -8,7 +8,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { token: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/i/2fa/key-done.ts b/packages/backend/src/server/api/endpoints/i/2fa/key-done.ts index 5052afda97..52a0afcbfd 100644 --- a/packages/backend/src/server/api/endpoints/i/2fa/key-done.ts +++ b/packages/backend/src/server/api/endpoints/i/2fa/key-done.ts @@ -21,7 +21,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { clientDataJSON: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/i/2fa/password-less.ts b/packages/backend/src/server/api/endpoints/i/2fa/password-less.ts index 2830f8994a..d9d2ec66c1 100644 --- a/packages/backend/src/server/api/endpoints/i/2fa/password-less.ts +++ b/packages/backend/src/server/api/endpoints/i/2fa/password-less.ts @@ -7,7 +7,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { value: { type: 'boolean' }, diff --git a/packages/backend/src/server/api/endpoints/i/2fa/register-key.ts b/packages/backend/src/server/api/endpoints/i/2fa/register-key.ts index da3ff421a7..86fc4fdffb 100644 --- a/packages/backend/src/server/api/endpoints/i/2fa/register-key.ts +++ b/packages/backend/src/server/api/endpoints/i/2fa/register-key.ts @@ -14,7 +14,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { password: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/i/2fa/register.ts b/packages/backend/src/server/api/endpoints/i/2fa/register.ts index 32acc838b7..e550698abb 100644 --- a/packages/backend/src/server/api/endpoints/i/2fa/register.ts +++ b/packages/backend/src/server/api/endpoints/i/2fa/register.ts @@ -11,7 +11,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { password: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/i/2fa/remove-key.ts b/packages/backend/src/server/api/endpoints/i/2fa/remove-key.ts index 3004ce36a1..0469912340 100644 --- a/packages/backend/src/server/api/endpoints/i/2fa/remove-key.ts +++ b/packages/backend/src/server/api/endpoints/i/2fa/remove-key.ts @@ -9,7 +9,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { password: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/i/2fa/unregister.ts b/packages/backend/src/server/api/endpoints/i/2fa/unregister.ts index b8e89bac72..c1ca445825 100644 --- a/packages/backend/src/server/api/endpoints/i/2fa/unregister.ts +++ b/packages/backend/src/server/api/endpoints/i/2fa/unregister.ts @@ -8,7 +8,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { password: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/i/apps.ts b/packages/backend/src/server/api/endpoints/i/apps.ts index f45b6745b8..0fe3db2d9f 100644 --- a/packages/backend/src/server/api/endpoints/i/apps.ts +++ b/packages/backend/src/server/api/endpoints/i/apps.ts @@ -7,7 +7,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { sort: { type: 'string', enum: ['+createdAt', '-createdAt', '+lastUsedAt', '-lastUsedAt'] }, diff --git a/packages/backend/src/server/api/endpoints/i/authorized-apps.ts b/packages/backend/src/server/api/endpoints/i/authorized-apps.ts index e417f3e81a..e2f5ceb7e1 100644 --- a/packages/backend/src/server/api/endpoints/i/authorized-apps.ts +++ b/packages/backend/src/server/api/endpoints/i/authorized-apps.ts @@ -7,7 +7,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/i/change-password.ts b/packages/backend/src/server/api/endpoints/i/change-password.ts index eac60ee183..e68d18b86d 100644 --- a/packages/backend/src/server/api/endpoints/i/change-password.ts +++ b/packages/backend/src/server/api/endpoints/i/change-password.ts @@ -8,7 +8,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { currentPassword: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/i/delete-account.ts b/packages/backend/src/server/api/endpoints/i/delete-account.ts index 6f689c0b4e..188d2257aa 100644 --- a/packages/backend/src/server/api/endpoints/i/delete-account.ts +++ b/packages/backend/src/server/api/endpoints/i/delete-account.ts @@ -11,7 +11,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { password: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/i/export-blocking.ts b/packages/backend/src/server/api/endpoints/i/export-blocking.ts index afa6f2fc8e..808b546bdb 100644 --- a/packages/backend/src/server/api/endpoints/i/export-blocking.ts +++ b/packages/backend/src/server/api/endpoints/i/export-blocking.ts @@ -11,7 +11,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/i/export-following.ts b/packages/backend/src/server/api/endpoints/i/export-following.ts index 4dd8cda398..10f8ee9ab2 100644 --- a/packages/backend/src/server/api/endpoints/i/export-following.ts +++ b/packages/backend/src/server/api/endpoints/i/export-following.ts @@ -11,7 +11,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { excludeMuting: { type: 'boolean', default: false }, diff --git a/packages/backend/src/server/api/endpoints/i/export-mute.ts b/packages/backend/src/server/api/endpoints/i/export-mute.ts index ca8a7b997c..ab39508534 100644 --- a/packages/backend/src/server/api/endpoints/i/export-mute.ts +++ b/packages/backend/src/server/api/endpoints/i/export-mute.ts @@ -11,7 +11,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/i/export-notes.ts b/packages/backend/src/server/api/endpoints/i/export-notes.ts index fc155d9d0f..770444d68b 100644 --- a/packages/backend/src/server/api/endpoints/i/export-notes.ts +++ b/packages/backend/src/server/api/endpoints/i/export-notes.ts @@ -11,7 +11,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/i/export-user-lists.ts b/packages/backend/src/server/api/endpoints/i/export-user-lists.ts index 22cbf973f8..c0d9d924bd 100644 --- a/packages/backend/src/server/api/endpoints/i/export-user-lists.ts +++ b/packages/backend/src/server/api/endpoints/i/export-user-lists.ts @@ -11,7 +11,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/i/favorites.ts b/packages/backend/src/server/api/endpoints/i/favorites.ts index 45f5d99cce..d6c12582d0 100644 --- a/packages/backend/src/server/api/endpoints/i/favorites.ts +++ b/packages/backend/src/server/api/endpoints/i/favorites.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/i/gallery/likes.ts b/packages/backend/src/server/api/endpoints/i/gallery/likes.ts index 7578ed3216..173a502622 100644 --- a/packages/backend/src/server/api/endpoints/i/gallery/likes.ts +++ b/packages/backend/src/server/api/endpoints/i/gallery/likes.ts @@ -31,7 +31,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/i/gallery/posts.ts b/packages/backend/src/server/api/endpoints/i/gallery/posts.ts index fbab8795ca..31e9636f84 100644 --- a/packages/backend/src/server/api/endpoints/i/gallery/posts.ts +++ b/packages/backend/src/server/api/endpoints/i/gallery/posts.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/i/get-word-muted-notes-count.ts b/packages/backend/src/server/api/endpoints/i/get-word-muted-notes-count.ts index 2b31b89ff1..c760dd0e23 100644 --- a/packages/backend/src/server/api/endpoints/i/get-word-muted-notes-count.ts +++ b/packages/backend/src/server/api/endpoints/i/get-word-muted-notes-count.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/i/import-blocking.ts b/packages/backend/src/server/api/endpoints/i/import-blocking.ts index b90bfb1402..e9cf6e562e 100644 --- a/packages/backend/src/server/api/endpoints/i/import-blocking.ts +++ b/packages/backend/src/server/api/endpoints/i/import-blocking.ts @@ -40,7 +40,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { fileId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/i/import-following.ts b/packages/backend/src/server/api/endpoints/i/import-following.ts index 75388502a5..d9c831daf8 100644 --- a/packages/backend/src/server/api/endpoints/i/import-following.ts +++ b/packages/backend/src/server/api/endpoints/i/import-following.ts @@ -39,7 +39,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { fileId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/i/import-muting.ts b/packages/backend/src/server/api/endpoints/i/import-muting.ts index e1c3df33e1..ac61a6c852 100644 --- a/packages/backend/src/server/api/endpoints/i/import-muting.ts +++ b/packages/backend/src/server/api/endpoints/i/import-muting.ts @@ -40,7 +40,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { fileId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/i/import-user-lists.ts b/packages/backend/src/server/api/endpoints/i/import-user-lists.ts index eb1302a98c..68f2b377a9 100644 --- a/packages/backend/src/server/api/endpoints/i/import-user-lists.ts +++ b/packages/backend/src/server/api/endpoints/i/import-user-lists.ts @@ -39,7 +39,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { fileId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/i/notifications.ts b/packages/backend/src/server/api/endpoints/i/notifications.ts index bb1d6a49b3..cecaa8ac44 100644 --- a/packages/backend/src/server/api/endpoints/i/notifications.ts +++ b/packages/backend/src/server/api/endpoints/i/notifications.ts @@ -25,7 +25,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/i/page-likes.ts b/packages/backend/src/server/api/endpoints/i/page-likes.ts index 60ac3ccde1..d3b68acdc5 100644 --- a/packages/backend/src/server/api/endpoints/i/page-likes.ts +++ b/packages/backend/src/server/api/endpoints/i/page-likes.ts @@ -30,7 +30,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/i/pages.ts b/packages/backend/src/server/api/endpoints/i/pages.ts index dbc58021b9..09cff4a0fb 100644 --- a/packages/backend/src/server/api/endpoints/i/pages.ts +++ b/packages/backend/src/server/api/endpoints/i/pages.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/i/pin.ts b/packages/backend/src/server/api/endpoints/i/pin.ts index a09618ebe8..a4dd64564a 100644 --- a/packages/backend/src/server/api/endpoints/i/pin.ts +++ b/packages/backend/src/server/api/endpoints/i/pin.ts @@ -37,7 +37,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/i/read-all-messaging-messages.ts b/packages/backend/src/server/api/endpoints/i/read-all-messaging-messages.ts index b0185a3e37..e6eb8d7ef0 100644 --- a/packages/backend/src/server/api/endpoints/i/read-all-messaging-messages.ts +++ b/packages/backend/src/server/api/endpoints/i/read-all-messaging-messages.ts @@ -10,7 +10,7 @@ export const meta = { kind: 'write:account', } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/i/read-all-unread-notes.ts b/packages/backend/src/server/api/endpoints/i/read-all-unread-notes.ts index 45638c2579..12038999ae 100644 --- a/packages/backend/src/server/api/endpoints/i/read-all-unread-notes.ts +++ b/packages/backend/src/server/api/endpoints/i/read-all-unread-notes.ts @@ -10,7 +10,7 @@ export const meta = { kind: 'write:account', } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/i/read-announcement.ts b/packages/backend/src/server/api/endpoints/i/read-announcement.ts index f3cedddb35..2d8c723e4e 100644 --- a/packages/backend/src/server/api/endpoints/i/read-announcement.ts +++ b/packages/backend/src/server/api/endpoints/i/read-announcement.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { announcementId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/i/regenerate-token.ts b/packages/backend/src/server/api/endpoints/i/regenerate-token.ts index 71a3ea08af..1462b902c4 100644 --- a/packages/backend/src/server/api/endpoints/i/regenerate-token.ts +++ b/packages/backend/src/server/api/endpoints/i/regenerate-token.ts @@ -10,7 +10,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { password: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/i/registry/get-all.ts b/packages/backend/src/server/api/endpoints/i/registry/get-all.ts index 0429cd283a..c371da87d8 100644 --- a/packages/backend/src/server/api/endpoints/i/registry/get-all.ts +++ b/packages/backend/src/server/api/endpoints/i/registry/get-all.ts @@ -7,7 +7,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { scope: { type: 'array', default: [], items: { diff --git a/packages/backend/src/server/api/endpoints/i/registry/get-detail.ts b/packages/backend/src/server/api/endpoints/i/registry/get-detail.ts index 194a922718..bd243946b0 100644 --- a/packages/backend/src/server/api/endpoints/i/registry/get-detail.ts +++ b/packages/backend/src/server/api/endpoints/i/registry/get-detail.ts @@ -16,7 +16,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { key: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/i/registry/get.ts b/packages/backend/src/server/api/endpoints/i/registry/get.ts index 7d413e3528..2bc6975bb3 100644 --- a/packages/backend/src/server/api/endpoints/i/registry/get.ts +++ b/packages/backend/src/server/api/endpoints/i/registry/get.ts @@ -16,7 +16,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { key: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/i/registry/keys-with-type.ts b/packages/backend/src/server/api/endpoints/i/registry/keys-with-type.ts index 52e0d6fac5..78bb9dd348 100644 --- a/packages/backend/src/server/api/endpoints/i/registry/keys-with-type.ts +++ b/packages/backend/src/server/api/endpoints/i/registry/keys-with-type.ts @@ -7,7 +7,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { scope: { type: 'array', default: [], items: { diff --git a/packages/backend/src/server/api/endpoints/i/registry/keys.ts b/packages/backend/src/server/api/endpoints/i/registry/keys.ts index c494ed8f5c..5f627125d5 100644 --- a/packages/backend/src/server/api/endpoints/i/registry/keys.ts +++ b/packages/backend/src/server/api/endpoints/i/registry/keys.ts @@ -7,7 +7,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { scope: { type: 'array', default: [], items: { diff --git a/packages/backend/src/server/api/endpoints/i/registry/remove.ts b/packages/backend/src/server/api/endpoints/i/registry/remove.ts index 5bc55bd297..6a005d10d4 100644 --- a/packages/backend/src/server/api/endpoints/i/registry/remove.ts +++ b/packages/backend/src/server/api/endpoints/i/registry/remove.ts @@ -16,7 +16,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { key: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/i/registry/scopes.ts b/packages/backend/src/server/api/endpoints/i/registry/scopes.ts index e04d123a1f..09de7125c9 100644 --- a/packages/backend/src/server/api/endpoints/i/registry/scopes.ts +++ b/packages/backend/src/server/api/endpoints/i/registry/scopes.ts @@ -7,7 +7,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/i/registry/set.ts b/packages/backend/src/server/api/endpoints/i/registry/set.ts index c78f4383be..28d9555b1c 100644 --- a/packages/backend/src/server/api/endpoints/i/registry/set.ts +++ b/packages/backend/src/server/api/endpoints/i/registry/set.ts @@ -9,7 +9,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { key: { type: 'string', minLength: 1 }, diff --git a/packages/backend/src/server/api/endpoints/i/revoke-token.ts b/packages/backend/src/server/api/endpoints/i/revoke-token.ts index 14800346c1..b889e795be 100644 --- a/packages/backend/src/server/api/endpoints/i/revoke-token.ts +++ b/packages/backend/src/server/api/endpoints/i/revoke-token.ts @@ -8,7 +8,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { tokenId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/i/signin-history.ts b/packages/backend/src/server/api/endpoints/i/signin-history.ts index 468972c239..f7a98a2332 100644 --- a/packages/backend/src/server/api/endpoints/i/signin-history.ts +++ b/packages/backend/src/server/api/endpoints/i/signin-history.ts @@ -8,7 +8,7 @@ export const meta = { secure: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/i/unpin.ts b/packages/backend/src/server/api/endpoints/i/unpin.ts index 895bfd0c28..5ab1e95c59 100644 --- a/packages/backend/src/server/api/endpoints/i/unpin.ts +++ b/packages/backend/src/server/api/endpoints/i/unpin.ts @@ -25,7 +25,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/i/update-email.ts b/packages/backend/src/server/api/endpoints/i/update-email.ts index 1450eabc2a..21a2081836 100644 --- a/packages/backend/src/server/api/endpoints/i/update-email.ts +++ b/packages/backend/src/server/api/endpoints/i/update-email.ts @@ -34,7 +34,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { password: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/i/update.ts b/packages/backend/src/server/api/endpoints/i/update.ts index 0a5188609b..d800f23f8e 100644 --- a/packages/backend/src/server/api/endpoints/i/update.ts +++ b/packages/backend/src/server/api/endpoints/i/update.ts @@ -67,7 +67,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { name: { ...Users.nameSchema, nullable: true }, diff --git a/packages/backend/src/server/api/endpoints/i/user-group-invites.ts b/packages/backend/src/server/api/endpoints/i/user-group-invites.ts index 6c38240913..a026d8d669 100644 --- a/packages/backend/src/server/api/endpoints/i/user-group-invites.ts +++ b/packages/backend/src/server/api/endpoints/i/user-group-invites.ts @@ -31,7 +31,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/messaging/history.ts b/packages/backend/src/server/api/endpoints/messaging/history.ts index 5c1c040cc3..cb27f37fbb 100644 --- a/packages/backend/src/server/api/endpoints/messaging/history.ts +++ b/packages/backend/src/server/api/endpoints/messaging/history.ts @@ -21,7 +21,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/messaging/messages.ts b/packages/backend/src/server/api/endpoints/messaging/messages.ts index ce477feac4..a21f8d8fc1 100644 --- a/packages/backend/src/server/api/endpoints/messaging/messages.ts +++ b/packages/backend/src/server/api/endpoints/messaging/messages.ts @@ -44,7 +44,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/messaging/messages/create.ts b/packages/backend/src/server/api/endpoints/messaging/messages/create.ts index 60b1e2cdce..c2f9e71b5c 100644 --- a/packages/backend/src/server/api/endpoints/messaging/messages/create.ts +++ b/packages/backend/src/server/api/endpoints/messaging/messages/create.ts @@ -64,7 +64,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/messaging/messages/delete.ts b/packages/backend/src/server/api/endpoints/messaging/messages/delete.ts index 67ecd4a1e6..8f5d6da665 100644 --- a/packages/backend/src/server/api/endpoints/messaging/messages/delete.ts +++ b/packages/backend/src/server/api/endpoints/messaging/messages/delete.ts @@ -26,7 +26,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { messageId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/messaging/messages/read.ts b/packages/backend/src/server/api/endpoints/messaging/messages/read.ts index 1d0ddaf98f..2a18d9c379 100644 --- a/packages/backend/src/server/api/endpoints/messaging/messages/read.ts +++ b/packages/backend/src/server/api/endpoints/messaging/messages/read.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { messageId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/meta.ts b/packages/backend/src/server/api/endpoints/meta.ts index fdd1586ca5..5b5604f6a6 100644 --- a/packages/backend/src/server/api/endpoints/meta.ts +++ b/packages/backend/src/server/api/endpoints/meta.ts @@ -440,7 +440,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { detail: { type: 'boolean', default: true }, diff --git a/packages/backend/src/server/api/endpoints/miauth/gen-token.ts b/packages/backend/src/server/api/endpoints/miauth/gen-token.ts index e61c78754f..56fc459d7e 100644 --- a/packages/backend/src/server/api/endpoints/miauth/gen-token.ts +++ b/packages/backend/src/server/api/endpoints/miauth/gen-token.ts @@ -22,7 +22,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { session: { type: 'string', nullable: true }, diff --git a/packages/backend/src/server/api/endpoints/mute/create.ts b/packages/backend/src/server/api/endpoints/mute/create.ts index 3ef97a1491..b8439cd3f6 100644 --- a/packages/backend/src/server/api/endpoints/mute/create.ts +++ b/packages/backend/src/server/api/endpoints/mute/create.ts @@ -34,7 +34,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/mute/delete.ts b/packages/backend/src/server/api/endpoints/mute/delete.ts index 8a88e13039..ff66aa26cf 100644 --- a/packages/backend/src/server/api/endpoints/mute/delete.ts +++ b/packages/backend/src/server/api/endpoints/mute/delete.ts @@ -32,7 +32,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/mute/list.ts b/packages/backend/src/server/api/endpoints/mute/list.ts index fd8443e2b7..a728affe05 100644 --- a/packages/backend/src/server/api/endpoints/mute/list.ts +++ b/packages/backend/src/server/api/endpoints/mute/list.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 30 }, diff --git a/packages/backend/src/server/api/endpoints/my/apps.ts b/packages/backend/src/server/api/endpoints/my/apps.ts index 8dee11fb93..5d08f34dac 100644 --- a/packages/backend/src/server/api/endpoints/my/apps.ts +++ b/packages/backend/src/server/api/endpoints/my/apps.ts @@ -17,7 +17,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/notes.ts b/packages/backend/src/server/api/endpoints/notes.ts index 0106bac516..28c49b0e63 100644 --- a/packages/backend/src/server/api/endpoints/notes.ts +++ b/packages/backend/src/server/api/endpoints/notes.ts @@ -16,7 +16,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { local: { type: 'boolean' }, diff --git a/packages/backend/src/server/api/endpoints/notes/children.ts b/packages/backend/src/server/api/endpoints/notes/children.ts index ea2c166b75..43471b8ed5 100644 --- a/packages/backend/src/server/api/endpoints/notes/children.ts +++ b/packages/backend/src/server/api/endpoints/notes/children.ts @@ -23,7 +23,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/clips.ts b/packages/backend/src/server/api/endpoints/notes/clips.ts index 2caa3a499f..2209894a96 100644 --- a/packages/backend/src/server/api/endpoints/notes/clips.ts +++ b/packages/backend/src/server/api/endpoints/notes/clips.ts @@ -28,7 +28,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/conversation.ts b/packages/backend/src/server/api/endpoints/notes/conversation.ts index c199a3f831..c785496f2e 100644 --- a/packages/backend/src/server/api/endpoints/notes/conversation.ts +++ b/packages/backend/src/server/api/endpoints/notes/conversation.ts @@ -28,7 +28,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/create.ts b/packages/backend/src/server/api/endpoints/notes/create.ts index 7d81abc3a7..7ac318c501 100644 --- a/packages/backend/src/server/api/endpoints/notes/create.ts +++ b/packages/backend/src/server/api/endpoints/notes/create.ts @@ -95,7 +95,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { visibility: { type: 'string', enum: ['public', 'home', 'followers', 'specified'], default: "public" }, diff --git a/packages/backend/src/server/api/endpoints/notes/delete.ts b/packages/backend/src/server/api/endpoints/notes/delete.ts index 62a2a98469..6084c93240 100644 --- a/packages/backend/src/server/api/endpoints/notes/delete.ts +++ b/packages/backend/src/server/api/endpoints/notes/delete.ts @@ -33,7 +33,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/favorites/create.ts b/packages/backend/src/server/api/endpoints/notes/favorites/create.ts index 570e2354ba..eaf2b1ac0f 100644 --- a/packages/backend/src/server/api/endpoints/notes/favorites/create.ts +++ b/packages/backend/src/server/api/endpoints/notes/favorites/create.ts @@ -26,7 +26,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/favorites/delete.ts b/packages/backend/src/server/api/endpoints/notes/favorites/delete.ts index b33a5f148b..1a64fc430e 100644 --- a/packages/backend/src/server/api/endpoints/notes/favorites/delete.ts +++ b/packages/backend/src/server/api/endpoints/notes/favorites/delete.ts @@ -25,7 +25,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/featured.ts b/packages/backend/src/server/api/endpoints/notes/featured.ts index 8a4297de62..11738cbe26 100644 --- a/packages/backend/src/server/api/endpoints/notes/featured.ts +++ b/packages/backend/src/server/api/endpoints/notes/featured.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/notes/global-timeline.ts b/packages/backend/src/server/api/endpoints/notes/global-timeline.ts index 23ca8752c9..54cf51c135 100644 --- a/packages/backend/src/server/api/endpoints/notes/global-timeline.ts +++ b/packages/backend/src/server/api/endpoints/notes/global-timeline.ts @@ -32,7 +32,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { withFiles: { type: 'boolean' }, diff --git a/packages/backend/src/server/api/endpoints/notes/hybrid-timeline.ts b/packages/backend/src/server/api/endpoints/notes/hybrid-timeline.ts index ba6f3b5927..f75cbeb008 100644 --- a/packages/backend/src/server/api/endpoints/notes/hybrid-timeline.ts +++ b/packages/backend/src/server/api/endpoints/notes/hybrid-timeline.ts @@ -37,7 +37,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/notes/local-timeline.ts b/packages/backend/src/server/api/endpoints/notes/local-timeline.ts index 7c118317d6..9793919487 100644 --- a/packages/backend/src/server/api/endpoints/notes/local-timeline.ts +++ b/packages/backend/src/server/api/endpoints/notes/local-timeline.ts @@ -34,7 +34,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { withFiles: { type: 'boolean' }, diff --git a/packages/backend/src/server/api/endpoints/notes/mentions.ts b/packages/backend/src/server/api/endpoints/notes/mentions.ts index 265882fa70..41f2ad5244 100644 --- a/packages/backend/src/server/api/endpoints/notes/mentions.ts +++ b/packages/backend/src/server/api/endpoints/notes/mentions.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { following: { type: 'boolean', default: false }, diff --git a/packages/backend/src/server/api/endpoints/notes/polls/recommendation.ts b/packages/backend/src/server/api/endpoints/notes/polls/recommendation.ts index 4030694b58..0f2d4699de 100644 --- a/packages/backend/src/server/api/endpoints/notes/polls/recommendation.ts +++ b/packages/backend/src/server/api/endpoints/notes/polls/recommendation.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/notes/polls/vote.ts b/packages/backend/src/server/api/endpoints/notes/polls/vote.ts index 739df8a03c..d889ba6f1f 100644 --- a/packages/backend/src/server/api/endpoints/notes/polls/vote.ts +++ b/packages/backend/src/server/api/endpoints/notes/polls/vote.ts @@ -58,7 +58,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/reactions.ts b/packages/backend/src/server/api/endpoints/notes/reactions.ts index fdcaed64e1..746344df3b 100644 --- a/packages/backend/src/server/api/endpoints/notes/reactions.ts +++ b/packages/backend/src/server/api/endpoints/notes/reactions.ts @@ -29,7 +29,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/reactions/create.ts b/packages/backend/src/server/api/endpoints/notes/reactions/create.ts index a898b3249a..9edbabc469 100644 --- a/packages/backend/src/server/api/endpoints/notes/reactions/create.ts +++ b/packages/backend/src/server/api/endpoints/notes/reactions/create.ts @@ -31,7 +31,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/reactions/delete.ts b/packages/backend/src/server/api/endpoints/notes/reactions/delete.ts index 53cadac7c9..d5e2e138a8 100644 --- a/packages/backend/src/server/api/endpoints/notes/reactions/delete.ts +++ b/packages/backend/src/server/api/endpoints/notes/reactions/delete.ts @@ -32,7 +32,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/renotes.ts b/packages/backend/src/server/api/endpoints/notes/renotes.ts index aa5c2c0a45..a964a0c766 100644 --- a/packages/backend/src/server/api/endpoints/notes/renotes.ts +++ b/packages/backend/src/server/api/endpoints/notes/renotes.ts @@ -31,7 +31,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/replies.ts b/packages/backend/src/server/api/endpoints/notes/replies.ts index b88e3d7168..78559abd5a 100644 --- a/packages/backend/src/server/api/endpoints/notes/replies.ts +++ b/packages/backend/src/server/api/endpoints/notes/replies.ts @@ -21,7 +21,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/search-by-tag.ts b/packages/backend/src/server/api/endpoints/notes/search-by-tag.ts index bf18a20b97..ff55f862aa 100644 --- a/packages/backend/src/server/api/endpoints/notes/search-by-tag.ts +++ b/packages/backend/src/server/api/endpoints/notes/search-by-tag.ts @@ -22,7 +22,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { tag: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/notes/search.ts b/packages/backend/src/server/api/endpoints/notes/search.ts index bcb9c2b8a1..7034645956 100644 --- a/packages/backend/src/server/api/endpoints/notes/search.ts +++ b/packages/backend/src/server/api/endpoints/notes/search.ts @@ -27,7 +27,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { query: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/notes/show.ts b/packages/backend/src/server/api/endpoints/notes/show.ts index 8f75eeb5e8..a300f1aefa 100644 --- a/packages/backend/src/server/api/endpoints/notes/show.ts +++ b/packages/backend/src/server/api/endpoints/notes/show.ts @@ -23,7 +23,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/state.ts b/packages/backend/src/server/api/endpoints/notes/state.ts index cf5f08ea9a..2e7f1f75c3 100644 --- a/packages/backend/src/server/api/endpoints/notes/state.ts +++ b/packages/backend/src/server/api/endpoints/notes/state.ts @@ -26,7 +26,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/thread-muting/create.ts b/packages/backend/src/server/api/endpoints/notes/thread-muting/create.ts index 4068a8a571..7b3c88785b 100644 --- a/packages/backend/src/server/api/endpoints/notes/thread-muting/create.ts +++ b/packages/backend/src/server/api/endpoints/notes/thread-muting/create.ts @@ -21,7 +21,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/thread-muting/delete.ts b/packages/backend/src/server/api/endpoints/notes/thread-muting/delete.ts index 09b64f7277..66d631640a 100644 --- a/packages/backend/src/server/api/endpoints/notes/thread-muting/delete.ts +++ b/packages/backend/src/server/api/endpoints/notes/thread-muting/delete.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/timeline.ts b/packages/backend/src/server/api/endpoints/notes/timeline.ts index c06a98feaa..14d0d71704 100644 --- a/packages/backend/src/server/api/endpoints/notes/timeline.ts +++ b/packages/backend/src/server/api/endpoints/notes/timeline.ts @@ -27,7 +27,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/notes/translate.ts b/packages/backend/src/server/api/endpoints/notes/translate.ts index d85c8b96f9..a1d8fae10b 100644 --- a/packages/backend/src/server/api/endpoints/notes/translate.ts +++ b/packages/backend/src/server/api/endpoints/notes/translate.ts @@ -27,7 +27,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/unrenote.ts b/packages/backend/src/server/api/endpoints/notes/unrenote.ts index c10d277de1..5b39239279 100644 --- a/packages/backend/src/server/api/endpoints/notes/unrenote.ts +++ b/packages/backend/src/server/api/endpoints/notes/unrenote.ts @@ -27,7 +27,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/user-list-timeline.ts b/packages/backend/src/server/api/endpoints/notes/user-list-timeline.ts index 018e3e06a8..68a15f05fb 100644 --- a/packages/backend/src/server/api/endpoints/notes/user-list-timeline.ts +++ b/packages/backend/src/server/api/endpoints/notes/user-list-timeline.ts @@ -30,7 +30,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { listId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/watching/create.ts b/packages/backend/src/server/api/endpoints/notes/watching/create.ts index b19d370027..ed35638329 100644 --- a/packages/backend/src/server/api/endpoints/notes/watching/create.ts +++ b/packages/backend/src/server/api/endpoints/notes/watching/create.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notes/watching/delete.ts b/packages/backend/src/server/api/endpoints/notes/watching/delete.ts index f9ceb49278..1918b887ef 100644 --- a/packages/backend/src/server/api/endpoints/notes/watching/delete.ts +++ b/packages/backend/src/server/api/endpoints/notes/watching/delete.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/notifications/create.ts b/packages/backend/src/server/api/endpoints/notifications/create.ts index b5bfb34f4b..590f1c540f 100644 --- a/packages/backend/src/server/api/endpoints/notifications/create.ts +++ b/packages/backend/src/server/api/endpoints/notifications/create.ts @@ -12,7 +12,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { body: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/notifications/mark-all-as-read.ts b/packages/backend/src/server/api/endpoints/notifications/mark-all-as-read.ts index 12dc43de16..5ad6605e7f 100644 --- a/packages/backend/src/server/api/endpoints/notifications/mark-all-as-read.ts +++ b/packages/backend/src/server/api/endpoints/notifications/mark-all-as-read.ts @@ -10,7 +10,7 @@ export const meta = { kind: 'write:notifications', } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/notifications/read.ts b/packages/backend/src/server/api/endpoints/notifications/read.ts index 6e5b5616dd..93ac75f649 100644 --- a/packages/backend/src/server/api/endpoints/notifications/read.ts +++ b/packages/backend/src/server/api/endpoints/notifications/read.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { notificationId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/page-push.ts b/packages/backend/src/server/api/endpoints/page-push.ts index 20334f33fc..690cd0884d 100644 --- a/packages/backend/src/server/api/endpoints/page-push.ts +++ b/packages/backend/src/server/api/endpoints/page-push.ts @@ -16,7 +16,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { pageId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/pages/create.ts b/packages/backend/src/server/api/endpoints/pages/create.ts index 6c00a2f779..c6d50e5cdf 100644 --- a/packages/backend/src/server/api/endpoints/pages/create.ts +++ b/packages/backend/src/server/api/endpoints/pages/create.ts @@ -37,7 +37,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { title: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/pages/delete.ts b/packages/backend/src/server/api/endpoints/pages/delete.ts index c41373bb7c..2933e04174 100644 --- a/packages/backend/src/server/api/endpoints/pages/delete.ts +++ b/packages/backend/src/server/api/endpoints/pages/delete.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { pageId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/pages/featured.ts b/packages/backend/src/server/api/endpoints/pages/featured.ts index 38aa4dfacc..dbd8737b08 100644 --- a/packages/backend/src/server/api/endpoints/pages/featured.ts +++ b/packages/backend/src/server/api/endpoints/pages/featured.ts @@ -17,7 +17,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/pages/like.ts b/packages/backend/src/server/api/endpoints/pages/like.ts index d286fd2bfd..0eb110732f 100644 --- a/packages/backend/src/server/api/endpoints/pages/like.ts +++ b/packages/backend/src/server/api/endpoints/pages/like.ts @@ -31,7 +31,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { pageId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/pages/show.ts b/packages/backend/src/server/api/endpoints/pages/show.ts index 95243e411f..e330460f23 100644 --- a/packages/backend/src/server/api/endpoints/pages/show.ts +++ b/packages/backend/src/server/api/endpoints/pages/show.ts @@ -23,7 +23,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { pageId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/pages/unlike.ts b/packages/backend/src/server/api/endpoints/pages/unlike.ts index 582c924d91..f8efe8969a 100644 --- a/packages/backend/src/server/api/endpoints/pages/unlike.ts +++ b/packages/backend/src/server/api/endpoints/pages/unlike.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { pageId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/pages/update.ts b/packages/backend/src/server/api/endpoints/pages/update.ts index 686271cf46..8c81ea7463 100644 --- a/packages/backend/src/server/api/endpoints/pages/update.ts +++ b/packages/backend/src/server/api/endpoints/pages/update.ts @@ -42,7 +42,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { pageId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/ping.ts b/packages/backend/src/server/api/endpoints/ping.ts index 964401e19b..4f68965598 100644 --- a/packages/backend/src/server/api/endpoints/ping.ts +++ b/packages/backend/src/server/api/endpoints/ping.ts @@ -17,7 +17,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/pinned-users.ts b/packages/backend/src/server/api/endpoints/pinned-users.ts index 83657f8bf9..61c67949cf 100644 --- a/packages/backend/src/server/api/endpoints/pinned-users.ts +++ b/packages/backend/src/server/api/endpoints/pinned-users.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/promo/read.ts b/packages/backend/src/server/api/endpoints/promo/read.ts index 99be33fb0c..b811159834 100644 --- a/packages/backend/src/server/api/endpoints/promo/read.ts +++ b/packages/backend/src/server/api/endpoints/promo/read.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { noteId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/request-reset-password.ts b/packages/backend/src/server/api/endpoints/request-reset-password.ts index 193c3ee79d..af190583c0 100644 --- a/packages/backend/src/server/api/endpoints/request-reset-password.ts +++ b/packages/backend/src/server/api/endpoints/request-reset-password.ts @@ -22,7 +22,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { username: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/reset-db.ts b/packages/backend/src/server/api/endpoints/reset-db.ts index 1c1cb3f136..5a72c306ba 100644 --- a/packages/backend/src/server/api/endpoints/reset-db.ts +++ b/packages/backend/src/server/api/endpoints/reset-db.ts @@ -10,7 +10,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/reset-password.ts b/packages/backend/src/server/api/endpoints/reset-password.ts index 04048b9ef1..880ff682fb 100644 --- a/packages/backend/src/server/api/endpoints/reset-password.ts +++ b/packages/backend/src/server/api/endpoints/reset-password.ts @@ -12,7 +12,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { token: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/server-info.ts b/packages/backend/src/server/api/endpoints/server-info.ts index 4a5bc6a86c..97245575e8 100644 --- a/packages/backend/src/server/api/endpoints/server-info.ts +++ b/packages/backend/src/server/api/endpoints/server-info.ts @@ -8,7 +8,7 @@ export const meta = { tags: ['meta'], } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/stats.ts b/packages/backend/src/server/api/endpoints/stats.ts index 8abae921ac..7863d439ca 100644 --- a/packages/backend/src/server/api/endpoints/stats.ts +++ b/packages/backend/src/server/api/endpoints/stats.ts @@ -43,7 +43,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/sw/register.ts b/packages/backend/src/server/api/endpoints/sw/register.ts index 459b0dd969..9971bfb7d0 100644 --- a/packages/backend/src/server/api/endpoints/sw/register.ts +++ b/packages/backend/src/server/api/endpoints/sw/register.ts @@ -25,7 +25,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { endpoint: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/sw/unregister.ts b/packages/backend/src/server/api/endpoints/sw/unregister.ts index ec994c37c2..fc5fb0ce92 100644 --- a/packages/backend/src/server/api/endpoints/sw/unregister.ts +++ b/packages/backend/src/server/api/endpoints/sw/unregister.ts @@ -7,7 +7,7 @@ export const meta = { requireCredential: true, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { endpoint: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/test.ts b/packages/backend/src/server/api/endpoints/test.ts index 820448e677..ee04009308 100644 --- a/packages/backend/src/server/api/endpoints/test.ts +++ b/packages/backend/src/server/api/endpoints/test.ts @@ -4,7 +4,7 @@ export const meta = { requireCredential: false, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { required: { type: 'boolean' }, diff --git a/packages/backend/src/server/api/endpoints/username/available.ts b/packages/backend/src/server/api/endpoints/username/available.ts index 6e38d4d310..4564784a9b 100644 --- a/packages/backend/src/server/api/endpoints/username/available.ts +++ b/packages/backend/src/server/api/endpoints/username/available.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { username: Users.localUsernameSchema, diff --git a/packages/backend/src/server/api/endpoints/users.ts b/packages/backend/src/server/api/endpoints/users.ts index 0c03ac05c3..2406fcd2fc 100644 --- a/packages/backend/src/server/api/endpoints/users.ts +++ b/packages/backend/src/server/api/endpoints/users.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/users/clips.ts b/packages/backend/src/server/api/endpoints/users/clips.ts index e224bdf603..7abb94e2cf 100644 --- a/packages/backend/src/server/api/endpoints/users/clips.ts +++ b/packages/backend/src/server/api/endpoints/users/clips.ts @@ -6,7 +6,7 @@ export const meta = { tags: ['users', 'clips'], } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/followers.ts b/packages/backend/src/server/api/endpoints/users/followers.ts index 5607b4cc73..75f13a2929 100644 --- a/packages/backend/src/server/api/endpoints/users/followers.ts +++ b/packages/backend/src/server/api/endpoints/users/followers.ts @@ -34,7 +34,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/following.ts b/packages/backend/src/server/api/endpoints/users/following.ts index 36943232d1..b1af55169c 100644 --- a/packages/backend/src/server/api/endpoints/users/following.ts +++ b/packages/backend/src/server/api/endpoints/users/following.ts @@ -34,7 +34,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/gallery/posts.ts b/packages/backend/src/server/api/endpoints/users/gallery/posts.ts index e874a54c77..7accc0b627 100644 --- a/packages/backend/src/server/api/endpoints/users/gallery/posts.ts +++ b/packages/backend/src/server/api/endpoints/users/gallery/posts.ts @@ -6,7 +6,7 @@ export const meta = { tags: ['users', 'gallery'], } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/get-frequently-replied-users.ts b/packages/backend/src/server/api/endpoints/users/get-frequently-replied-users.ts index a08587cd16..5173982840 100644 --- a/packages/backend/src/server/api/endpoints/users/get-frequently-replied-users.ts +++ b/packages/backend/src/server/api/endpoints/users/get-frequently-replied-users.ts @@ -39,7 +39,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/groups/create.ts b/packages/backend/src/server/api/endpoints/users/groups/create.ts index e7bc95791f..358d3828a0 100644 --- a/packages/backend/src/server/api/endpoints/users/groups/create.ts +++ b/packages/backend/src/server/api/endpoints/users/groups/create.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { name: { type: 'string', minLength: 1, maxLength: 100 }, diff --git a/packages/backend/src/server/api/endpoints/users/groups/delete.ts b/packages/backend/src/server/api/endpoints/users/groups/delete.ts index cb30b4d813..ca8d864dcd 100644 --- a/packages/backend/src/server/api/endpoints/users/groups/delete.ts +++ b/packages/backend/src/server/api/endpoints/users/groups/delete.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { groupId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/groups/invitations/accept.ts b/packages/backend/src/server/api/endpoints/users/groups/invitations/accept.ts index 7a6a620cb3..31d3461280 100644 --- a/packages/backend/src/server/api/endpoints/users/groups/invitations/accept.ts +++ b/packages/backend/src/server/api/endpoints/users/groups/invitations/accept.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { invitationId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/groups/invitations/reject.ts b/packages/backend/src/server/api/endpoints/users/groups/invitations/reject.ts index b5c7f0908a..29b7612a8a 100644 --- a/packages/backend/src/server/api/endpoints/users/groups/invitations/reject.ts +++ b/packages/backend/src/server/api/endpoints/users/groups/invitations/reject.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { invitationId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/groups/invite.ts b/packages/backend/src/server/api/endpoints/users/groups/invite.ts index ba78a28a38..31eef02b2f 100644 --- a/packages/backend/src/server/api/endpoints/users/groups/invite.ts +++ b/packages/backend/src/server/api/endpoints/users/groups/invite.ts @@ -40,7 +40,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { groupId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/groups/joined.ts b/packages/backend/src/server/api/endpoints/users/groups/joined.ts index 192a52a66b..465585376e 100644 --- a/packages/backend/src/server/api/endpoints/users/groups/joined.ts +++ b/packages/backend/src/server/api/endpoints/users/groups/joined.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/users/groups/leave.ts b/packages/backend/src/server/api/endpoints/users/groups/leave.ts index b7c7b328fd..56b5330c83 100644 --- a/packages/backend/src/server/api/endpoints/users/groups/leave.ts +++ b/packages/backend/src/server/api/endpoints/users/groups/leave.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { groupId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/groups/owned.ts b/packages/backend/src/server/api/endpoints/users/groups/owned.ts index 4592fc437f..a3724a0547 100644 --- a/packages/backend/src/server/api/endpoints/users/groups/owned.ts +++ b/packages/backend/src/server/api/endpoints/users/groups/owned.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/users/groups/pull.ts b/packages/backend/src/server/api/endpoints/users/groups/pull.ts index d50f61b159..dd93faa62e 100644 --- a/packages/backend/src/server/api/endpoints/users/groups/pull.ts +++ b/packages/backend/src/server/api/endpoints/users/groups/pull.ts @@ -31,7 +31,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { groupId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/groups/show.ts b/packages/backend/src/server/api/endpoints/users/groups/show.ts index 230254060d..799ec3202e 100644 --- a/packages/backend/src/server/api/endpoints/users/groups/show.ts +++ b/packages/backend/src/server/api/endpoints/users/groups/show.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { groupId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/groups/transfer.ts b/packages/backend/src/server/api/endpoints/users/groups/transfer.ts index 4b5206fa18..bb3b7f11c2 100644 --- a/packages/backend/src/server/api/endpoints/users/groups/transfer.ts +++ b/packages/backend/src/server/api/endpoints/users/groups/transfer.ts @@ -37,7 +37,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { groupId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/groups/update.ts b/packages/backend/src/server/api/endpoints/users/groups/update.ts index 0714fb4bd4..6c8851889a 100644 --- a/packages/backend/src/server/api/endpoints/users/groups/update.ts +++ b/packages/backend/src/server/api/endpoints/users/groups/update.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { groupId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/lists/create.ts b/packages/backend/src/server/api/endpoints/users/lists/create.ts index 0a74424e0e..c0c37f96f1 100644 --- a/packages/backend/src/server/api/endpoints/users/lists/create.ts +++ b/packages/backend/src/server/api/endpoints/users/lists/create.ts @@ -17,7 +17,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { name: { type: 'string', minLength: 1, maxLength: 100 }, diff --git a/packages/backend/src/server/api/endpoints/users/lists/delete.ts b/packages/backend/src/server/api/endpoints/users/lists/delete.ts index 6795a227dc..0f7fdbc908 100644 --- a/packages/backend/src/server/api/endpoints/users/lists/delete.ts +++ b/packages/backend/src/server/api/endpoints/users/lists/delete.ts @@ -18,7 +18,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { listId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/lists/list.ts b/packages/backend/src/server/api/endpoints/users/lists/list.ts index d439723403..5245c57849 100644 --- a/packages/backend/src/server/api/endpoints/users/lists/list.ts +++ b/packages/backend/src/server/api/endpoints/users/lists/list.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: {}, required: [], diff --git a/packages/backend/src/server/api/endpoints/users/lists/pull.ts b/packages/backend/src/server/api/endpoints/users/lists/pull.ts index 5eca5a999d..45b0b41564 100644 --- a/packages/backend/src/server/api/endpoints/users/lists/pull.ts +++ b/packages/backend/src/server/api/endpoints/users/lists/pull.ts @@ -26,7 +26,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { listId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/lists/push.ts b/packages/backend/src/server/api/endpoints/users/lists/push.ts index 68a1f00774..252f7e6e19 100644 --- a/packages/backend/src/server/api/endpoints/users/lists/push.ts +++ b/packages/backend/src/server/api/endpoints/users/lists/push.ts @@ -38,7 +38,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { listId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/lists/show.ts b/packages/backend/src/server/api/endpoints/users/lists/show.ts index 3e9aa836ba..91a2bf55a4 100644 --- a/packages/backend/src/server/api/endpoints/users/lists/show.ts +++ b/packages/backend/src/server/api/endpoints/users/lists/show.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { listId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/lists/update.ts b/packages/backend/src/server/api/endpoints/users/lists/update.ts index ee1489fc6a..3e3f6ec9fe 100644 --- a/packages/backend/src/server/api/endpoints/users/lists/update.ts +++ b/packages/backend/src/server/api/endpoints/users/lists/update.ts @@ -24,7 +24,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { listId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/notes.ts b/packages/backend/src/server/api/endpoints/users/notes.ts index 956d90b7ad..4c27fb8ee4 100644 --- a/packages/backend/src/server/api/endpoints/users/notes.ts +++ b/packages/backend/src/server/api/endpoints/users/notes.ts @@ -31,7 +31,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/pages.ts b/packages/backend/src/server/api/endpoints/users/pages.ts index 873b5e80fa..f7b39b75fd 100644 --- a/packages/backend/src/server/api/endpoints/users/pages.ts +++ b/packages/backend/src/server/api/endpoints/users/pages.ts @@ -6,7 +6,7 @@ export const meta = { tags: ['users', 'pages'], } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/reactions.ts b/packages/backend/src/server/api/endpoints/users/reactions.ts index 8d968210bc..c9b5a95639 100644 --- a/packages/backend/src/server/api/endpoints/users/reactions.ts +++ b/packages/backend/src/server/api/endpoints/users/reactions.ts @@ -28,7 +28,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/recommendation.ts b/packages/backend/src/server/api/endpoints/users/recommendation.ts index 4a2d8d7e4a..78c2f3e1a4 100644 --- a/packages/backend/src/server/api/endpoints/users/recommendation.ts +++ b/packages/backend/src/server/api/endpoints/users/recommendation.ts @@ -22,7 +22,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, diff --git a/packages/backend/src/server/api/endpoints/users/relation.ts b/packages/backend/src/server/api/endpoints/users/relation.ts index fac1a4b92d..140126cab5 100644 --- a/packages/backend/src/server/api/endpoints/users/relation.ts +++ b/packages/backend/src/server/api/endpoints/users/relation.ts @@ -93,7 +93,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { diff --git a/packages/backend/src/server/api/endpoints/users/report-abuse.ts b/packages/backend/src/server/api/endpoints/users/report-abuse.ts index 1df5e1573f..717724a4cf 100644 --- a/packages/backend/src/server/api/endpoints/users/report-abuse.ts +++ b/packages/backend/src/server/api/endpoints/users/report-abuse.ts @@ -34,7 +34,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/search-by-username-and-host.ts b/packages/backend/src/server/api/endpoints/users/search-by-username-and-host.ts index 433779ae2d..15a93bc4f8 100644 --- a/packages/backend/src/server/api/endpoints/users/search-by-username-and-host.ts +++ b/packages/backend/src/server/api/endpoints/users/search-by-username-and-host.ts @@ -20,7 +20,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { username: { type: 'string', nullable: true }, diff --git a/packages/backend/src/server/api/endpoints/users/search.ts b/packages/backend/src/server/api/endpoints/users/search.ts index 8c28e7c3a6..9d772f0968 100644 --- a/packages/backend/src/server/api/endpoints/users/search.ts +++ b/packages/backend/src/server/api/endpoints/users/search.ts @@ -19,7 +19,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { query: { type: 'string' }, diff --git a/packages/backend/src/server/api/endpoints/users/show.ts b/packages/backend/src/server/api/endpoints/users/show.ts index 29c90963ad..cb42cc80a0 100644 --- a/packages/backend/src/server/api/endpoints/users/show.ts +++ b/packages/backend/src/server/api/endpoints/users/show.ts @@ -44,7 +44,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' }, diff --git a/packages/backend/src/server/api/endpoints/users/stats.ts b/packages/backend/src/server/api/endpoints/users/stats.ts index 29dd8fdf93..2f4ca10fc1 100644 --- a/packages/backend/src/server/api/endpoints/users/stats.ts +++ b/packages/backend/src/server/api/endpoints/users/stats.ts @@ -16,7 +16,7 @@ export const meta = { }, } as const; -const paramDef = { +export const paramDef = { type: 'object', properties: { userId: { type: 'string', format: 'misskey:id' },