projects
PATCH
https://lucidace.com /v1/projects/{project_id}/settings/sdk Scope admin`PATCH` is the same merge as `PUT` (both take only the keys to change).
Parameters
project_idstringpathrequiredRequest body
application/json
Remote SDK configuration. Every field is optional on write: present keys replace, absent keys are left as they are.
article_selectorstringCSS selector of the article region for read-through metrics (N-DXA-6); pages can also mark it with
data-lc-region="article".autocapturebooleanautocapture_inputsbooleanfalse stops autocapture of input, change and submit events; clicks are still captured. Default true.consent_bannerConsentBannerShow child parameters
accept_labelstringrequiredbodystringrequiredcategoriesConsentCategory[]Show child parameters
descriptionstringidstringrequiredlabelstringrequiredrequiredbooleanRequired categories cannot be declined (e.g. strictly necessary).
customize_labelstringdecline_labelstringrequiredpositionstringrequiredbottom | top | center | bottom_left | bottom_righttitlestringrequiredconsent_geo_rulesarrayGeo consent defaults (N-ANA-17): per country / US state, the mode a visitor starts in.
consent_modestringoff | opt_in | opt_outcookieless_modebooleanflag_targeting_sourcesFlagTargetingSourcesShow child parameters
cookiesstring[]data_layerstring[]globalsstring[]heatmap_url_allowlistarrayURL patterns (substring,
* wildcard) whose pages produce heatmap data; empty = every page. The worker drops points from other pages.heatmapsbooleanmask_all_inputsbooleanreplay_block_selectorsarrayCSS selectors whose subtree is blocked in replays (on top of
[data-lc-block]).replay_capture_canvasbooleanRecords canvas/WebGL content with default fps and quality (refused under the masking floor).
replay_exposure_fieldsarrayNative ids of mobile fields captured encrypted for audited reveal (P-L12).
replay_mask_all_textbooleanMask every text node and text attribute in replays except under the site's own unmask allow-list (
[data-lc-unmask], local unmask_selectors). true forces it on in the SDK.replay_mask_screensarrayMobile screen names (
* wildcard, case-insensitive) whose replays mask all text, inputs and images (P-M17).replay_mask_selectorsarrayCSS selectors whose text is masked in replays (on top of
[data-lc-mask]).replay_mask_text_patternsarrayRegexes masked in replay text on device (mobile) and again by the worker (P-M46).
replay_min_duration_modestringbuffer (strict: this page's recorded data) or session (session age).replay_min_duration_msintegerSessions shorter than this (ms, at most 600000) are never sent.
replay_never_recordarrayURL patterns: a session that starts on one of these pages is never recorded.
replay_retentionstringHow long recordings are kept:
30d (default), 90d, 1y or 5y; the worker reads it per session.replay_sample_ratenumber0 to 1.
replay_trigger_groupsarrayRecording rules: which sessions are recorded (URL / event / flag conditions, per-group sampling and minimum duration).
replay_url_blocklistarrayURL patterns (substring,
* wildcard) whose pages are not recorded; the worker drops them too.replay_url_privacy_rulesarrayPage-scoped replay masking (P-M16): extra masking on pages matching each rule's URL pattern.
respect_gpcbooleanTreat the browser's Global Privacy Control signal (
navigator.globalPrivacyControl) as an analytics opt-out. Unset = true when consent_mode is opt_in, else false.session_idle_minutesintegerSession definition (N-ANA-6): minutes without an event before a new session (1 to 1440, default 30).
session_max_minutesintegerLongest session in minutes (5 to 10080, default 1440).
session_new_on_eventsarrayEvent names that always start a new session (at most 20), e.g.
login.session_recordingbooleansnapshot_propertiesarrayNo-code snapshot properties (P-M15): page text or an attribute attached to clicks and pageviews.
{
"article_selector": "string",
"autocapture": true,
"autocapture_inputs": true,
"consent_banner": {
"accept_label": "string",
"body": "string",
"categories": [
{
"description": "string",
"id": "string",
"label": "string",
"required": true
}
],
"customize_label": "string",
"decline_label": "string",
"position": "string",
"title": "string"
},
"consent_geo_rules": [
{
"country": "string",
"mode": "string",
"region": "string"
}
],
"consent_mode": "string",
"cookieless_mode": true,
"flag_targeting_sources": {
"cookies": [
"string"
],
"data_layer": [
"string"
],
"globals": [
"string"
]
},
"heatmap_url_allowlist": [
"string"
],
"heatmaps": true,
"mask_all_inputs": true,
"replay_block_selectors": [
"string"
],
"replay_capture_canvas": true,
"replay_exposure_fields": [
"string"
],
"replay_mask_all_text": true,
"replay_mask_screens": [
"string"
],
"replay_mask_selectors": [
"string"
],
"replay_mask_text_patterns": [
"string"
],
"replay_min_duration_mode": "string",
"replay_min_duration_ms": 0,
"replay_never_record": [
"string"
],
"replay_retention": "string",
"replay_sample_rate": 0,
"replay_trigger_groups": [
{
"event_filters": [
{
"event": "string",
"properties": [
{
"key": "string",
"op": "string",
"value": {}
}
]
}
],
"events": [
"string"
],
"flag": {
"key": "string",
"variant": "string"
},
"id": "string",
"match": "string",
"min_duration_ms": 0,
"name": "string",
"sample_rate": 0,
"url_patterns": [
"string"
]
}
],
"replay_url_blocklist": [
"string"
],
"replay_url_privacy_rules": [
{
"block_selectors": [
"string"
],
"mask_all_text": true,
"mask_selectors": [
"string"
],
"url": "string"
}
],
"respect_gpc": true,
"session_idle_minutes": 0,
"session_max_minutes": 0,
"session_new_on_events": [
"string"
],
"session_recording": true,
"snapshot_properties": [
{
"attribute": "string",
"events": [
"string"
],
"name": "string",
"scope": "string",
"selector": "string",
"source": "string",
"url": "string"
}
]
}Code samples
cURL
curl -X PATCH "https://lucidace.com/v1/projects/{project_id}/settings/sdk" \
-H "Content-Type: application/json" \
-d '{"article_selector":"string","autocapture":true,"autocapture_inputs":true,"consent_banner":{"accept_label":"string","body":"string","categories":[{"description":"string","id":"string","label":"string","required":true}],"customize_label":"string","decline_label":"string","position":"string","title":"string"},"consent_geo_rules":[{"country":"string","mode":"string","region":"string"}],"consent_mode":"string","cookieless_mode":true,"flag_targeting_sources":{"cookies":["string"],"data_layer":["string"],"globals":["string"]},"heatmap_url_allowlist":["string"],"heatmaps":true,"mask_all_inputs":true,"replay_block_selectors":["string"],"replay_capture_canvas":true,"replay_exposure_fields":["string"],"replay_mask_all_text":true,"replay_mask_screens":["string"],"replay_mask_selectors":["string"],"replay_mask_text_patterns":["string"],"replay_min_duration_mode":"string","replay_min_duration_ms":0,"replay_never_record":["string"],"replay_retention":"string","replay_sample_rate":0,"replay_trigger_groups":[{"event_filters":[{"event":"string","properties":[{"key":"string","op":"string","value":{}}]}],"events":["string"],"flag":{"key":"string","variant":"string"},"id":"string","match":"string","min_duration_ms":0,"name":"string","sample_rate":0,"url_patterns":["string"]}],"replay_url_blocklist":["string"],"replay_url_privacy_rules":[{"block_selectors":["string"],"mask_all_text":true,"mask_selectors":["string"],"url":"string"}],"respect_gpc":true,"session_idle_minutes":0,"session_max_minutes":0,"session_new_on_events":["string"],"session_recording":true,"snapshot_properties":[{"attribute":"string","events":["string"],"name":"string","scope":"string","selector":"string","source":"string","url":"string"}]}'TypeScript
Python
Go
PHP
Ruby
Java
Responses
200 the merged settings
Example
{
"article_selector": "string",
"autocapture": true,
"autocapture_inputs": true,
"consent_banner": {
"accept_label": "string",
"body": "string",
"categories": [
{
"description": "string",
"id": "string",
"label": "string",
"required": true
}
],
"customize_label": "string",
"decline_label": "string",
"position": "string",
"title": "string"
},
"consent_geo_rules": [
{
"country": "string",
"mode": "string",
"region": "string"
}
],
"consent_mode": "string",
"cookieless_mode": true,
"flag_targeting_sources": {
"cookies": [
"string"
],
"data_layer": [
"string"
],
"globals": [
"string"
]
},
"heatmap_url_allowlist": [
"string"
],
"heatmaps": true,
"mask_all_inputs": true,
"replay_block_selectors": [
"string"
],
"replay_capture_canvas": true,
"replay_exposure_fields": [
"string"
],
"replay_mask_all_text": true,
"replay_mask_screens": [
"string"
],
"replay_mask_selectors": [
"string"
],
"replay_mask_text_patterns": [
"string"
],
"replay_min_duration_mode": "string",
"replay_min_duration_ms": 0,
"replay_never_record": [
"string"
],
"replay_retention": "string",
"replay_sample_rate": 0,
"replay_trigger_groups": [
{
"event_filters": [
{
"event": "string",
"properties": [
{
"key": "string",
"op": "string",
"value": {}
}
]
}
],
"events": [
"string"
],
"flag": {
"key": "string",
"variant": "string"
},
"id": "string",
"match": "string",
"min_duration_ms": 0,
"name": "string",
"sample_rate": 0,
"url_patterns": [
"string"
]
}
],
"replay_url_blocklist": [
"string"
],
"replay_url_privacy_rules": [
{
"block_selectors": [
"string"
],
"mask_all_text": true,
"mask_selectors": [
"string"
],
"url": "string"
}
],
"respect_gpc": true,
"session_idle_minutes": 0,
"session_max_minutes": 0,
"session_new_on_events": [
"string"
],
"session_recording": true,
"snapshot_properties": [
{
"attribute": "string",
"events": [
"string"
],
"name": "string",
"scope": "string",
"selector": "string",
"source": "string",
"url": "string"
}
]
}Schema
article_selectorstringCSS selector of the article region for read-through metrics (N-DXA-6); pages can also mark it with
data-lc-region="article".autocapturebooleanautocapture_inputsbooleanfalse stops autocapture of input, change and submit events; clicks are still captured. Default true.consent_bannerConsentBannerShow child parameters
accept_labelstringrequiredbodystringrequiredcategoriesConsentCategory[]Show child parameters
descriptionstringidstringrequiredlabelstringrequiredrequiredbooleanRequired categories cannot be declined (e.g. strictly necessary).
customize_labelstringdecline_labelstringrequiredpositionstringrequiredbottom | top | center | bottom_left | bottom_righttitlestringrequiredconsent_geo_rulesarrayGeo consent defaults (N-ANA-17): per country / US state, the mode a visitor starts in.
consent_modestringoff | opt_in | opt_outcookieless_modebooleanflag_targeting_sourcesFlagTargetingSourcesShow child parameters
cookiesstring[]data_layerstring[]globalsstring[]heatmap_url_allowlistarrayURL patterns (substring,
* wildcard) whose pages produce heatmap data; empty = every page. The worker drops points from other pages.heatmapsbooleanmask_all_inputsbooleanreplay_block_selectorsarrayCSS selectors whose subtree is blocked in replays (on top of
[data-lc-block]).replay_capture_canvasbooleanRecords canvas/WebGL content with default fps and quality (refused under the masking floor).
replay_exposure_fieldsarrayNative ids of mobile fields captured encrypted for audited reveal (P-L12).
replay_mask_all_textbooleanMask every text node and text attribute in replays except under the site's own unmask allow-list (
[data-lc-unmask], local unmask_selectors). true forces it on in the SDK.replay_mask_screensarrayMobile screen names (
* wildcard, case-insensitive) whose replays mask all text, inputs and images (P-M17).replay_mask_selectorsarrayCSS selectors whose text is masked in replays (on top of
[data-lc-mask]).replay_mask_text_patternsarrayRegexes masked in replay text on device (mobile) and again by the worker (P-M46).
replay_min_duration_modestringbuffer (strict: this page's recorded data) or session (session age).replay_min_duration_msintegerSessions shorter than this (ms, at most 600000) are never sent.
replay_never_recordarrayURL patterns: a session that starts on one of these pages is never recorded.
replay_retentionstringHow long recordings are kept:
30d (default), 90d, 1y or 5y; the worker reads it per session.replay_sample_ratenumber0 to 1.
replay_trigger_groupsarrayRecording rules: which sessions are recorded (URL / event / flag conditions, per-group sampling and minimum duration).
replay_url_blocklistarrayURL patterns (substring,
* wildcard) whose pages are not recorded; the worker drops them too.replay_url_privacy_rulesarrayPage-scoped replay masking (P-M16): extra masking on pages matching each rule's URL pattern.
respect_gpcbooleanTreat the browser's Global Privacy Control signal (
navigator.globalPrivacyControl) as an analytics opt-out. Unset = true when consent_mode is opt_in, else false.session_idle_minutesintegerSession definition (N-ANA-6): minutes without an event before a new session (1 to 1440, default 30).
session_max_minutesintegerLongest session in minutes (5 to 10080, default 1440).
session_new_on_eventsarrayEvent names that always start a new session (at most 20), e.g.
login.session_recordingbooleansnapshot_propertiesarrayNo-code snapshot properties (P-M15): page text or an attribute attached to clicks and pageviews.
400
403
404
GET
https://lucidace.com /v1/projects/{project_id}/snapshot-properties Scope action:readParameters
project_idstringpathrequiredCode samples
cURL
curl -X GET "https://lucidace.com/v1/projects/{project_id}/snapshot-properties"TypeScript
Python
Go
PHP
Ruby
Java
Responses
200
Example
{
"data": [
{
"attribute": "string",
"events": [
"string"
],
"name": "string",
"scope": "string",
"selector": "string",
"source": "string",
"url": "string"
}
]
}Schema
dataSnapshotRule[]requiredShow child parameters
attributestringWith
source = attribute: the attribute to read.eventsstring[]requiredclick and/or pageview.namestringrequiredEvent property name (no
$ prefix), unique per project.scopestringpage (first match in the document, default) or target (closest match around the clicked element).selectorstringrequiredCSS selector (tag, #id, .class, [attr], [attr=value], descendant combinator).
sourcestringrequiredtext (visible text, whitespace collapsed, at most 255 characters) or attribute.urlstringOnly on pages matching this URL pattern (substring,
* wildcard, re: regex).404
POST
https://lucidace.com /v1/projects/{project_id}/snapshot-properties Scope action:writeAdd a rule, or replace the rule with the same name (case-insensitive). Members and up; the toolbar calls it with an `actions:write` token.
Parameters
project_idstringpathrequiredRequest body
application/json
One snapshot property.
attributestringWith
source = attribute: the attribute to read.eventsstring[]requiredclick and/or pageview.namestringrequiredEvent property name (no
$ prefix), unique per project.scopestringpage (first match in the document, default) or target (closest match around the clicked element).selectorstringrequiredCSS selector (tag, #id, .class, [attr], [attr=value], descendant combinator).
sourcestringrequiredtext (visible text, whitespace collapsed, at most 255 characters) or attribute.urlstringOnly on pages matching this URL pattern (substring,
* wildcard, re: regex).{
"attribute": "string",
"events": [
"string"
],
"name": "string",
"scope": "string",
"selector": "string",
"source": "string",
"url": "string"
}Code samples
cURL
curl -X POST "https://lucidace.com/v1/projects/{project_id}/snapshot-properties" \
-H "Content-Type: application/json" \
-d '{"attribute":"string","events":["string"],"name":"string","scope":"string","selector":"string","source":"string","url":"string"}'TypeScript
Python
Go
PHP
Ruby
Java
Responses
400
403
404
409
DELETE
https://lucidace.com /v1/projects/{project_id}/snapshot-properties/{name} Scope action:writeParameters
project_idstringpathrequirednamestringpathrequiredCode samples
cURL
curl -X DELETE "https://lucidace.com/v1/projects/{project_id}/snapshot-properties/{name}"TypeScript
Python
Go
PHP
Ruby
Java
Responses
204
403
404
Updated