API Reference

Overview

If you do not want to perform the mapping mentioned here, you can use the autoMapping flag with the request. If you use this flag, you must use the structures provided below for your request body.

📖

Note:

Please note that sessionid and userid must be included in all requests except for users events. For user events, you must only include userid.

📖

Note - 2:

Please also note that all other values, apart from sessionid and userid, are optional. Therefore, you do not have to send all values. As a result, you should be careful about which values you include. We recommend you to use eventtime for all events' time.

Endpoint

POST /api/EventRouter?apikey=<your_apikey>

Example Requests

Sessions

Session start is starttime. Session endtime is endtime. You can send sessions event separately for starttime and endtime. In this case, you must send the same sessionid for both event.

Example Request Body

{
  "entityName": "sessions",
  "id": "eventId",
  "autoMapping": true,
  "value": {
    "amount": 4,
    "appversionid": "1.2.3",
    "cheater": false,
    "country": "TR",
    "createtime": "2011-10-05T14:48:00.000Z",
    "deviceid": "xxxxx",
    "duration": 100,
    "endtime": "2011-10-05T14:50:00.000Z",
    "eventtime": "2011-10-05T14:50:00.000Z",
    "firstappversionid": "1.1.1",
    "idfv": "idfv",
    "level": 1,
    "locale": "en",
    "osversionid": "1.0.0",
    "paying_status": 1,
    "paymentcount": 2,
    "paymentsum": 3,
    "sbspaymentcount": 4,
    "sbspaymentsum": 5,
    "sessionid": "session_id",
    "starttime": "2011-10-05T14:48:00.000Z",
    "tester": false,
    "updatetime": "2011-10-05T14:49:00.000Z",
    "userid": "user_id"
  }
}

AdImpressions

Example Request Body

{
  "entityName": "ad_impressions",
  "type": "insert",
  "id": "eventId",
  "autoMapping": true,
  "value": {
    "eventtime": "2023-05-04T15:30:00.000Z",
    "userid": "unique_id",
    "sessionid": "unique_id2",
    "abtestvalues": "test1,test2",
    "ad_network": "AdMob",
    "ad_placement": "bottom",
    "ad_source": "source1",
    "ad_unit": "unit1",
    "appversion": "1.0.0",
    "appversionid": "1.2.3",
    "cheater": false,
    "country": "US",
    "created": "2023-05-04T15:30:00.000Z",
    "device": "iPhone",
    "deviceid": "123456789",
    "eventlevel": 1,
    "firstappversion": "1.0.0",
    "firstappversionid": 100,
    "firstpaymentdate": "2023-01-01T12:00:00.000Z",
    "lastpaymentdate": "2023-05-01T12:00:00.000Z",
    "level": 5,
    "locale": "en_US",
    "location": "New York",
    "locationid": 1,
    "osversion": "14.5",
    "osversionid": 145,
    "paymentcount": 2,
    "paymentsum": 10.99,
    "revenue": 4.99,
    "sbsfirstpaymentdate": "2023-02-01T12:00:00.000Z",
    "sbspaymentcount": 1,
    "sbspaymentsum": 5.99,
    "sdkversion": "2.0.0",
    "sdkversionid": 200,
    "segmentvalues": "segment1,segment2",
    "tester": true,
  }
}

Custom Events

Example Request Body

{
  "entityName": "custom_events",
  "type": "insert",
  "id": "eventId",
  "autoMapping": true,
  "value": {
    "eventtime": "2023-05-04T10:15:30Z",
    "userid": "user_123",
    "sessionid": "session_123",
    "cheater": false,
    "customBooleanProperty1": true,
    "customNumberProperty1": 10,
    "customNumberProperty2": 2.5,
    "customStringProperty1": "value1",
    "customStringProperty2": "value2",
    "customStringProperty3": "value3",
    "eventName": "eventA",
    "tester": false
  }
}

Ingame Purchases

Example Request Body

