Actions109
- Activity Actions
- Assets Actions
- Authentication Actions
- Collections Actions
- Extensions Actions
- Fields Actions
- Files Actions
- Folders Actions
- Items Actions
- Permissions Actions
- Presets Actions
- Relations Actions
- Revisions Actions
- Roles Actions
- Settings Actions
- Users Actions
- Utilities Actions
- Webhooks Actions
Overview
This node integrates with the Directus API to manage user data within a Directus instance. Specifically, the Users - Update operation allows you to update an existing user's information by specifying their unique ID and providing partial user data in JSON format.
Common scenarios where this node is beneficial include:
- Updating user profiles or attributes programmatically.
- Automating user management workflows such as changing roles, updating contact details, or modifying permissions.
- Integrating Directus user updates into larger automation pipelines.
For example, you might use this node to update a user's title or department after receiving input from another system or form submission.
Properties
| Name | Meaning |
|---|---|
| ID | The primary key (unique identifier) of the user to update. |
| Data (JSON) | A partial user object in JSON format containing the fields and values to update for the user. |
The "Data (JSON)" property expects a JSON object representing any subset of the user fields supported by Directus. For example:
{
"title": "CTO",
"email": "new.email@example.com"
}
Output
The output of this operation is a JSON object representing the updated user record as returned by the Directus API. This includes all user fields after the update has been applied.
Example output structure:
{
"id": "72a1ce24-4748-47de-a05f-ce9af3033727",
"email": "new.email@example.com",
"title": "CTO",
"first_name": "John",
"last_name": "Doe",
...
}
No binary data output is produced by this operation.
Dependencies
- Requires a valid connection to a Directus instance via an API key credential configured in n8n.
- The node uses the Directus REST API endpoints and requires appropriate permissions to update users.
- No additional external dependencies beyond the Directus API and n8n's HTTP request capabilities.
Troubleshooting
- Invalid ID or User Not Found: If the provided user ID does not exist, the API will return an error. Verify the ID is correct.
- Insufficient Permissions: Ensure the API key used has permission to update user records.
- Malformed JSON Data: The "Data (JSON)" field must be valid JSON. Syntax errors will cause failures.
- API Connectivity Issues: Network problems or incorrect Directus URL/credentials can cause request failures.
- Partial Updates: Only provide fields you want to update; omitting required fields may cause errors depending on your Directus setup.
If an error occurs, the node will throw an error unless "Continue On Fail" is enabled, in which case it outputs an error message in the JSON.
Links and References
This summary focuses exclusively on the "Users" resource and the "Update" operation as requested.