
I want to upgrade my old functions to V3. I follwed the tutorial on: https://appwrite.io/docs/functions-develop#upgrade
But on front its still showing that I need to update the function to V3. Is there any other tutorials?

You'll need to recreate the function

do you mean rebuild?

No, either create a new function or delete your existing function and recreate it with the same ID

is it working only with es6 or also with commonjs?

Probably es6 but I'm not sure

oh, then I need to migrate to es6

after recreate Cannot find package 'node-appwrite'

that is my packege.json
{
"name": "appwrite-function",
"version": "1.0.0",
"description": "",
"main": "src/index.js",
"type": "module",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"keywords": [],
"author": "",
"license": "ISC",
"dependencies": {
"circular-json": "^0.5.9",
"crypto-js": "^4.1.1",
"graphql": "^16.8.0",
"graphql-request": "^6.1.0",
"https": "^1.0.0",
"JSONStream": "^1.3.5",
"node-appwrite": "^11.0.0",
"node-fetch": "^2.6.11"
},
"devDependencies": {
"eslint": "^8.49.0"
}
}

A function has build commands. You'll need to add npm install
for the build command

ahh okay, that is new I guess. I cann add it in appwrite.json
"commands": "npm install",

the idea behind this was to allow anything else you may need as well such as whatever setup needed to install a pivate package or install some chromium driver, etc.

"The req object has been updated to use terminology consistent with typical HTTP concepts. You'll now find familiar concepts like headers, body, HTTP methods, and others."
That means req.payload is not any more supported in V3, right? In the new concept it should be req.body?

yes, req.bodyRaw
or req.body
. see https://appwrite.io/docs/functions-develop#request
Recommended threads
- Struggling with Sessions
Understanding check: createAnonymousSession() registers the session with the backend setSession() creates a cookie on the user’s computer(?) getSession(‘curr...
- MCP and VSCode Docs
I like your tools, but would like to set up Copilot in VSCode, but these docs don't offer that guide. Did I miss something? https://appwrite.io/docs/tooling/mcp
- How to set wildcard at custom doamin
For OAuth2 redirect, I have set the appwrite api endpoint as appwrite.example.com, and added the CANME in cloudfare where I bought the domain name. And I hosted...
