0

I have a dynamic field defined on a request object like so:

/// <summary>
/// Some description of this field
/// <example>17.5 or MyString in some cases</example>    
/// </summary>
public dynamic MyField { get; set; }

However, in our docs, the fields is showing up as:

myField    object (Object) Nullable

Is there a way to add a more user-friendly description to this field using ReDoc? I'd at least like ReDoc to honor the example text. Note - this is in a dotnet core API using Swashbuckle.

WEFX
  • 8,298
  • 8
  • 66
  • 102
  • Do you use Swashbuckle or Swagger-Net (or something else) to generate your API definition? – Helen Mar 04 '20 at 19:02
  • We use Swashbuckle. – WEFX Mar 04 '20 at 19:04
  • Why dynamic why? can we all get along ... my best guess would be to hack the resulting swagger doc with an `IDocumentFilter` not sure what more "user-friendly description" you can do (other than changing the type to just string) – Helder Sepulveda Mar 05 '20 at 00:51

0 Answers0