Kitura-OpenAPI icon indicating copy to clipboard operation
Kitura-OpenAPI copied to clipboard

Error in SwaggerUI when POSTing arrays

Open seabaylea opened this issue 6 years ago • 0 comments

When I create a POST handler with the following signature:

func addContacts(contacts: [Contact], completion: @escaping ([Contact]?, RequestError?) -> Void) {
    completion(contacts, nil)
}

I get the following error in SwaggerUI when clicking on the Try it out button for the API:

Errors
 
Resolver error at paths./contacts/.post.parameters.0.schema.$ref
Could not resolve reference because of: Could not resolve pointer: /definitions/Array<Contact> does not exist in document

seabaylea avatar May 08 '19 17:05 seabaylea