(variables []*ai_api_dto.AiPromptVariable)
| 36 | } |
| 37 | |
| 38 | func genRequestBody(variables []*ai_api_dto.AiPromptVariable) *openapi3.RequestBodyRef { |
| 39 | requestBody := openapi3.NewRequestBody() |
| 40 | requestBody.Description = "Request body" |
| 41 | requestBody.Required = true |
| 42 | requestBody.Content = openapi3.NewContentWithSchema(genRequestBodySchema(variables), []string{"application/json"}) |
| 43 | return &openapi3.RequestBodyRef{ |
| 44 | Value: requestBody, |
| 45 | } |
| 46 | } |
| 47 | |
| 48 | func genResponse() *openapi3.ResponseRef { |
| 49 | response := openapi3.NewResponse() |
no test coverage detected