improve docs

This commit is contained in:
Johann150 2022-10-20 21:22:34 +02:00
parent cfb8723618
commit b359b01700
Signed by untrusted user: Johann150
GPG key ID: 9EE6577A2A06F8F1
3 changed files with 7 additions and 3 deletions

View file

@ -16,7 +16,7 @@ export const meta = {
errors: { errors: {
noSuchFile: { noSuchFile: {
message: 'No such file.', message: 'No such file.',
code: 'MO_SUCH_FILE', code: 'NO_SUCH_FILE',
id: 'fc46b5a4-6b92-4c33-ac66-b806659bb5cf', id: 'fc46b5a4-6b92-4c33-ac66-b806659bb5cf',
}, },
}, },

View file

@ -36,7 +36,11 @@ export const paramDef = {
type: 'object', type: 'object',
properties: { properties: {
noteId: { type: 'string', format: 'misskey:id' }, noteId: { type: 'string', format: 'misskey:id' },
type: { type: 'string', nullable: true }, type: {
description: 'A Unicode emoji or custom emoji code. A custom emoji should look like `:name:` or `:name@example.com`.',
type: 'string',
nullable: true,
},
limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 }, limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 },
offset: { type: 'integer', default: 0 }, offset: { type: 'integer', default: 0 },
sinceId: { type: 'string', format: 'misskey:id' }, sinceId: { type: 'string', format: 'misskey:id' },

View file

@ -168,7 +168,7 @@ export function genOpenapiSpec() {
}, },
...(endpoint.meta.limit ? { ...(endpoint.meta.limit ? {
'429': { '429': {
description: 'To many requests', description: 'Too many requests',
content: { content: {
'application/json': { 'application/json': {
schema: { schema: {