Rank 2: Process
Hello,
I am using the code that was generated by the AI in the Appwrite Dashboard. Sadly, the mentioned mathods are not available in the sdk.
import sdk from 'node-appwrite';
// Init SDKconst client = new sdk.Client();
const account = new sdk.Account(client);
client .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint .setProject('<PROJECT_ID>') // Your project ID .setKey('<YOUR_SECRET_KEY>') // Your secret API key;
const promise = account.createSession('email@example.com', 'password');
promise.then(function (response) { console.log(response); // Success}, function (error) { console.log(error); // Failure});