Skip to main content

Roles and permissions

Permissions in tmspec have two layers and one general principle: every credential belongs to a person.

Roles​

You have a role in the workspace and, separately for each project, a role in the project.

LevelRoleWhat it can do
WorkspaceownerEverything, including managing other owners. A workspace always keeps at least one owner
WorkspaceadminManages members and projects; is admin in every project
WorkspacememberA member; has no right in any project until given a project role
ProjectviewerReads specs, change requests and history; comments on change requests
ProjectcontributorLike viewer, and proposes, edits, submits and withdraws their own change requests; writes implementation specs; adds tags
ProjectreviewerLike contributor, and approves, rejects or asks for changes on change requests
ProjectadminLike reviewer, and manages Areas, project settings and roles in the project

A few things worth knowing:

  • Workspace owners and admins are admins in every project, with no separate grant needed.
  • Reviewers and admins can also approve a change request they proposed themselves, as long as they belong to the group that has to sign (see Area).
  • The owner of a spec who has the contributor role or above in the project can also click Ready and retire that implementation spec, and confirm (No impact included) the links of that spec, even when they are not a reviewer.
  • A person with no role in a project does not see that project: the answer is identical to the project not existing.
  • Removing or lowering a role takes effect at the next request, even when that person still has an open session.

Credentials and scopes​

You reach tmspec in three ways: signing in on the web, signing in with the CLI, or an API key (for agents, CI, scripts). All three are you. The real permission of a request is the intersection of two things:

the person's role ∩ the credential's scopes = real permission

Scopes only narrow, they never widen. A person's sign-in carries all 15 scopes, so their permission is their role. An API key carries exactly the scopes chosen when it was created; the default is read and propose.

GroupScopeAllows
Readread:specRead specs, change requests, history
Readread:workspaceRead the workspace and projects
Writewrite:proposalPropose change requests and retires
Writewrite:commentComment on change requests
Writewrite:wspec-draftCreate and edit implementation spec drafts
Writewrite:linkAdd and remove weak links
Writewrite:tagAdd and remove tags and manage the tag catalogue
Writewrite:verificationRecord the verification of a criterion
Decidedecide:change-requestApprove, reject, ask for changes
Decidedecide:linkConfirm No impact
Decidedecide:wspecClick Ready, retire an implementation spec
Managemanage:itemChange a spec's owner and visibility
Managemanage:projectManage projects and Areas
Managemanage:membersManage members
Managemanage:workspaceManage the workspace, create projects

Scopes are independent of each other: write:* does not imply read:*, and every key must have read:spec: the sign-in service refuses to create a key without it, even one that only has read:workspace. No scope allows creating or revoking an API key; that can only be done by your own sign-in on the web.

A decision always has a person's name​

When an API key approves a change request, the record names the person who owns the key and the key that was used. There is no separate "agent": an agent works under the name of the person who gave it the key, within the scopes. So giving a key decide:* or manage:* lets the key do that on your behalf; the web warns you when you tick these scopes.

The answer when refused​

SituationWhat you see
Not a member, or no role in the projectNot found (404), identical to the resource not existing
Role not enoughNo permission (403)
Role enough but the key lacks a scopeNo permission, with the name of the missing scope

On the web, a button shows only when you can really do it. Through the API, each resource has an allowed_actions field that lists exactly what your role and scopes allow.