Swagger, Swashbuckle, Web API Core - Set custom property example
up vote
-1
down vote
favorite
Is there a way to specify an example for a specific property in my model. I've looked at ISchemaFilter
but I can only set an example for the entire class and it's children.
If I could call the same logic that Swagger uses to generate the default Example then that would work too but I think that's not part of the .NET code (Swashbuckle).
asp.net-web-api swagger asp.net-core-webapi swagger-ui swashbuckle
add a comment |
up vote
-1
down vote
favorite
Is there a way to specify an example for a specific property in my model. I've looked at ISchemaFilter
but I can only set an example for the entire class and it's children.
If I could call the same logic that Swagger uses to generate the default Example then that would work too but I think that's not part of the .NET code (Swashbuckle).
asp.net-web-api swagger asp.net-core-webapi swagger-ui swashbuckle
add a comment |
up vote
-1
down vote
favorite
up vote
-1
down vote
favorite
Is there a way to specify an example for a specific property in my model. I've looked at ISchemaFilter
but I can only set an example for the entire class and it's children.
If I could call the same logic that Swagger uses to generate the default Example then that would work too but I think that's not part of the .NET code (Swashbuckle).
asp.net-web-api swagger asp.net-core-webapi swagger-ui swashbuckle
Is there a way to specify an example for a specific property in my model. I've looked at ISchemaFilter
but I can only set an example for the entire class and it's children.
If I could call the same logic that Swagger uses to generate the default Example then that would work too but I think that's not part of the .NET code (Swashbuckle).
asp.net-web-api swagger asp.net-core-webapi swagger-ui swashbuckle
asp.net-web-api swagger asp.net-core-webapi swagger-ui swashbuckle
asked Nov 9 at 0:00
Mr Universe
746423
746423
add a comment |
add a comment |
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53217934%2fswagger-swashbuckle-web-api-core-set-custom-property-example%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown