Overview

The AppsFlyer platform attributes and records mobile app events sent by the AppsFlyer SDK and by S2S APIs.

Endpoint

POST https://api3.appsflyer.com/inappevent/{app_id}

Prerequisites

S2S key. Learn how to obtain the S2S key.

Path parameters

ParameterTypeDescriptionExample
app_idstringThe app identifier used in the AppsFlyer dashboard.
iOS apps: Ensure to prefix with id. Failure to do so results in a valid 200 OK return code; without recording the event. Windows: Get the app ID from the Microsoft App Store.
id123456789

Android body parameters

NameTypeDescriptionExample
advertising_idstringWhere available, populate with the device GAID (advertising ID).9c9a82fb-d5de-4cd1-90c3-527441c11828
oaidstringAn identifier for advertisers on Android devices that is used for tracking and serving ads without using the Google Advertising ID (GAID).1fe9a970-efbb-29e0-0bdd-f5dbbf751ab5
amazon_aidstringAn advertising identifier provided by Amazon for apps on Amazon devices.
imeistringInternational Mobile Equipment Identity: A unique identifier for mobile phones, typically found by dialing *#06#.AA-BBBBBB-CCCCCC-D
appsflyer_id*stringA unique identifier, generated by AppsFlyer, when the app launches for the first time.1234567890123-1234567
customer_user_idstringCustomer user ID, a unique user identifier set by the app owner.customer_user_id
ipstringThe mobile device's IP address during the event occurrence.192.0.2.1
eventName*stringSpecify the event name. Ensure that the event names are aligned with the marketer's requirements.af_ad_revenue
eventValue*stringEvent values must be sent without additional symbols or formatting. For af_revenue, a decimal point can be used. Negative values should be preceded by a minus sign. If you send an event without a value then send: "eventValue":" " Explicit TikTok For Business instructions{ "af_revenue": "6", "af_content_type": "wallets", "af_content_id": "15854", "your_custom_attribute": "456.123" }
app_version_namestringThe public version name of the app.my_app_version
app_storestringThe store from which the app was downloaded. Equivalent to AF_STORE in Android apps.my_android_store_is_best
eventTimestringThe time the event occurred using UTC timezone. Default: If no eventTime is sent, the time is set to the HTTP message arrival time. Format: yyyy-mm-dd hh:mm:ss.sss (time needs to be in UTC timezone). Time stamping S2S events.2019-05-15 12:17:01.123
eventCurrencystringUSD
bundleIdentifierstringA unique app identifier. In raw data reports, the parameter populates Bundle ID. Best practice - Always populate this parameter. Many ad networks require it for campaign optimization.com.example.myapp
sharing_filterarrayAllows you to block sharing of S2S events via postbacks/API with partners. Utilize all to block all partners. Input partner IDs to block individual ones.
List of partner ids in an array: To find out the required partner IDs:
1. Run the Get active integrations API for a list of all active integrations.
2. Use the media_source_name values from the API response as input values to the method partners array.
Exceptions:
For Apple Search Ads use Apple Search Ads (and not iossearchads_int).
For Twitter, use twitter (and not twitter_int).
["googleadwords_int", "adcolony_int"]
custom_dimensionstringReserved for AppsFlyer future use.
app_typestringIf the user event takes place in an app_clip, send the parameter. In all other cases, do not send the parameter.app_clip
custom_datastringSend custom data to the AppsFlyer platform. Similar to sending data from the SDK using setAdditionalData. In raw data, populates the custom_data field.{"key_group" : { "key_a1" : "value a1", "key_a2" : "value a2" }, "key_b" : "value b"}
osstringThe device operating system version. To enable correct data processing, you must send this parameter.14.5.1
aiebooleanUse this flag to indicate if the user has opted out of sharing their advertiser ID. Use this field for devices running Android (all versions), or iOS versions before 14.5+. true: if the user agrees to share the advertiser ID. false: if the user enabled Limited Ad Tracking (LAT).false
consent_dataobjectConsent data accompanying the event: - TCF or - Manual object"consent_data": { "manual": { "gdpr_applies": true, "ad_user_data_enabled": false, "ad_personalization_enabled": true } }

