
`import { Client } from 'node-appwrite';
export default async ({ req, res, log, error }) => { // Initialize Appwrite const client = new Client() .setEndpoint('api.example.com') .setProject(process.env.APPWRITE_FUNCTION_PROJECT_ID) .setKey(process.env.APPWRITE_API_KEY);
// Init database const database = new client.Databases(client)`
error: TypeError: client.Databases is not a constructor at Module.default (file:///usr/local/server/src/function/src/main.js:28:20) at execute (/usr/local/server/src/server.js:141:48) at async /usr/local/server/src/server.js:158:13

Function was made with the starter template.

Databases is not a valid constructor functions
Recommended threads
- Relationship null, even when relationshi...
Hi Everyone, im experiencing issues with set relation data. When im setting the document id from the related database most of them seem fine, except one table. ...
- Website shows just the HTML in safari
Hi y'all, I've been working on a project for a while but, for some reason it just shows the html in safari, It work perfectly fine in firefox and chrome, but sa...
- TableDB.getRow() response does not conta...
This is for Web/React sdk 20.0.0 The row was created via `TableDB.createRow(...)` and I can see it in the console with the relationships correctly set. In the c...
