Args Reference

This page documents the argument objects used across the CiaoSDK API.

CiaoConsent

Passed to CiaoSDK.Initialize and CiaoSDK.UpdateConsent.
If adsConsent, mmpConsent, or analyticsConsent are not explicitly set, they inherit the value of gdprConsent .

FieldTypeDescriptionDefault
gdprConsentboolGDPR consent granted.true
adsConsentbool?Ads (LevelPlay) consent. Overrides gdprConsent for ads only.Inherits from gdprConsent
mmpConsentbool?MMP (Singular) consent. Overrides gdprConsent for MMP only.Inherits from gdprConsent
analyticsConsentbool?Analytics (ByteBrew) consent. Overrides gdprConsent for analytics only.Inherits from gdprConsent
isChildDirectedboolCOPPA — user is under 13.false
isUnderAgeOfConsentboolGDPR — user is under the age of digital consent (typically 16).false
attGrantedbooliOS App Tracking Transparency granted.false

LevelCompletedArgs

Passed to CiaoSDK.SendLevelCompleted.

FieldTypeDescription
levelintLevel ID.
interstitialViewsintInterstitials shown during this level.
rewardedViewsintRewarded ads shown during this level.
timeintTime spent in level (seconds).
sessionintCurrent session number.
ltvfloatLifetime value (USD) so far.
playerLevelintPlayer's overall progression level.
currencyNamestring (optional)Name of the in-game currency tracked.
currencyBalanceint (optional)Currency balance at end of level.

IAPArgs

Passed to CiaoSDK.SendIAPPurchased for Unity IAP purchases. Supports Unity IAP v4 (Product) and v5 (Order). For non-Unity IAP purchases (DTC, web shops, etc), see RevenueArgs.

FieldTypeDescription
order (Unity IAP v5)OrderThe Unity IAP v5 Order object.
product (Unity IAP v4)ProductThe Unity IAP v4 Product object.
restoredbooltrue if this is a restored purchase. Default: false.
categorystringOptional product category. Default: "".

RevenueArgs

Passed to CiaoSDK.SendIAPPurchased for non-Unity IAP purchases (DTC, web shop, etc). Use when you don’t have a Unity IAP Product or Order.

FieldTypeDescription
currencystringRequired. ISO 4217 code, UPPERCASE (e.g. USD, EUR).
amountdoubleRequired. Total transaction amount. Must be > 0.
productSKUstringRequired. Product identifier in your catalog.
transactionIdstringRequired. Unique transaction ID.
sourcestringRequired. Payment rail name (e.g. "Appcharge", "Stripe", "Hive", etc).
productNamestringOptional. Human-readable product name.
productCategorystringOptional. Product category.
productQuantityintOptional. Default 1.
productPricedoubleOptional. Unit price.
extraDictionary<string, object>Optional. Extra attributes forwarded to MMP (promo codes, user tier, etc.).

AdImpressionArgs

Passed to CiaoSDKAnalytics.SendAdImpression.

FieldTypeDescription
adTypeAdTypeEnum: Interstitial, Rewarded, or Banner.
adCountintTotal impressions of this ad type so far.
levelIdintCurrent level ID.
placementstringPlacement name. Default: null.

CheatArgs

Passed to CiaoSDK.SendCheaterDetected.

FieldTypeDescription
reasonCheatReasonRequired. Enum: LevelJump, ThirdPartyInstall, TimeCheat, IAPFraud, MemoryEdit, SpeedHack.
playtimeint?Optional playtime in seconds.
sessionint?Optional session number.
claimedLevelint?Optional level claimed by client.
lastValidLevelint?Optional last server-validated level.
installSourcestringOptional install source.
deviceTimestringOptional device timestamp.
serverTimestringOptional server timestamp.
productIdstringOptional product ID (for IAPFraud).

Did this page help you?