mirror of
https://github.com/misskey-dev/misskey.git
synced 2026-03-24 04:53:33 +00:00
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>
This commit is contained in:
@@ -3,6 +3,11 @@ import { destroy } from '../../../../../queue';
|
||||
import { insertModerationLog } from '../../../../../services/insert-moderation-log';
|
||||
|
||||
export const meta = {
|
||||
desc: {
|
||||
'ja-JP': 'ジョブキューを全て削除します。',
|
||||
'en-US': 'Delete all job queues.'
|
||||
},
|
||||
|
||||
tags: ['admin'],
|
||||
|
||||
requireCredential: true as const,
|
||||
|
||||
@@ -2,12 +2,42 @@ import define from '../../../define';
|
||||
import { deliverQueue } from '../../../../../queue';
|
||||
|
||||
export const meta = {
|
||||
desc: {
|
||||
'ja-JP': '他サーバーへ送るキューの遅延一覧を返します。',
|
||||
'en-US': 'Returns a list of delays in queues sent to other servers.'
|
||||
},
|
||||
|
||||
tags: ['admin'],
|
||||
|
||||
requireCredential: true as const,
|
||||
requireModerator: true,
|
||||
|
||||
params: {
|
||||
},
|
||||
|
||||
res: {
|
||||
type: 'array' as const,
|
||||
optional: false as const, nullable: false as const,
|
||||
items: {
|
||||
type: 'array' as const,
|
||||
optional: false as const, nullable: false as const,
|
||||
items: {
|
||||
anyOf: [
|
||||
{
|
||||
type: 'string' as const,
|
||||
description: 'FQDN to fediverse server'
|
||||
},
|
||||
{
|
||||
type: 'number' as const,
|
||||
description: 'Delayed queue counts'
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
example: [[
|
||||
'example.com',
|
||||
12
|
||||
]]
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -2,12 +2,42 @@ import define from '../../../define';
|
||||
import { inboxQueue } from '../../../../../queue';
|
||||
|
||||
export const meta = {
|
||||
desc: {
|
||||
'ja-JP': 'このサーバーへのキューの遅延一覧を返します。',
|
||||
'en-US': 'Returns a list of queue delays to this server.'
|
||||
},
|
||||
|
||||
tags: ['admin'],
|
||||
|
||||
requireCredential: true as const,
|
||||
requireModerator: true,
|
||||
|
||||
params: {
|
||||
},
|
||||
|
||||
res: {
|
||||
type: 'array' as const,
|
||||
optional: false as const, nullable: false as const,
|
||||
items: {
|
||||
type: 'array' as const,
|
||||
optional: false as const, nullable: false as const,
|
||||
items: {
|
||||
anyOf: [
|
||||
{
|
||||
type: 'string' as const,
|
||||
description: 'FQDN to fediverse server'
|
||||
},
|
||||
{
|
||||
type: 'number' as const,
|
||||
description: 'Delayed queue counts'
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
example: [[
|
||||
'example.com',
|
||||
12
|
||||
]]
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -3,6 +3,11 @@ import define from '../../../define';
|
||||
import { deliverQueue, inboxQueue, dbQueue, objectStorageQueue } from '../../../../../queue';
|
||||
|
||||
export const meta = {
|
||||
desc: {
|
||||
'ja-JP': 'ジョブ一覧を表示します。',
|
||||
'en-US': 'Display the job list.'
|
||||
},
|
||||
|
||||
tags: ['admin'],
|
||||
|
||||
requireCredential: true as const,
|
||||
@@ -21,6 +26,38 @@ export const meta = {
|
||||
validator: $.optional.num,
|
||||
default: 50
|
||||
},
|
||||
},
|
||||
|
||||
res: {
|
||||
type: 'array' as const,
|
||||
optional: false as const, nullable: false as const,
|
||||
items: {
|
||||
type: 'object' as const,
|
||||
optional: false as const, nullable: false as const,
|
||||
properties: {
|
||||
id: {
|
||||
type: 'string' as const,
|
||||
optional: false as const, nullable: false as const,
|
||||
format: 'id'
|
||||
},
|
||||
data: {
|
||||
type: 'object' as const,
|
||||
optional: false as const, nullable: false as const
|
||||
},
|
||||
attempts: {
|
||||
type: 'number' as const,
|
||||
optional: false as const, nullable: false as const
|
||||
},
|
||||
maxAttempts: {
|
||||
type: 'number' as const,
|
||||
optional: false as const, nullable: false as const
|
||||
},
|
||||
timestamp: {
|
||||
type: 'number' as const,
|
||||
optional: false as const, nullable: false as const
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -2,12 +2,36 @@ import define from '../../../define';
|
||||
import { deliverQueue, inboxQueue, dbQueue, objectStorageQueue } from '../../../../../queue';
|
||||
|
||||
export const meta = {
|
||||
desc: {
|
||||
'ja-JP': 'キューの状態を返します。',
|
||||
'en-US': 'Returns the status of the queue.'
|
||||
},
|
||||
|
||||
tags: ['admin'],
|
||||
|
||||
requireCredential: true as const,
|
||||
requireModerator: true,
|
||||
|
||||
params: {}
|
||||
params: {},
|
||||
|
||||
res: {
|
||||
type: 'object' as const,
|
||||
optional: false as const, nullable: false as const,
|
||||
properties: {
|
||||
deliver: {
|
||||
ref: 'QueueCount'
|
||||
},
|
||||
inbox: {
|
||||
ref: 'QueueCount'
|
||||
},
|
||||
db: {
|
||||
ref: 'QueueCount'
|
||||
},
|
||||
objectStorage: {
|
||||
ref: 'QueueCount'
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
export default define(meta, async (ps) => {
|
||||
|
||||
Reference in New Issue
Block a user