mirror of
https://github.com/versia-pub/server.git
synced 2026-04-28 05:09:16 +02:00
refactor(api): ♻️ Move all client schema code to new package
This commit is contained in:
parent
52602c3da7
commit
3fe07a79b8
128 changed files with 3904 additions and 169 deletions
23
packages/client/schemas/search.ts
Normal file
23
packages/client/schemas/search.ts
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
import { z } from "@hono/zod-openapi";
|
||||
import { Account } from "./account.ts";
|
||||
import { Status } from "./status.ts";
|
||||
import { Tag } from "./tag.ts";
|
||||
|
||||
export const Search = z
|
||||
.object({
|
||||
accounts: z.array(Account).openapi({
|
||||
description: "Accounts which match the given query",
|
||||
}),
|
||||
statuses: z.array(Status).openapi({
|
||||
description: "Statuses which match the given query",
|
||||
}),
|
||||
hashtags: z.array(Tag).openapi({
|
||||
description: "Hashtags which match the given query",
|
||||
}),
|
||||
})
|
||||
.openapi({
|
||||
description: "Represents the results of a search.",
|
||||
externalDocs: {
|
||||
url: "https://docs.joinmastodon.org/entities/Search",
|
||||
},
|
||||
});
|
||||
Loading…
Add table
Add a link
Reference in a new issue