n8n

How to Automate Zammad User Role Management?

Assign default roles to your helpdesk users in one run. The setup also exports all role names to Excel so your team can review and choose the right defaults. It suits support teams that want simple access control without manual editing in the admin panel.

The run begins by loading your base URL, API token, and default role IDs from a single variables node. It then pulls every user from your service using the Zammad connector and maps key fields for clean processing. A second branch calls the roles API, shapes the data, lets you filter, and writes an Excel file with role names and IDs. After an optional filter on the user list, a final request updates each user with the default roles you set. Authentication uses a Bearer token in the header for both the roles fetch and the user updates.

You need a Zammad instance, an access token, and permission to manage users and roles. Expect to cut routine role changes from hours to minutes while keeping a clear roles list you can share. This is useful for new tenant setup, seasonal hiring, and standardizing permissions after an audit. Configuration is simple and guided by the variables node, and testing is safe because it runs on demand with a manual start.

What are the key features?

  • Manual start for safe, on demand updates without surprises
  • Fetch all users from Zammad with token based authentication
  • Standardize user and role fields using set nodes for clean data
  • Call the Zammad roles API and include a secure Bearer header
  • Optional filters to narrow which roles to export and which users to change
  • Export roles to an Excel file named Zammad_Roles.xlsx
  • Update users by sending a PUT request with selected role IDs
  • Central variables store for base URL, API key, and default role IDs

What are the benefits?

  • Reduce manual role updates from 2 hours to 10 minutes per cycle
  • Automate up to 90 percent of user role assignments
  • Improve data accuracy by using a single source for role IDs
  • Export a fresh roles list to Excel for quick review and sharing
  • Connect Zammad user data and role data in one controlled run

How do you set it up?

  1. Import the template into n8n: Create a new workflow in n8n > Click the three dots menu > Select 'Import from File' > Choose the downloaded JSON file.
  2. You'll need accounts with Zammad. See the Tools Required section above for links to create accounts with these services.
  3. In the n8n credentials manager, double click the Zammad Users node, then on the Credential to connect with dropdown, click Create new credential, and follow the on screen steps to add your Zammad Token Auth credential using a personal access token with permission to read users.
  4. Open the Basic Variables node and set zammad_base_url to your full Zammad URL including https, for example https://yourdomain.tld.
  5. In the Basic Variables node, set zammad_api_key to a Zammad personal access token that can read roles and update users. This token is used by the HTTP Request nodes through the Authorization header.
  6. Run a test to fetch roles: Click Execute. Open the Convert to Excel Roles node output and download Zammad_Roles.xlsx. Use this sheet to find the correct role IDs.
  7. Back in the Basic Variables node, set default_roles to a comma separated list of role IDs, for example 2,3. These will be applied to each targeted user.
  8. Adjust the user If node to match your target group if needed, for example only active users or users missing roles. Save your changes.
  9. Click Execute again. Confirm updates in Zammad by opening a few users and checking that the default roles now appear.
  10. If you see 401 or 403 errors, check the token and its permissions. If you see 404, verify the base URL. If the update fails, make sure default_roles contains valid numeric IDs with commas and no extra spaces.

Tools Required

$24 / mo or $20 / mo billed annually to use n8n in the cloud. However, the local or self-hosted n8n Community Edition is free.

Zammad

Sign up

Self-hosted (open-source): Free (AGPLv3), API included

Similar Templates

Join Futurise to access 1,200+ automation templates

Get instant access to ready-made automation workflows for n8n, Make.com, AI agents, and more. Download, customise, and deploy in minutes.