crewAIInc/crewAI · error · ValueError
Audience is required. Please set it in the configuration.
Error message
Audience is required. Please set it in the configuration.
What it means
Error "Audience is required. Please set it in the configuration." thrown in crewAIInc/crewAI.
Source
Thrown at lib/crewai-core/src/crewai_core/auth/providers/auth0.py:25
class Auth0Provider(BaseProvider):
"""Auth0 OAuth2 provider implementation."""
def get_authorize_url(self) -> str:
return f"https://{self._get_domain()}/oauth/device/code"
def get_token_url(self) -> str:
return f"https://{self._get_domain()}/oauth/token"
def get_jwks_url(self) -> str:
return f"https://{self._get_domain()}/.well-known/jwks.json"
def get_issuer(self) -> str:
return f"https://{self._get_domain()}/"
def get_audience(self) -> str:
if self.settings.audience is None:
raise ValueError(
"Audience is required. Please set it in the configuration."
)
return self.settings.audience
def get_client_id(self) -> str:
if self.settings.client_id is None:
raise ValueError(
"Client ID is required. Please set it in the configuration."
)
return self.settings.client_id
def _get_domain(self) -> str:
if self.settings.domain is None:
raise ValueError("Domain is required. Please set it in the configuration.")
return self.settings.domain
View on GitHub (pinned to 754d7323be)
Solutions
- Set the audience in your auth provider configuration (e.g. CREWAI_AUTH_AUDIENCE or the provider config 'audience' field).
- Verify the audience value matches the API identifier registered in Auth0.
When it happens
Trigger: Thrown at lib/crewai-core/src/crewai_core/auth/providers/auth0.py:25 when the library encounters an invalid state.
Common situations: Occurs when the Auth0 provider configuration is missing the audience value. Set the audience in the configuration (or AUTH0_AUDIENCE environment variable) before initializing the provider.
AI-assisted analysis of crewAIInc/crewAI@754d7323be (2026-08-15).
Data as JSON: /api/errors/ffdb24557b2aa7af.
Report an issue: GitHub.