mirror of
https://github.com/langgenius/dify.git
synced 2026-05-26 22:00:53 -04:00
204 lines
6.2 KiB
TypeScript
204 lines
6.2 KiB
TypeScript
// This file is auto-generated by @hey-api/openapi-ts
|
|
|
|
import { oc } from '@orpc/contract'
|
|
import * as z from 'zod'
|
|
|
|
import {
|
|
zDeleteAgentsByAgentIdPath,
|
|
zDeleteAgentsByAgentIdResponse,
|
|
zGetAgentsByAgentIdPath,
|
|
zGetAgentsByAgentIdResponse,
|
|
zGetAgentsByAgentIdVersionsByVersionIdPath,
|
|
zGetAgentsByAgentIdVersionsByVersionIdResponse,
|
|
zGetAgentsByAgentIdVersionsPath,
|
|
zGetAgentsByAgentIdVersionsResponse,
|
|
zGetAgentsInviteOptionsResponse,
|
|
zGetAgentsResponse,
|
|
zPatchAgentsByAgentIdBody,
|
|
zPatchAgentsByAgentIdPath,
|
|
zPatchAgentsByAgentIdResponse,
|
|
zPostAgentsBody,
|
|
zPostAgentsResponse,
|
|
} from './zod.gen'
|
|
|
|
/**
|
|
* Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.
|
|
*
|
|
* @deprecated
|
|
*/
|
|
export const get = oc
|
|
.route({
|
|
deprecated: true,
|
|
description:
|
|
'Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.',
|
|
inputStructure: 'detailed',
|
|
method: 'GET',
|
|
operationId: 'getAgentsInviteOptions',
|
|
path: '/agents/invite-options',
|
|
tags: ['console'],
|
|
})
|
|
.output(zGetAgentsInviteOptionsResponse)
|
|
|
|
export const inviteOptions = {
|
|
get,
|
|
}
|
|
|
|
/**
|
|
* Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.
|
|
*
|
|
* @deprecated
|
|
*/
|
|
export const get2 = oc
|
|
.route({
|
|
deprecated: true,
|
|
description:
|
|
'Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.',
|
|
inputStructure: 'detailed',
|
|
method: 'GET',
|
|
operationId: 'getAgentsByAgentIdVersionsByVersionId',
|
|
path: '/agents/{agent_id}/versions/{version_id}',
|
|
tags: ['console'],
|
|
})
|
|
.input(z.object({ params: zGetAgentsByAgentIdVersionsByVersionIdPath }))
|
|
.output(zGetAgentsByAgentIdVersionsByVersionIdResponse)
|
|
|
|
export const byVersionId = {
|
|
get: get2,
|
|
}
|
|
|
|
/**
|
|
* Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.
|
|
*
|
|
* @deprecated
|
|
*/
|
|
export const get3 = oc
|
|
.route({
|
|
deprecated: true,
|
|
description:
|
|
'Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.',
|
|
inputStructure: 'detailed',
|
|
method: 'GET',
|
|
operationId: 'getAgentsByAgentIdVersions',
|
|
path: '/agents/{agent_id}/versions',
|
|
tags: ['console'],
|
|
})
|
|
.input(z.object({ params: zGetAgentsByAgentIdVersionsPath }))
|
|
.output(zGetAgentsByAgentIdVersionsResponse)
|
|
|
|
export const versions = {
|
|
get: get3,
|
|
byVersionId,
|
|
}
|
|
|
|
/**
|
|
* Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.
|
|
*
|
|
* @deprecated
|
|
*/
|
|
export const delete_ = oc
|
|
.route({
|
|
deprecated: true,
|
|
description:
|
|
'Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.',
|
|
inputStructure: 'detailed',
|
|
method: 'DELETE',
|
|
operationId: 'deleteAgentsByAgentId',
|
|
path: '/agents/{agent_id}',
|
|
tags: ['console'],
|
|
})
|
|
.input(z.object({ params: zDeleteAgentsByAgentIdPath }))
|
|
.output(zDeleteAgentsByAgentIdResponse)
|
|
|
|
/**
|
|
* Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.
|
|
*
|
|
* @deprecated
|
|
*/
|
|
export const get4 = oc
|
|
.route({
|
|
deprecated: true,
|
|
description:
|
|
'Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.',
|
|
inputStructure: 'detailed',
|
|
method: 'GET',
|
|
operationId: 'getAgentsByAgentId',
|
|
path: '/agents/{agent_id}',
|
|
tags: ['console'],
|
|
})
|
|
.input(z.object({ params: zGetAgentsByAgentIdPath }))
|
|
.output(zGetAgentsByAgentIdResponse)
|
|
|
|
/**
|
|
* Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.
|
|
*
|
|
* @deprecated
|
|
*/
|
|
export const patch = oc
|
|
.route({
|
|
deprecated: true,
|
|
description:
|
|
'Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.',
|
|
inputStructure: 'detailed',
|
|
method: 'PATCH',
|
|
operationId: 'patchAgentsByAgentId',
|
|
path: '/agents/{agent_id}',
|
|
tags: ['console'],
|
|
})
|
|
.input(z.object({ body: zPatchAgentsByAgentIdBody, params: zPatchAgentsByAgentIdPath }))
|
|
.output(zPatchAgentsByAgentIdResponse)
|
|
|
|
export const byAgentId = {
|
|
delete: delete_,
|
|
get: get4,
|
|
patch,
|
|
versions,
|
|
}
|
|
|
|
/**
|
|
* Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.
|
|
*
|
|
* @deprecated
|
|
*/
|
|
export const get5 = oc
|
|
.route({
|
|
deprecated: true,
|
|
description:
|
|
'Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.',
|
|
inputStructure: 'detailed',
|
|
method: 'GET',
|
|
operationId: 'getAgents',
|
|
path: '/agents',
|
|
tags: ['console'],
|
|
})
|
|
.output(zGetAgentsResponse)
|
|
|
|
/**
|
|
* Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.
|
|
*
|
|
* @deprecated
|
|
*/
|
|
export const post = oc
|
|
.route({
|
|
deprecated: true,
|
|
description:
|
|
'Generated contract types may be inaccurate because backend OpenAPI annotations are incomplete. Do not migrate callers until the generated contract is accurate.',
|
|
inputStructure: 'detailed',
|
|
method: 'POST',
|
|
operationId: 'postAgents',
|
|
path: '/agents',
|
|
tags: ['console'],
|
|
})
|
|
.input(z.object({ body: zPostAgentsBody }))
|
|
.output(zPostAgentsResponse)
|
|
|
|
export const agents = {
|
|
get: get5,
|
|
post,
|
|
inviteOptions,
|
|
byAgentId,
|
|
}
|
|
|
|
export const contract = {
|
|
agents,
|
|
}
|