Group a grant's scope entries into one { scope, actions } row per scope
pattern - the view builders and consent UIs should render instead of the
raw strings.
The result is canonical: rows are ordered by scope (code-unit order),
actions within a row follow SCOPE_ACTIONS order, and neither rows
nor actions repeat, whatever order or duplication the input had.
Fails closed: if any entry does not fit the grammar this throws
InvalidScopeEntryError rather than silently dropping it, so a grant
carrying an operation this SDK does not know is never shown as narrower
than it is.
Group a grant's scope entries into one
{ scope, actions }row per scope pattern - the view builders and consent UIs should render instead of the raw strings.The result is canonical: rows are ordered by scope (code-unit order), actions within a row follow SCOPE_ACTIONS order, and neither rows nor actions repeat, whatever order or duplication the input had.
Fails closed: if any entry does not fit the grammar this throws InvalidScopeEntryError rather than silently dropping it, so a grant carrying an operation this SDK does not know is never shown as narrower than it is.