mirror of
https://github.com/documenso/documenso.git
synced 2025-11-10 04:22:32 +10:00
feat: update contract
This commit is contained in:
@ -19,13 +19,18 @@ const DocumentSchema = z.object({
|
||||
completedAt: z.date().nullable(),
|
||||
});
|
||||
|
||||
const SuccessfulResponse = z.object({
|
||||
documents: DocumentSchema.array(),
|
||||
totalPages: z.number(),
|
||||
});
|
||||
|
||||
export const contract = c.router({
|
||||
getDocuments: {
|
||||
method: 'GET',
|
||||
path: '/documents',
|
||||
query: GetDocumentsQuery,
|
||||
responses: {
|
||||
200: DocumentSchema.array(),
|
||||
200: SuccessfulResponse,
|
||||
},
|
||||
summary: 'Get all documents for a user',
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user