# Appwrite ## API Docs - account [Delete Account](https://uq63rbjj6t.apidog.io/api-3486306.md): Delete a currently logged in user account. Behind the scene, the user record is not deleted but permanently blocked from any access. This is done to avoid deleted accounts being overtaken by new users with the same email address. Any user-related resources like documents or storage files should be deleted separately. - account [Get Account](https://uq63rbjj6t.apidog.io/api-3486317.md): Get currently logged in user data as JSON object. - account [Create Account](https://uq63rbjj6t.apidog.io/api-3486311.md): Use this endpoint to allow a new user to register a new account in your project. After the user registration completes successfully, you can use the [/account/verfication](/docs/client/account#accountCreateVerification) route to start verifying the user email address. To allow the new user to login to their new account, you need to create a new [account session](/docs/client/account#accountCreateSession). - account [Update Account Email](https://uq63rbjj6t.apidog.io/api-3486312.md): Update currently logged in user account email address. After changing user address, user confirmation status is being reset and a new confirmation mail is sent. For security measures, user password is required to complete this request. - account [Create Account JWT](https://uq63rbjj6t.apidog.io/api-3486299.md): Use this endpoint to create a JSON Web Token. You can use the resulting JWT to authenticate on behalf of the current user when working with the Appwrite server-side API and SDKs. The JWT secret is valid for 15 minutes from its creation and will be invalid if the user will logout in that time frame. - account [Get Account Logs](https://uq63rbjj6t.apidog.io/api-3486300.md): Get currently logged in user list of latest security activity logs. Each log returns user IP address, location and date and time of log. - account [Update Account Name](https://uq63rbjj6t.apidog.io/api-3486307.md): Update currently logged in user account name. - account [Update Account Password](https://uq63rbjj6t.apidog.io/api-3486313.md): Update currently logged in user password. For validation, user is required to pass in the new password, and the old password. For users created with OAuth and Team Invites, oldPassword is optional. - account [Get Account Preferences](https://uq63rbjj6t.apidog.io/api-3486301.md): Get currently logged in user preferences as a key-value object. - account [Update Account Preferences](https://uq63rbjj6t.apidog.io/api-3486308.md): Update currently logged in user account preferences. You can pass only the specific settings you wish to update. - account [Create Password Recovery](https://uq63rbjj6t.apidog.io/api-3486309.md): Sends the user an email with a temporary secret key for password reset. When the user clicks the confirmation link he is redirected back to your app password reset URL with the secret key and email address values attached to the URL query string. Use the query string params to submit a request to the [PUT /account/recovery](/docs/client/account#accountUpdateRecovery) endpoint to complete the process. The verification link sent to the user's email address is valid for 1 hour. - account [Complete Password Recovery](https://uq63rbjj6t.apidog.io/api-3486315.md): Use this endpoint to complete the user account password reset. Both the **userId** and **secret** arguments will be passed as query parameters to the redirect URL you have provided when sending your request to the [POST /account/recovery](/docs/client/account#accountCreateRecovery) endpoint. - account [Delete All Account Sessions](https://uq63rbjj6t.apidog.io/api-3486318.md): Delete all sessions from the user account and remove any sessions cookies from the end client. - account [Get Account Sessions](https://uq63rbjj6t.apidog.io/api-3486302.md): Get currently logged in user list of active sessions across different devices. - account [Create Account Session](https://uq63rbjj6t.apidog.io/api-3486314.md): Allow the user to login into their account by providing a valid email and password combination. This route will create a new session for the user. - account [Create Anonymous Session](https://uq63rbjj6t.apidog.io/api-3486305.md): Use this endpoint to allow a new user to register an anonymous account in your project. This route will also create a new session for the user. To allow the new user to convert an anonymous account to a normal account, you need to update its [email and password](/docs/client/account#accountUpdateEmail) or create an [OAuth2 session](/docs/client/account#accountCreateOAuth2Session). - account [Create Account Session with OAuth2](https://uq63rbjj6t.apidog.io/api-3486304.md): Allow the user to login to their account using the OAuth2 provider of their choice. Each OAuth2 provider should be enabled from the Appwrite console first. Use the success and failure arguments to provide a redirect URL's back to your app when login is completed. - account [Delete Account Session](https://uq63rbjj6t.apidog.io/api-3486316.md): Use this endpoint to log out the currently logged in user from all their account sessions across all of their different devices. When using the option id argument, only the session unique ID provider will be deleted. - account [Get Session By ID](https://uq63rbjj6t.apidog.io/api-3486303.md): Use this endpoint to get a logged in user's session using a Session ID. Inputting 'current' will return the current session being used. - account [Create Email Verification](https://uq63rbjj6t.apidog.io/api-3486310.md): Use this endpoint to send a verification message to your user email address to confirm they are the valid owners of that address. Both the **userId** and **secret** arguments will be passed as query parameters to the URL you have provided to be attached to the verification email. The provided URL should redirect the user back to your app and allow you to complete the verification process by verifying both the **userId** and **secret** parameters. Learn more about how to [complete the verification process](/docs/client/account#accountUpdateVerification). The verification link sent to the user's email address is valid for 7 days. - account [Complete Email Verification](https://uq63rbjj6t.apidog.io/api-3486320.md): Use this endpoint to complete the user email verification process. Use both the **userId** and **secret** parameters that were attached to your app URL to verify the user email ownership. If confirmed this route will return a 200 status code. - avatars [Get Browser Icon](https://uq63rbjj6t.apidog.io/api-3486319.md): You can use this endpoint to show different browser icons to your users. The code argument receives the browser code as it appears in your user /account/sessions endpoint. Use width, height and quality arguments to change the output settings. - avatars [Get Credit Card Icon](https://uq63rbjj6t.apidog.io/api-3486321.md): The credit card endpoint will return you the icon of the credit card provider you need. Use width, height and quality arguments to change the output settings. - avatars [Get Favicon](https://uq63rbjj6t.apidog.io/api-3486322.md): Use this endpoint to fetch the favorite icon (AKA favicon) of any remote website URL. - avatars [Get Country Flag](https://uq63rbjj6t.apidog.io/api-3486323.md): You can use this endpoint to show different country flags icons to your users. The code argument receives the 2 letter country code. Use width, height and quality arguments to change the output settings. - avatars [Get Image from URL](https://uq63rbjj6t.apidog.io/api-3486325.md): Use this endpoint to fetch a remote image URL and crop it to any image size you want. This endpoint is very useful if you need to crop and display remote images in your app or in case you want to make sure a 3rd party image is properly served using a TLS protocol. - avatars [Get User Initials](https://uq63rbjj6t.apidog.io/api-3486327.md): Use this endpoint to show your user initials avatar icon on your website or app. By default, this route will try to print your logged-in user name or email initials. You can also overwrite the user name if you pass the 'name' parameter. If no name is given and no user is logged, an empty avatar will be returned. - avatars [Get QR Code](https://uq63rbjj6t.apidog.io/api-3486326.md): Converts a given plain text to a QR code image. You can use the query parameters to change the size and style of the resulting image. - database [List Documents](https://uq63rbjj6t.apidog.io/api-3486324.md): Get a list of all the user documents. You can use the query params to filter your results. On admin mode, this endpoint will return a list of all of the project's documents. [Learn more about different API modes](/docs/admin). - database [Create Document](https://uq63rbjj6t.apidog.io/api-3486328.md): Create a new Document. Before using this route, you should create a new collection resource using either a [server integration](/docs/server/database#databaseCreateCollection) API or directly from your database console. - database [Delete Document](https://uq63rbjj6t.apidog.io/api-3486335.md): Delete a document by its unique ID. This endpoint deletes only the parent documents, its attributes and relations to other documents. Child documents **will not** be deleted. - database [Get Document](https://uq63rbjj6t.apidog.io/api-3486338.md): Get a document by its unique ID. This endpoint response returns a JSON object with the document data. - database [Update Document](https://uq63rbjj6t.apidog.io/api-3486337.md): Update a document by its unique ID. Using the patch method you can pass only specific fields that will get updated. - functions [List Executions](https://uq63rbjj6t.apidog.io/api-3486329.md): Get a list of all the current user function execution logs. You can use the query params to filter your results. On admin mode, this endpoint will return a list of all of the project's executions. [Learn more about different API modes](/docs/admin). - functions [Create Execution](https://uq63rbjj6t.apidog.io/api-3486336.md): Trigger a function execution. The returned object will return you the current execution status. You can ping the `Get Execution` endpoint to get updates on the current execution status. Once this endpoint is called, your function execution process will start asynchronously. - functions [Get Execution](https://uq63rbjj6t.apidog.io/api-3486330.md): Get a function execution log by its unique ID. - locale [Get User Locale](https://uq63rbjj6t.apidog.io/api-3486331.md): Get the current user location based on IP. Returns an object with user country code, country name, continent name, continent code, ip address and suggested currency. You can use the locale header to get the data in a supported language. - locale [List Continents](https://uq63rbjj6t.apidog.io/api-3486332.md): List of all continents. You can use the locale header to get the data in a supported language. - locale [List Countries](https://uq63rbjj6t.apidog.io/api-3486333.md): List of all countries. You can use the locale header to get the data in a supported language. - locale [List EU Countries](https://uq63rbjj6t.apidog.io/api-3486334.md): List of all countries that are currently members of the EU. You can use the locale header to get the data in a supported language. - locale [List Countries Phone Codes](https://uq63rbjj6t.apidog.io/api-3486339.md): List of all countries phone codes. You can use the locale header to get the data in a supported language. - locale [List Currencies](https://uq63rbjj6t.apidog.io/api-3486340.md): List of all currencies, including currency symbol, name, plural, and decimal digits for all major and minor currencies. You can use the locale header to get the data in a supported language. - locale [List Languages](https://uq63rbjj6t.apidog.io/api-3486341.md): List of all languages classified by ISO 639-1 including 2-letter code, name in English, and name in the respective language. - storage [List Files](https://uq63rbjj6t.apidog.io/api-3486342.md): Get a list of all the user files. You can use the query params to filter your results. On admin mode, this endpoint will return a list of all of the project's files. [Learn more about different API modes](/docs/admin). - storage [Create File](https://uq63rbjj6t.apidog.io/api-3486343.md): Create a new file. The user who creates the file will automatically be assigned to read and write access unless he has passed custom values for read and write arguments. - storage [Delete File](https://uq63rbjj6t.apidog.io/api-3486344.md): Delete a file by its unique ID. Only users with write permissions have access to delete this resource. - storage [Get File](https://uq63rbjj6t.apidog.io/api-3486345.md): Get a file by its unique ID. This endpoint response returns a JSON object with the file metadata. - storage [Update File](https://uq63rbjj6t.apidog.io/api-3486346.md): Update a file by its unique ID. Only users with write permissions have access to update this resource. - storage [Get File for Download](https://uq63rbjj6t.apidog.io/api-3486348.md): Get a file content by its unique ID. The endpoint response return with a 'Content-Disposition: attachment' header that tells the browser to start downloading the file to user downloads directory. - storage [Get File Preview](https://uq63rbjj6t.apidog.io/api-3486347.md): Get a file preview image. Currently, this method supports preview for image files (jpg, png, and gif), other supported formats, like pdf, docs, slides, and spreadsheets, will return the file icon image. You can also pass query string arguments for cutting and resizing your preview image. - storage [Get File for View](https://uq63rbjj6t.apidog.io/api-3486349.md): Get a file content by its unique ID. This endpoint is similar to the download method but returns with no 'Content-Disposition: attachment' header. - teams [List Teams](https://uq63rbjj6t.apidog.io/api-3486350.md): Get a list of all the current user teams. You can use the query params to filter your results. On admin mode, this endpoint will return a list of all of the project's teams. [Learn more about different API modes](/docs/admin). - teams [Create Team](https://uq63rbjj6t.apidog.io/api-3486351.md): Create a new team. The user who creates the team will automatically be assigned as the owner of the team. The team owner can invite new members, who will be able add new owners and update or delete the team from your project. - teams [Delete Team](https://uq63rbjj6t.apidog.io/api-3486353.md): Delete a team by its unique ID. Only team owners have write access for this resource. - teams [Get Team](https://uq63rbjj6t.apidog.io/api-3486355.md): Get a team by its unique ID. All team members have read access for this resource. - teams [Update Team](https://uq63rbjj6t.apidog.io/api-3486358.md): Update a team by its unique ID. Only team owners have write access for this resource. - teams [Get Team Memberships](https://uq63rbjj6t.apidog.io/api-3486352.md): Get a team members by the team unique ID. All team members have read access for this list of resources. - teams [Create Team Membership](https://uq63rbjj6t.apidog.io/api-3486357.md): Use this endpoint to invite a new member to join your team. If initiated from Client SDK, an email with a link to join the team will be sent to the new member's email address if the member doesn't exist in the project it will be created automatically. If initiated from server side SDKs, new member will automatically be added to the team. - teams [Delete Team Membership](https://uq63rbjj6t.apidog.io/api-3486354.md): This endpoint allows a user to leave a team or for a team owner to delete the membership of any other team member. You can also use this endpoint to delete a user membership even if it is not accepted. - teams [Update Membership Roles](https://uq63rbjj6t.apidog.io/api-3486356.md): - teams [Update Team Membership Status](https://uq63rbjj6t.apidog.io/api-3486359.md): Use this endpoint to allow a user to accept an invitation to join a team after being redirected back to your app from the invitation email recieved by the user.