Skip to content
Niu DocsNiu 牛元文档
Dashboard控制台

Read public branding and theme defaults

Generated from the checked-in source. Do not edit this reference by hand.

GET /v1/branding

Public safe projection only; no authentication required. Returns display name, normalized logo/favicon PNG data URLs, default appearance and light/dark token maps; excludes actors, credentials and commercial settings. When no saved configuration exists, returns revision string 0 and Niu defaults. Theme fields are part of settings; there is no separate theme endpoint.

Operation: getPublicBranding.

No OpenAPI security scheme is required. Other request validation still applies.

JSON
[]

Set NIU_ORIGIN to your installation origin (without /v1). Replace path, query and header placeholders with the required values. Query examples use curl 7.87 or newer to encode values with --url-query. Use the credential scope described above; a bearer token must have the authority required by this operation.

Shell
curl --fail-with-body -X GET "$NIU_ORIGIN/v1/branding"

No path, query, or header parameters are declared.

No request body is declared.

Branding revision and settings in data.

Content type: application/json.

JSON
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"type": "object",
"required": [
"revision",
"settings"
],
"properties": {
"revision": {
"type": "string",
"pattern": "^(0|[1-9][0-9]*)$"
},
"settings": {
"type": "object",
"additionalProperties": false,
"required": [
"display_name",
"default_appearance",
"light",
"dark"
],
"properties": {
"display_name": {
"type": "string",
"minLength": 1,
"maxLength": 80,
"description": "Trimmed nonempty text without control characters"
},
"default_appearance": {
"type": "string",
"enum": [
"system",
"light",
"dark"
]
},
"logo_data_url": {
"type": [
"string",
"null"
],
"maxLength": 349550,
"pattern": "^data:image/png;base64,[A-Za-z0-9+/=]+$",
"description": "Static PNG up to 256 KiB, at most 1024 by 512 pixels. Re-encoded from decoded pixels before saving. Missing or null resets to default."
},
"favicon_data_url": {
"type": [
"string",
"null"
],
"maxLength": 43714,
"pattern": "^data:image/png;base64,[A-Za-z0-9+/=]+$",
"description": "Square static PNG up to 32 KiB, at most 256 by 256 pixels. Missing or null resets to default."
},
"light": {
"type": "object",
"maxProperties": 8,
"propertyNames": {
"enum": [
"background",
"foreground",
"primary",
"primary-foreground",
"sidebar",
"sidebar-foreground",
"accent",
"accent-foreground"
]
},
"additionalProperties": {
"type": "string",
"pattern": "^#[0-9a-fA-F]{6}$"
}
},
"dark": {
"type": "object",
"maxProperties": 8,
"propertyNames": {
"enum": [
"background",
"foreground",
"primary",
"primary-foreground",
"sidebar",
"sidebar-foreground",
"accent",
"accent-foreground"
]
},
"additionalProperties": {
"type": "string",
"pattern": "^#[0-9a-fA-F]{6}$"
}
}
}
}
}
}
}
}

Durable storage unavailable.

Public safe projection only; no authentication required. Returns display name, normalized logo/favicon PNG data URLs, default appearance and light/dark token maps; excludes actors, credentials and commercial settings. When no saved configuration exists, returns revision string 0 and Niu defaults. Theme fields are part of settings; there is no separate theme endpoint.

Supported scope: implemented