Summary
The role selection dropdown across the UI (user creation, bot config, SSO mapping, etc.) relies on GET /v1/roles with cursor-based pagination. When the number of roles exceeds the page limit, roles beyond the first page are silently missing from the dropdown. Users cannot search or filter to find a specific role.
Unlike User and Team which have dedicated search indices (user_search_index, team_search_index) and are searchable via GET /v1/search/query, Roles have no search index and no search support at any level — no index mapping, no RoleIndex class, no SearchIndex.ROLE on the frontend.
Current Behavior
Role selection dropdowns fetch all roles via paginated list API calls.
Roles beyond the pagination boundary are not displayed and cannot be selected.
There is no way to search or filter roles by name — neither in the API nor the UI.
The frontend works around this with inflated limits (e.g., limit: 1000) or looping through all pages, both of which don't scale.
Expected Behavior
Users should be able to find and select any role regardless of how many roles exist, via a search/typeahead in the dropdown backed by a search-capable API.
Impact
Users with 100+ roles cannot reliably assign roles during user creation or configuration.
Playwright test UserCreationWithPersona.spec.ts fails because the target role falls beyond the pagination boundary.
Summary
The role selection dropdown across the UI (user creation, bot config, SSO mapping, etc.) relies on GET /v1/roles with cursor-based pagination. When the number of roles exceeds the page limit, roles beyond the first page are silently missing from the dropdown. Users cannot search or filter to find a specific role.
Unlike User and Team which have dedicated search indices (user_search_index, team_search_index) and are searchable via GET /v1/search/query, Roles have no search index and no search support at any level — no index mapping, no RoleIndex class, no SearchIndex.ROLE on the frontend.
Current Behavior
Role selection dropdowns fetch all roles via paginated list API calls.
Roles beyond the pagination boundary are not displayed and cannot be selected.
There is no way to search or filter roles by name — neither in the API nor the UI.
The frontend works around this with inflated limits (e.g., limit: 1000) or looping through all pages, both of which don't scale.
Expected Behavior
Users should be able to find and select any role regardless of how many roles exist, via a search/typeahead in the dropdown backed by a search-capable API.
Impact
Users with 100+ roles cannot reliably assign roles during user creation or configuration.
Playwright test UserCreationWithPersona.spec.ts fails because the target role falls beyond the pagination boundary.