Themes
Auto-generated API documentation.
Themes Service
Manage Obsidian themes - list, install, set, and uninstall.
Service Overview
The Themes service provides endpoints to manage visual themes for your Obsidian interface, including listing available themes, installing community themes, and switching between themes.
Base URL
/api/platform/themes
/api/platform/themeEndpoints
GET /api/platform/themes
List all available themes (installed and community).
CLI Command: obsidian themes
Example Request:
curl "http://localhost:3000/api/platform/themes?vault=youtube"Example Response:
{
"success": true,
"data": {
"type": "list",
"data": [
"obsidian",
"atom",
"nord",
" Dracula"
]
}
}GET /api/platform/theme/current
Get the currently active theme.
CLI Command: obsidian theme
Example Request:
curl "http://localhost:3000/api/platform/theme/current?vault=youtube"Example Response:
{
"success": true,
"data": {
"type": "message",
"data": "obsidian"
}
}GET /api/platform/theme/:id
Get information about a specific theme.
CLI Command: obsidian theme
URL Parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | Yes | Theme identifier |
Example Request:
curl "http://localhost:3000/api/platform/theme/nord?vault=youtube"Example Request:
curl -X POST "http://localhost:3000/api/platform/theme/set?vault=youtube" \
-H "Content-Type: application/json" \
-d '{"id": "nord"}'Example Response:
{
"success": true,
"data": "Theme set to: nord"
}POST /api/platform/theme/install
Install a theme from the community store.
CLI Command: obsidian theme:install
Request Body:
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | Yes | Theme ID |
enable | boolean | No | Enable after install (default true) |
vault | string | No | Target vault name |
Example Request:
curl -X POST "http://localhost:3000/api/platform/theme/install?vault=youtube" \
-H "Content-Type: application/json" \
-d '{"id": "nord"}'Example Request:
curl -X DELETE "http://localhost:3000/api/platform/theme/nord?vault=youtube"# Switch to a theme temporarily for preview
curl -X POST "http://localhost:3000/api/platform/theme/set?vault=youtube" \
-H "Content-Type: application/json" \
-d '{"id": "dracula"}'
# Do your work...
# Switch back to default
curl -X POST "http://localhost:3000/api/platform/theme/set?vault=youtube" \
-H "Content-Type: application/json" \
-d '{"id": "obsidian"}'# One-step install with auto-enable
curl -X POST "http://localhost:3000/api/platform/theme/install?vault=youtube" \
-H "Content-Type: application/json" \
-d '{"id": "nord", "enable": true}'