
Hi, I am using express and i'm getting an error with the database.createDocument: {"success":false,"message":"database.createDocument is not a function"}
This only shows if i want to import the database from another file, the config file is looking like this now:
import { Client, Databases } from 'node-appwrite';
const client = new Client();
client
.setEndpoint(process.env.APPWRITE_ENDPOINT)
.setProject(process.env.APPWRITE_PROJECT_ID)
.setKey(process.env.APPWRITE_API_KEY);
export const database = new Databases(client);
And im importing it like this:
import { database } from '../config/appwrite.js';
and i get the error
The weird thing is the documents are being created, but the error is not dissapearing.
Recommended threads
- How do I format an array in a CSV file t...
I want to import a CSV file to create a document on it on the AppWrite website. I have an attribute "name" of type String and "ingredients" which is of type St...
- my database attribute stuck in processin...
when i created attributes in collection 3 of those attributes become "processing", and they are not updating, the worst thing is that i cant even delete them s...
- Forever Processing Issue
I encountered an issue when creating attributes in the collections . if you create an attribute of type string for example and choose a size of 200 or 250 or a...
