Open
Description
About
When I define a schema which has only one property in openapi.yaml
That schema will not appear in generate code like below.
But if I define two or more properties, it works properly.
I want to know how can I solve this issue. Thanks
Open API YAML
schemas:
PostJobsRequest:
type: object
properties:
job_id:
type: string
description: Job ID
required:
- job_id
Generated
const PostJobsRequest = z.object({ job_id: z.string() }).passthrough();
...
const endpoints = makeApi([
...
schema: z.object({ job_id: z.string() }).passthrough(),
Expected
const PostJobsRequest = z.object({ job_id: z.string() }).passthrough();
...
const endpoints = makeApi([
...
schema: PostJobsRequest,
Metadata
Metadata
Assignees
Labels
No labels