Have you ever received an Invalid Swagger 2.0 Error for an API App?

If you are returning the standard status codes, you will find that there are duplicate codes.  This is one cause of the error.

If you edit your SwaggerConfig.cs, as shown below, this will solve the problem

 // In accordance with the built in JsonSerializer, Swashbuckle will, by default, describe enums as integers.
 // You can change the serializer behavior by configuring the StringToEnumConverter globally or for a given
 // enum type. Swashbuckle will honor this change out-of-the-box. However, if you use a different
 // approach to serialize enums as strings, you can also force Swashbuckle to describe them as strings.
 // 
 c.DescribeAllEnumsAsStrings()