Appwrite Account API
The Account service allows you to authenticate and manage a user account. 73 operations across 47 paths in the Appwrite 2.0.0 OpenAPI.
Operations 73
Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay
Ask an LLM
“Who is the user currently logged in to my Appwrite app?”
“Can I fetch the profile of the signed-in user from the client side?”
Tell an agent
Show me the account details of the currently logged-in user.
Fetch my own account profile.
Ask an LLM
“How do I let a new user sign up with an email and password?”
“What do I need to register someone as a new account in my project?”
Tell an agent
Register a new account for {email} with password {password} and user ID {userId}.
Sign up {name} as a new user with email {email}, password {password} and ID {userId}.
Ask an LLM
“Can a logged-in user delete their own account?”
“What endpoint removes the current user's whole account?”
Tell an agent destructive · confirm first
Delete my own user account entirely.
Remove the currently logged-in user's account.
Ask an LLM
“Which billing addresses are saved on my account?”
“Can I filter the billing addresses on my account with queries?”
Tell an agent
List all billing addresses on my account.
List my billing addresses matching {queries}.
Ask an LLM
“How do I add a new billing address to my account?”
“Which fields are required when saving a billing address?”
Tell an agent
Add a billing address at {streetAddress}, {city}, {country} to my account.
Save a new billing address {streetAddress}, {city} {postalCode}, {state}, {country}.
GET
/account/billing-addresses/{billingAddressId}
Get one billing address by ID · Get billing address
#
Ask an LLM
“Can I look up a single saved billing address by its ID?”
“What details are stored for a specific billing address on my account?”
Tell an agent
Show billing address {billingAddressId}.
Get the details of my billing address {billingAddressId}.
PUT
/account/billing-addresses/{billingAddressId}
Update an existing billing address · Update billing address
#
Ask an LLM
“How do I change a billing address I already saved?”
“Can I correct the street or city on an existing billing address?”
Tell an agent
Update billing address {billingAddressId} to {streetAddress}, {city}, {country}.
Change the postal code on billing address {billingAddressId} to {postalCode}, keeping {streetAddress}, {city}, {country}.
DELETE
/account/billing-addresses/{billingAddressId}
Delete a billing address · Delete billing address
#
Ask an LLM
“Can I remove an old billing address from my account?”
“What happens when I delete a saved billing address?”
Tell an agent destructive · confirm first
Delete billing address {billingAddressId}.
Remove the billing address {billingAddressId} from my account.
Ask an LLM
“Which third-party apps have I granted OAuth2 consent to?”
“Can I see every app the current user has authorized?”
Tell an agent
List the OAuth2 consents I have given to third-party apps.
List my app consents matching {queries}.
Ask an LLM
“What scopes did I grant in a particular OAuth2 consent?”
“Can I look up a single third-party app consent by ID?”
Tell an agent
Show OAuth2 consent {consentId}.
Get the details of the app consent {consentId}.
Ask an LLM
“How do I revoke a third-party app's access to my account?”
“Does withdrawing an OAuth2 consent also revoke the app's tokens?”
Tell an agent destructive · confirm first
Revoke OAuth2 consent {consentId} and all its tokens.
Withdraw my consent {consentId} so that app must ask again.
GET
/account/consents/{consentId}/tokens
List token families under an OAuth2 consent · List consent tokens
#
Ask an LLM
“Which devices or sessions hold tokens under an app consent I gave?”
“Are the token secrets returned when I list a consent's tokens?”
Tell an agent
List the token families issued under consent {consentId}.
Show every authorized device for app consent {consentId}.
GET
/account/consents/{consentId}/tokens/{tokenId}
Get one token family under a consent · Get consent token
#
Ask an LLM
“Can I inspect a single token family issued under an app consent?”
“What metadata is shown for one authorized device of a consent?”
Tell an agent
Show token family {tokenId} under consent {consentId}.
Get details of consent {consentId} token {tokenId}.
DELETE
/account/consents/{consentId}/tokens/{tokenId}
Revoke one device's tokens under a consent · Delete consent token
#
Ask an LLM
“Can I sign one device out of a third-party app without revoking the whole consent?”
“Do other devices keep working when I delete one consent token family?”
Tell an agent destructive · confirm first
Revoke token family {tokenId} under consent {consentId}.
Cut off one device, token {tokenId}, from app consent {consentId} but keep the consent.
Ask an LLM
“What does a coupon code give my account before I apply it?”
“Can I check a coupon's details from my account?”
Tell an agent
Show the details of coupon {couponId} for my account.
Check what coupon {couponId} is worth on my account.
Ask an LLM
“How can a user change the email address on their account?”
“Does changing my email reset its verification status?”
Tell an agent
Change my account email to {email}; my password is {password}.
Update the logged-in user's email address to {email} using password {password}.
Ask an LLM
“Which OAuth identities are linked to my account?”
“Can I see the external logins attached to the current user?”
Tell an agent
List the identities linked to my account.
List my linked identities matching {queries}.
Ask an LLM
“How do I unlink an OAuth identity from my account?”
“Can I remove one external login provider from my profile?”
Tell an agent destructive · confirm first
Unlink identity {identityId} from my account.
Delete the linked identity {identityId}.
Ask an LLM
“Where can I see all invoices billed to my account?”
“Can I filter my account invoices with queries?”
Tell an agent
List all invoices on my account.
List my account invoices matching {queries}.
Ask an LLM
“How do I get a JWT to call the server API on behalf of the logged-in user?”
“How long is an account JWT valid for?”
Tell an agent
Create a JSON Web Token for the current user.
Issue a JWT for me that lasts {duration} seconds.
Ask an LLM
“Which API keys exist on my personal account?”
“Can I get just the count of my account keys?”
Tell an agent
List all API keys on my account.
Show my account keys with total count set to {total}.
Ask an LLM
“How do I create a personal account API key with specific scopes?”
“Can an account key be given an expiration date?”
Tell an agent
Create an account key named {name} with scopes {scopes}.
Create account key {name} with scopes {scopes} expiring {expire}.
Ask an LLM
“What scopes does one of my account keys have?”
“Can I look up a single account API key by ID?”
Tell an agent
Show account key {keyId}.
Get the scopes of my account key {keyId}.
Ask an LLM
“Can I change the scopes on an existing account key?”
“How do I extend the expiry of an account API key?”
Tell an agent
Rename account key {keyId} to {name} with scopes {scopes}.
Set account key {keyId} to expire at {expire}, keeping name {name} and scopes {scopes}.
Ask an LLM
“How do I revoke one of my account API keys?”
“Does a deleted account key stop authenticating immediately?”
Tell an agent destructive · confirm first
Delete account key {keyId}.
Revoke my account API key {keyId}.
Ask an LLM
“Where can I see recent security activity on my account?”
“Do account logs include IP address and location?”
Tell an agent
List my latest account security logs.
List my activity logs matching {queries}.
Ask an LLM
“How do I enable MFA on my account?”
“Can a user switch off multi-factor authentication?”
Tell an agent
Set MFA on my account to {mfa}.
Turn on multi-factor authentication for my account.
POST
/account/mfa/authenticators/{type}
Add an authenticator app as an MFA factor · Create authenticator
#
Ask an LLM
“Can I add an authenticator app like TOTP as a second factor?”
“What is the first step to register an authenticator for MFA?”
Tell an agent
Add a {type} authenticator to my account.
Start setting up a new {type} authenticator app for MFA.
PUT
/account/mfa/authenticators/{type}
Verify a newly added authenticator app · Update authenticator (confirmation)
#
Ask an LLM
“How do I confirm an authenticator app after adding it?”
“What code do I send to finish setting up a TOTP authenticator?”
Tell an agent
Verify my {type} authenticator with code {otp}.
Confirm the {type} authenticator setup using one-time password {otp}.
Ask an LLM
“How do I remove an authenticator app from my account?”
“Can I delete my TOTP factor if I lost my phone?”
Tell an agent destructive · confirm first
Remove my {type} authenticator.
Delete the {type} MFA authenticator from my account.
Ask an LLM
“How do I begin MFA verification once a user has signed in?”
“Which factor types can I request an MFA challenge for?”
Tell an agent
Start an MFA challenge using the {factor} factor.
Send me an MFA challenge via {factor}.
PUT
/account/mfa/challenges
Complete an MFA challenge with a code · Update MFA challenge (confirmation)
#
Ask an LLM
“How do I finish MFA verification after sign-in?”
“Where do I submit the one-time password for an MFA challenge?”
Tell an agent
Complete MFA challenge {challengeId} with code {otp}.
Answer challenge {challengeId} using one-time password {otp}.
Ask an LLM
“Which MFA factors are available on my account?”
“Can I check whether email, phone or TOTP factors are enabled for me?”
Tell an agent
List the MFA factors available on my account.
Show which second factors I can use for a challenge.
Ask an LLM
“Can I view the MFA recovery codes I already generated?”
“Is an OTP challenge needed before reading recovery codes?”
Tell an agent
Show my existing MFA recovery codes.
Retrieve the backup recovery codes I generated earlier.
POST
/account/mfa/recovery-codes
Generate MFA recovery codes for the first time · Create MFA recovery codes
#
Ask an LLM
“How do I generate backup recovery codes after adding an authenticator?”
“When should recovery codes first be created for MFA?”
Tell an agent
Generate my first set of MFA recovery codes.
Create backup recovery codes for my new authenticator.
PATCH
/account/mfa/recovery-codes
Regenerate MFA recovery codes · Update MFA recovery codes (regenerate)
#
Ask an LLM
“Can I replace my MFA recovery codes with a fresh set?”
“What do I do if my existing recovery codes were exposed?”
Tell an agent
Regenerate my MFA recovery codes, replacing the old ones.
Issue a fresh set of recovery codes to replace my current codes.
Ask an LLM
“How can a user change their display name?”
“Can I rename the currently logged-in account?”
Tell an agent
Change my account name to {name}.
Set the logged-in user's name to {name}.
Ask an LLM
“How do I change my password while logged in?”
“Is the old password required for users who signed up with OAuth or magic URL?”
Tell an agent
Change my password from {oldPassword} to {password}.
Set a new password {password} on my account.
Ask an LLM
“Which payment methods are saved on my account?”
“Can I filter my payment methods with queries?”
Tell an agent
List my saved payment methods.
List payment methods on my account matching {queries}.
Ask an LLM
“How do I add a new card to my account?”
“What is the first step to register a payment method?”
Tell an agent
Create a new payment method on my account.
Start setting up a new card for my account billing.
Ask an LLM
“Can I look up a specific saved card by ID?”
“What details are stored for one of my payment methods?”
Tell an agent
Show payment method {paymentMethodId}.
Get details of my card {paymentMethodId}.
PATCH
/account/payment-methods/{paymentMethodId}
Update a card's expiry date · Update payment method
#
Ask an LLM
“Can I update the expiry date on a saved card?”
“How do I change the expiration month and year of a payment method?”
Tell an agent
Set the expiry of payment method {paymentMethodId} to {expiryMonth}/{expiryYear}.
Update card {paymentMethodId} to expire in month {expiryMonth} of {expiryYear}.
Ask an LLM
“How do I remove an old card from my account?”
“Can I delete a saved payment method?”
Tell an agent destructive · confirm first
Delete payment method {paymentMethodId}.
Remove card {paymentMethodId} from my account.
PATCH
/account/payment-methods/{paymentMethodId}/provider
Link a payment method to its provider ID · Update payment method provider id
#
Ask an LLM
“How do I attach the payment provider's method ID to my saved card?”
“Can I set the provider method ID and name on a payment method?”
Tell an agent
Set payment method {paymentMethodId} provider ID to {providerMethodId} with name {name}.
Link card {paymentMethodId} to provider method {providerMethodId} named {name}.
PATCH
/account/payment-methods/{paymentMethodId}/setup
Set up mandates for an Indian card · Update payment method with new setup with mandates for indian cards
#
Ask an LLM
“How do I set up mandate options for an Indian card payment method?”
“Do Indian cards need a separate mandate setup step?”
Tell an agent
Set up mandate options on payment method {paymentMethodId}.
Configure the Indian card mandate for card {paymentMethodId}.
Ask an LLM
“How can a user change the phone number on their account?”
“Is a confirmation SMS sent automatically after changing my phone?”
Tell an agent
Change my phone number to {phone}; password is {password}.
Update the logged-in user's phone to {phone} using password {password}.
Ask an LLM
“Where are the current user's key-value preferences stored?”
“Can I read my own account preferences object?”
Tell an agent
Show my account preferences.
Fetch the logged-in user's saved prefs.
Ask an LLM
“How do I save preferences like theme or language for a user?”
“What is the size limit for account preferences?”
Tell an agent
Replace my account preferences with {prefs}.
Save {prefs} as the logged-in user's preferences.
Ask an LLM
“How do I send a forgot-password email to a user?”
“Where does the password reset link redirect the user?”
Tell an agent
Send a password reset email to {email} redirecting to {url}.
Start password recovery for {email} with reset page {url}.
Ask an LLM
“How do I finish a password reset after the user clicks the email link?”
“Which values from the reset link do I need to set a new password?”
Tell an agent
Reset the password for user {userId} to {password} using secret {secret}.
Complete password recovery for {userId} with secret {secret} and new password {password}.
Ask an LLM
“On which devices am I currently logged in?”
“Can I see all active sessions for my account?”
Tell an agent
List my active sessions across devices.
Show every device I'm logged in on.
Ask an LLM
“How do I sign the user out everywhere at once?”
“Can I delete every session on my account in one call?”
Tell an agent destructive · confirm first
Log me out of all devices.
Delete every session on my account.
Ask an LLM
“Can users try my app as a guest without signing up?”
“How can an anonymous account later become a normal account?”
Tell an agent
Create an anonymous guest session.
Log this visitor in anonymously.
Ask an LLM
“How do I log a user in with their email and password?”
“How many active sessions can one user have at a time?”
Tell an agent
Log in as {email} with password {password}.
Create an email-password session for {email} using {password}.
Ask an LLM
“What do I call after the user clicks the magic URL link in their email?”
“Which endpoint turns a magic link secret into a session?”
Tell an agent
Complete the magic URL login for user {userId} with secret {secret}.
Turn magic link secret {secret} for {userId} into a session.
Ask an LLM
“Can users log in to my app through a third-party OAuth2 provider they already have an account with?”
“Where does the user land after an OAuth2 login succeeds or fails?”
Tell an agent
Start an OAuth2 login with {provider}.
Sign in via {provider} and redirect to {success} on success or {failure} on failure.
Ask an LLM
“What do I call after the user enters the SMS code to log in?”
“Can I create a session from a phone login secret?”
Tell an agent
Complete the phone login for user {userId} with SMS secret {secret}.
Turn phone code {secret} for {userId} into a session.
Ask an LLM
“Is there one generic endpoint to exchange a login token for a session?”
“How do I exchange an email OTP token for a session?”
Tell an agent
Exchange token secret {secret} for user {userId} into a session.
Create a session using the generic token endpoint for {userId} and {secret}.
Ask an LLM
“How do I get details about the session I'm using right now?”
“Can I look up a specific login session by ID?”
Tell an agent
Show session {sessionId}.
Get my current session details.
Ask an LLM
“Can I extend a session that is about to expire?”
“Does refreshing a session also renew the OAuth provider's access token?”
Tell an agent
Extend session {sessionId}.
Refresh the OAuth access token on session {sessionId}.
Ask an LLM
“How do I log the user out on this device only?”
“Can I sign out a single other device remotely?”
Tell an agent destructive · confirm first
Log out session {sessionId}.
Log me out on this device.
Ask an LLM
“Can a user deactivate their own account without deleting it?”
“What happens to the user record when an account is blocked?”
Tell an agent destructive · confirm first
Block my account permanently.
Deactivate the logged-in user's account.
Ask an LLM
“How do I register a device token for push notifications?”
“Can I choose which provider sends pushes to a device?”
Tell an agent
Register device token {identifier} as push target {targetId}.
Add push target {targetId} for device {identifier} using provider {providerId}.
Ask an LLM
“What do I do when a device's push token changes?”
“Can I update the identifier on an existing push target?”
Tell an agent
Update push target {targetId} with new device token {identifier}.
Replace the device token on push target {targetId} with {identifier}.
Ask an LLM
“How do I stop sending push notifications to a device?”
“Can a user remove their own push target?”
Tell an agent destructive · confirm first
Delete push target {targetId}.
Unregister device push target {targetId}.
Ask an LLM
“Can users log in with a one-time code sent by email?”
“Does sending an email OTP create a new account for an unknown address?”
Tell an agent
Email a one-time login code to {email} for user {userId}.
Send an email OTP to {email} as user {userId} with a security phrase set to {phrase}.
Ask an LLM
“How do I send a passwordless magic link to a user's email?”
“Where does the magic URL redirect the user after they click it?”
Tell an agent
Send a magic login link to {email} for user {userId}.
Email a magic URL to {email} as {userId} that returns to {url}.
GET
/account/tokens/oauth2/{provider}
Get an OAuth2 login token instead of a session · Create OAuth2 token
#
Ask an LLM
“Can I get a token from an OAuth2 login rather than a session cookie?”
“Which OAuth2 flow suits server-side rendered apps that create their own session?”
Tell an agent
Start an OAuth2 token flow with {provider}.
Get an OAuth2 login token via {provider}, returning to {success}.
Ask an LLM
“How do users log in with a code sent by SMS?”
“Does an SMS login create a new user if the ID is unknown?”
Tell an agent
Text a login code to {phone} for user {userId}.
Send an SMS login token to {phone} as {userId}.
Ask an LLM
“How do I send a verification email to the logged-in user?”
“Can I set the page the email verification link points to?”
Tell an agent
Send me an email verification link pointing to {url}.
Email a confirm-your-address link that returns to {url}.
PUT
/account/verifications/email
Confirm a user's email address · Update email verification (confirmation)
#
Ask an LLM
“How do I finish email verification after the user clicks the link?”
“Which values from the verification link confirm email ownership?”
Tell an agent
Confirm the email of user {userId} with secret {secret}.
Complete email verification for {userId} using {secret}.
Ask an LLM
“How do I text a verification code to the user's new phone number?”
“Can I resend the phone verification SMS after updating a number?”
Tell an agent
Send a verification SMS to my phone.
Text the logged-in user a phone verification code.
PUT
/account/verifications/phone
Confirm a user's phone number · Update phone verification (confirmation)
#
Ask an LLM
“How do I finish phone verification with the SMS code?”
“What do I submit to mark a phone number as verified?”
Tell an agent
Confirm the phone of user {userId} with SMS secret {secret}.
Complete phone verification for {userId} using code {secret}.
Documentation
Specifications
SDKs
Schemas & Data
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/appwrite/refs/heads/main/json-schema/user-schema.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/appwrite/refs/heads/main/json-structure/user-structure.json
Other Resources
🔗
Overlay
https://raw.githubusercontent.com/api-evangelist/appwrite/refs/heads/main/overlays/appwrite-account-overlay.yaml
🔗
PostmanCollection
https://raw.githubusercontent.com/api-evangelist/appwrite/refs/heads/main/postman/appwrite-account-api.postman_collection.json
🔗
OpenCollection
https://raw.githubusercontent.com/api-evangelist/appwrite/refs/heads/main/collections/appwrite-account-api.opencollection.json
🔗
Examples
https://raw.githubusercontent.com/api-evangelist/appwrite/refs/heads/main/examples/user-example.json
🔗
JSONLD
https://raw.githubusercontent.com/api-evangelist/appwrite/refs/heads/main/json-ld/appwrite-context.jsonld
🔗
SpectralRules
https://raw.githubusercontent.com/api-evangelist/appwrite/refs/heads/main/rules/appwrite-spectral-rules.yml
🔗
Vocabulary
https://raw.githubusercontent.com/api-evangelist/appwrite/refs/heads/main/vocabulary/appwrite-vocabulary.yaml