Files
dify/web/gen/orpc/api/apps.ts
Stephen Zhou 4061c83b26 no sufix
2026-01-25 16:19:07 +08:00

91 lines
3.5 KiB
TypeScript

// This file is auto-generated by @hey-api/openapi-ts
import { z } from 'zod'
import { zCreateAnnotationData, zCreateAnnotationResponse, zDeleteAnnotationData, zGetAnnotationListData, zGetAnnotationListResponse, zGetInitialAnnotationReplySettingsStatusData, zGetInitialAnnotationReplySettingsStatusResponse, zInitialAnnotationReplySettingsData, zInitialAnnotationReplySettingsResponse, zUpdateAnnotationData, zUpdateAnnotationResponse } from '../../zod/api/apps'
import { base } from '../common'
/**
* Get Annotation List
*
* Retrieves a list of annotations for the application.
*/
export const getAnnotationListContract = base.route({
path: '/apps/annotations',
method: 'GET',
operationId: 'getAnnotationList',
summary: 'Get Annotation List',
description: 'Retrieves a list of annotations for the application.',
tags: ['Annotations'],
}).input(zGetAnnotationListData).output(z.object({ body: zGetAnnotationListResponse, status: z.literal(200) }))
/**
* Create Annotation
*
* Creates a new annotation.
*/
export const createAnnotationContract = base.route({
path: '/apps/annotations',
method: 'POST',
operationId: 'createAnnotation',
summary: 'Create Annotation',
description: 'Creates a new annotation.',
tags: ['Annotations'],
}).input(zCreateAnnotationData).output(z.object({ body: zCreateAnnotationResponse, status: z.literal(200) }))
/**
* Delete Annotation
*
* Deletes an annotation.
*/
export const deleteAnnotationContract = base.route({
path: '/apps/annotations/{annotation_id}',
method: 'DELETE',
operationId: 'deleteAnnotation',
summary: 'Delete Annotation',
description: 'Deletes an annotation.',
tags: ['Annotations'],
}).input(zDeleteAnnotationData)
/**
* Update Annotation
*
* Updates an existing annotation.
*/
export const updateAnnotationContract = base.route({
path: '/apps/annotations/{annotation_id}',
method: 'PUT',
operationId: 'updateAnnotation',
summary: 'Update Annotation',
description: 'Updates an existing annotation.',
tags: ['Annotations'],
}).input(zUpdateAnnotationData).output(z.object({ body: zUpdateAnnotationResponse, status: z.literal(200) }))
/**
* Initial Annotation Reply Settings
*
* Enable or disable annotation reply settings and configure embedding models. This interface is executed asynchronously.
*/
export const initialAnnotationReplySettingsContract = base.route({
path: '/apps/annotation-reply/{action}',
method: 'POST',
operationId: 'initialAnnotationReplySettings',
summary: 'Initial Annotation Reply Settings',
description: 'Enable or disable annotation reply settings and configure embedding models. This interface is executed asynchronously.',
tags: ['Annotations'],
}).input(zInitialAnnotationReplySettingsData).output(z.object({ body: zInitialAnnotationReplySettingsResponse, status: z.literal(200) }))
/**
* Query Initial Annotation Reply Settings Task Status
*
* Queries the status of an asynchronously executed annotation reply settings task.
*/
export const getInitialAnnotationReplySettingsStatusContract = base.route({
path: '/apps/annotation-reply/{action}/status/{job_id}',
method: 'GET',
operationId: 'getInitialAnnotationReplySettingsStatus',
summary: 'Query Initial Annotation Reply Settings Task Status',
description: 'Queries the status of an asynchronously executed annotation reply settings task.',
tags: ['Annotations'],
}).input(zGetInitialAnnotationReplySettingsStatusData).output(z.object({ body: zGetInitialAnnotationReplySettingsStatusResponse, status: z.literal(200) }))