mirror of
https://github.com/langgenius/dify.git
synced 2026-11-10 21:35:45 +08:00
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
24 lines
662 B
TypeScript
Generated
24 lines
662 B
TypeScript
Generated
// This file is auto-generated by scripts/add-orpc-error-maps.ts
|
|
import * as z from 'zod'
|
|
|
|
const zErrorResponse = /* @__PURE__ */ (() =>
|
|
z.object({
|
|
code: z.string(),
|
|
details: z.record(z.string(), z.unknown()).optional(),
|
|
message: z.string(),
|
|
params: z.string().optional(),
|
|
status: z.int(),
|
|
}))()
|
|
|
|
const zCrawlFailedError = /* @__PURE__ */ (() =>
|
|
zErrorResponse.and(
|
|
z.object({
|
|
code: z.literal('crawl_failed'),
|
|
status: z.literal(500),
|
|
}),
|
|
))()
|
|
|
|
export const getErrors = { crawl_failed: { status: 500, data: zCrawlFailedError } }
|
|
|
|
export const postErrors = { crawl_failed: { status: 500, data: zCrawlFailedError } }
|