Settings API
API Reference
Requires Bearer token + settings permission.
Return the full site settings object from config/site.json.
// Response 200
{ "siteName": "My Site", "adminTheme": "charcoal-dark", "smtp": { ... }, ... }Requires Bearer token + settings permission.
Replace the site settings object. Send the full merged object — partial updates overwrite the entire config.
// Request body — full site settings object
{ "siteName": "My Site", "adminTheme": "ocean-dark", ... }
// Response 200
{ "success": true }
Requires Bearer token + settings permission.
Send a test email using the stored SMTP configuration.
| Field | Type | Description |
|---|---|---|
to |
string | Optional. Recipient address. Defaults to the configured From Address. |
// Response 200
{ "success": true, "message": "Test email sent to alice@example.com" }
// Error 400
{ "error": "SMTP is not configured. Save your SMTP settings first." }
Requires Bearer token + settings permission.
Return the current custom CSS from content/custom.css.
// Response 200
{ "css": "body { font-family: sans-serif; }" }Requires Bearer token + settings permission.
Write CSS to content/custom.css. Maximum size is 100 KB.
| Field | Type | Description |
|---|---|---|
css |
string | CSS string (max 100 KB) |
// Response 200
{ "success": true }