{
  "entityName": "ingame_purchases",
  "type": "insert",
  "id": "eventId",
  "autoMapping": true,
  "value": {
    "eventtime": "2023-05-04T12:30:00Z",
    "userid": "user_123",
    "sessionid": "session_123",
    "amount": 10,
    "appversionid": "1.2.3",
    "cheater": false,
    "country": "US",
    "currency": "USD",
    "deviceid": "device_123",
    "firstappversionid": "1.0.0",
    "item": "item_123",
    "itemtype": "consumable",
    "level": 10,
    "locale": "en_US",
    "osversionid": "13.5.1",
    "p1": 1,
    "paying_status": "completed",
    "paymentcount": 5,
    "paymentsum": 100,
    "price": 10,
    "sbspaymentcount": 2,
    "sbspaymentsum": 50,
    "tester": false
  }
}

Levelups

Example Request Body

{
  "entityName": "levelups",
  "type": "insert",
  "id": "eventId",
  "autoMapping": "true",
  "value": {
    "eventtime": "2023-05-04T14:30:00.000Z",
    "userid": "user123",
    "sessionid": "session123",
    "appversionid": "1.2.3",
    "cheater": false,
    "country": "US",
    "deviceid": "device123",
    "eventlevel": 5,
    "firstappversionid": "1.0.0",
    "level": 10,
    "locale": "en-US",
    "osversionid": "12.4",
    "paying_status": true,
    "paymentcount": 2,
    "paymentsum": 9.99,
    "sbspaymentcount": 1,
    "sbspaymentsum": 4.99,
    "tester": false
  }
}

Payments

Example Request Body

{
  "entityName": "payments",
  "type": "insert",
  "id": "eventId",
  "autoMapping": true,
  "value": {
    "eventtime": "2023-05-08T10:30:00Z",
    "userid": "user123",
    "sessionid": "session456",
    "appversionid": "1.2.3",
    "cheater": false,
    "country": "US",
    "currency": "USD",
    "deviceid": "device789",
    "firstappversionid": "1.0.0",
    "level": 10,
    "locale": "en-US",
    "osversionid": "14.5",
    "paymentcount": 3,
    "paymentid": "payment123",
    "paymentsum": 29.99,
    "price": 9.99,
    "priceusd": 11.99,
    "product": "premium",
    "sbspaymentcount": 1,
    "sbspaymentsum": 9.99,
    "tester": false,
    "valid": true
  }
}

Progressions

Example Request Body

{
  "entityName": "progressions",
  "type": "insert",
  "id": "eventId",
  "autoMapping": true,
  "value": {
    "eventtime": "2023-05-08T10:30:00Z",
    "userid": "unique_id",
    "sessionid": "unique_id2",
    "appversionid": "1.0",
    "cheater": false,
    "country": "US",
    "currencytype": "USD",
    "deviceid": "device123",
    "difficulty": "hard",
    "duration": 120,
    "firstappversionid": "1.0",
    "level": 5,
    "locale": "en_US",
    "locationid": 123,
    "locationsource": "gps",
    "osversionid": "10.3.2",
    "paying_status": true,
    "paymentcount": 2,
    "paymentsum": 10.99,
    "sbspaymentcount": 1,
    "sbspaymentsum": 4.99,
    "success": true,
    "tester": false
  }
}

Push Clicked

Example Request Body

{
  "entityName": "push_clicked",
  "type": "insert",
  "id": "eventId",
  "autoMapping": true,
  "value": {
    "eventtime": "2023-05-08T14:30:00.000Z",
    "userid": "unique_id",
    "sessionid": "unique_id2",
    "appversionid": "1.0.0",
    "cheater": false,
    "country": "US",
    "firstappversionid": "1.0.0",
    "level": 10,
    "locale": "en_US",
    "osversionid": "14.5.1",
    "paying_status": true,
    "paymentcount": 2,
    "paymentsum": 10.0,
    "sbspaymentcount": 1,
    "sbspaymentsum": 5.0,
    "tag_id": "unique_tag_id",
    "tester": false
  }
}

