TraceItXConfig(
appId = "txx_app_…",
sdkKey = "txx_live_…",
theme = ReporterThemeOptions(
accent = "#3b82f6",
accentForeground = "#ffffff",
surface = "#0b0f14",
),
)
The eight roles
| Role | Paints |
|---|---|
background | The reporter surface behind everything. |
surface | Cards, fields and raised areas. |
border | Hairlines between them. |
text | Primary copy. |
textMuted | Secondary copy, hints, counters. |
accent | Buttons, focus rings, the active tool. |
accentForeground | Text ON the accent — set it whenever you set accent. |
destructive | Delete and discard actions. |
Values are #rrggbb strings, not @color resources or Color values. A string
crosses the config boundary unambiguously and serialises into the server-side
theme as the same value — a resource id would have to be resolved against a
configuration, and the reporter’s is not necessarily your Activity’s.
Notably it does not follow Material You. Dynamic colour would make the
reporter change appearance per device, which is the opposite of the point —
TraceItXConfig.useDynamicColor exists but is not read.
A value that is not a valid #rrggbb string is ignored for that field only.
Plan gating
Theming applies only once the server confirms a paid plan. On a free plan
GET /api/config returns { "watermark": true }, the theme is suppressed, and
the reporter renders in default colours with a TraceItX mark.
That is a 200, not an error. An inline theme on a free plan is silently
ignored rather than failing your build — so upgrading a plan themes the reporter
with no code change and no Play release.
Precedence
Per field, highest wins:
- Server theme — set in the dashboard, applies to every client
- Inline
theme— this config object - Default
Per field, not per object: setting only accent in the dashboard and only
surface here gives you both. On Android that split earns its keep — the
dashboard can change brand colour without a staged rollout.
Defaults and derived colours
The default reporter is dark, and it does not follow the system night mode.
Roles you leave unset are derived from the ones you set: background and text
anchor the hairlines and muted text, surface falls back to a lightened
background. So a light background without a text value gives you light
default text on a light surface — set text whenever you set background or
surface.