iOS body parameters

NameTypeDescriptionExample
idfastringWhere available populate with the device IDFA9876F1SS-2983-3855-27RR-2R626772VFNB
idfvstringWhere available populate with the device IDFV95C9BD22-4A4C-41C8-9548-ED07C5C8C145
appsflyer_id*stringA unique identifier, generated by AppsFlyer, when the app launches for the first time.1234567890123-1234567
customer_user_idstringCustomer user ID, a unique user identifier set by the app owner.customer_user_id
attintegeriOS ATTrackingManager authorization status.
If the device OS version is iOS 14 or later, populate att with the ATTrackingManager value.
The iOS values for ATTrackingManager are: Not determined, Restricted, Denied, Authorized.
We recommend that you populate att with the ATTrackingManager value as it impacts which identifiers are shared with partners in accordance with your Aggregated Advanced Privacy settings.
3
ipstringThe mobile device's IP address during the event occurrence.
If sent, the IP address is used to populate geo fields.
If not sent, AppsFlyer populates the geo fields using the values from the install attribution event. The IP address isn't populated.
192.0.2.1
eventName*stringSpecify the event name. Ensure that the event names are aligned with the marketer's requirements.score_share
eventValue*stringEvent values must be sent without additional symbols or formatting.
For af_revenue a decimal point can be used. Negative values should be preceded by a minus sign.
Explicit TikTok For Business instructions
If you send an event without a value then send: "eventValue":""
{ "af_revenue": "6", "af_content_type": "wallets", "af_content_id": "15854", "your_custom_attribute" :"456.123" }
app_version_namestringmy_app_version
app_storestringEquivalent to AF_STORE in Android apps. The store from which the app was downloaded.app_store
eventTimestringThe time the event occurred using UTC timezone.
Default: If no eventTime is sent, the time is set to the HTTP message arrival time.
Format: string yyyy-mm-dd hh:mm:ss.sss the time needs to be in UTC timezone.
To learn how events are timestamped after arriving at AppsFlyer based on the eventTime value see this KB section.
2019-05-15 12:17:01.123
eventCurrencystringNZD
bundleIdentifierstringThe app's unique identifier. Populates Bundle ID in raw data reports. As best practice always include this parameter for campaign optimization by ad networks.com.myapp
sharing_filterarrayAllows you to block sharing of S2S events via postbacks/API with partners. Utilize all to block all partners. Input partner IDs to block individual ones.
List of partner ids in an array: To find out the required partner IDs:
1. Run the Get active integrations API for a list of all active integrations.
2. Use the media_source_name values from the API response as input values to the method partners array.
Exceptions:
For Apple Search Ads use Apple Search Ads (and not iossearchads_int).
For Twitter, use twitter (and not twitter_int).
["googleadwords_int", "adcolony_int"]
custom_dimensionstringReserved for future use by AppsFlyer.string
app_typestringUse app_clip if the event happened in an app clip. Otherwise, this parameter can be omitted.app_clip
custom_datastringCustom data that is sent along to AppsFlyer. In raw data: populates the custom_data field.{"key_group" : { "key_a1" : "value a1", "key_a2" : "value a2" }, "key_b" : "value b"}
osstringThe operating system version of the device. Important for correct data processing. If omitted, it is assumed to be iOS 14.5.14.5.1
aiebooleanIndicates if the user has opted out of sharing their advertiser ID. true if the user agreed to share, false if user enabled Limited Ad Tracking (LAT). For iOS 14.5+, use att instead.false
consent_dataobjectConsent data accompanying the event:
- TCF or
- Manual object
"consent_data": { "manual": { "gdpr_applies": true, "ad_user_data_enabled": false, "ad_personalization_enabled": true } }