Skip to main content
API Tools
Daria Mamchenkova avatar
Written by Daria Mamchenkova
Updated over a week ago

API Tools allows you to get raw data in your analytics systems, which helps you better analyze users and improve their customer journey map (CJM). The option helps in testing new functionality, product performance analytics, and making forecasts on the financial condition of the application.

API Keys

To find the list of API Keys, go to Attribution > API Tools. On this page, you can see the following:

  • The list of API-keys, which you can add, delete and regenerate:

🔎 You can add up to 3 API-keys.

You can use any of these API-keys to get installs, events, and conversions data. Each of these requests has its own conditions.

Get installs

Headers: API-KEY

Params:

  • pagination.limit (uint) - limit.

  • pagination.offset (uint) - offset.

  • time_window.from_rfc3339 (string) - example:2022-01-01T12:00:27.87+00:20.

  • time_window.from.seconds (uint) - timestamp - higher priority than from_rfc3339.

  • time_window.from_not_include bool - if checked "time > from" else "time >= from".

  • time_window.to_rfc3339 (string) - example:2022-01-01T12:00:27.87+00:20.

  • time_window.to.seconds (uint) - timestamp - higher priority than to_rfc3339.

  • non_organic_only (boolean).

All fields are optional. Order by created_at asc always. New events with less created_at cannot be added.

