<iframe src="https://www.googletagmanager.com/ns.html?id=GTM-M74D8PB" height="0" width="0" style="display:none;visibility:hidden">
Loading
Skip to NavigationSkip to Main Content

Okta Invalid Scope Error Occurs When Requesting "groups" Scope Through Custom Authorization Server

API Access Management
Okta Classic Engine
Okta Identity Engine

Overview

An invalid scope error occurs when requesting groups for an OpenID Connect application through a custom Authorization Server. This happens because the custom Authorization Server does not automatically create the groups scope. When requesting the groups scope, Okta generates the following error:

 

One or more scopes are not configured for the authorization server resource.

 

Create a new groups scope and configure a custom groups claim to resolve the error.

Applies To

  • Okta Classic Engine
  • Okta Identity Engine (OIE)
  • OpenID Connect
  • API Access Management
  • Groups claim
  • Scopes

Cause

When using the Okta Org Authorization Server, the built-in groups scope can be requested so an associated groups claim can be returned. When using a Custom Authorization Server, a custom groups claim can be created on the Authorization Server but Okta does not automatically create a dedicated groups scope.

Solution

How is the groups scope error resolved?

 

A custom groups claim created on an Authorization Server can be configured to always be returned or to only be included when a specific scope is requested. If a dedicated scope is needed, create a new scope on the Authorization Server and update/create the groups claim so it will be included when this scope is requested.

  1. Navigate to the Scopes tab on the Authorization Server and create a Scope called groups to match the name for the Org Authorization Server.

Add scope

  1. Navigate to the Claims tab and create a custom claim named groups to match the default name for an application groups claim.
  2. Set the Token type to ID Token.
  3. Change the Include in setting from Any scope to The following scopes.
  4. Enter groups in the text box and choose it from the dropdown menu to include it in the specific Scope from step 1.

Add claim

Related References

Loading
Okta Invalid Scope Error Occurs When Requesting "groups" Scope Through Custom Authorization Server | Okta Support