monkeeShark/packages/misskey-js/src/schemas/ad.ts

48 lines
933 B
TypeScript
Raw Normal View History

2023-05-15 08:39:41 +00:00
import type { JSONSchema7Definition } from 'schema-type';
export const packedAdSchema = {
$id: 'https://misskey-hub.net/api/schemas/Ad',
type: 'object',
properties: {
id: { $ref: 'https://misskey-hub.net/api/schemas/Id' },
createdAt: {
type: 'string',
format: 'date-time',
},
expiresAt: {
type: 'string',
format: 'date-time',
},
startsAt: {
type: 'string',
format: 'date-time',
},
place: {
type: 'string',
},
property: {
type: 'string',
},
ratio: {
type: 'number',
},
imageUrl: {
type: ['string', 'null'],
},
memo: {
type: 'string',
},
},
required: [
'id',
'createdAt',
'expiresAt',
'startsAt',
'place',
'ratio',
'imageUrl',
'memo',
],
} as const satisfies JSONSchema7Definition;