Push Sent

Example Request Body

{
  "entityName": "push_sent",
  "type": "insert",
  "id": "eventId",
  "autoMapping": "true",
  "value": {
    "eventtime": "2023-05-08T10:15:30Z",
    "userid": "user123",
    "sessionid": "session456",
    "appversionid": "2.1.0",
    "cheater": false,
    "country": "US",
    "deviceid": "device789",
    "firstappversionid": "1.0.0",
    "level": 5,
    "locale": "en_US",
    "osversionid": "12.4.1",
    "paying_status": true,
    "paymentcount": 3,
    "paymentsum": 15.99,
    "sbspaymentcount": 0,
    "sbspaymentsum": 0,
    "tag_id": "promo123",
    "tester": false
  }
}

Subscriptions

Example Request Body

{
  "entityName": "subscriptions",
  "type": "insert",
  "id": "eventId",
  "autoMapping": "true",
  "value": {
    "eventtime": "2022-05-08T10:30:00Z",
    "userid": "user123",
    "sessionid": "session456",
    "appversionid": "1.0.0",
    "cheater": false,
    "country": "US",
    "currency": "USD",
    "deviceid": "device789",
    "firstappversionid": "1.0.0",
    "level": 10,
    "locale": "en_US",
    "osversionid": "12.3",
    "p21": 1234,
    "paymentcount": 2,
    "paymentid": "payment123",
    "paymentsum": 9.99,
    "period": "monthly",
    "price": 4.99,
    "priceusd": 4.99,
    "product": "premium",
    "sbs_state": "active",
    "sbspaymentcount": 1,
    "sbspaymentsum": 4.99,
    "tester": false,
    "valid": true
 }
}

Tutorials

Example Request Body

{
  "entityName": "tutorials",
  "type": "insert",
  "id": "eventId",
  "autoMapping": true,
  "value": {
    "eventtime": "2023-05-08T14:30:00.000Z",
    "userid": "user123",
    "sessionid": "session456",
    "appversionid": "1.2.3",
    "cheater": false,
    "country": "US",
    "deviceid": "device789",
    "eventtime_daily": "2023-05-08T00:00:00.000Z",
    "firstappversionid": "1.0.0",
    "level": 10,
    "locale": "en_US",
    "osversionid": "14.5",
    "paying_status": true,
    "paymentcount": 3,
    "paymentsum": 9.99,
    "sbspaymentcount": 1,
    "sbspaymentsum": 4.99,
    "step": "impression",
    "tester": false
  }
}

Users

Please, prioritize using walletid_1. Currently, we do not support joining web3 data using walletid_2 and walletid_3

Example Request Body

{
  "entityName": "mv_users",
  "type": "insert",
  "id": "eventId",
  "autoMapping": true,
  "value": {
    "advertisingid": "ad_id_1234",
    "age": 35,
    "androidid": "android_id_5678",
    "appversionid": "1.2.3",
    "cheater": false,
    "country": "US",
    "customuid": "user123",
    "deviceid": "device123",
    "firstappversionid": "1.0.0",
    "idfa": "idfa_1234",
    "idfv": "idfv_5678",
    "lasttime": "2023-05-08 10:30:00",
    "level": 10,
    "locale": "en_US",
    "min_createtime": "2023-01-01 00:00:00",
    "osversionid": "11.0",
    "paying_status": true,
    "paymentcount": 5,
    "paymentsum": 25.99,
    "publisherid": "pub123",
    "push_available": true,
    "sbspaymentcount": 2,
    "sbspaymentsum": 4.99,
    "subcampaignid": "subcamp123",
    "tester": false,
    "timezoneoffset": -300,
    "useremail": "[email protected]",
    "username": "John Doe",
    "userphone": "+1-555-555-5555",
    "userphoto": "https://example.com/user.jpg",
    "walletid_1": "wallet123",
    "walletid_2": "wallet456",
    "walletid_3": "wallet789"
  }
}