Skip to content

Commit dac187a

Browse files
gmrclaude
andcommitted
Rewrite admin docs for end-user audience
Replace API-reference-style docs (POST /api/... examples) with UI-oriented guides that walk users through the web interface. Covers authentication setup, blueprint creation, role management, and user/group administration. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 21e23f4 commit dac187a

4 files changed

Lines changed: 211 additions & 135 deletions

File tree

docs/docs/admin/authentication.md

Lines changed: 34 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,40 @@
11
# Authentication
22

33
Imbi supports multiple authentication methods that can be used
4-
simultaneously.
4+
simultaneously. As an administrator, you configure these during
5+
deployment via environment variables.
56

67
## Local Authentication
78

8-
Local authentication uses email and password credentials stored in Neo4j
9-
with Argon2 password hashing.
9+
Local authentication allows users to sign in with an email address and
10+
password. It is enabled by default and is the simplest way to get
11+
started.
1012

11-
Password requirements:
13+
When creating a user account (or when users set their own password),
14+
the following requirements apply:
1215

1316
- Minimum 12 characters
1417
- At least one uppercase letter
1518
- At least one lowercase letter
1619
- At least one digit
1720
- At least one special character
1821

19-
Local authentication is enabled by default. Disable it with:
22+
To disable local authentication (for example, if you only want OAuth):
2023

2124
```
2225
IMBI_AUTH_LOCAL_ENABLED=false
2326
```
2427

25-
## OAuth2 / OIDC
28+
## Single Sign-On (OAuth2 / OIDC)
2629

27-
Imbi supports OAuth2/OIDC authentication with the following providers:
30+
For organizations using a centralized identity provider, Imbi supports
31+
OAuth2 and OpenID Connect. When configured, a "Sign in with ..."
32+
button appears on the login page. Users who sign in via SSO for the
33+
first time are automatically provisioned with a default role.
2834

2935
### Google
3036

31-
Set the following environment variables:
37+
Add these environment variables to enable Google sign-in:
3238

3339
```
3440
IMBI_AUTH_GOOGLE_CLIENT_ID=your-client-id
@@ -44,23 +50,37 @@ IMBI_AUTH_GITHUB_CLIENT_SECRET=your-client-secret
4450

4551
### Generic OIDC (Keycloak, Okta, etc.)
4652

53+
Any OpenID Connect-compatible provider can be used:
54+
4755
```
4856
IMBI_AUTH_OIDC_CLIENT_ID=your-client-id
4957
IMBI_AUTH_OIDC_CLIENT_SECRET=your-client-secret
5058
IMBI_AUTH_OIDC_DISCOVERY_URL=https://your-idp/.well-known/openid-configuration
5159
```
5260

61+
!!! tip
62+
Set `IMBI_AUTH_CALLBACK_BASE_URL` to the public URL of your Imbi
63+
instance (e.g. `https://imbi.example.com`) so that OAuth callbacks
64+
route correctly.
65+
5366
## Multi-Factor Authentication
5467

55-
Imbi supports TOTP-based MFA. Users can enable MFA from their profile
56-
settings. When enabled, users must provide a time-based one-time password
57-
in addition to their primary credentials.
68+
Users can enable TOTP-based multi-factor authentication from their
69+
profile settings page. Once enabled, they will be prompted for a
70+
time-based one-time password after entering their credentials.
71+
72+
MFA is optional and user-managed -- administrators cannot force it at
73+
this time, but it is recommended for accounts with elevated privileges.
5874

5975
## Sessions
6076

61-
Sessions are managed via JWT tokens:
77+
Imbi manages sessions automatically:
6278

63-
- **Access tokens** expire after 15 minutes
79+
- **Access tokens** expire after 15 minutes and are refreshed transparently
6480
- **Refresh tokens** expire after 7 days
6581
- Maximum 5 concurrent sessions per user
66-
- Session timeout (inactivity): 24 hours (configurable)
82+
- Session timeout (inactivity): 24 hours (configurable via
83+
`IMBI_AUTH_SESSION_TIMEOUT`)
84+
85+
Users do not need to manage sessions directly. If a session expires,
86+
they are redirected to the login page.

docs/docs/admin/blueprints.md

