foliot docs

Concepts / Roles and permissions

Roles and permissions

Everyone in a workspace has one role there, and it applies to every app in that workspace. These roles are:

  • Owner: owns the workspace. In addition to admin access, they can close the workspace, delete apps for good, and manage other owners.
  • Admin: manages the workspace. Manages the members who are not owners, creates apps as well as app settings, credentials and members’ roles.
  • Operator: handles the day-to-day operations. They can register workflows as well as start, fix and stop runs.
  • Viewer: has read-only access to the workspace and cannot change anything in it, other than leaving it.

Your service talks to Foliot using its app’s API key, which is not associated with a role. It is limited to its own app, and can do there what the tables below give it under API key.

Note: 

A role is scoped to a workspace. So, you can be an owner in one workspace and a viewer in another. A change to someone’s role applies to their next request.

What each role may do

✓ means allowed. “Own app” means the API key may do it for its own app and no other.

The workspace

Action Viewer Operator Admin Owner API key
See its apps, workflows, runs, paused steps and bulk actions ✓ ✓ ✓ ✓ Own app
See its metrics and its usage against the plan ✓ ✓ ✓ ✓
Leave it ✓ ✓ ✓ ✓
See its members, invitations and history ✓ ✓
Invite people as viewer, operator or admin ✓ ✓
Change roles among viewer, operator and admin ✓ ✓
Remove a member who is not an owner ✓ ✓
Cancel an invitation, except one to become an owner ✓ ✓
Invite someone as an owner, cancel that invitation, or make someone an owner ✓
Change an owner’s role, or remove an owner ✓
Close it, restore it, or delete it for good ✓

Anyone signed in can also make a workspace of their own, and become its first owner. A workspace’s only owner cannot leave it or be demoted without assigning ownership to another owner first.

Apps

Action Viewer Operator Admin Owner API key
Create an app ✓ ✓
Change its handler base URL, description or automatic pausing ✓ ✓ Own app
Reveal or rotate its signing secret, and see who has ✓ ✓ Own app
Rotate its API key ✓ ✓
Delete or restore it, and see deleted apps ✓ ✓
Delete it for good ✓

Every reveal and rotation records who did it and the reason they provided. When an owner or admin creates an app, the reveal reason for its signing secret is auto-filled, so setting up the handlers for the initial creation takes one click.

Workflows and runs

Action Viewer Operator Admin Owner API key
Register a workflow version, and set or remove an alias ✓ ✓ ✓ Own app
Pause or resume a step ✓ ✓ ✓ Own app
Start, cancel, redrive or rewind a run; skip a step; edit state; send a signal ✓ ✓ ✓ Own app
Start or cancel a bulk action ✓ ✓ ✓ Own app
Claim tasks and answer them (a worker or handler) Own app

A bulk action keeps running only while the person who started it is still an operator, admin or owner. It stops before its next run once they are no longer an operator, admin or owner, or are removed from the workspace.

Emails

Owners and admins are sent an email if Foliot auto pauses/resumes a step on its own, when a member leaves the workspace, or when the workspace’s usage reaches a percentage of its plan.

Confirming it is you

Some actions ask you to confirm it is you before Foliot carries them out, even with the right role:

  • revealing or rotating the signing secret, and rotating the API key;
  • changing an app’s settings, such as its handler URL;
  • inviting someone, changing a member’s role, and removing a member;
  • deleting or purging an app;
  • closing or purging the workspace;
  • starting a bulk action (a preview never asks).

If you have not entered your authenticator code recently enough (or your password, if you do not use an authenticator), Foliot Console asks you to do so and then carries on. An app’s API key is never asked.

  • When you try to carry out an action not allowed by your role, it is refused with 403. That includes an admin asking to do anything about an owner.
  • If you act on a workspace or an app you are not a member of, you get a 404.
  • If an action needs you to confirm it is you and you have not done so recently enough, it is refused with 403 and the error code reverification_required, before anything changes. Sign in again and repeat the request.