Configuration
Endpoints for reading and updating Grav configuration scopes including system, site, plugins, and themes.
Endpoints for reading and updating Grav configuration scopes including system, site, plugins, and themes.
List Config Sections
GET
/config
List available configuration scopes.
JSON
{"data": ["system", "site", "media", "security"]}
Response Codes
200
Success
401
Unauthorized
Get Config
GET
/config/{scope}
Get configuration values for a scope.
Parameters
| Name | Type | Description |
|---|---|---|
| scope required | string | Configuration scope: system, site, media, security, plugins/{name}, or themes/{name} |
JSON
{"data": {"title": "My Site", "author": {"name": "Admin"}}}
Response Codes
200
Success
401
Unauthorized
404
Scope not found
Update Config
PATCH
/config/{scope}
Update configuration values with deep merge.
Parameters
| Name | Type | Description |
|---|---|---|
| scope required | string | Configuration scope: system, site, media, security, plugins/{name}, or themes/{name} |
JSON
{"title": "Updated Site Title"}
Response Codes
200
Configuration updated
401
Unauthorized
404
Scope not found
409
Conflict (ETag mismatch)
422
Validation error
The request body is deep-merged into the existing configuration. Supports optimistic concurrency control via the If-Match header.