duplicate-type-name
@typespec/openapi/duplicate-type-nameThis diagnostic is issued when a schema or parameter name is a duplicate of another schema or parameter.
This generally happens when a model or parameter is renamed with the @friendlyName decorator, resulting in two different TypeSpec types getting the same name in the OpenAPI output.
How to fix
Section titled “How to fix”Change the name or friendly-name of one of the models or parameters.
Incorrect
Section titled “Incorrect”@friendlyName("User")model Customer { id: string;}
model User { id: string;}Both Customer and User would appear as User in the OpenAPI output, causing a conflict.