Skip to content

Subscribe to interventions

GET
/edgekit/v1/decide/interventions
curl --request GET \
--url 'https://your-tenant-host/edgekit/v1/decide/interventions?domain_userid=7d3f2a1c-5b8e-4f60-9c2d-1e4a6b8c0f37'

Server-sent events for Snowplow’s signals browser plugin, at /edgekit/v1/decide/interventions only. EventSource holds no key and sets no header, so the site comes from the Host, or from x-edgekit-site-id when present. The site proxy sends that header, because behind the proxy the Host is the tenant’s. The stream opens before anything is verified; a failure closes it and the client reconnects (retry: 15–25 s, jittered per stream). Rate limited as POST /edgekit/v1/decide.

domain_userid

Snowplow’s device id; the socket is addressed by it.

string

Example

7d3f2a1c-5b8e-4f60-9c2d-1e4a6b8c0f37

Snowplow’s device id; the socket is addressed by it.

user_id

Snowplow’s user attribute key. Its value is ignored: the user comes from the signed access cookie. One of the two keys is required (400).

string

Snowplow’s user attribute key. Its value is ignored: the user comes from the signed access cookie. One of the two keys is required (400).

An open stream. Each unnamed message event’s data is one JSON intervention in the plugin’s own shape — intervention_id, name, version, target_attribute_key: { name, id }, attributes (always {}); : ping comments keep it alive.

Media typetext/event-stream
string

Example

data: {"intervention_id":"…","name":"trial_banner","version":1,"target_attribute_key":{"name":"domain_userid","id":"…"},"attributes":{}}

Invalid request.

Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
details

Example

{
"error": {
"code": "unauthorized",
"message": "Invalid or missing API key."
}
}

Request validation failed.

Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
details

Example

{
"error": {
"code": "unauthorized",
"message": "Invalid or missing API key."
}
}

Too many requests. Retry-After says when to retry.

Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
details

Example

{
"error": {
"code": "unauthorized",
"message": "Invalid or missing API key."
}
}

Unexpected error.

Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
details

Example

{
"error": {
"code": "unauthorized",
"message": "Invalid or missing API key."
}
}

With Retry-After, briefly unavailable; without it, not configured.

Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
details

Example

{
"error": {
"code": "unauthorized",
"message": "Invalid or missing API key."
}
}