I've got an API endpoint that takes a ShortGuid class as a parameter, like such:
[HttpGet("api/endpoint")]
public async Task<IActionResult> GetTablesAsync(ShortGuid id){}
Generates a swagger definition of:
"parameters":[
{
"name":"guid",
"in":"query",
"required":false,
"type":"string",
"format":"uuid"
},
{
"name":"value",
"in":"query",
"required":false,
"type":"string"
}
],
I need to treat that parameter as a string, not a ShortGuid object. I already have a JsonConverter for the type that works fine, but Swashbuckle doesn't understand it so my schema is incorrect (and this my swagger-js client doesnt work). I thought MapType<> would work however that seems to only affect response objects as the schema still treats it as a ShortGuid.
c.MapType<ShortGuid>(() => new Schema { Type = "string" });
Will I require an ISchemaFilter to do this? And if so, how do I go about writing it (tried multiple attempts but no success)