API response example:

 {
"info": [
{ "device": {
"affise_device_id": "310d8335-80b1-4849-8925-ef54126004af",
"random_user_id": "b2080f39-f9e1-4f7e-bc42-8863dfe028d5",
"first_open_time": {
"seconds": 1696156153
},
"app_id": 1,
"affise_pkg_app_name": "com.itbxp.surf",
"partner_id": 10,
"device_parameters": {
"platform": "android",
"device_name": "5058",
"device_type": "smartphone",
"os_name": "Nougat",
"os_version": "7.0",
"android_id": "421a9e99321086d6",
"gaid_adid": "d8313cad-070f-4c0e-824f-bb58d7be5acf",
"referrer": "referrer=4107abce-890d-4098-b83b-01d9bdc195d4&clickid=651949b9660c680001ef66c8&pid=10"
},
"click_affise": {
"click_id": "4317abce-990d-4098-b83b-01d9bdc195d4",
"created_at": {
"seconds": 1696156090
},
"subs": {},
"geo": {
"country": "ID",
"region": "Jawa Timur",
"city": "Tamansari",
"isp": "?"
},
"ip": "2001:448a:5139:1985:5d62:4fe6:118d:9c12",
"user_agent": "Mozilla/5.0 (Linux; Android 7.0; 5058 Build/NRD90M; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/117.0.0.0 Mobile Safari/537.36 agentweb/4.0.2 UCBrowser/11.6.4.950",
"pub_click_id": "652949b9660c680001ef66c8"
}
},
"uuid": "924ee319-6e6d-44f3-9449-08d4b4dd1300",
"timestamp": {
"seconds": 1696156248
},
"geo": {
"country": "ID",
"region": "ID",
"isp": "IND TELKOMSEL"
},
"ip": "2001:448a:2130:1985:5d62:4fe6:118d:9c12",
"created_at": {
"seconds": 1696156279
}
}

Get events

Headers: API-KEY

Params:

  • pagination.limit (uint) - limit.

  • pagination.offset (uint) - offset.

  • time_window.from_rfc3339 (string) - example:2022-01-01T12:00:27.87+00:20.

  • time_window.from.seconds (uint) - timestamp - higher priority than from_rfc3339.

  • time_window.from_not_include bool - if checked "time > from" else "time >= from".

  • time_window.to_rfc3339 (string) - example:2022-01-01T12:00:27.87+00:20.

  • time_window.to.seconds (uint) - timestamp - higher priority than to_rfc3339.

  • non_organic_only (boolean).

All fields are optional. Order by created_at asc always. New events with less created_at cannot be added.

API response example:

{
"events": [
{
"info": {
"device": {
"affise_device_id": "8f29848f-ecfa-49f2-93a7-d2d484a13515",
"random_user_id": "071dcb20-1826-47ff-a310-e84ab4a673a1",
"first_open_time": {
"seconds": 1696122018
},
"app_id": 1,
"affise_pkg_app_name": "com.itbxp.surf",
"is_organic": true,
"device_parameters": {
"platform": "android",
"device_name": "i55C",
"device_type": "smartphone",
"os_name": "Nougat",
"os_version": "7.0",
"android_id": "e627c254f84cd9a9",
"gaid_adid": "0ed20689-2435-4816-ab58-e2bc03639ecb",
"referrer": "referrer=8ba10af2-4cc9-4cda-806f-47181d47fcef&clickid=65176bfb55c3260001bad183&pid=10"
}
},
"uuid": "0f8e8e41-3b1e-4981-b36d-f919dc15f7ca",
"timestamp": {
"seconds": 1696122034
},
"geo": {
"country": "ID",
"region": "ID",
"isp": "Indosat Ooredoo"
},
"ip": "2001:448a:3041:2d33:b900:e218:be45:ae55",
"created_at": {
"seconds": 1696122079
}
},
"created_at": {
"seconds": 1696122079
},
"id": "afbcac17-4a0a-4df8-9acd-d0b7706185b9",
"name": "ContentItemsView",
"category": "native",
"timestamp": {
"seconds": 1696122019
},
"user_data": "shortcuts",
"data":"{\"affise_event_content_items_view\":[{\"title\":\"News\",\"url\":\"https://track.g2afse.com/click?pid=127\&offer_id=32107\"},{\"title\":\"Kids\",\"url\":\"https://track.g2afse.com/click?pid=127\&offer_id=32102\"},{\"title\":\"Goods\",\"url\":\"https://track.g2afse.com/click?pid=127\&offer_id=32100\"},{\"title\":\"Utilities\",\"url\":\"https://track.g2afse.com/click?pid=127\&offer_id=32110\"},{\"title\":\"Fun\",\"url\":\"https://appspress.g2afse.com/click?pid=127\&offer_id=32098\"},{\"title\":\"Food\",\"url\":\"https://appspress.g2afse.com/click?pid=127\&offer_id=32097\"}]}"
}

Get conversions

Headers: API-KEY

Params:

  • pagination.limit (uint) - limit.

  • pagination.offset (uint) - offset.

  • time_window.from_rfc3339 (string) - example:2022-01-01T12:00:27.87+00:20.

  • time_window.from.seconds (uint) - timestamp - higher priority than from_rfc3339.

  • time_window.from_not_include bool - if checked "time > from" else "time >= from".

  • time_window.to_rfc3339 (string) - example:2022-01-01T12:00:27.87+00:20.

  • time_window.to.seconds (uint) - timestamp - higher priority than to_rfc3339.

  • non_organic_only (boolean).

All fields are optional. Order by created_at asc always. New events with less created_at cannot be added.

⚠️ The example includes additional values that you can get if you pass them via the referrer.

{
"conversions": [
{
"event": {
"info": {
"device": {
"affise_device_id": "6f9491d3-000a-1000-0f45-58674f4c7485",
"random_user_id": "6f9000ee-018a-1000-8c19-58a34e8a8d72",
"first_open_time": {
"seconds": 1694089122,
"nanos": 256000000
},
"app_id": 129,
"affise_pkg_app_name": "com.affise.app",
"device_parameters": {
"platform": "android",
"device_name": "sdk_gphone_x86_64",
"device_type": "smartphone",
"os_name": "Android11",
"os_version": "11",
"android_id": "b6ea55ccaee29142",
"referrer": "referrer=4c5a6cff-4a76-4518-b2b7-a9d21abbd8ca&clickid=640f91362bc1a20001646bd7&pid=85"
},
"click_affise": {
"click_id": "4c9a6cff-4a76-4518-b2b7-a9d90abbd0ca",
"created_at": {
"seconds": 1694089122
},
"subs": {
"sub1": "s1",
"sub2": "s2",
"sub3": "s3",
"sub4": "s4",
"sub5": "s5"
},
"geo": {
"country": "UK"
},
"ip": "127.0.0.1",
"user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/99.0.4844.51 Safari/537.36",
"campaign_id": "123",
"campaign_name": "cname",
"network_id": "123",
"network_name": "nname",
"tracker_id": "123",
"tracker_name": "tname",
"creative_id": "123",
"pub_click_id": "640f91362bc1a20001646bd7",
"partner_name": "pname"
}
},
"uuid": "f5a01792-018a-1000-bd27-633c0f2d5839",
"timestamp": {
"seconds": 1696338024
},
"geo": {
"country": "US",
"region": "US"
},
"ip": "188.17.96.239",
"user_agent": "Dalvik/2.1.0 (Linux; U; Android 11; sdk_gphone_x86_64 Build/RSR1.201211.001)",
"created_at": {
"seconds": 1696338042,
"nanos": 67913469
}
}
},
"created_at": {
"seconds": 1696338026
},
"id": "5c8791a4-3a4f-41aa-9319-225a30f847e5",
"conversion_type": "install",
"currency": "USD"
}
]
}{

Try API-key

To try an API-Key, do the following:

  1. Select Try installs, Try events, or Try conversions.

  2. In the API-KEY drop-down list, select a certain API-key.

  3. In the Period filter, specify the period.

  4. If you want to get only non organic events, click the Non organic only checkbox.

  5. Click Request.

You may have the following response:

Postback errors

On the Postbacks errors tab, you can check the logs for the postbacks that your advertiser sent.


Please contact the Affise Customer Support team regarding all raised questions via the e-mail: [email protected].

Did this answer your question?