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 perform various operations on different resources. Specifically, for the Users resource and the Accept User Invite operation, it allows a user to accept an invitation to join a Directus project by providing a valid invite token and setting their password. This is useful in workflows where user onboarding is automated, such as when inviting users via email and then programmatically accepting their invites once they respond.
Practical example: After sending an invite to a new user, you can use this node to accept the invite on their behalf by supplying the invite token and a password, thereby activating their account without manual intervention.
Properties
| Name | Meaning |
|---|---|
| Password | The password that the invited user will set for their account upon accepting the invite. |
| Token | The unique token provided in the user invite, used to verify and accept the invitation. |
Output
The output of this operation is a JSON object representing the response from the Directus API after accepting the user invite. Typically, this includes details about the newly activated user or confirmation of successful acceptance.
The structure generally contains fields such as user ID, email, role, status, and other metadata related to the user account.
No binary data output is produced by this operation.
Dependencies
- Requires an active connection to a Directus instance via an API key credential.
- The node uses the Directus REST API endpoint
users/invite/acceptwith a POST request. - Proper permissions are needed on the Directus API side to accept user invites.
Troubleshooting
- Invalid or expired token error: If the token provided is invalid or has expired, the API will reject the request. Ensure the token is correct and still valid.
- Missing required parameters: Both
passwordandtokenmust be provided; missing either will cause the request to fail. - API authentication errors: Make sure the API credentials configured in n8n have sufficient rights and are correctly set up.
- Network or connectivity issues: Verify that the Directus instance is reachable from the n8n environment.
If errors occur, enabling "Continue On Fail" in the node settings can help capture error messages in the workflow output for debugging.