Apply a theme for the current user's session
POST
/api/v1/themes/{name}/apply
const url = 'http://localhost:11044/api/v1/themes/example/apply';const options = {method: 'POST', headers: {'X-Embabel-Api-Key': '<X-Embabel-Api-Key>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url http://localhost:11044/api/v1/themes/example/apply \ --header 'X-Embabel-Api-Key: <X-Embabel-Api-Key>'Sets the theme on the in-memory user; the choice is not persisted across restarts by this endpoint.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”name
required
string
Theme name, as name in GET /themes (case-sensitive); 404 when no theme has this name
Responses
Section titled “Responses”Theme applied
Media type*/*
A theme switch that took effect for the current session
object
displayName
required
The theme’s name for display
string
status
required
Always “applied”: the only outcome this body reports, since an unknown theme answers 404 with no body
string
theme
required
The name of the theme now active, as the theme list and the stylesheet path spell it
string
Unknown theme

