Actions37
- Groups Actions
- Members Actions
- Roles Actions
- Permissions Actions
- Jobs Actions
- Shares Actions
- Actions Actions
- Users Actions
Overview
This node interacts with the iTwin Users and Access Control API, specifically allowing you to update a user member within an iTwin project. The "Update iTwin user member" operation modifies the roles assigned to a specific member of an iTwin user group.
Common scenarios include managing access control by updating user permissions or roles dynamically based on project needs. For example, if a team member's responsibilities change, you can update their role assignments programmatically without manual intervention in the iTwin platform.
Practical examples:
- Automatically updating user roles when onboarding or offboarding team members.
- Adjusting access levels for users based on project phase or task requirements.
- Integrating with HR systems to sync role changes into iTwin user management.
Properties
| Name | Meaning |
|---|---|
| ID | The identifier of the iTwin project or context where the user member exists. |
| Member ID | The unique identifier of the user member whose roles are being updated. |
| Role Ids | A JSON array listing the role IDs to assign to the user member. |
| Options | Additional optional settings: |
| - Custom Payload | Allows overriding the default request body with a custom JSON payload for advanced use cases. |
Output
The node outputs JSON data representing the response from the iTwin API after attempting to update the user member. This typically includes confirmation of the updated roles or details about the user member post-update.
If the API returns multiple objects, each is output as a separate JSON item. If the response is a single object, it is output directly. In case of errors (and if the node is configured to continue on failure), the output will contain an error message describing what went wrong.
No binary data output is involved in this operation.
Dependencies
- Requires an API authentication token credential for the iTwin OAuth2 API.
- The node depends on the iTwin Users and Access Control API endpoint.
- Proper configuration of the OAuth2 credentials in n8n is necessary to authenticate requests.
Troubleshooting
Common issues:
- Invalid or expired API tokens causing authentication failures.
- Incorrect or missing IDs (ID or Member ID) leading to "not found" errors.
- Malformed JSON in the Role Ids property causing request parsing errors.
- Insufficient permissions for the authenticated user to update roles.
Error messages:
"Unknown operation: update-itwin-user-member": Indicates the operation name is incorrect or not supported; verify spelling and case.- API errors returned from iTwin may include HTTP status codes like 401 (Unauthorized), 404 (Not Found), or 400 (Bad Request). Check credentials and input parameters accordingly.
- JSON parsing errors if the Role Ids input is not valid JSON; ensure correct formatting.
Resolutions:
- Refresh or reconfigure the API authentication token.
- Double-check all required IDs and ensure they exist in the iTwin system.
- Validate JSON inputs before running the node.
- Confirm that the authenticated user has sufficient privileges to perform updates.
Links and References
- iTwin Developer Documentation
- iTwin Users and Access Control API Reference (general link; specific endpoints documented there)