Open Closed

Need to Add Additional Controller to Identity Service/Module #1333


User avatar
0
viswajwalith created
  • ABP Framework version: v4.3
  • UI type: MVC
  • DB provider: EF Core / MongoDB
  • Tiered (MVC) or Identity Server Separated (Angular): yes (Micro Service Template)
  • Exception message and stack trace:
  • Steps to reproduce the issue:

We would like to add additional controler to the Identity Service/Module in Micro Service based architecture, We have added the required files across layers but still not able to see that controler and method exposed. Can you please guilde to handle this scenrio.

Let me know if you need additional info.


2 Answer(s)
  • User Avatar
    0
    alper created
    Support Team Director

    do you see it in Swagger UI? here's a sample controller

        [RemoteService(Name = "AbpIdentity")]
        [Area("identity")]
        [ControllerName("User")]
        [Route("api/identity/users")]
        public class IdentityUserController : AbpController, IIdentityUserAppService
        {
            [HttpGet]
            [Route("{id}")]
            public virtual Task<IdentityUserDto> GetAsync(Guid id)
            {
                return UserAppService.GetAsync(id);
            }
        }
        
    
  • User Avatar
    0
    viswajwalith created

    do you see it in Swagger UI? here's a sample controller

        [RemoteService(Name = "AbpIdentity")] 
        [Area("identity")] 
        [ControllerName("User")] 
        [Route("api/identity/users")] 
        public class IdentityUserController : AbpController, IIdentityUserAppService 
        { 
            [HttpGet] 
            [Route("{id}")] 
            public virtual Task<IdentityUserDto> GetAsync(Guid id) 
            { 
                return UserAppService.GetAsync(id); 
            } 
        } 
         
    

    Thanks, actually we made big mistake, missed to add "Public" to our controller.

Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
Do you need assistance from an ABP expert?
Schedule a Meeting
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v9.2.0-preview. Updated on March 19, 2025, 10:09