Dotnet core The request matched multiple endpoints. Matches Base class

Error while calling the API controller methods:

fail: Middlewares.ExceptionHandlingMiddleware[0]
      The request matched multiple endpoints. Matches: 
      
      ....Controller.GetYourMethod (StudyRaft.API)
      ....Controller.GetYourSecondMethod (StudyRaft.API)
      Fallback {*path:nonfile}

Solution:

Change your base class methods from public to protected so that they are not exposed to API endpoints:

Replace: protected async Task<int> GetYourMethod() with this:

protected async Task<int> GetYourMethod()