diff --git a/packages/backend/src/core/WebhookTestService.ts b/packages/backend/src/core/WebhookTestService.ts index 2f8cfea7f7..e9be72c8a4 100644 --- a/packages/backend/src/core/WebhookTestService.ts +++ b/packages/backend/src/core/WebhookTestService.ts @@ -427,10 +427,12 @@ export class WebhookTestService { private async toPackedUserLite(user: MiUser, override?: Packed<'UserLite'>): Promise> { return { ...user, + createdAt: new Date(Date.now() - oneDayMillis * 9).toISOString(), id: user.id, name: user.name, username: user.username, host: user.host, + description: 'dummy user', avatarUrl: user.avatarId == null ? null : user.avatarUrl, avatarBlurhash: user.avatarId == null ? null : user.avatarBlurhash, avatarDecorations: user.avatarDecorations.map(it => ({ diff --git a/packages/backend/src/models/json-schema/user.ts b/packages/backend/src/models/json-schema/user.ts index 2f3cd5d36c..013d8949c8 100644 --- a/packages/backend/src/models/json-schema/user.ts +++ b/packages/backend/src/models/json-schema/user.ts @@ -64,6 +64,20 @@ export const packedUserLiteSchema = { example: 'misskey.example.com', description: 'The local host is represented with `null`.', }, + createdAt: { + type: 'string', + nullable: false, optional: false, + format: 'date-time', + }, + approved: { + type: 'boolean', + nullable: false, optional: false, + }, + description: { + type: 'string', + nullable: true, optional: false, + example: 'Hi masters, I am Ai!', + }, avatarUrl: { type: 'string', format: 'url', @@ -202,6 +216,18 @@ export const packedUserLiteSchema = { }, }, }, + followersCount: { + type: 'number', + nullable: false, optional: false, + }, + followingCount: { + type: 'number', + nullable: false, optional: false, + }, + notesCount: { + type: 'number', + nullable: false, optional: false, + }, emojis: { type: 'object', nullable: false, optional: false, @@ -266,11 +292,6 @@ export const packedUserDetailedNotMeOnlySchema = { nullable: false, optional: false, }, }, - createdAt: { - type: 'string', - nullable: false, optional: false, - format: 'date-time', - }, updatedAt: { type: 'string', nullable: true, optional: false, @@ -312,11 +333,6 @@ export const packedUserDetailedNotMeOnlySchema = { nullable: false, optional: false, example: false, }, - description: { - type: 'string', - nullable: true, optional: false, - example: 'Hi masters, I am Ai!', - }, location: { type: 'string', nullable: true, optional: false, @@ -365,18 +381,6 @@ export const packedUserDetailedNotMeOnlySchema = { format: 'url', }, }, - followersCount: { - type: 'number', - nullable: false, optional: false, - }, - followingCount: { - type: 'number', - nullable: false, optional: false, - }, - notesCount: { - type: 'number', - nullable: false, optional: false, - }, pinnedNoteIds: { type: 'array', nullable: false, optional: false, @@ -739,6 +743,10 @@ export const packedMeDetailedOnlySchema = { type: 'boolean', nullable: true, optional: true, }, + signupReason: { + type: 'string', + nullable: true, optional: true, + }, securityKeysList: { type: 'array', nullable: false, optional: true, diff --git a/packages/misskey-js/src/autogen/types.ts b/packages/misskey-js/src/autogen/types.ts index 72535250d0..7ceadd3108 100644 --- a/packages/misskey-js/src/autogen/types.ts +++ b/packages/misskey-js/src/autogen/types.ts @@ -4243,6 +4243,11 @@ export type components = { * @example misskey.example.com */ host: string | null; + /** Format: date-time */ + createdAt: string; + approved: boolean; + /** @example Hi masters, I am Ai! */ + description: string | null; /** Format: url */ avatarUrl: string | null; avatarBlurhash: string | null; @@ -4282,6 +4287,9 @@ export type components = { faviconUrl: string | null; themeColor: string | null; }; + followersCount: number; + followingCount: number; + notesCount: number; emojis: { [key: string]: string; }; @@ -4302,8 +4310,6 @@ export type components = { movedTo: string | null; alsoKnownAs: string[] | null; /** Format: date-time */ - createdAt: string; - /** Format: date-time */ updatedAt: string | null; /** Format: date-time */ lastFetchedAt: string | null; @@ -4317,8 +4323,6 @@ export type components = { isSilenced: boolean; /** @example false */ isSuspended: boolean; - /** @example Hi masters, I am Ai! */ - description: string | null; location: string | null; /** @example 2018-03-12 */ birthday: string | null; @@ -4331,9 +4335,6 @@ export type components = { value: string; }[]; verifiedLinks: string[]; - followersCount: number; - followingCount: number; - notesCount: number; pinnedNoteIds: string[]; pinnedNotes: components['schemas']['Note'][]; pinnedPageId: string | null; @@ -4552,6 +4553,7 @@ export type components = { securityKeys: boolean; email?: string | null; emailVerified?: boolean | null; + signupReason?: string | null; securityKeysList?: { /** * Format: id