Branding

Upload a branding image

POST/branding/images

Stores an image and sets the branding field purpose names, then returns the branding settings. Only a super admin can upload, else 403 missing_permission; a service identity cannot. dry_run validates the file and stores nothing. Emits branding.updated once, listing the changed group in changed_fields, not individual fields; no email. It cannot be undone through the API: a replaced or cleared image stays stored (as in the platform UI), and PATCH /branding with null clears the field.

Query parameters

  • dry_runboolean#

    Validate and run the call without committing it, returning what the real call would return with meta.dry_run set.

Headers

  • Idempotency-Keystring#

    Makes a retry safe. Send a new UUID for each new request and reuse it only to retry that request; the first response is replayed for 24 hours.

Request body

multipart/form-data, required

  • purposestringRequired#

    What the image is for: login_logo (login page logo), login_background (login page background), sign_up_logo (sign-up page logo), sign_up_background (sign-up page background), mobile_light_logo (mobile app logo on light backgrounds) or mobile_dark_logo (on dark backgrounds).

    One of: login_logo, login_background, sign_up_logo, sign_up_background, mobile_light_logo, mobile_dark_logo
  • filestring (binary)Required#

    The image, at most 10 MB.

Responses

201

The branding settings after the upload, with a Location of GET /branding. An image it replaces stays in storage.

Branding
{
  "data": {
    "access_pages": {
      "align": "LEFT",
      "password_visibility_enabled": true,
      "display_sign_up_link": true,
      "login_title": "string",
      "login_description": "string",
      "terms_and_conditions_title": "string",
      "terms_and_conditions": "string",
      "privacy_policy_title": "string",
      "privacy_policy": "string",
      "logo": "string",
      "background_image": "string",
      "mobile_light_logo": "string",
      "mobile_dark_logo": "string"
    },
    "sign_up_page": {
      "header": "string",
      "sub_header": "string",
      "find_out_label": "string",
      "find_out_placeholder": "string",
      "find_out_mandatory": true,
      "confirmation_header": "string",
      "confirmation_message": "string",
      "logo": "string",
      "background_image": "string",
      "display_phone_number": true
    }
  }
}
401

Authentication failed. error.code is one of invalid_token, expired, revoked.

Error
403

Authorization failed. error.code is one of org_disabled, ip_blocked, missing_scope, scope_disabled, user_disabled.

Error
422

The request can't be processed (HTTP 422): validation_failed with one ErrorDetail per problem, or a code documented on the operation.

Error
429

Rate limit exceeded (error.code = rate_limited).

Error

Examples

curl -X POST https://your-org-domain/kong/core/api/v2/branding/images\
  -H "Authorization: Bearer $HELM_API_KEY"\
  -H "Content-Type: application/json"