There lies your problem then. Use the data returned from sign up or in to get the up to date IdToken to use.
I have just tested all this on my setup and everything works as it should:
Sign Up data returned (with idToken) - truncated
Do It Result:
"[
["email", "timai2@domain.co.uk"],
["expiresIn", "3600"],
["idToken", "eyJhbGciOiJSUzIXAiOiJKV1Qif..._mwsCape9jcN0RggEbhXqguwDA"],
["kind", "identitytoolkit#SignupNewUserResponse"],
["localId", "hw2Gztt7iThDOLTSfoY73SGTgDF2"],
["refreshToken", "AG8BCne8Az...A8NGl8vmxCb1mUlX"]
]"
Send the verification email
data returned:
Do It Result: "{
"kind": "identitytoolkit#GetOobConfirmationCodeResponse",
"email": "timai2@domain.co.uk"
}
"
Email received:
Check the user data
data returned:
Do It Result: "{
"kind": "identitytoolkit#GetAccountInfoResponse",
"users": [
{
"localId": "hw2Gztt7iThDOLTSfoY73SGTgDF2",
"email": "timai2@domain.co.uk",
"passwordHash": "UkVEQUNURUQ=",
"emailVerified": true,
"passwordUpdatedAt": 1609683072990,
"providerUserInfo": [
{
"providerId": "password",
"federatedId": "timai2@domain.co.uk",
"email": "timai2@domain.co.uk",
"rawId": "timai2@domain.co.uk"
}
],
"validSince": "1609683072",
"lastLoginAt": "1609683072990",
"createdAt": "1609683072990",
"lastRefreshAt": "2021-01-03T14:11:12.990Z"
}
]
}
"