Lines changed: 52 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -1,64 +1,66 @@
11
# Blueprints
22

3-
Blueprints are customizable metadata schemas that extend the base project
4-
model with additional fields specific to your organization's needs.
3+
Blueprints let you define custom metadata fields for different types of
4+
projects in your service catalog. For example, you might create a
5+
"Microservice" blueprint that requires every microservice to specify its
6+
programming language and SLA tier, while a "Library" blueprint asks for
7+
documentation URL and supported platforms.
58

69
## How Blueprints Work
710

8-
Each blueprint defines a JSON Schema that describes additional metadata
9-
fields for projects. When a project is created with a blueprint, the
10-
project's metadata is validated against the blueprint's schema.
11+
Each blueprint defines a set of additional fields (as a JSON Schema)
12+
that are added to the project creation and edit forms. When someone
13+
creates a project and selects a blueprint, Imbi shows the blueprint's
14+
fields in the UI and validates them before saving.
1115

1216
## Creating a Blueprint
1317

14-
```json
15-
POST /api/blueprints
16-
{
17-
"name": "Microservice",
18-
"description": "Schema for microservice projects",
19-
"schema": {
20-
"type": "object",
21-
"properties": {
22-
"language": {
23-
"type": "string",
24-
"enum": ["python", "go", "rust", "typescript"]
25-
},
26-
"framework": {
27-
"type": "string"
28-
},
29-
"sla_tier": {
30-
"type": "string",
31-
"enum": ["tier1", "tier2", "tier3"]
32-
}
33-
},
34-
"required": ["language", "sla_tier"]
35-
}
36-
}
37-
```
18+
1. Navigate to **Settings > Blueprints** in the admin panel
19+
2. Click **New Blueprint**
20+
3. Fill in the name and description
21+
4. Define the fields using the schema editor:
22+
- Add fields with types like text, number, select (dropdown), or
23+
boolean
24+
- Mark fields as required or optional
25+
- For select fields, define the allowed values
26+
5. Click **Save**
27+
28+
### Example
29+
30+
A "Microservice" blueprint might define:
31+
32+
| Field | Type | Required | Options |
33+
|-------|------|----------|---------|
34+
| Language | Select | Yes | Python, Go, Rust, TypeScript |
35+
| Framework | Text | No | - |
36+
| SLA Tier | Select | Yes | Tier 1, Tier 2, Tier 3 |
37+
38+
When a user creates a new project with this blueprint, they see these
39+
fields alongside the standard project fields (name, description,
40+
team, etc.).
3841

3942
## Using Blueprints
4043

41-
When creating a project, specify the blueprint to apply its schema:
42-
43-
```json
44-
POST /api/projects
45-
{
46-
"name": "my-service",
47-
"blueprint_id": "blueprint-id",
48-
"metadata": {
49-
"language": "python",
50-
"framework": "FastAPI",
51-
"sla_tier": "tier1"
52-
}
53-
}
54-
```
55-
56-
The metadata will be validated against the blueprint's JSON Schema. If
57-
validation fails, the request is rejected with details about which fields
58-
are invalid.
44+
When creating or editing a project:
45+
46+
1. Select a blueprint from the **Blueprint** dropdown
47+
2. Fill in the blueprint-specific fields that appear
48+
3. Required fields must be completed before the project can be saved
49+
50+
The blueprint selection can be changed later, but metadata from the
51+
previous blueprint is not automatically migrated.
5952

6053
## Updating Blueprints
6154

62-
Blueprint schemas can be updated over time. Existing projects are not
63-
retroactively validated against updated schemas, but new project
64-
creations and updates will use the current schema.
55+
Blueprint schemas can be updated over time as your organization's
56+
needs change. When you update a blueprint:
57+
58+
- **New projects** use the updated schema immediately
59+
- **Existing projects** are not retroactively validated -- they keep
60+
their current metadata until the next edit
61+
- When editing an existing project, the current schema is applied
62+
63+
!!! tip
64+
Start with fewer required fields and add more over time. It is
65+
easier to make a field required later than to deal with existing
66+
projects that are missing a newly required field.
Lines changed: 69 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -1,61 +1,87 @@
11
# Roles and Permissions
22

