Skip to content

Read public-mode settings

GET
/admin/system/public-mode

Returns the saved public-mode setting.

You need system.config.read or system.admin for the whole install; a permission held only for a team doesn’t count. Without one you get 403, and signed-out callers get 401. Public mode is off until a setting is saved. This endpoint reads the database directly, while the access middleware keeps its own cache, so the middleware can be acting on a different value from the one returned here.

When the middleware sees public mode as off, requests with no valid identity get 401 on the governed paths: assets, collections, the public user-profile paths, the post feed and post-by-asset lookup, featured content, search, IIIF, previews and browse layouts. When it’s on, those requests reach their handlers, and each handler still decides what the caller can access. Turning public mode on doesn’t grant access to every item or remove a handler’s own sign-in requirement.

Not every anonymous endpoint is covered: sign-in, setup, appearance and build information sit outside this switch. Requests with a valid bearer token or session cookie skip the public-mode check either way. The bearer token is tried first, and if it fails, a valid session cookie can still identify the caller.

The saved public-mode setting.

The instance setting that decides whether anonymous requests are admitted to the governed public paths. It’s separate from each handler’s own access rules.

object
enabled
required

True lets requests with no valid identity reach the handlers on the governed public paths. False asks the middleware to refuse them with 401, and is the default until a setting is saved. Requests with a valid identity skip this check. The middleware caches the value, so the saved value isn’t necessarily the one it’s using right now. Other anonymous endpoints keep their own access rules.

boolean

Authentication required, missing, or invalid

object
error
required

Human-readable error summary

string
Example
the request could not be completed
Example
{
"error": "authentication required: sign in and retry with a valid session or API token"
}

Authenticated but missing required capabilities

object
error
required

Human-readable error summary

string
Example
the request could not be completed