Workspaces, teams and users
Workspaces
The tenant is called a workspace, with the same word on every surface: console, admin API, CLI and declarative documents. Each workspace has its own APIs, applications, teams and its own developer portal.
A workspace is never an Otoroshi tenant: everything the product projects lands in the default location of the gateway. Tenancy lives in the product.
- In the console, the workspace is a selector at the top of the sidebar: a session state, bounded by your rights.
- On the portal, it is read from the URL — never from a session, because an anonymous visitor has none and an API URL must mean the same thing to everyone.
Users
Users are global: one record per person, with memberships in several workspaces. A membership carries a role:
| Role | Can |
|---|---|
admin | everything in the workspace: settings, members, portal, catalogs, metadata fields |
producer | create APIs, and manage the APIs of the teams they belong to (or with no team) |
consumer | use the developer portal; no access to the console |
Installation administrators (APIM_BOOTSTRAP_ADMINS, or created with admin in Global
settings) can do everything everywhere. Who sees what, screen by screen:
Who sees what in the console. An administrator only sees the users who are members of
its own workspaces: a shared installation does not reveal that an email exists elsewhere.
Users signing in with an identity provider are created on their first login, with no workspace — an administrator adds them, or the portal of a workspace makes them consumers (see Authentication).
Deleting a person
Someone leaves, or asks to be forgotten: an installation administrator deletes the person —
Global settings › Users, the bin of their row; DELETE /api/users/<id or email>;
otoroshi-apim users delete <email>. What goes with them:
- their personal applications — the ones a consumer makes on a portal, in their personal team: the subscriptions of those applications are closed first, and the gateway revokes their keys (projected like any closing: replayed until the gateway answers), then the applications and the personal team are deleted;
- their sessions and API tokens — they are signed out everywhere at once —, their memberships of workspaces and teams, their notifications, their reviews.
What stays: the teams they shared with others, and what those teams own; the audit trail, the
record of what was done, under their email. Nobody deletes themselves, and a bootstrap administrator
is made again at every start: remove it from APIM_BOOTSTRAP_ADMINS first. An application or a
subscription a source declares (a remote catalog, Kubernetes) is the source's: remove it there first.
Teams
A team belongs to a workspace and groups people. It owns APIs (its producers can edit them) and applications (its members can see them and their credentials).
An individual developer never has to create a team to get a key: the portal gives each user an implicit personal team in the workspace, invisible until it matters.
ACL tags
Restricted visibility — of an API or of a plan — is expressed as tags:
user:jane@corp.eu a person
team:team_01a1… the members of a team
role:producer the members with a role in the workspace
A user carries user:<email>, role:<role> for its membership and team:<id> for each of its
teams; installation administrators also carry role:admin.