Actions181
- Account Actions
- Get Account
- Create Account
- Update Email
- Update Name
- Update Password
- Update Phone
- Update Status
- Get Preferences
- Update Preferences
- List Sessions
- Delete Sessions
- Get Session
- Update Session
- Delete Session
- Create Anonymous Session
- Create Email/Password Session
- Create Magic URL Session
- Create OAuth2 Session
- Create Phone Session
- Create Session from Token
- Create JWT
- Create Magic URL
- Create Phone Token
- Create Email Verification
- Update Email Verification
- Create Phone Verification
- Update Phone Verification
- Create Password Recovery
- Update Password Recovery
- Create Recovery
- Update Recovery
- Update MFA
- Create MFA Authenticator
- Update MFA Authenticator
- Delete MFA Authenticator
- Create MFA Challenge
- Update MFA Challenge
- Attribute Actions
- Avatars Actions
- Collection Actions
- Database Actions
- Document Actions
- Functions Actions
- Index Actions
- Locale Actions
- Messaging Actions
- Sites Actions
- Storage Actions
- Teams Actions
- Users Actions
Attribute → Create Multiple
AI-generatedOverview
This node interacts with the Appwrite API to create multiple attributes within a specified database collection. It supports two input modes: a user-friendly form for adding attributes one by one, or a JSON array for bulk attribute creation. This is useful for automating the setup of database schemas or dynamically managing attribute definitions in Appwrite databases.
Use Case Examples
- Creating multiple attributes for a user profile collection by specifying each attribute's type, key, size, and other properties via the form input mode.
- Providing a JSON array of attribute definitions to quickly create multiple attributes in a collection, such as for product specifications or metadata.
Properties
| Name | Meaning |
|---|---|
| Database ID | The ID of the database where attributes will be created. |
| Collection ID | The ID of the collection within the database where attributes will be added. |
| Input Mode | Determines how attributes are provided: either through a form interface or as a JSON array. |
| Attributes | A collection of attribute definitions entered via the form, each specifying type, key, size, required flag, default value, array flag, enum elements, and min/max values as applicable. |
| Attributes (JSON) | An array of attribute objects provided as JSON to create multiple attributes in bulk. |
Output
JSON
json- The response from the Appwrite API after creating the attributes, typically including details of the created attributes or any errors.
Dependencies
- Appwrite API with credentials including endpoint, project ID, and API key.
Troubleshooting
- Ensure the provided databaseId and collectionId are correct and exist in the Appwrite project to avoid 'Unknown resource' or 'Not found' errors.
- Validate JSON input format when using JSON input mode to prevent parsing errors.
- Check API key permissions to ensure the node has rights to create attributes in the specified database and collection.
- If the node throws errors related to attribute properties, verify that required fields like 'key' and 'type' are correctly set and that values like 'size', 'min', and 'max' are valid for the attribute type.
Links
- Appwrite Database Attributes Documentation - Official documentation on managing database attributes in Appwrite.