#[CLOSED] There was an error processing your request. Please check the inputs and try again.

15 messages · Page 1 of 1 (latest)

lofty goblet
broken tide
lofty goblet
#

This is the function

#
    try {
      if (!user.email || !user.password || !user.name) {
        toast.error("All fields are required");
        return;
      }

      if (await checkLoggedIn()) {
        await account.deleteSession("current");
      }

      const userAccount = await account.create(
        ID.unique(),
        user.email,
        user.password,
        user.name
      );

      console.log(userAccount);

      if (userAccount.status) {
        await account.createEmailPasswordSession(user.email, user.password);
        const verify = await account.createVerification(
          `${process.env.NEXT_PUBLIC_DOMAIN}/auth/verify`
        );
        console.log("account verify", verify);
        toast.success("Account created successfully, please verify your email");
        router.push("/auth/login");
      }
    } catch (error) {
      console.error(error);
      if (error?.response?.code === 409) {
        toast.error("User with this email already exists");
      } else {
        toast.error(
          "There was an error processing your request. Please check the inputs and try again."
        );
      }
    }
  };```
lofty goblet
#

!???

ornate trench
#

check if the email is already registered in the console when you create an account.

lofty goblet
#

No it's not, else it would have given 409 error

#

also, how can i disable rate limiting, i keep getting this error {
"message": "Rate limit for the current endpoint has been exceeded. Please try again after some time.",
"code": 429,
"type": "general_rate_limit_exceeded",
"version": "1.5.7"
}

visual portal
lofty goblet
visual portal
lofty goblet
#

i mean, its working fine now, no errors

visual portal