API referenceAmbient backgrounds

Ambient backgrounds

1 operation. Every schema and example on this page is generated from the platform contract.

Resolve a store's ambient background + app text theme.

Returns the DB-driven ambient background (video | image | colour, with poster + playback speed for video) and the app text colour for a store, resolved by priority store override > business_type default > global default. Backgrounds are swappable via the database, in bulk per business type or per individual merchant, with no app release. `version` is the client cache-bust token. No money, no PII.

Parameters

store_idstring · uuidqueryrequired

Store whose ambient background + text theme to resolve (also authorises the merchant).

Response, 200

kindenumrequired

Which kind of background to render. Determines which value field is populated.

videoimagecolor
videoUrlstring, nullablerequired

Looping video URL when kind=video, else null.

posterUrlstring, nullablerequired

Optional still poster for the video (Reduce-Motion / while-loading), else null.

imageUrlstring, nullablerequired

Static image URL when kind=image, else null.

hexColorstring, nullablerequired

Solid background colour (6-digit hex, leading #) when kind=color, else null.

playbackRatenumberrequired

Video playback speed multiplier (e.g. 0.5 = calm half-speed). Ignored for image/color.

textColorstring, nullablerequired

Back-compat: the resolved PRIMARY text colour (= textColors.primary; 6-digit hex, leading #), or null → the app uses its built-in ink. Kept until the multi-role client ships.

textColorsobjectrequired

DB-overridden app text theme, five independently-swappable semantic roles (business app is forced-light: one hex per role, no light/dark pair). Each role is resolved by priority store override > business_type default > global default, independently, and is null when no scope set it → the app uses its built-in ink for that role. Status colours (red/amber/green) are NOT here (semantic-locked in the app).

5 child fields
primarystring, nullablerequired

Primary body ink (6-digit hex, leading #), or null → app default.

secondarystring, nullablerequired

Secondary text ink, or null → app default.

mutedstring, nullablerequired

Muted / tertiary text ink, or null → app default.

titlestring, nullablerequired

Title / heading ink, or null → app default.

accentstring, nullablerequired

Accent text ink, or null → app default.

businessTypestring, nullablerequired

The canonical business type the store resolved to (e.g. coffee_shop), or null if unknown.

sourceenumrequired

Which scope won the background resolution, or null when no background config exists yet.

storebusiness_typeglobal
versionnumberrequired

Cache-bust token: epoch-ms of the newest of the resolved background / text-theme rows. Changes when either changes.

curl -G "https://www.membber.com/api/v1/ambient-background" \
  -H "Authorization: Bearer $MEMBBER_TOKEN" \
  --data-urlencode "store_id=6659c139-0000-4000-8000-d0c500000066"
Response, 200
{
  "kind": "video",
  "videoUrl": "https://example.com/image.jpg",
  "posterUrl": "https://example.com/image.jpg",
  "imageUrl": "https://example.com/image.jpg",
  "hexColor": "<hexColor>",
  "playbackRate": 1,
  "textColor": "<textColor>",
  "textColors": {
    "primary": "<primary>",
    "secondary": "<secondary>",
    "muted": "<muted>",
    "title": "Morning class",
    "accent": "<accent>"
  },
  "businessType": "<businessType>",
  "source": "store",
  "version": 1
}
WhatsApp
Book a Call
Start Free