Submit an event to be processed by Endu.

Request [POST]

All payloads should be sent as a JSON, with the appropriate content-type of application/json or similar.

The request object has a multitude of forms. The following base request contains keys shared by all variations; you should select one of the below variations based on available data at the time to be sent as a minimum requirement.

Variations are interchangeable, but the below set out the minimum formulation of property keys required to ingest an event successfully.

For example, to use a p_user_id property, you must include a property_type property.

This base event is insufficient to send as it is and requires more metadata.

{
    "property_id":"D#1007491775344160808", // Property ID
    "organization_id":"848WN4oEUgisKrV9dY9Ni6", // Organization ID
    "timestamp":"1672536219",  // Unix Time, in Seconds.
    "event_type":"ITEM_PURCHASED", // User-Defined.
    "event_data":{} // This data is provided by you. You should be consistent in scheme, but ultimately it is yours to populate.
}

Variation: Platform Identity

When should I use this?

You should use this when you know the User ID of the user on a specific platform. This will record the chosen event to be associated with the underlying identity we determine.

{
    "property_id":"D#1007491775344160808",
    "organization_id":"848WN4oEUgisKrV9dY9Ni6",
    "timestamp":"1672536219",
    "event_type":"ITEM_PURCHASED",
    "p_user_id": "702877938567086080", // Platform User ID
    "platform_type": "Discord", // Platform - One of: Discord, Telegram
    "event_data":{
        "item_id": "8258727671",
    }
}

Variation: Unique Identity

When should I use this?

You should use this when you know the Chatsight-Assigned Unique Identity ID (c_user_id).

{
    "property_id":"D#1007491775344160808",
    "organization_id":"848WN4oEUgisKrV9dY9Ni6",
    "timestamp":"1672536219",
    "event_type":"ITEM_PURCHASED",
    "c_user_id": "59078598125872925",
    "event_data":{
        "item_id": "8258727671",
    }
}

Variation: Blockchain

When should I use this?

You should use this when you know the wallet address/account and the type of blockchain (Ethereum, Solana, or otherwise).

{
    "property_id":"D#1007491775344160808",
    "organization_id":"848WN4oEUgisKrV9dY9Ni6",
    "timestamp":"1672536219",
    "event_type":"ITEM_PURCHASED",
    "blockchain":{
        "chain_type": "solana",
        "chain_account": "0x0"
    },
    "event_data":{
        "item_id":"8258727671"
    }
}

Variation: Fingerprint

When should I use this?

When using our JS Agent, we use Fingerprint to help associate users from the cold before you may have them use Flow or Link-Tracking. This allows us to retain events for future reconciliation before a unique identifier is assigned to them.

In the future, Endu will be able to take over this responsibility - and will be interchangeable with existing events ingested with this variation.

{
    "property_id":"D#1007491775344160808",
    "organization_id":"848WN4oEUgisKrV9dY9Ni6",
    "timestamp":"1672536219",
    "event_type":"PAGE_VIEW",
    "fingerprint":"xuauwiaufjwaj",
    "event_data":{
        "item_id":"8258727671"
    }
}

Mutation: Combined Platform and Blockchain

When can I use this?

This mutation is an example of combining two variations to improve (and speed up) the resolution of user identities. Any mutation similar to this is supported; this example demonstrates one such combination.

You can use this example (and many others) when you know the Blockchain address/account, type, AND the user ID on the platform specified.

{
    "property_id":"D#1007491775344160808",
    "organization_id":"848WN4oEUgisKrV9dY9Ni6",
    "timestamp":"1672536219",
    "event_type":"ITEM_PURCHASED",
    "p_user_id": "702877938567086080",
    "platform_type": "Discord",
    "blockchain":{
        "chain_type": "solana",
        "chain_account": "0x0"
    },
    "event_data":{
        "item_id":"8258727671"
    }
}

Response

All responses are empty HTTP 200 Status Code responses.