Back

[SOLVED] account.create is not a function

  • 1
  • Cloud
Valou
22 Oct, 2024, 13:37

When running the account.create function in node js from the documentation(https://appwrite.io/docs/references/cloud/server-nodejs/account)

TypeScript
const result = await account.create(
    '<USER_ID>', // userId
    '[email protected]', // email
    '', // password
    '<NAME>' // name (optional)
);

It prompts me that account.create is not a function. I am running node v20.16.0 and [email protected] How can i fix this? I also keep having the same issue with other functions that they are not recognized even though they are copy pasted from the docs

Thanks for reading this, hope someone might have a solution ๐Ÿ™‚

TL;DR
Issue: account.create is not recognized as a function when running node js from the documentation. Solution: Make sure to keep package versions up to date. You should be using version 14.1.0 of node-appwrite.
Kenny
22 Oct, 2024, 13:38

Make sure to keep your package versions up to date.

You should be using version 14.1.0

https://www.npmjs.com/package/node-appwrite

Valou
22 Oct, 2024, 13:41

Thanks that seems to solve it

Kenny
22 Oct, 2024, 13:41

[SOLVED] account.create is not a function

Valou
22 Oct, 2024, 13:41

I was using this guide to get started, this guide says to install 11.1.1, perhaps you could update it? https://appwrite.io/docs/quick-starts/node

Valou
22 Oct, 2024, 13:42

it seems a bit outdated

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