tangled
alpha
login
or
join now
malpercio.dev
/
atbb
5
fork
atom
WIP! A BB-style forum, on the ATmosphere! We're still working... we'll be back soon when we have something to show off!
node
typescript
hono
htmx
atproto
5
fork
atom
overview
issues
pulls
pipelines
docs(bruno): add Themes API collection (ATB-55)
malpercio.dev
1 week ago
f19ad429
6993441e
+115
3 changed files
expand all
collapse all
unified
split
bruno
AppView API
Themes
Get Theme Policy.bru
Get Theme.bru
List Available Themes.bru
+35
bruno/AppView API/Themes/Get Theme Policy.bru
···
1
1
+
meta {
2
2
+
name: Get Theme Policy
3
3
+
type: http
4
4
+
seq: 3
5
5
+
}
6
6
+
7
7
+
get {
8
8
+
url: {{appview_url}}/api/theme-policy
9
9
+
}
10
10
+
11
11
+
assert {
12
12
+
res.status: eq 200
13
13
+
res.body.allowUserChoice: isDefined
14
14
+
res.body.availableThemes: isDefined
15
15
+
}
16
16
+
17
17
+
docs {
18
18
+
Returns the forum's theme policy: which themes are available to users,
19
19
+
the default light and dark themes, and whether users can pick their own.
20
20
+
21
21
+
Returns:
22
22
+
{
23
23
+
"defaultLightThemeUri": "at://did:plc:.../space.atbb.forum.theme/...",
24
24
+
"defaultDarkThemeUri": "at://did:plc:.../space.atbb.forum.theme/...",
25
25
+
"allowUserChoice": true,
26
26
+
"availableThemes": [
27
27
+
{ "uri": "at://did:plc:.../space.atbb.forum.theme/...", "cid": "bafy..." }
28
28
+
]
29
29
+
}
30
30
+
31
31
+
Error codes:
32
32
+
- 404: No theme policy published yet
33
33
+
- 500: Server error
34
34
+
- 503: Database temporarily unavailable
35
35
+
}
+44
bruno/AppView API/Themes/Get Theme.bru
···
1
1
+
meta {
2
2
+
name: Get Theme
3
3
+
type: http
4
4
+
seq: 2
5
5
+
}
6
6
+
7
7
+
get {
8
8
+
url: {{appview_url}}/api/themes/{{theme_rkey}}
9
9
+
}
10
10
+
11
11
+
assert {
12
12
+
res.status: eq 200
13
13
+
res.body.name: isDefined
14
14
+
res.body.tokens: isDefined
15
15
+
}
16
16
+
17
17
+
docs {
18
18
+
Returns full theme data (name, colorScheme, tokens, cssOverrides, fontUrls)
19
19
+
for the theme identified by its rkey (TID).
20
20
+
21
21
+
Set the theme_rkey environment variable to a valid theme rkey before running.
22
22
+
23
23
+
Path params:
24
24
+
- rkey: Theme record key (TID, e.g. 3lblexample)
25
25
+
26
26
+
Returns:
27
27
+
{
28
28
+
"id": "1",
29
29
+
"uri": "at://did:plc:.../space.atbb.forum.theme/3lblexample",
30
30
+
"name": "Neobrutal Light",
31
31
+
"colorScheme": "light",
32
32
+
"tokens": { "color-bg": "#f5f0e8", "color-text": "#1a1a1a" },
33
33
+
"cssOverrides": null,
34
34
+
"fontUrls": null,
35
35
+
"createdAt": "2026-03-01T00:00:00.000Z",
36
36
+
"indexedAt": "2026-03-01T00:00:00.000Z"
37
37
+
}
38
38
+
39
39
+
Error codes:
40
40
+
- 400: Invalid rkey (empty)
41
41
+
- 404: Theme not found
42
42
+
- 500: Server error
43
43
+
- 503: Database temporarily unavailable
44
44
+
}
+36
bruno/AppView API/Themes/List Available Themes.bru
···
1
1
+
meta {
2
2
+
name: List Available Themes
3
3
+
type: http
4
4
+
seq: 1
5
5
+
}
6
6
+
7
7
+
get {
8
8
+
url: {{appview_url}}/api/themes
9
9
+
}
10
10
+
11
11
+
assert {
12
12
+
res.status: eq 200
13
13
+
res.body.themes: isDefined
14
14
+
}
15
15
+
16
16
+
docs {
17
17
+
Returns themes filtered to those in the forum's themePolicy.availableThemes.
18
18
+
Returns an empty array if no theme policy has been published.
19
19
+
20
20
+
Returns:
21
21
+
{
22
22
+
"themes": [
23
23
+
{
24
24
+
"id": "1",
25
25
+
"uri": "at://did:plc:.../space.atbb.forum.theme/...",
26
26
+
"name": "Neobrutal Light",
27
27
+
"colorScheme": "light",
28
28
+
"indexedAt": "2026-03-01T00:00:00.000Z"
29
29
+
}
30
30
+
]
31
31
+
}
32
32
+
33
33
+
Error codes:
34
34
+
- 500: Server error
35
35
+
- 503: Database temporarily unavailable
36
36
+
}