Hi there,
I am currently exploring apple sign in using Appwrite. Google works great, but when I log in using my apple ID there is no name returned. Both the first time, and times after that.
And apple has the function the hide the user's email. Apple provides an private for them. But when I select this function, my actual email is returned instead of the one generated by apple.
How can I solve these two problems?
Would love to hear your thoughts. Code pasted below.
// Functie om in te loggen async function handleGoogleLogin() { account.createOAuth2Session( 'google', 'https://just-roomies.com/test-login2.html', 'https://just-roomies.com/test-login2-fail.html' ) };
async function handleAppleLogin() {
account.createOAuth2Session(
'apple',
'https://just-roomies.com/test-login2.html',
'https://just-roomies.com/test-login2-fail.html'
)
};
async function getUser() {
try{
const user = await account.get()
renderProfileScreen(user)
}catch(error) {
renderLoginScreen()
}
}
function renderLoginScreen() {
loginScreen.classList.remove('hidden');
}
function renderProfileScreen(user) {
userName.textContent = user.name;
console.log(user)
profileScreen.classList.remove("hidden");
}
function handleLogout() {
account.deleteSession('current')
profileScreen.classList.add("hidden");
renderLoginScreen()
}
getUser()
Recommended threads
- The data displayed in Vercel is not real...
Hello! I did a test by developing a dashboard that displays data from the Appwrite database, when I changed the data through the Vercel hosting or updated the d...
- I never receive emails from account.crea...
Hi community, Actually, I'm testing the password recovery feature and everything goes well at the beginning. It returns me an object : ` "$createdAt": "2024-09...
- Issue with Sending Verification Email Af...
Hello, I'm trying to create an Appwrite function that takes an email address as input, checks it against a list, and if there's a match, it creates a user and ...