Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/appwrite/mod.ts>Users#createToken

[READ-ONLY] Official Appwrite Deno SDK 🦕
Go to Latest
method Users.prototype.createToken
Re-export
import { Users } from "https://deno.land/x/appwrite@10.0.0/mod.ts";

Create token

Returns a token with a secret key for creating a session. If the provided user ID has not be registered, a new user will be created. Use the returned user ID and secret and submit a request to the PUT /account/sessions/custom endpoint to complete the login process.

Parameters

userId: string
optional
length: number
optional
expire: number