Alper Ebicoglu
Alper Ebicoglu

Reputation: 9624

How to disable dynamic WebAPI for certain application services

I want to turn off the automatic WebAPI generation service for a specific application service in my ABP project.

Upvotes: 2

Views: 608

Answers (1)

Alper Ebicoglu
Alper Ebicoglu

Reputation: 9624

RemoteService attribute can be used to mark a class as a remote service or disable for a particular class that inherently implements the IRemoteService interface

[RemoteService(false)]
public class PersonAppService : ApplicationService
{

}

if you just want to hide from Swagger

[RemoteService(IsMetadataEnabled = false)]
public class PersonAppService : ApplicationService
{

}

Upvotes: 7

Related Questions