ApiMember Attribute Not Displayed in Metadata Generated by ServiceStack

I use ServiceStack, and I would like to help "automatic documentation" of the generated metadata.

I recently found ApiAttribute and ApiMemberAttribute here ( here and here ). However, I cannot get the page http://me/api/metadata?op=ReadFormType to emit any information for the decorated element.

He is a stripped-down version of my DTO (this is just a stub), which uses the test property:

 [Api("Read FormType")] [Route("/formTypes/{FormType}", "GET")] public class ReadFormType { [ApiMember(Name = "X", Description = "X Description", ParameterType = "path", DataType = "string", IsRequired = true)] public string X { get; set; } } 

ApiAttribute text ApiAttribute correctly displayed at the top of the metadata response, and the member is listed correctly in the DTO request section below.

What do I need to do to add additional information to ApiMemberAttribute ? (Or do I not understand how this attribute works?)

ServiceStack version is 3.9.35.

+6
source share
1 answer

The Api and ApiMember attributes are currently used by ServiceStack Swagger Support .

But we will also include them in the automatic generation of ServiceStack metadata pages in the next version of ServiceStack.

+2
source

All Articles