Hello, Sorry for the late reply, my email client was not properly configured and I missed these.
The EventCollector endpoint is designed to be used after a session and profile has been created. Currently it does not create them. So the sequence should be: - /context.json first - /eventcollector after Or you could just always call the context.json that also accepts events. I think this is missing in the documentation and should be added. Regards, Serge... Serge Huber CTO & Co-Founder T +41 22 361 3424 9 route des Jeunes | 1227 Acacias | Switzerland jahia.com <http://www.jahia.com/> SKYPE | LINKEDIN <https://www.linkedin.com/in/sergehuber> | TWITTER <https://twitter.com/sergehuber> | VCARD <http://www.jahia.com/vcard/HuberSerge.vcf> > JOIN OUR COMMUNITY <http://www.jahia.com/> to evaluate, get trained and to discover why Jahia is a leading User Experience Platform (UXP) for Digital Transformation. On Wed, Feb 5, 2020 at 4:17 PM Gilad Weinbach <gweinb...@yotpo.com> wrote: > hi, > after starting unomi server for the first time and create merge and copy > rule. > I'm sending 2 events to http://{{UNOMI_URL}}/eventcollector . > they are attached to anonymous profile and the session is not persisted > > code sample for the event sending > POST http://{{UNOMI_URL}}/eventcollector > { > "sessionId" : "a1", > "events":[ > { > "eventType":"orderCreated", > "scope": "store1", > "properties" : { > "email" : "a...@email.com", > "store_id": "store1", > "key": "store1#a...@mail.com", > "value": 100, > "currency": "USD" > } > } > ] > } > > merge rules: > > { > "metadata": { > "id": "mergeProfile", > "name": "merge", > "description": "merge" > }, > "condition": { > "type": "booleanCondition", > "parameterValues": { > "subConditions": [ > { > "type": "eventTypeCondition", > "parameterValues": { > "eventTypeId": "orderCreated" > } > }, > { > "type": "eventTypeCondition", > "parameterValues": { > "eventTypeId": "reviewCreated" > } > } > ], > "operator": "or" > } > }, > "actions": [ > { > "parameterValues": { > "mergeProfilePropertyValue": "eventProperty::properties(key)", > "mergeProfilePropertyName": "mergeIdentifier" > }, > "type": "mergeProfilesOnPropertyAction" > } > ] > } > > profile result: > > { > "itemId": "temp_95277704-a0eb-46df-9de3-37bb900cc799", > "itemType": "profile", > "version": 5, > "properties": { > "firstVisit": "2020-02-05T07:13:52Z", > "email": "a...@mail.com" > }, > "systemProperties": { > "mergeIdentifier": "a...@mail.com" > }, > "segments": [], > "scores": {}, > "mergedWith": null, > "consents": {} > } > > >