They should inferred automatically from your Attribute usage, are any custom roles appearing? Can you repro this issue in a new project? e.g. a fork of https://github.com/NetCoreApps/BookingsCrud that includes a protected Service with Roles that don’t appear?
It’s better for ServiceStack to automatically aggregate the roles, but you can also ensure Roles are added by registering an AppMetadata Filter after the plugins ar run to the AdminUsers metadata, e.g:
I don’t understand what the issue is, the custom role is appearing in the UI:
I’m able to create a new user with the role, remove it, save it, re-add it, save it, etc. Everything’s working as expected. What is the issue and what are the exact steps to repro it?
Also you don’t need to use [RequiresAnyRole] with Admin role as it’s a super user role that can already access all protected services and when you use any of the [Require*] Auth Attributes it also implicitly requires Authentication so you can just use a single [RequiredRole] attribute instead, e.g:
The issue for me is I don’t see the roles in the drop down. If I click on it nothing happens. Clicking on it makes it look like the screenshots in my previous post. I dont see the 2 roles that you have screenshot in the dropdown inside ss studio.
This should return the roles in the App i.e. an observable array of ["Admin", "SubSite"]. If it does then I’m assuming you have a JS error preventing the drop down from working, can you go through the console history and paste any JS Exceptions that might cause the issue.