env0 / env0/serverless-openapi-typescript

Post requestBody not showing/generating

Open
#46 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
14
Forks
7
PR merge metrics
No merged PRs in 30d

Description

I'm trying to add request body here for my post endpoint, I cannot, I have tried requestBody property and nothing.
As seen in the picture I've been able to add it manually in the json output but not from the yml config file
![imagen](https://github.com/env0/serverless-openapi-typescript/assets/107485722/9d78893f-21a8-4820-9b6d-fd9aae531159)

```yml
endpoints:
createPerson:
summary: Crear personaje
description: Crea un personaje nuevo en la BD.
requestBody:
description: "Body param"
requestModels:
application/json: RequestObject
```

Basically this object is not being generated I have to add it manually for it to work

![imagen](https://github.com/env0/serverless-openapi-typescript/assets/107485722/870da583-9524-4a7c-817e-0f18ccf5ed9a)

Contributor guide

No contributing guide indexed for this repository

Research direction

No source file, test, or entry point is named. Start by tracing how the endpoints YAML configuration maps to the generated JSON, focusing on the requestBody and requestModels fields; done when the configured request body appears in the generated OpenAPI output without manual edits.

Written by the indexing model from the issue text.

Assessment

Tech stack
openapi, typescript
Domain
api
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.