Hi @raghavn,
For standard events like page views, or any of the javascript tracker’s built-in events/contexts, you don’t need schemas at all.
For custom events, or custom contexts, you do need them.
Iglu is used to host schemas, if you want to use custom events or contexts, you’ll need to set up an Iglu server and connect it to your Enrich component.
Assuming you’ve done that, you’ll need to create a schema to match your custom event or context, and upload it to Iglu for testing. Here’s a guide to doing that, and here’s a guide to self-describing JSON, which is the format of the schema. I would recommend using Snowplow Mini to test your schemas and tracking.
Once you have uploaded your schema, you can then track your custom events as described in the documentation - reference the path to your custom schema for that event, and the data that you’d like to send against that schema. Same format for attaching custom contexts to events.
To give you direct answers to your questions:
- Which iglu schema name do I need to give in the Javascript tracker? Not sure whether the below given schema is correct or not. I just copied from some webpage. iglu:com.snowplowanalytics.snowplow/event_fingerprint_config/jsonschema/1-0-0
You don’t need to give any schema name in the javascript tracker unless you’re referencing one you’ve created yourself via the above process. The event_fingerprint_config schema is a definition for a config file in enrichment, it doesn’t apply to this.
- What about using multiple iglu schemas?
For custom events, you reference one schema per-event each event can only point to one schema. For custom contexts, you reference a list of schemas - one per context. You can attach as many contexts as you like to your events. You can attach custom contexts to any event.
- Handling Unstructured events
Unstructured events are what I refer to as custom events - in the documentation you’ll sometimes see them referred to as Self-describing events. It’s a bit confusing I know - technically they’re ‘Custom Self-Describing events’. It’s quite the mouthful.