Error when deactivating workflow with the Owner account
What is the error message (if any)?
Workflow could not be deactivated:
User is missing a scope required to perform this action
Hello everyone, how are you? I wanted to ask if in version 2.x it is no longer possible to deactivate workflows in other accounts, even if I use the owner account, since it was possible before. In fact, if I use the API Key by logging in with the account where I have the workflow I want to deactivate, it lets me, but not with the Owner account, using the Owner’s API Key.
that “missing scope” error started popping up right after the v2.x RBAC update because n8n changed how permissions are handled for the owner account.
might be worth checking these two things:
api key scopes: go to settings → n8n api and make sure the owner’s key has the workflow:update and workflow:unpublish scopes enabled.
project sharing: if the workflow is in a private project, the owner needs to be added as a “collaborator” with edit rights before they can deactivate it.
honestly, if it works with the creator’s key but not yours, it’s 100% a scope mismatch on the owner’s account — i’d just regenerate that key with all permissions checked and see if it clears.
did you just move that workflow into a new project?
Thank you for your prompt response. I am using the community version n8n, and regarding the Owner account Scopes, I selected all of them when I generated the API KEY. In fact, I deleted the one I had with version 1.x and generated it again with version 2.x.
Hi @Internalit_Automatio Welcome!
In community edition the API does not support the concept of scoped permissions, and the owner of the instance has the full access by default, the issue might be caused after the 2.x updates as they do not support those protocols now, i mean just try using the workflow owner’s API key , although if this is enterprise level consider upgrading as licensed plans support RBAC and proper project-level access controls.
Hello @Anshul_Namdev
Thank you for your prompt response. I tried using the API Key from the account where I wanted to disable the workflows, using the Owner account, and it worked correctly. We will consider the Enterprise option.