Is there a way to inspect Users data from firebase console (https://console.firebase.google.com/)
Example:
UserRecord {
uid: 'xxxxxxxxxxxxxxxxxxxxxx',
email: undefined,
emailVerified: false,
displayName: undefined,
photoURL: undefined,
phoneNumber: '+xxxxxxxxxxxxxxx',
disabled: false,
metadata:
UserMetadata {
creationTime: 'Fri, 29 Mar 2019 16:58:32 GMT',
lastSignInTime: 'Wed, 15 May 2019 09:27:35 GMT' },
providerData:
[ UserInfo {
uid: '+xxxxxxxxxxxxxxx',
displayName: undefined,
email: undefined,
photoURL: undefined,
providerId: 'phone',
phoneNumber: '+xxxxxxxxxxxxxxx' } ],
passwordHash: undefined,
passwordSalt: undefined,
customClaims: { test: true },
tokensValidAfterTime: undefined
}
No, at the time of writing, there is no way to inspect, from the Firebase console, the Custom Claims that have been set for a user.
One way to inspect the Claims, is to write a Cloud Function with the following code
// Lookup the user associated with the specified uid.
admin.auth().getUser(uid).then((userRecord) => {
// The claims can be accessed on the user record.
console.log(userRecord.customClaims);
});
See this documentation item: https://firebase.google.com/docs/auth/admin/custom-claims#set_and_validate_custom_user_claims_via_the_admin_sdk
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With