3-
Imbi uses a role-based access control (RBAC) system for authorization.
3+
Imbi uses role-based access control (RBAC) to manage what users can
4+
see and do. Permissions are grouped into roles, and roles are assigned
5+
to users.
46

5-
## Permissions
7+
## Built-in Roles
68

7-
Permissions are fine-grained access controls in the format
8-
`resource:action`. For example:
9-
10-
- `projects:read` - View projects
11-
- `projects:write` - Create and update projects
12-
- `projects:delete` - Delete projects
13-
- `users:read` - View user profiles
14-
- `users:write` - Create and update users
15-
- `blueprints:read` - View blueprints
16-
- `blueprints:write` - Create and update blueprints
17-
18-
## Roles
19-
20-
Roles are named collections of permissions. Imbi ships with three
21-
default roles:
9+
Imbi ships with three default roles created during initial setup:
2210

2311
### Admin
2412

25-
Full access to all resources and operations.
13+
Full access to everything: manage users, roles, organizations, teams,
14+
blueprints, and all project operations. Assign this role to platform
15+
administrators.
2616

2717
### Developer
2818

29-
Read and write access to projects, blueprints, and related resources.
30-
Cannot manage users, roles, or system settings.
19+
Can view and manage projects, blueprints, and related resources. Cannot
20+
manage users, roles, or system-level settings. This is the typical role
21+
for engineering team members.
3122

3223
### Readonly
3324

34-
Read-only access to all resources. Cannot create, update, or delete
35-
anything.
25+
Can view all resources but cannot create, edit, or delete anything.
26+
Useful for stakeholders who need visibility without write access.
3627

37-
## Custom Roles
28+
## Assigning Roles
3829

39-
Administrators can create custom roles with any combination of
40-
permissions via the REST API:
41-
42-
```
43-
POST /api/roles
44-
{
45-
"name": "Team Lead",
46-
"permissions": [
47-
"projects:read",
48-
"projects:write",
49-
"users:read",
50-
"blueprints:read"
51-
]
52-
}
53-
```
30+
Roles are assigned to users within the context of an organization. A
31+
user can have different roles in different organizations -- for example,
32+
an admin in one org and a developer in another.
5433

55-
## Assigning Roles
34+
To assign a role:
35+
36+
1. Navigate to **Settings > Users**
37+
2. Select the user
38+
3. Under **Organization Memberships**, choose the role for each
39+
organization the user belongs to
40+
4. Click **Save**
5641

57-
Roles are assigned to users within the context of an organization. A user
58-
can have different roles in different organizations.
42+
## Group-Based Roles
43+
44+
Instead of assigning roles to individual users, you can assign roles
45+
to groups. All members of the group automatically inherit the group's
46+
roles.
47+
48+
This is the recommended approach for teams:
49+
50+
1. Create a group (e.g. "Backend Team")
51+
2. Assign a role to the group (e.g. "Developer")
52+
3. Add users to the group
53+
54+
When a user is added to or removed from the group, their effective
55+
permissions update immediately.
56+
57+
## Custom Roles
5958

60-
Roles can also be assigned to groups. All members of the group inherit the
61-
group's roles in addition to any individually assigned roles.
59+
If the built-in roles do not fit your needs, administrators can create
60+
custom roles:
61+
62+
1. Navigate to **Settings > Roles**
63+
2. Click **New Role**
64+
3. Enter a name (e.g. "Team Lead")
65+
4. Select the permissions to include
66+
5. Click **Save**
67+
68+
### Available Permissions
69+
70+
Permissions follow a `resource:action` pattern:
71+
72+
| Permission | Description |
73+
|------------|-------------|
74+
| `projects:read` | View projects and their metadata |
75+
| `projects:write` | Create and update projects |
76+
| `projects:delete` | Delete projects |
77+
| `users:read` | View user profiles |
78+
| `users:write` | Create and manage user accounts |
79+
| `blueprints:read` | View blueprints |
80+
| `blueprints:write` | Create and manage blueprints |
81+
| `roles:read` | View roles and permissions |
82+
| `roles:write` | Create and manage roles |
83+
84+
!!! tip
85+
Follow the principle of least privilege: start with the Readonly
86+
role and add permissions as needed, rather than starting with Admin
87+
and removing them.

0 commit comments

Comments
 (0)