summaryrefslogtreecommitdiff
path: root/src/server/api/endpoints/admin/show-user.ts
diff options
context:
space:
mode:
authorYuzuRyo61 <yuzuryo61@yuzulia.work>2021-03-06 22:34:11 +0900
committerGitHub <noreply@github.com>2021-03-06 22:34:11 +0900
commita07d753da84191bc8c185a7bcd6d73fab9529b5d (patch)
tree085bc62b1f979020796a73373c3050f4948ed2bd /src/server/api/endpoints/admin/show-user.ts
parentfeat: video play inline (using video tag) (#7242) (diff)
downloadsharkey-a07d753da84191bc8c185a7bcd6d73fab9529b5d.tar.gz
sharkey-a07d753da84191bc8c185a7bcd6d73fab9529b5d.tar.bz2
sharkey-a07d753da84191bc8c185a7bcd6d73fab9529b5d.zip
APIドキュメントの改善 (#6757)
* Update api document in admin/announcements * Update api document in announcements * Update api document in i/read-announcements * Update api document in username/available * Update api document & Fix typo in API 403 error * Update api document * Update api document * Update api document * Fix API permission definition * Update api document * Update api document * Update api document * Update api document * Update api document * Update api document * Update api document * Update api document * Fix bug in users (api) * Apply reviews #6757 * Apply reviews #6757 Co-authored-by: syuilo <Syuilotan@yahoo.co.jp>
Diffstat (limited to 'src/server/api/endpoints/admin/show-user.ts')
-rw-r--r--src/server/api/endpoints/admin/show-user.ts146
1 files changed, 145 insertions, 1 deletions
diff --git a/src/server/api/endpoints/admin/show-user.ts b/src/server/api/endpoints/admin/show-user.ts
index ea4df141f3..63889a9e6b 100644
--- a/src/server/api/endpoints/admin/show-user.ts
+++ b/src/server/api/endpoints/admin/show-user.ts
@@ -5,7 +5,8 @@ import { Users } from '../../../../models';
export const meta = {
desc: {
- 'ja-JP': '指定したユーザーの情報を取得します。',
+ 'ja-JP': '指定したユーザーの情報を取得します(管理者向け)。',
+ 'en-US': 'Gets the information of the specified user (for administrators).'
},
tags: ['admin'],
@@ -21,6 +22,149 @@ export const meta = {
'en-US': 'The user ID which you want to suspend'
}
},
+ },
+
+ res: {
+ type: 'object' as const,
+ nullable: false as const, optional: false as const,
+ properties: {
+ id: {
+ type: 'string' as const,
+ nullable: false as const, optional: false as const,
+ format: 'id'
+ },
+ createdAt: {
+ type: 'string' as const,
+ nullable: false as const, optional: false as const,
+ format: 'date-time'
+ },
+ updatedAt: {
+ type: 'string' as const,
+ nullable: true as const, optional: false as const,
+ format: 'date-time'
+ },
+ lastFetchedAt: {
+ type: 'string' as const,
+ nullable: true as const, optional: false as const
+ },
+ username: {
+ type: 'string' as const,
+ nullable: false as const, optional: false as const
+ },
+ name: {
+ type: 'string' as const,
+ nullable: false as const, optional: false as const
+ },
+ folowersCount: {
+ type: 'number' as const,
+ nullable: false as const, optional: false as const
+ },
+ followingCount: {
+ type: 'number' as const,
+ nullable: false as const, optional: false as const
+ },
+ notesCount: {
+ type: 'number' as const,
+ nullable: false as const, optional: false as const
+ },
+ avatarId: {
+ type: 'string' as const,
+ nullable: true as const, optional: false as const
+ },
+ bannerId: {
+ type: 'string' as const,
+ nullable: true as const, optional: false as const
+ },
+ tags: {
+ type: 'array' as const,
+ nullable: false as const, optional: false as const,
+ items: {
+ type: 'string' as const,
+ nullable: false as const, optional: false as const
+ }
+ },
+ avatarUrl: {
+ type: 'string' as const,
+ nullable: true as const, optional: false as const,
+ format: 'url'
+ },
+ bannerUrl: {
+ type: 'string' as const,
+ nullable: true as const, optional: false as const,
+ format: 'url'
+ },
+ avatarBlurhash: {
+ type: 'any' as const,
+ nullable: true as const, optional: false as const,
+ default: null
+ },
+ bannerBlurhash: {
+ type: 'any' as const,
+ nullable: true as const, optional: false as const,
+ default: null
+ },
+ isSuspended: {
+ type: 'boolean' as const,
+ nullable: false as const, optional: false as const
+ },
+ isSilenced: {
+ type: 'boolean' as const,
+ nullable: false as const, optional: false as const
+ },
+ isLocked: {
+ type: 'boolean' as const,
+ nullable: false as const, optional: false as const,
+ },
+ isBot: {
+ type: 'boolean' as const,
+ nullable: false as const, optional: false as const
+ },
+ isCat: {
+ type: 'boolean' as const,
+ nullable: false as const, optional: false as const
+ },
+ isAdmin: {
+ type: 'boolean' as const,
+ nullable: false as const, optional: false as const
+ },
+ isModerator: {
+ type: 'boolean' as const,
+ nullable: false as const, optional: false as const
+ },
+ emojis: {
+ type: 'array' as const,
+ nullable: false as const, optional: false as const,
+ items: {
+ type: 'string' as const,
+ nullable: false as const, optional: false as const
+ }
+ },
+ host: {
+ type: 'string' as const,
+ nullable: true as const, optional: false as const
+ },
+ inbox: {
+ type: 'string' as const,
+ nullable: true as const, optional: false as const
+ },
+ sharedInbox: {
+ type: 'string' as const,
+ nullable: true as const, optional: false as const
+ },
+ featured: {
+ type: 'string' as const,
+ nullable: true as const, optional: false as const
+ },
+ uri: {
+ type: 'string' as const,
+ nullable: true as const, optional: false as const
+ },
+ token: {
+ type: 'string' as const,
+ nullable: false as const, optional: false as const,
+ default: '<MASKED>'
+ }
+ }
}
};