Event contract
{
"id": "cfb0237f-1519-4c09-a0f9-9534c9f69df0",
"key_field": "SessionId",
"metadata": {
"create_time": "2022-05-31T14:22:13Z"
},
"pii_fields": {
"SessionId": 1,
"UserName": 2,
"url": 0
},
"ref": {
"handle": "strm-demo",
"name": "demo-fahad",
"version": "1.0.0"
},
"schema_ref": {
"handle": "strm-demo",
"name": "demo-fahad",
"version": "1.0.0"
},
"state": "DRAFT"
}
Serialization schema
{
"type": "record",
"name": "Clicks",
"namespace": "StrmDemo.DemoFahad.v1_0_0",
"fields": [
{
"name": "strmMeta",
"type": {
"type": "record",
"name": "strmMeta",
"namespace": "StrmDemo.DemoFahad.v1_0_0.strmmeta",
"fields": [
{
"name": "eventContractRef",
"type": "string"
},
{
"name": "nonce",
"type": [
"null",
"int"
],
"default": null
},
{
"name": "timestamp",
"type": [
"null",
"long"
],
"default": null
},
{
"name": "keyLink",
"type": [
"null",
"string"
],
"default": null
},
{
"name": "billingId",
"type": [
"null",
"string"
],
"default": null
},
{
"name": "consentLevels",
"type": {
"type": "array",
"items": "int"
}
}
]
}
},
{
"name": "SessionId",
"type": "string",
"doc": "the string value that connects events to a single sequence"
},
{
"name": "UserName",
"type": [
"null",
"string"
],
"doc": "we use an event contract to define that this is private",
"default": null
},
{
"name": "url",
"type": [
"null",
"string"
],
"doc": "the URL of the current page",
"default": null
},
{
"name": "MousePositions",
"type": {
"type": "array",
"items": [
"null",
{
"type": "record",
"name": "MousePositions",
"namespace": "StrmDemo.DemoFahad.v1_0_0.mousepositions",
"fields": [
{
"name": "x",
"type": [
"null",
"int"
],
"default": null
},
{
"name": "y",
"type": [
"null",
"int"
],
"default": null
}
]
}
]
}
}
]
}