I am trying to use my API (build with ServiceStack) with PowerApps and Microsoft Flow which require it to be an OpenAPI. However, It throws an error that the path template parameters must be defined in path parameters collection. It seems to fix the error, if I have a route like this [Route("/ServiceProvider/{Id}", “PUT”, Summary = “Update a ServiceProvider”)]
I should annotate the “id” parameter in the DTO as follows:
[ApiMember(ParameterType = “path”)]
public int Id { get; set; }
However, when I do that I get another error:
Failed PowerApps Custom API creation. Error Details: The request failed with error: ‘Parsing error(s): JSON is valid against more than one schema from ‘oneOf’. No valid schemas. Path ‘paths./{connectionId}/ServiceProvider/{Id}.put.parameters[1]’, line 218, position 11.’.
The API is hosted here: https://serviceproviderapi.azurewebsites.net/swagger-ui/