
Hi there,
I am upgrading my cloud functions from 1.1.2 to 1.4.3. In the "old" functions one could use the function variables like APPWRITE_FUNCTION_JWT
or APPWRITE_FUNCTION_USER_ID
. Do these, now environment variables, still exist or do I need to pass those information's myself?

Hey there 👋 Information that used to be in env variables and is not static was moved to headers. For example, function ID stayed as env var, as that never changes. But user ID and JWT are different with every request, so those are now headers. Here you can check all that Appwrite provides for you: https://appwrite.io/docs/functions-develop#headers
In your scenario you are looking for context.req.headers['x-appwrite-user-id']
and context.req.headers['x-appwrite-user-jwt']
.

Yes! Thats what I was looking for, thank you! <:appwriteheart2:1073243188954935387>

<:appwriteheart2:946074073627246692>

[SOLVED] 1.4 Function JWT token
Recommended threads
- Subdomain failed verification
So I wanted to do a custom subdomain, because local storage doesn't work for me, but I've tried it a long time ago, it didn't work for me, and now I'm trying ag...
- Sites 30MB limit from GitHub
I’m deploying a site from github as Other type on the Hobby plan. It is actually a Flutter web app but it’s in a subdirectory with the root being an html landin...
- [bug] API response is good but UI don't ...
Hi guys! When i got my object, it have billingInfo relation, in the web ui i just got pading state, and the row shows object is null, but when i work whit this...
