Getting organization handle in id token claims
When user visits
myapp.com/org-handle
, I'd like to check whether the user has access to the org-handle
organization, and if so, show them the page.
I found how to add organizations
to the id token claims, but this array contains the org id and name only. I'd like the org handle to be there.
Is this possible?
If not, what's the recommended way to check whether the user has access to a specific org given an org handle?
I also tried to fetch the list of all organizations using the Management API, but the handle is not returned there either.7 Replies
Hi @moroshko,
I would suggest creating an
org handle
organization custom property and populate the custom property with the org handles
. And then add the custom property value to the tokens.
Let me know if you have any other questions.cool, thanks, I'll try that
it would be really nice if when you used the Management API to get an Organization the handle that was created came back from the system instead of mapping a custom property to store the handle which already exists as a property on the Organization in your system.
Hey @mfraser,
Just confirming, would you want the org handle to be in the response of a Get Organization API call?
Yes, that would be helpful
Gotcha. I have noted this down as a request and passed it onto my team.
Thank you!