mirror of
https://github.com/hotomoe/hotomoe
synced 2024-11-24 23:26:17 +09:00
Improve doc
This commit is contained in:
parent
f4ae939124
commit
fcc6a65e08
@ -30,6 +30,13 @@ export const meta = {
|
||||
}
|
||||
},
|
||||
|
||||
res: {
|
||||
type: 'array',
|
||||
items: {
|
||||
type: 'Note',
|
||||
},
|
||||
},
|
||||
|
||||
errors: {
|
||||
noSuchFile: {
|
||||
message: 'No such file.',
|
||||
|
@ -21,7 +21,11 @@ export const meta = {
|
||||
'ja-JP': 'ファイルのMD5ハッシュ'
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
res: {
|
||||
type: 'DriveFile',
|
||||
},
|
||||
};
|
||||
|
||||
export default define(meta, async (ps, user) => {
|
||||
|
@ -29,7 +29,14 @@ export const meta = {
|
||||
type: {
|
||||
validator: $.optional.str.match(/^[a-zA-Z\/\-\*]+$/)
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
res: {
|
||||
type: 'array',
|
||||
items: {
|
||||
type: 'DriveFile',
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
export default define(meta, async (ps, user) => {
|
||||
|
@ -54,7 +54,14 @@ export const meta = {
|
||||
validator: $.optional.arr($.str.or(['follow', 'mention', 'reply', 'renote', 'quote', 'reaction', 'poll_vote', 'receiveFollowRequest'])),
|
||||
default: [] as string[]
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
res: {
|
||||
type: 'array',
|
||||
items: {
|
||||
type: 'Notification',
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
export default define(meta, async (ps, user) => {
|
||||
|
@ -146,6 +146,28 @@ export const schemas = {
|
||||
required: ['id', 'userId', 'createdAt']
|
||||
},
|
||||
|
||||
Notification: {
|
||||
type: 'object',
|
||||
properties: {
|
||||
id: {
|
||||
type: 'string',
|
||||
format: 'id',
|
||||
description: 'The unique identifier for this notification.'
|
||||
},
|
||||
createdAt: {
|
||||
type: 'string',
|
||||
format: 'date-time',
|
||||
description: 'The date that the notification was created.'
|
||||
},
|
||||
type: {
|
||||
type: 'string',
|
||||
enum: ['follow', 'receiveFollowRequest', 'mention', 'reply', 'renote', 'quote', 'reaction', 'poll_vote'],
|
||||
description: 'The type of the notification.'
|
||||
},
|
||||
},
|
||||
required: ['id', 'createdAt', 'type']
|
||||
},
|
||||
|
||||
DriveFile: {
|
||||
type: 'object',
|
||||
properties: {
|
||||
|
Loading…
Reference in New Issue
Block a user