NabuCasa / pycognito

Python library for using AWS Cognito. With support for SRP.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Easy API for custom jwt claims

shughes-uk opened this issue · comments

Currently we have an an easy access to attributes but not to custom JWT claims added by a pre-token generation lambda

You can can get the decoded ID Token with

Cognito.verify_token(id_token,"id_token","id")

but it's kind of hacky, otherwise you're on your own to decode the ID token and extract the claims.

It would be nice to have a proper route to access these custom claims!