[AppwriteException: Invalid url param: Invalid URI. Register your new client (app) as a new platform on your project console dashboard].
i previously had email verification working and sending email verifications. now it will only ping this error when sending the await account.createverification function
info: i have not ran the appwrite starter repo so i dont think its linked to my project properly, previously i had a web platform with wildcard hostname ' * ' to redirect to my app. i am using expo dev build atm. i just need help working out how to register the platform as ive not seen this before
Appwrite does not support deep links for verification urls. You either need to use universal link or a cloud function to do this.
<@743532656767270934> did you guys worked on this? I think it should work if followed oauth redirection logic 😐
i had it working not so long ago, im un sure if its an issue from an update, thanks for your help btw.
It was working because you used wild cards
yeah i get the wildcards thing, im just a bit confused as to why its stopped working. for me as it was all working fine before. ive recently started using .env file too but i cant find anything about it making my verification invalid
Hi there, so we recently updated our Origin validation logic. Now if you are using a react native project that has a special scheme (in this case app) you need to add it as a new platform on your Appwrite console
Looking at your error, its not able to recognize the exact platform you should register... so can I ask what platform are you using?
is it web, android, ios? none?
appname in the url appname://app/verification does not seem like a valid scheme
you can see list of supported schemes here - https://github.com/appwrite/appwrite/blob/0f38bb689f3f8b4384c11eacec26a89712d5c166/src/Appwrite/Network/Platform.php#L25-L37
additional info on why the * hostname is not working anymore, it will only do the hostname validation if the scheme is http or https
hi Chirag, yeah im using react native/expo for an ios/android project. ive been getting away with using the wildcard on a web platform to handle the createVerification (' deeplink url ')request, but ive been using a reactnative platform for the app in general for uploading to and from the database. i had the email verifications working and sedning to my emial the other week and now i get the errror message you have seen. i recently changed my logic in my app during development to use .env files and used expo_PUBLIC_Appwrite... to make sure i can always acess the platform (the mobile version). im assuming that it was to do with a 'connect' button at the top of my project overview which was telling me i was only 33% complete on the web, ios reactnative and android react native platforms. ive now ran the starter repo in a different folder that was suggested to send a ping to the server to verifiy the actual console. it hasnt fixed my issue and im still getting the error message. connect-react platofrm - requires 'Waiting for connection...' git clone https://github.com/appwrite/starter-for-react cd starter-for-react
- are you using sdk for react native? if so can you please share the code using emailVerification
- what is your bundle identifier? looks something like this:
yeah it does look like that, i also have inputted associatedDomains: [ 'deeplink url '], just after bundleidentifier. my code: export const createEmailVerification = async () => {
try {
await account.createVerification('deeplink url e.g [slug://app/verifiy]');
console.log('email sent')
} catch (error) {
console.log('error verifying email:', error)
}
};
i cant remomber how to format the code for discord
i assume its because of a security update as you mentioned but also im now unsure how to go about this. i do have a domain i can use but i would like to understand the backend a bit better
try creating an expo redirect uri like this:
import { makeRedirectUri } from 'expo-auth-session'
const deepLink = new URL(makeRedirectUri());
if (!deepLink.hostname) {
deepLink.hostname = '<your_hostname>';
}
account.createVerification(`${deepLink}/verification`)
this will create a deeplink with exp as a scheme. i am asuming right now you are passing appname://app/verification directly as a redirect URI, and appname is not really a valid scheme
just to make sure, im changing <Hostname> to my 'apname://app/ver' or would it be better to use the wildcard or domain
use just your domain, any domain like app.com etc. a domain should not have scheme or path
some eg.s chiragaggarwal.tech, google.com etc.
yeah it didnt work, i am using javascript btw. Invalid url param: Invalid URI. Register your new client (app) as a new platform on your project console dashboard
when using given code: expo-auth-session could not be found within the project or in these directories: i think it is not what im using; i imported it at top of page but inside appwrite.js, gonna have a go inside page logic
export const createEmailVerification = async () => {
try {
const redirectUri = 'slug://app/verification; // your deep link
await account.createVerification(redirectUri);
console.log('email sent');
} catch (error) {
console.log('error verifying email:', error.message);
}
}; comes back with [error verifying email: Invalid url param: Invalid URI. Register your new client (app) as a new platform on your project console dashboard]; i have a domain but its just a landing page atm nothing ive coded
Recommended threads
- TEAM INVITE
There is a problem with the team invitation. When a user invites other users, that time, the newly created email address they don't get the invite link and old ...
- education plan not activated
Hi I have an edu id 13103046@iubat.edu but when I am trying to claim my plan and trying to logging with github where education student plan active. the appwrite...
- 500 simultaneous OAuth logins from the s...
Hi, I'd like to ask about rate limiting around Google OAuth login on Appwrite Cloud. **OVERVIEW** Service type: A PWA (web app) for members of a university clu...