Skip to content
Back

Why does this happen?

  • 0
  • Flutter
  • Web
  • Auth
  • Self Hosted
  • Functions
Turboman
12 Jun, 2026, 18:17

AppwriteException: general_argument_invalid, Invalid secret param: Value must be a valid string and at least 1 chars and no longer than 256 chars (400)

the error makes sense (the secret token is too long), but i'm getting the session secret directly from an appwrite function from the same instance.

TL;DR
Error message: Invalid `secret` parameter due to the length being longer than allowed User is getting the session secret directly from an Appwrite function from the same instance The secret obtained from the function is a JWT with the UserID and the Secret User is questioning why the error is happening despite the origin of the secret User solved the issue by identifying that the secret token obtained was too long
Turboman
12 Jun, 2026, 18:24

okay i figured out what it is (by looking at the start of the secret) - but it still doesn't answer my question WHY - if i do Users#createSession from a function the secret is a JWT with the UserID and the Secret

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more