Session Metadata is currently in Early Access for Enterprise customers only. By using this feature, you agree to the applicable Free Trial terms in Okta’s Master Subscription Agreement. To learn more about Auth0’s product release cycle, read Product Release Stages.
Add organization information to session metadata
You can use Actions to store the organization’s identifiers in a session with the post-loginapi.session.setMetadata() method and query it with the event.session.metadata object.
Post-Login Action code:
- In subsequent Actions, you can query the data via the
event.session.metadataobject:
- If you use the Management API, you can query the data via the /api/v2/sessions/ endpoint:
Calls to the
/api/v2/sessions/{id} endpoint require a Management API access token with the update:session scope.- If you have an OIDC Back-Channel Logout session metadata configured application, the
logout_tokenincludes the session metadata: