# Getting Session ID as Claim in Access Token

**URL:** <https://devforum.okta.com/t/getting-session-id-as-claim-in-access-token/15555>\
**Category:** Questions\
**Created:** [August 17, 2021, 6:02pm UTC](https://devforum.okta.com/t/getting-session-id-as-claim-in-access-token/15555 "2021-08-17T18:02:22Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![andrea](https://sea1.discourse-cdn.com/oktadev/user_avatar/devforum.okta.com/andrea/32/2172_2.png) [@andrea](https://devforum.okta.com/u/andrea)\
**Post date:** [August 17, 2021, 6:05pm UTC](https://devforum.okta.com/t/getting-session-id-as-claim-in-access-token/15555/2 "2021-08-17T18:05:48Z")

</div>

Take a look at the following thread that details a way to do this with Token Inline Hooks (a Custom Authorization Server is required for this option): [Validate access token is linked to Okta session - #2 by andrea](https://devforum.okta.com/t/validate-access-token-is-linked-to-okta-session/13052/2)

Note that the session id is only available in the payload sent to the Inline Hook during a new OAuth flow. It will NOT be present if a refresh token is used to get new tokens for the user.

---

_[View the full topic](https://devforum.okta.com/t/getting-session-id-as-claim-in-access-token/15555)._
