Skip to Content
APICampaignsClass: Campaign

Class: Campaign

A campaign shown by a totem screensaver. Its media items and weekly schedules drive the playlist; the SDK returns campaigns for a maps-group verbatim (it does NOT filter by status/date/schedule — the consumer decides which are active).

Constructors

Constructor

new Campaign(rawCampaign): Campaign;

Creates a campaign from API response data, applying the same normalization the backend uses: an unrecognized mediaType falls back to the MIME type and then to "image", endDate defaults to null, and order mirrors sortOrder.

Parameters

rawCampaign

CampaignResponse

API response data for a campaign.

Returns

Campaign

Properties

endDate

endDate: string | null

endTime

endTime: string | null

id?

optional id?: string;

images

images: CampaignImage[];

name?

optional name?: string;

order

order: number

Alias of sortOrder.


schedules

schedules: CampaignSchedule[];

sortOrder

sortOrder: number

Per-group playlist order of this campaign (0 = first).


startDate?

optional startDate?: string;

startTime?

optional startTime?: string;

status?

optional status?: string;
Last updated on