Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
com.facebook.ads.sdk.AdsInsights Maven / Gradle / Ivy
/*
* Copyright (c) Meta Platforms, Inc. and affiliates.
* All rights reserved.
*
* This source code is licensed under the license found in the
* LICENSE file in the root directory of this source tree.
*/
package com.facebook.ads.sdk;
import java.io.File;
import java.lang.reflect.Modifier;
import java.lang.reflect.Type;
import java.util.Arrays;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import com.google.common.base.Function;
import com.google.common.util.concurrent.Futures;
import com.google.common.util.concurrent.ListenableFuture;
import com.google.common.util.concurrent.MoreExecutors;
import com.google.common.util.concurrent.SettableFuture;
import com.google.gson.JsonObject;
import com.google.gson.JsonArray;
import com.google.gson.annotations.SerializedName;
import com.google.gson.reflect.TypeToken;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.google.gson.JsonElement;
import com.google.gson.JsonParser;
import com.facebook.ads.sdk.APIException.MalformedResponseException;
/**
* This class is auto-generated.
*
* For any issues or feature requests related to this class, please let us know
* on github and we'll fix in our codegen framework. We'll not be able to accept
* pull request for this class.
*
*/
public class AdsInsights extends APINode {
@SerializedName("account_currency")
private String mAccountCurrency = null;
@SerializedName("account_id")
private String mAccountId = null;
@SerializedName("account_name")
private String mAccountName = null;
@SerializedName("action_values")
private List mActionValues = null;
@SerializedName("actions")
private List mActions = null;
@SerializedName("ad_click_actions")
private List mAdClickActions = null;
@SerializedName("ad_id")
private String mAdId = null;
@SerializedName("ad_impression_actions")
private List mAdImpressionActions = null;
@SerializedName("ad_name")
private String mAdName = null;
@SerializedName("adset_end")
private String mAdsetEnd = null;
@SerializedName("adset_id")
private String mAdsetId = null;
@SerializedName("adset_name")
private String mAdsetName = null;
@SerializedName("adset_start")
private String mAdsetStart = null;
@SerializedName("age_targeting")
private String mAgeTargeting = null;
@SerializedName("attribution_setting")
private String mAttributionSetting = null;
@SerializedName("auction_bid")
private String mAuctionBid = null;
@SerializedName("auction_competitiveness")
private String mAuctionCompetitiveness = null;
@SerializedName("auction_max_competitor_bid")
private String mAuctionMaxCompetitorBid = null;
@SerializedName("average_purchases_conversion_value")
private List mAveragePurchasesConversionValue = null;
@SerializedName("buying_type")
private String mBuyingType = null;
@SerializedName("campaign_id")
private String mCampaignId = null;
@SerializedName("campaign_name")
private String mCampaignName = null;
@SerializedName("canvas_avg_view_percent")
private String mCanvasAvgViewPercent = null;
@SerializedName("canvas_avg_view_time")
private String mCanvasAvgViewTime = null;
@SerializedName("catalog_segment_actions")
private List mCatalogSegmentActions = null;
@SerializedName("catalog_segment_value")
private List mCatalogSegmentValue = null;
@SerializedName("catalog_segment_value_mobile_purchase_roas")
private List mCatalogSegmentValueMobilePurchaseRoas = null;
@SerializedName("catalog_segment_value_omni_purchase_roas")
private List mCatalogSegmentValueOmniPurchaseRoas = null;
@SerializedName("catalog_segment_value_website_purchase_roas")
private List mCatalogSegmentValueWebsitePurchaseRoas = null;
@SerializedName("clicks")
private String mClicks = null;
@SerializedName("conversion_lead_rate")
private List mConversionLeadRate = null;
@SerializedName("conversion_leads")
private List mConversionLeads = null;
@SerializedName("conversion_rate_ranking")
private String mConversionRateRanking = null;
@SerializedName("conversion_values")
private List mConversionValues = null;
@SerializedName("conversions")
private List mConversions = null;
@SerializedName("converted_product_app_custom_event_fb_mobile_purchase")
private List mConvertedProductAppCustomEventFbMobilePurchase = null;
@SerializedName("converted_product_app_custom_event_fb_mobile_purchase_value")
private List mConvertedProductAppCustomEventFbMobilePurchaseValue = null;
@SerializedName("converted_product_offline_purchase")
private List mConvertedProductOfflinePurchase = null;
@SerializedName("converted_product_offline_purchase_value")
private List mConvertedProductOfflinePurchaseValue = null;
@SerializedName("converted_product_omni_purchase")
private List mConvertedProductOmniPurchase = null;
@SerializedName("converted_product_omni_purchase_values")
private List mConvertedProductOmniPurchaseValues = null;
@SerializedName("converted_product_quantity")
private List mConvertedProductQuantity = null;
@SerializedName("converted_product_value")
private List mConvertedProductValue = null;
@SerializedName("converted_product_website_pixel_purchase")
private List mConvertedProductWebsitePixelPurchase = null;
@SerializedName("converted_product_website_pixel_purchase_value")
private List mConvertedProductWebsitePixelPurchaseValue = null;
@SerializedName("converted_promoted_product_app_custom_event_fb_mobile_purchase")
private List mConvertedPromotedProductAppCustomEventFbMobilePurchase = null;
@SerializedName("converted_promoted_product_app_custom_event_fb_mobile_purchase_value")
private List mConvertedPromotedProductAppCustomEventFbMobilePurchaseValue = null;
@SerializedName("converted_promoted_product_offline_purchase")
private List mConvertedPromotedProductOfflinePurchase = null;
@SerializedName("converted_promoted_product_offline_purchase_value")
private List mConvertedPromotedProductOfflinePurchaseValue = null;
@SerializedName("converted_promoted_product_omni_purchase")
private List mConvertedPromotedProductOmniPurchase = null;
@SerializedName("converted_promoted_product_omni_purchase_values")
private List mConvertedPromotedProductOmniPurchaseValues = null;
@SerializedName("converted_promoted_product_quantity")
private List mConvertedPromotedProductQuantity = null;
@SerializedName("converted_promoted_product_value")
private List mConvertedPromotedProductValue = null;
@SerializedName("converted_promoted_product_website_pixel_purchase")
private List mConvertedPromotedProductWebsitePixelPurchase = null;
@SerializedName("converted_promoted_product_website_pixel_purchase_value")
private List mConvertedPromotedProductWebsitePixelPurchaseValue = null;
@SerializedName("cost_per_15_sec_video_view")
private List mCostPer15SecVideoView = null;
@SerializedName("cost_per_2_sec_continuous_video_view")
private List mCostPer2SecContinuousVideoView = null;
@SerializedName("cost_per_action_type")
private List mCostPerActionType = null;
@SerializedName("cost_per_ad_click")
private List mCostPerAdClick = null;
@SerializedName("cost_per_conversion")
private List mCostPerConversion = null;
@SerializedName("cost_per_conversion_lead")
private List mCostPerConversionLead = null;
@SerializedName("cost_per_dda_countby_convs")
private String mCostPerDdaCountbyConvs = null;
@SerializedName("cost_per_estimated_ad_recallers")
private String mCostPerEstimatedAdRecallers = null;
@SerializedName("cost_per_inline_link_click")
private String mCostPerInlineLinkClick = null;
@SerializedName("cost_per_inline_post_engagement")
private String mCostPerInlinePostEngagement = null;
@SerializedName("cost_per_objective_result")
private List mCostPerObjectiveResult = null;
@SerializedName("cost_per_one_thousand_ad_impression")
private List mCostPerOneThousandAdImpression = null;
@SerializedName("cost_per_outbound_click")
private List mCostPerOutboundClick = null;
@SerializedName("cost_per_result")
private List mCostPerResult = null;
@SerializedName("cost_per_thruplay")
private List mCostPerThruplay = null;
@SerializedName("cost_per_unique_action_type")
private List mCostPerUniqueActionType = null;
@SerializedName("cost_per_unique_click")
private String mCostPerUniqueClick = null;
@SerializedName("cost_per_unique_conversion")
private List mCostPerUniqueConversion = null;
@SerializedName("cost_per_unique_inline_link_click")
private String mCostPerUniqueInlineLinkClick = null;
@SerializedName("cost_per_unique_outbound_click")
private List mCostPerUniqueOutboundClick = null;
@SerializedName("cpc")
private String mCpc = null;
@SerializedName("cpm")
private String mCpm = null;
@SerializedName("cpp")
private String mCpp = null;
@SerializedName("created_time")
private String mCreatedTime = null;
@SerializedName("creative_media_type")
private String mCreativeMediaType = null;
@SerializedName("ctr")
private String mCtr = null;
@SerializedName("date_start")
private String mDateStart = null;
@SerializedName("date_stop")
private String mDateStop = null;
@SerializedName("dda_countby_convs")
private String mDdaCountbyConvs = null;
@SerializedName("dda_results")
private List mDdaResults = null;
@SerializedName("engagement_rate_ranking")
private String mEngagementRateRanking = null;
@SerializedName("estimated_ad_recall_rate")
private String mEstimatedAdRecallRate = null;
@SerializedName("estimated_ad_recall_rate_lower_bound")
private String mEstimatedAdRecallRateLowerBound = null;
@SerializedName("estimated_ad_recall_rate_upper_bound")
private String mEstimatedAdRecallRateUpperBound = null;
@SerializedName("estimated_ad_recallers")
private String mEstimatedAdRecallers = null;
@SerializedName("estimated_ad_recallers_lower_bound")
private String mEstimatedAdRecallersLowerBound = null;
@SerializedName("estimated_ad_recallers_upper_bound")
private String mEstimatedAdRecallersUpperBound = null;
@SerializedName("frequency")
private String mFrequency = null;
@SerializedName("full_view_impressions")
private String mFullViewImpressions = null;
@SerializedName("full_view_reach")
private String mFullViewReach = null;
@SerializedName("gender_targeting")
private String mGenderTargeting = null;
@SerializedName("impressions")
private String mImpressions = null;
@SerializedName("inline_link_click_ctr")
private String mInlineLinkClickCtr = null;
@SerializedName("inline_link_clicks")
private String mInlineLinkClicks = null;
@SerializedName("inline_post_engagement")
private String mInlinePostEngagement = null;
@SerializedName("instagram_upcoming_event_reminders_set")
private String mInstagramUpcomingEventRemindersSet = null;
@SerializedName("instant_experience_clicks_to_open")
private String mInstantExperienceClicksToOpen = null;
@SerializedName("instant_experience_clicks_to_start")
private String mInstantExperienceClicksToStart = null;
@SerializedName("instant_experience_outbound_clicks")
private List mInstantExperienceOutboundClicks = null;
@SerializedName("interactive_component_tap")
private List mInteractiveComponentTap = null;
@SerializedName("labels")
private String mLabels = null;
@SerializedName("landing_page_view_actions_per_link_click")
private String mLandingPageViewActionsPerLinkClick = null;
@SerializedName("landing_page_view_per_link_click")
private String mLandingPageViewPerLinkClick = null;
@SerializedName("landing_page_view_per_purchase_rate")
private String mLandingPageViewPerPurchaseRate = null;
@SerializedName("location")
private String mLocation = null;
@SerializedName("marketing_messages_click_rate_benchmark")
private String mMarketingMessagesClickRateBenchmark = null;
@SerializedName("marketing_messages_cost_per_delivered")
private String mMarketingMessagesCostPerDelivered = null;
@SerializedName("marketing_messages_cost_per_link_btn_click")
private String mMarketingMessagesCostPerLinkBtnClick = null;
@SerializedName("marketing_messages_delivered")
private String mMarketingMessagesDelivered = null;
@SerializedName("marketing_messages_delivery_rate")
private String mMarketingMessagesDeliveryRate = null;
@SerializedName("marketing_messages_link_btn_click")
private String mMarketingMessagesLinkBtnClick = null;
@SerializedName("marketing_messages_link_btn_click_rate")
private String mMarketingMessagesLinkBtnClickRate = null;
@SerializedName("marketing_messages_media_view_rate")
private String mMarketingMessagesMediaViewRate = null;
@SerializedName("marketing_messages_phone_call_btn_click_rate")
private String mMarketingMessagesPhoneCallBtnClickRate = null;
@SerializedName("marketing_messages_quick_reply_btn_click")
private String mMarketingMessagesQuickReplyBtnClick = null;
@SerializedName("marketing_messages_quick_reply_btn_click_rate")
private String mMarketingMessagesQuickReplyBtnClickRate = null;
@SerializedName("marketing_messages_read")
private String mMarketingMessagesRead = null;
@SerializedName("marketing_messages_read_rate")
private String mMarketingMessagesReadRate = null;
@SerializedName("marketing_messages_read_rate_benchmark")
private String mMarketingMessagesReadRateBenchmark = null;
@SerializedName("marketing_messages_sent")
private String mMarketingMessagesSent = null;
@SerializedName("marketing_messages_spend")
private String mMarketingMessagesSpend = null;
@SerializedName("marketing_messages_spend_currency")
private String mMarketingMessagesSpendCurrency = null;
@SerializedName("marketing_messages_website_add_to_cart")
private String mMarketingMessagesWebsiteAddToCart = null;
@SerializedName("marketing_messages_website_initiate_checkout")
private String mMarketingMessagesWebsiteInitiateCheckout = null;
@SerializedName("marketing_messages_website_purchase")
private String mMarketingMessagesWebsitePurchase = null;
@SerializedName("marketing_messages_website_purchase_values")
private String mMarketingMessagesWebsitePurchaseValues = null;
@SerializedName("mobile_app_purchase_roas")
private List mMobileAppPurchaseRoas = null;
@SerializedName("objective")
private String mObjective = null;
@SerializedName("objective_result_rate")
private List mObjectiveResultRate = null;
@SerializedName("objective_results")
private List mObjectiveResults = null;
@SerializedName("onsite_conversion_messaging_detected_purchase_deduped")
private List mOnsiteConversionMessagingDetectedPurchaseDeduped = null;
@SerializedName("optimization_goal")
private String mOptimizationGoal = null;
@SerializedName("outbound_clicks")
private List mOutboundClicks = null;
@SerializedName("outbound_clicks_ctr")
private List mOutboundClicksCtr = null;
@SerializedName("place_page_name")
private String mPlacePageName = null;
@SerializedName("product_brand")
private String mProductBrand = null;
@SerializedName("product_category")
private String mProductCategory = null;
@SerializedName("product_content_id")
private String mProductContentId = null;
@SerializedName("product_custom_label_0")
private String mProductCustomLabel0 = null;
@SerializedName("product_custom_label_1")
private String mProductCustomLabel1 = null;
@SerializedName("product_custom_label_2")
private String mProductCustomLabel2 = null;
@SerializedName("product_custom_label_3")
private String mProductCustomLabel3 = null;
@SerializedName("product_custom_label_4")
private String mProductCustomLabel4 = null;
@SerializedName("product_group_content_id")
private String mProductGroupContentId = null;
@SerializedName("product_group_retailer_id")
private String mProductGroupRetailerId = null;
@SerializedName("product_name")
private String mProductName = null;
@SerializedName("product_retailer_id")
private String mProductRetailerId = null;
@SerializedName("purchase_per_landing_page_view")
private String mPurchasePerLandingPageView = null;
@SerializedName("purchase_roas")
private List mPurchaseRoas = null;
@SerializedName("purchases_per_link_click")
private String mPurchasesPerLinkClick = null;
@SerializedName("qualifying_question_qualify_answer_rate")
private String mQualifyingQuestionQualifyAnswerRate = null;
@SerializedName("quality_ranking")
private String mQualityRanking = null;
@SerializedName("reach")
private String mReach = null;
@SerializedName("result_rate")
private List mResultRate = null;
@SerializedName("result_values_performance_indicator")
private String mResultValuesPerformanceIndicator = null;
@SerializedName("results")
private List mResults = null;
@SerializedName("shops_assisted_purchases")
private String mShopsAssistedPurchases = null;
@SerializedName("social_spend")
private String mSocialSpend = null;
@SerializedName("spend")
private String mSpend = null;
@SerializedName("total_postbacks")
private String mTotalPostbacks = null;
@SerializedName("total_postbacks_detailed")
private List mTotalPostbacksDetailed = null;
@SerializedName("total_postbacks_detailed_v4")
private List mTotalPostbacksDetailedV4 = null;
@SerializedName("unique_actions")
private List mUniqueActions = null;
@SerializedName("unique_clicks")
private String mUniqueClicks = null;
@SerializedName("unique_conversions")
private List mUniqueConversions = null;
@SerializedName("unique_ctr")
private String mUniqueCtr = null;
@SerializedName("unique_inline_link_click_ctr")
private String mUniqueInlineLinkClickCtr = null;
@SerializedName("unique_inline_link_clicks")
private String mUniqueInlineLinkClicks = null;
@SerializedName("unique_link_clicks_ctr")
private String mUniqueLinkClicksCtr = null;
@SerializedName("unique_outbound_clicks")
private List mUniqueOutboundClicks = null;
@SerializedName("unique_outbound_clicks_ctr")
private List mUniqueOutboundClicksCtr = null;
@SerializedName("unique_video_continuous_2_sec_watched_actions")
private List mUniqueVideoContinuous2SecWatchedActions = null;
@SerializedName("unique_video_view_15_sec")
private List mUniqueVideoView15Sec = null;
@SerializedName("updated_time")
private String mUpdatedTime = null;
@SerializedName("video_15_sec_watched_actions")
private List mVideo15SecWatchedActions = null;
@SerializedName("video_30_sec_watched_actions")
private List mVideo30SecWatchedActions = null;
@SerializedName("video_avg_time_watched_actions")
private List mVideoAvgTimeWatchedActions = null;
@SerializedName("video_continuous_2_sec_watched_actions")
private List mVideoContinuous2SecWatchedActions = null;
@SerializedName("video_p100_watched_actions")
private List mVideoP100WatchedActions = null;
@SerializedName("video_p25_watched_actions")
private List mVideoP25WatchedActions = null;
@SerializedName("video_p50_watched_actions")
private List mVideoP50WatchedActions = null;
@SerializedName("video_p75_watched_actions")
private List mVideoP75WatchedActions = null;
@SerializedName("video_p95_watched_actions")
private List mVideoP95WatchedActions = null;
@SerializedName("video_play_actions")
private List mVideoPlayActions = null;
@SerializedName("video_play_curve_actions")
private List mVideoPlayCurveActions = null;
@SerializedName("video_play_retention_0_to_15s_actions")
private List mVideoPlayRetention0To15sActions = null;
@SerializedName("video_play_retention_20_to_60s_actions")
private List mVideoPlayRetention20To60sActions = null;
@SerializedName("video_play_retention_graph_actions")
private List mVideoPlayRetentionGraphActions = null;
@SerializedName("video_thruplay_watched_actions")
private List mVideoThruplayWatchedActions = null;
@SerializedName("video_time_watched_actions")
private List mVideoTimeWatchedActions = null;
@SerializedName("video_view_per_impression")
private List mVideoViewPerImpression = null;
@SerializedName("website_ctr")
private List mWebsiteCtr = null;
@SerializedName("website_purchase_roas")
private List mWebsitePurchaseRoas = null;
@SerializedName("wish_bid")
private String mWishBid = null;
// Breakdowns
@SerializedName("ad_extension_domain")
private String mAdExtensionDomain = null;
@SerializedName("ad_extension_url")
private String mAdExtensionUrl = null;
@SerializedName("ad_format_asset")
private String mAdFormatAsset = null;
@SerializedName("age")
private String mAge = null;
@SerializedName("app_id")
private String mAppId = null;
@SerializedName("body_asset")
private AdAssetBody mBodyAsset = null;
@SerializedName("breakdown_ad_objective")
private String mBreakdownAdObjective = null;
@SerializedName("breakdown_reporting_ad_id")
private String mBreakdownReportingAdId = null;
@SerializedName("call_to_action_asset")
private AdAssetCallToActionType mCallToActionAsset = null;
@SerializedName("coarse_conversion_value")
private String mCoarseConversionValue = null;
@SerializedName("comscore_market")
private String mComscoreMarket = null;
@SerializedName("comscore_market_code")
private String mComscoreMarketCode = null;
@SerializedName("conversion_destination")
private String mConversionDestination = null;
@SerializedName("country")
private String mCountry = null;
@SerializedName("creative_relaxation_asset_type")
private String mCreativeRelaxationAssetType = null;
@SerializedName("description_asset")
private AdAssetDescription mDescriptionAsset = null;
@SerializedName("device_platform")
private String mDevicePlatform = null;
@SerializedName("dma")
private String mDma = null;
@SerializedName("fidelity_type")
private String mFidelityType = null;
@SerializedName("flexible_format_asset_type")
private String mFlexibleFormatAssetType = null;
@SerializedName("frequency_value")
private String mFrequencyValue = null;
@SerializedName("gen_ai_asset_type")
private String mGenAiAssetType = null;
@SerializedName("gender")
private String mGender = null;
@SerializedName("hourly_stats_aggregated_by_advertiser_time_zone")
private String mHourlyStatsAggregatedByAdvertiserTimeZone = null;
@SerializedName("hourly_stats_aggregated_by_audience_time_zone")
private String mHourlyStatsAggregatedByAudienceTimeZone = null;
@SerializedName("hsid")
private String mHsid = null;
@SerializedName("image_asset")
private AdAssetImage mImageAsset = null;
@SerializedName("impression_device")
private String mImpressionDevice = null;
@SerializedName("impression_view_time_advertiser_hour_v2")
private String mImpressionViewTimeAdvertiserHourV2 = null;
@SerializedName("is_auto_advance")
private String mIsAutoAdvance = null;
@SerializedName("is_conversion_id_modeled")
private String mIsConversionIdModeled = null;
@SerializedName("is_rendered_as_delayed_skip_ad")
private String mIsRenderedAsDelayedSkipAd = null;
@SerializedName("landing_destination")
private String mLandingDestination = null;
@SerializedName("link_url_asset")
private AdAssetLinkURL mLinkUrlAsset = null;
@SerializedName("marketing_messages_btn_name")
private String mMarketingMessagesBtnName = null;
@SerializedName("mdsa_landing_destination")
private String mMdsaLandingDestination = null;
@SerializedName("media_asset_url")
private String mMediaAssetUrl = null;
@SerializedName("media_creator")
private String mMediaCreator = null;
@SerializedName("media_destination_url")
private String mMediaDestinationUrl = null;
@SerializedName("media_format")
private String mMediaFormat = null;
@SerializedName("media_origin_url")
private String mMediaOriginUrl = null;
@SerializedName("media_text_content")
private String mMediaTextContent = null;
@SerializedName("media_type")
private String mMediaType = null;
@SerializedName("mmm")
private String mMmm = null;
@SerializedName("place_page_id")
private String mPlacePageId = null;
@SerializedName("platform_position")
private String mPlatformPosition = null;
@SerializedName("postback_sequence_index")
private String mPostbackSequenceIndex = null;
@SerializedName("product_id")
private String mProductId = null;
@SerializedName("publisher_platform")
private String mPublisherPlatform = null;
@SerializedName("redownload")
private String mRedownload = null;
@SerializedName("region")
private String mRegion = null;
@SerializedName("signal_source_bucket")
private String mSignalSourceBucket = null;
@SerializedName("skan_campaign_id")
private String mSkanCampaignId = null;
@SerializedName("skan_conversion_id")
private String mSkanConversionId = null;
@SerializedName("skan_version")
private String mSkanVersion = null;
@SerializedName("sot_attribution_model_type")
private String mSotAttributionModelType = null;
@SerializedName("sot_attribution_window")
private String mSotAttributionWindow = null;
@SerializedName("sot_channel")
private String mSotChannel = null;
@SerializedName("sot_event_type")
private String mSotEventType = null;
@SerializedName("sot_source")
private String mSotSource = null;
@SerializedName("standard_event_content_type")
private String mStandardEventContentType = null;
@SerializedName("title_asset")
private AdAssetTitle mTitleAsset = null;
@SerializedName("user_persona_id")
private String mUserPersonaId = null;
@SerializedName("user_persona_name")
private String mUserPersonaName = null;
@SerializedName("video_asset")
private AdAssetVideo mVideoAsset = null;
protected static Gson gson = null;
public AdsInsights() {
}
public String getId() {
return null;
}
public static AdsInsights loadJSON(String json, APIContext context, String header) {
AdsInsights adsInsights = getGson().fromJson(json, AdsInsights.class);
if (context.isDebug()) {
JsonParser parser = new JsonParser();
JsonElement o1 = parser.parse(json);
JsonElement o2 = parser.parse(adsInsights.toString());
if (o1.getAsJsonObject().get("__fb_trace_id__") != null) {
o2.getAsJsonObject().add("__fb_trace_id__", o1.getAsJsonObject().get("__fb_trace_id__"));
}
if (!o1.equals(o2)) {
context.log("[Warning] When parsing response, object is not consistent with JSON:");
context.log("[JSON]" + o1);
context.log("[Object]" + o2);
}
}
adsInsights.context = context;
adsInsights.rawValue = json;
adsInsights.header = header;
return adsInsights;
}
public static APINodeList parseResponse(String json, APIContext context, APIRequest request, String header) throws MalformedResponseException {
APINodeList adsInsightss = new APINodeList(request, json, header);
JsonArray arr;
JsonObject obj;
JsonParser parser = new JsonParser();
Exception exception = null;
try{
JsonElement result = parser.parse(json);
if (result.isJsonArray()) {
// First, check if it's a pure JSON Array
arr = result.getAsJsonArray();
for (int i = 0; i < arr.size(); i++) {
adsInsightss.add(loadJSON(arr.get(i).getAsJsonObject().toString(), context, header));
};
return adsInsightss;
} else if (result.isJsonObject()) {
obj = result.getAsJsonObject();
if (obj.has("data")) {
if (obj.has("paging")) {
JsonObject paging = obj.get("paging").getAsJsonObject();
if (paging.has("cursors")) {
JsonObject cursors = paging.get("cursors").getAsJsonObject();
String before = cursors.has("before") ? cursors.get("before").getAsString() : null;
String after = cursors.has("after") ? cursors.get("after").getAsString() : null;
adsInsightss.setCursors(before, after);
}
String previous = paging.has("previous") ? paging.get("previous").getAsString() : null;
String next = paging.has("next") ? paging.get("next").getAsString() : null;
adsInsightss.setPaging(previous, next);
if (context.hasAppSecret()) {
adsInsightss.setAppSecret(context.getAppSecretProof());
}
}
if (obj.get("data").isJsonArray()) {
// Second, check if it's a JSON array with "data"
arr = obj.get("data").getAsJsonArray();
for (int i = 0; i < arr.size(); i++) {
adsInsightss.add(loadJSON(arr.get(i).getAsJsonObject().toString(), context, header));
};
} else if (obj.get("data").isJsonObject()) {
// Third, check if it's a JSON object with "data"
obj = obj.get("data").getAsJsonObject();
boolean isRedownload = false;
for (String s : new String[]{"campaigns", "adsets", "ads"}) {
if (obj.has(s)) {
isRedownload = true;
obj = obj.getAsJsonObject(s);
for (Map.Entry entry : obj.entrySet()) {
adsInsightss.add(loadJSON(entry.getValue().toString(), context, header));
}
break;
}
}
if (!isRedownload) {
adsInsightss.add(loadJSON(obj.toString(), context, header));
}
}
return adsInsightss;
} else if (obj.has("images")) {
// Fourth, check if it's a map of image objects
obj = obj.get("images").getAsJsonObject();
for (Map.Entry entry : obj.entrySet()) {
adsInsightss.add(loadJSON(entry.getValue().toString(), context, header));
}
return adsInsightss;
} else {
// Fifth, check if it's an array of objects indexed by id
boolean isIdIndexedArray = true;
for (Map.Entry entry : obj.entrySet()) {
String key = (String) entry.getKey();
if (key.equals("__fb_trace_id__")) {
continue;
}
JsonElement value = (JsonElement) entry.getValue();
if (
value != null &&
value.isJsonObject() &&
value.getAsJsonObject().has("id") &&
value.getAsJsonObject().get("id") != null &&
value.getAsJsonObject().get("id").getAsString().equals(key)
) {
adsInsightss.add(loadJSON(value.toString(), context, header));
} else {
isIdIndexedArray = false;
break;
}
}
if (isIdIndexedArray) {
return adsInsightss;
}
// Sixth, check if it's pure JsonObject
adsInsightss.clear();
adsInsightss.add(loadJSON(json, context, header));
return adsInsightss;
}
}
} catch (Exception e) {
exception = e;
}
throw new MalformedResponseException(
"Invalid response string: " + json,
exception
);
}
@Override
public APIContext getContext() {
return context;
}
@Override
public void setContext(APIContext context) {
this.context = context;
}
@Override
public String toString() {
return getGson().toJson(this);
}
public String getFieldAccountCurrency() {
return mAccountCurrency;
}
public AdsInsights setFieldAccountCurrency(String value) {
this.mAccountCurrency = value;
return this;
}
public String getFieldAccountId() {
return mAccountId;
}
public AdsInsights setFieldAccountId(String value) {
this.mAccountId = value;
return this;
}
public String getFieldAccountName() {
return mAccountName;
}
public AdsInsights setFieldAccountName(String value) {
this.mAccountName = value;
return this;
}
public List getFieldActionValues() {
return mActionValues;
}
public AdsInsights setFieldActionValues(List value) {
this.mActionValues = value;
return this;
}
public AdsInsights setFieldActionValues(String value) {
Type type = new TypeToken>(){}.getType();
this.mActionValues = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldActions() {
return mActions;
}
public AdsInsights setFieldActions(List value) {
this.mActions = value;
return this;
}
public AdsInsights setFieldActions(String value) {
Type type = new TypeToken>(){}.getType();
this.mActions = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldAdClickActions() {
return mAdClickActions;
}
public AdsInsights setFieldAdClickActions(List value) {
this.mAdClickActions = value;
return this;
}
public AdsInsights setFieldAdClickActions(String value) {
Type type = new TypeToken>(){}.getType();
this.mAdClickActions = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public String getFieldAdId() {
return mAdId;
}
public AdsInsights setFieldAdId(String value) {
this.mAdId = value;
return this;
}
public List getFieldAdImpressionActions() {
return mAdImpressionActions;
}
public AdsInsights setFieldAdImpressionActions(List value) {
this.mAdImpressionActions = value;
return this;
}
public AdsInsights setFieldAdImpressionActions(String value) {
Type type = new TypeToken>(){}.getType();
this.mAdImpressionActions = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public String getFieldAdName() {
return mAdName;
}
public AdsInsights setFieldAdName(String value) {
this.mAdName = value;
return this;
}
public String getFieldAdsetEnd() {
return mAdsetEnd;
}
public AdsInsights setFieldAdsetEnd(String value) {
this.mAdsetEnd = value;
return this;
}
public String getFieldAdsetId() {
return mAdsetId;
}
public AdsInsights setFieldAdsetId(String value) {
this.mAdsetId = value;
return this;
}
public String getFieldAdsetName() {
return mAdsetName;
}
public AdsInsights setFieldAdsetName(String value) {
this.mAdsetName = value;
return this;
}
public String getFieldAdsetStart() {
return mAdsetStart;
}
public AdsInsights setFieldAdsetStart(String value) {
this.mAdsetStart = value;
return this;
}
public String getFieldAgeTargeting() {
return mAgeTargeting;
}
public AdsInsights setFieldAgeTargeting(String value) {
this.mAgeTargeting = value;
return this;
}
public String getFieldAttributionSetting() {
return mAttributionSetting;
}
public AdsInsights setFieldAttributionSetting(String value) {
this.mAttributionSetting = value;
return this;
}
public String getFieldAuctionBid() {
return mAuctionBid;
}
public AdsInsights setFieldAuctionBid(String value) {
this.mAuctionBid = value;
return this;
}
public String getFieldAuctionCompetitiveness() {
return mAuctionCompetitiveness;
}
public AdsInsights setFieldAuctionCompetitiveness(String value) {
this.mAuctionCompetitiveness = value;
return this;
}
public String getFieldAuctionMaxCompetitorBid() {
return mAuctionMaxCompetitorBid;
}
public AdsInsights setFieldAuctionMaxCompetitorBid(String value) {
this.mAuctionMaxCompetitorBid = value;
return this;
}
public List getFieldAveragePurchasesConversionValue() {
return mAveragePurchasesConversionValue;
}
public AdsInsights setFieldAveragePurchasesConversionValue(List value) {
this.mAveragePurchasesConversionValue = value;
return this;
}
public AdsInsights setFieldAveragePurchasesConversionValue(String value) {
Type type = new TypeToken>(){}.getType();
this.mAveragePurchasesConversionValue = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public String getFieldBuyingType() {
return mBuyingType;
}
public AdsInsights setFieldBuyingType(String value) {
this.mBuyingType = value;
return this;
}
public String getFieldCampaignId() {
return mCampaignId;
}
public AdsInsights setFieldCampaignId(String value) {
this.mCampaignId = value;
return this;
}
public String getFieldCampaignName() {
return mCampaignName;
}
public AdsInsights setFieldCampaignName(String value) {
this.mCampaignName = value;
return this;
}
public String getFieldCanvasAvgViewPercent() {
return mCanvasAvgViewPercent;
}
public AdsInsights setFieldCanvasAvgViewPercent(String value) {
this.mCanvasAvgViewPercent = value;
return this;
}
public String getFieldCanvasAvgViewTime() {
return mCanvasAvgViewTime;
}
public AdsInsights setFieldCanvasAvgViewTime(String value) {
this.mCanvasAvgViewTime = value;
return this;
}
public List getFieldCatalogSegmentActions() {
return mCatalogSegmentActions;
}
public AdsInsights setFieldCatalogSegmentActions(List value) {
this.mCatalogSegmentActions = value;
return this;
}
public AdsInsights setFieldCatalogSegmentActions(String value) {
Type type = new TypeToken>(){}.getType();
this.mCatalogSegmentActions = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldCatalogSegmentValue() {
return mCatalogSegmentValue;
}
public AdsInsights setFieldCatalogSegmentValue(List value) {
this.mCatalogSegmentValue = value;
return this;
}
public AdsInsights setFieldCatalogSegmentValue(String value) {
Type type = new TypeToken>(){}.getType();
this.mCatalogSegmentValue = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldCatalogSegmentValueMobilePurchaseRoas() {
return mCatalogSegmentValueMobilePurchaseRoas;
}
public AdsInsights setFieldCatalogSegmentValueMobilePurchaseRoas(List value) {
this.mCatalogSegmentValueMobilePurchaseRoas = value;
return this;
}
public AdsInsights setFieldCatalogSegmentValueMobilePurchaseRoas(String value) {
Type type = new TypeToken>(){}.getType();
this.mCatalogSegmentValueMobilePurchaseRoas = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldCatalogSegmentValueOmniPurchaseRoas() {
return mCatalogSegmentValueOmniPurchaseRoas;
}
public AdsInsights setFieldCatalogSegmentValueOmniPurchaseRoas(List value) {
this.mCatalogSegmentValueOmniPurchaseRoas = value;
return this;
}
public AdsInsights setFieldCatalogSegmentValueOmniPurchaseRoas(String value) {
Type type = new TypeToken>(){}.getType();
this.mCatalogSegmentValueOmniPurchaseRoas = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldCatalogSegmentValueWebsitePurchaseRoas() {
return mCatalogSegmentValueWebsitePurchaseRoas;
}
public AdsInsights setFieldCatalogSegmentValueWebsitePurchaseRoas(List value) {
this.mCatalogSegmentValueWebsitePurchaseRoas = value;
return this;
}
public AdsInsights setFieldCatalogSegmentValueWebsitePurchaseRoas(String value) {
Type type = new TypeToken>(){}.getType();
this.mCatalogSegmentValueWebsitePurchaseRoas = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public String getFieldClicks() {
return mClicks;
}
public AdsInsights setFieldClicks(String value) {
this.mClicks = value;
return this;
}
public List getFieldConversionLeadRate() {
return mConversionLeadRate;
}
public AdsInsights setFieldConversionLeadRate(List value) {
this.mConversionLeadRate = value;
return this;
}
public AdsInsights setFieldConversionLeadRate(String value) {
Type type = new TypeToken>(){}.getType();
this.mConversionLeadRate = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConversionLeads() {
return mConversionLeads;
}
public AdsInsights setFieldConversionLeads(List value) {
this.mConversionLeads = value;
return this;
}
public AdsInsights setFieldConversionLeads(String value) {
Type type = new TypeToken>(){}.getType();
this.mConversionLeads = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public String getFieldConversionRateRanking() {
return mConversionRateRanking;
}
public AdsInsights setFieldConversionRateRanking(String value) {
this.mConversionRateRanking = value;
return this;
}
public List getFieldConversionValues() {
return mConversionValues;
}
public AdsInsights setFieldConversionValues(List value) {
this.mConversionValues = value;
return this;
}
public AdsInsights setFieldConversionValues(String value) {
Type type = new TypeToken>(){}.getType();
this.mConversionValues = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConversions() {
return mConversions;
}
public AdsInsights setFieldConversions(List value) {
this.mConversions = value;
return this;
}
public AdsInsights setFieldConversions(String value) {
Type type = new TypeToken>(){}.getType();
this.mConversions = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedProductAppCustomEventFbMobilePurchase() {
return mConvertedProductAppCustomEventFbMobilePurchase;
}
public AdsInsights setFieldConvertedProductAppCustomEventFbMobilePurchase(List value) {
this.mConvertedProductAppCustomEventFbMobilePurchase = value;
return this;
}
public AdsInsights setFieldConvertedProductAppCustomEventFbMobilePurchase(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedProductAppCustomEventFbMobilePurchase = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedProductAppCustomEventFbMobilePurchaseValue() {
return mConvertedProductAppCustomEventFbMobilePurchaseValue;
}
public AdsInsights setFieldConvertedProductAppCustomEventFbMobilePurchaseValue(List value) {
this.mConvertedProductAppCustomEventFbMobilePurchaseValue = value;
return this;
}
public AdsInsights setFieldConvertedProductAppCustomEventFbMobilePurchaseValue(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedProductAppCustomEventFbMobilePurchaseValue = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedProductOfflinePurchase() {
return mConvertedProductOfflinePurchase;
}
public AdsInsights setFieldConvertedProductOfflinePurchase(List value) {
this.mConvertedProductOfflinePurchase = value;
return this;
}
public AdsInsights setFieldConvertedProductOfflinePurchase(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedProductOfflinePurchase = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedProductOfflinePurchaseValue() {
return mConvertedProductOfflinePurchaseValue;
}
public AdsInsights setFieldConvertedProductOfflinePurchaseValue(List value) {
this.mConvertedProductOfflinePurchaseValue = value;
return this;
}
public AdsInsights setFieldConvertedProductOfflinePurchaseValue(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedProductOfflinePurchaseValue = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedProductOmniPurchase() {
return mConvertedProductOmniPurchase;
}
public AdsInsights setFieldConvertedProductOmniPurchase(List value) {
this.mConvertedProductOmniPurchase = value;
return this;
}
public AdsInsights setFieldConvertedProductOmniPurchase(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedProductOmniPurchase = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedProductOmniPurchaseValues() {
return mConvertedProductOmniPurchaseValues;
}
public AdsInsights setFieldConvertedProductOmniPurchaseValues(List value) {
this.mConvertedProductOmniPurchaseValues = value;
return this;
}
public AdsInsights setFieldConvertedProductOmniPurchaseValues(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedProductOmniPurchaseValues = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedProductQuantity() {
return mConvertedProductQuantity;
}
public AdsInsights setFieldConvertedProductQuantity(List value) {
this.mConvertedProductQuantity = value;
return this;
}
public AdsInsights setFieldConvertedProductQuantity(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedProductQuantity = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedProductValue() {
return mConvertedProductValue;
}
public AdsInsights setFieldConvertedProductValue(List value) {
this.mConvertedProductValue = value;
return this;
}
public AdsInsights setFieldConvertedProductValue(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedProductValue = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedProductWebsitePixelPurchase() {
return mConvertedProductWebsitePixelPurchase;
}
public AdsInsights setFieldConvertedProductWebsitePixelPurchase(List value) {
this.mConvertedProductWebsitePixelPurchase = value;
return this;
}
public AdsInsights setFieldConvertedProductWebsitePixelPurchase(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedProductWebsitePixelPurchase = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedProductWebsitePixelPurchaseValue() {
return mConvertedProductWebsitePixelPurchaseValue;
}
public AdsInsights setFieldConvertedProductWebsitePixelPurchaseValue(List value) {
this.mConvertedProductWebsitePixelPurchaseValue = value;
return this;
}
public AdsInsights setFieldConvertedProductWebsitePixelPurchaseValue(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedProductWebsitePixelPurchaseValue = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedPromotedProductAppCustomEventFbMobilePurchase() {
return mConvertedPromotedProductAppCustomEventFbMobilePurchase;
}
public AdsInsights setFieldConvertedPromotedProductAppCustomEventFbMobilePurchase(List value) {
this.mConvertedPromotedProductAppCustomEventFbMobilePurchase = value;
return this;
}
public AdsInsights setFieldConvertedPromotedProductAppCustomEventFbMobilePurchase(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedPromotedProductAppCustomEventFbMobilePurchase = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedPromotedProductAppCustomEventFbMobilePurchaseValue() {
return mConvertedPromotedProductAppCustomEventFbMobilePurchaseValue;
}
public AdsInsights setFieldConvertedPromotedProductAppCustomEventFbMobilePurchaseValue(List value) {
this.mConvertedPromotedProductAppCustomEventFbMobilePurchaseValue = value;
return this;
}
public AdsInsights setFieldConvertedPromotedProductAppCustomEventFbMobilePurchaseValue(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedPromotedProductAppCustomEventFbMobilePurchaseValue = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedPromotedProductOfflinePurchase() {
return mConvertedPromotedProductOfflinePurchase;
}
public AdsInsights setFieldConvertedPromotedProductOfflinePurchase(List value) {
this.mConvertedPromotedProductOfflinePurchase = value;
return this;
}
public AdsInsights setFieldConvertedPromotedProductOfflinePurchase(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedPromotedProductOfflinePurchase = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedPromotedProductOfflinePurchaseValue() {
return mConvertedPromotedProductOfflinePurchaseValue;
}
public AdsInsights setFieldConvertedPromotedProductOfflinePurchaseValue(List value) {
this.mConvertedPromotedProductOfflinePurchaseValue = value;
return this;
}
public AdsInsights setFieldConvertedPromotedProductOfflinePurchaseValue(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedPromotedProductOfflinePurchaseValue = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedPromotedProductOmniPurchase() {
return mConvertedPromotedProductOmniPurchase;
}
public AdsInsights setFieldConvertedPromotedProductOmniPurchase(List value) {
this.mConvertedPromotedProductOmniPurchase = value;
return this;
}
public AdsInsights setFieldConvertedPromotedProductOmniPurchase(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedPromotedProductOmniPurchase = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedPromotedProductOmniPurchaseValues() {
return mConvertedPromotedProductOmniPurchaseValues;
}
public AdsInsights setFieldConvertedPromotedProductOmniPurchaseValues(List value) {
this.mConvertedPromotedProductOmniPurchaseValues = value;
return this;
}
public AdsInsights setFieldConvertedPromotedProductOmniPurchaseValues(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedPromotedProductOmniPurchaseValues = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedPromotedProductQuantity() {
return mConvertedPromotedProductQuantity;
}
public AdsInsights setFieldConvertedPromotedProductQuantity(List value) {
this.mConvertedPromotedProductQuantity = value;
return this;
}
public AdsInsights setFieldConvertedPromotedProductQuantity(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedPromotedProductQuantity = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedPromotedProductValue() {
return mConvertedPromotedProductValue;
}
public AdsInsights setFieldConvertedPromotedProductValue(List value) {
this.mConvertedPromotedProductValue = value;
return this;
}
public AdsInsights setFieldConvertedPromotedProductValue(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedPromotedProductValue = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedPromotedProductWebsitePixelPurchase() {
return mConvertedPromotedProductWebsitePixelPurchase;
}
public AdsInsights setFieldConvertedPromotedProductWebsitePixelPurchase(List value) {
this.mConvertedPromotedProductWebsitePixelPurchase = value;
return this;
}
public AdsInsights setFieldConvertedPromotedProductWebsitePixelPurchase(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedPromotedProductWebsitePixelPurchase = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldConvertedPromotedProductWebsitePixelPurchaseValue() {
return mConvertedPromotedProductWebsitePixelPurchaseValue;
}
public AdsInsights setFieldConvertedPromotedProductWebsitePixelPurchaseValue(List value) {
this.mConvertedPromotedProductWebsitePixelPurchaseValue = value;
return this;
}
public AdsInsights setFieldConvertedPromotedProductWebsitePixelPurchaseValue(String value) {
Type type = new TypeToken>(){}.getType();
this.mConvertedPromotedProductWebsitePixelPurchaseValue = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldCostPer15SecVideoView() {
return mCostPer15SecVideoView;
}
public AdsInsights setFieldCostPer15SecVideoView(List value) {
this.mCostPer15SecVideoView = value;
return this;
}
public AdsInsights setFieldCostPer15SecVideoView(String value) {
Type type = new TypeToken>(){}.getType();
this.mCostPer15SecVideoView = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldCostPer2SecContinuousVideoView() {
return mCostPer2SecContinuousVideoView;
}
public AdsInsights setFieldCostPer2SecContinuousVideoView(List value) {
this.mCostPer2SecContinuousVideoView = value;
return this;
}
public AdsInsights setFieldCostPer2SecContinuousVideoView(String value) {
Type type = new TypeToken>(){}.getType();
this.mCostPer2SecContinuousVideoView = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldCostPerActionType() {
return mCostPerActionType;
}
public AdsInsights setFieldCostPerActionType(List value) {
this.mCostPerActionType = value;
return this;
}
public AdsInsights setFieldCostPerActionType(String value) {
Type type = new TypeToken>(){}.getType();
this.mCostPerActionType = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldCostPerAdClick() {
return mCostPerAdClick;
}
public AdsInsights setFieldCostPerAdClick(List value) {
this.mCostPerAdClick = value;
return this;
}
public AdsInsights setFieldCostPerAdClick(String value) {
Type type = new TypeToken>(){}.getType();
this.mCostPerAdClick = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldCostPerConversion() {
return mCostPerConversion;
}
public AdsInsights setFieldCostPerConversion(List value) {
this.mCostPerConversion = value;
return this;
}
public AdsInsights setFieldCostPerConversion(String value) {
Type type = new TypeToken>(){}.getType();
this.mCostPerConversion = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldCostPerConversionLead() {
return mCostPerConversionLead;
}
public AdsInsights setFieldCostPerConversionLead(List value) {
this.mCostPerConversionLead = value;
return this;
}
public AdsInsights setFieldCostPerConversionLead(String value) {
Type type = new TypeToken>(){}.getType();
this.mCostPerConversionLead = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public String getFieldCostPerDdaCountbyConvs() {
return mCostPerDdaCountbyConvs;
}
public AdsInsights setFieldCostPerDdaCountbyConvs(String value) {
this.mCostPerDdaCountbyConvs = value;
return this;
}
public String getFieldCostPerEstimatedAdRecallers() {
return mCostPerEstimatedAdRecallers;
}
public AdsInsights setFieldCostPerEstimatedAdRecallers(String value) {
this.mCostPerEstimatedAdRecallers = value;
return this;
}
public String getFieldCostPerInlineLinkClick() {
return mCostPerInlineLinkClick;
}
public AdsInsights setFieldCostPerInlineLinkClick(String value) {
this.mCostPerInlineLinkClick = value;
return this;
}
public String getFieldCostPerInlinePostEngagement() {
return mCostPerInlinePostEngagement;
}
public AdsInsights setFieldCostPerInlinePostEngagement(String value) {
this.mCostPerInlinePostEngagement = value;
return this;
}
public List getFieldCostPerObjectiveResult() {
return mCostPerObjectiveResult;
}
public AdsInsights setFieldCostPerObjectiveResult(List value) {
this.mCostPerObjectiveResult = value;
return this;
}
public List getFieldCostPerOneThousandAdImpression() {
return mCostPerOneThousandAdImpression;
}
public AdsInsights setFieldCostPerOneThousandAdImpression(List value) {
this.mCostPerOneThousandAdImpression = value;
return this;
}
public AdsInsights setFieldCostPerOneThousandAdImpression(String value) {
Type type = new TypeToken>(){}.getType();
this.mCostPerOneThousandAdImpression = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldCostPerOutboundClick() {
return mCostPerOutboundClick;
}
public AdsInsights setFieldCostPerOutboundClick(List value) {
this.mCostPerOutboundClick = value;
return this;
}
public AdsInsights setFieldCostPerOutboundClick(String value) {
Type type = new TypeToken>(){}.getType();
this.mCostPerOutboundClick = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldCostPerResult() {
return mCostPerResult;
}
public AdsInsights setFieldCostPerResult(List value) {
this.mCostPerResult = value;
return this;
}
public List getFieldCostPerThruplay() {
return mCostPerThruplay;
}
public AdsInsights setFieldCostPerThruplay(List value) {
this.mCostPerThruplay = value;
return this;
}
public AdsInsights setFieldCostPerThruplay(String value) {
Type type = new TypeToken>(){}.getType();
this.mCostPerThruplay = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldCostPerUniqueActionType() {
return mCostPerUniqueActionType;
}
public AdsInsights setFieldCostPerUniqueActionType(List value) {
this.mCostPerUniqueActionType = value;
return this;
}
public AdsInsights setFieldCostPerUniqueActionType(String value) {
Type type = new TypeToken>(){}.getType();
this.mCostPerUniqueActionType = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public String getFieldCostPerUniqueClick() {
return mCostPerUniqueClick;
}
public AdsInsights setFieldCostPerUniqueClick(String value) {
this.mCostPerUniqueClick = value;
return this;
}
public List getFieldCostPerUniqueConversion() {
return mCostPerUniqueConversion;
}
public AdsInsights setFieldCostPerUniqueConversion(List value) {
this.mCostPerUniqueConversion = value;
return this;
}
public AdsInsights setFieldCostPerUniqueConversion(String value) {
Type type = new TypeToken>(){}.getType();
this.mCostPerUniqueConversion = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public String getFieldCostPerUniqueInlineLinkClick() {
return mCostPerUniqueInlineLinkClick;
}
public AdsInsights setFieldCostPerUniqueInlineLinkClick(String value) {
this.mCostPerUniqueInlineLinkClick = value;
return this;
}
public List getFieldCostPerUniqueOutboundClick() {
return mCostPerUniqueOutboundClick;
}
public AdsInsights setFieldCostPerUniqueOutboundClick(List value) {
this.mCostPerUniqueOutboundClick = value;
return this;
}
public AdsInsights setFieldCostPerUniqueOutboundClick(String value) {
Type type = new TypeToken>(){}.getType();
this.mCostPerUniqueOutboundClick = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public String getFieldCpc() {
return mCpc;
}
public AdsInsights setFieldCpc(String value) {
this.mCpc = value;
return this;
}
public String getFieldCpm() {
return mCpm;
}
public AdsInsights setFieldCpm(String value) {
this.mCpm = value;
return this;
}
public String getFieldCpp() {
return mCpp;
}
public AdsInsights setFieldCpp(String value) {
this.mCpp = value;
return this;
}
public String getFieldCreatedTime() {
return mCreatedTime;
}
public AdsInsights setFieldCreatedTime(String value) {
this.mCreatedTime = value;
return this;
}
public String getFieldCreativeMediaType() {
return mCreativeMediaType;
}
public AdsInsights setFieldCreativeMediaType(String value) {
this.mCreativeMediaType = value;
return this;
}
public String getFieldCtr() {
return mCtr;
}
public AdsInsights setFieldCtr(String value) {
this.mCtr = value;
return this;
}
public String getFieldDateStart() {
return mDateStart;
}
public AdsInsights setFieldDateStart(String value) {
this.mDateStart = value;
return this;
}
public String getFieldDateStop() {
return mDateStop;
}
public AdsInsights setFieldDateStop(String value) {
this.mDateStop = value;
return this;
}
public String getFieldDdaCountbyConvs() {
return mDdaCountbyConvs;
}
public AdsInsights setFieldDdaCountbyConvs(String value) {
this.mDdaCountbyConvs = value;
return this;
}
public List getFieldDdaResults() {
return mDdaResults;
}
public AdsInsights setFieldDdaResults(List value) {
this.mDdaResults = value;
return this;
}
public String getFieldEngagementRateRanking() {
return mEngagementRateRanking;
}
public AdsInsights setFieldEngagementRateRanking(String value) {
this.mEngagementRateRanking = value;
return this;
}
public String getFieldEstimatedAdRecallRate() {
return mEstimatedAdRecallRate;
}
public AdsInsights setFieldEstimatedAdRecallRate(String value) {
this.mEstimatedAdRecallRate = value;
return this;
}
public String getFieldEstimatedAdRecallRateLowerBound() {
return mEstimatedAdRecallRateLowerBound;
}
public AdsInsights setFieldEstimatedAdRecallRateLowerBound(String value) {
this.mEstimatedAdRecallRateLowerBound = value;
return this;
}
public String getFieldEstimatedAdRecallRateUpperBound() {
return mEstimatedAdRecallRateUpperBound;
}
public AdsInsights setFieldEstimatedAdRecallRateUpperBound(String value) {
this.mEstimatedAdRecallRateUpperBound = value;
return this;
}
public String getFieldEstimatedAdRecallers() {
return mEstimatedAdRecallers;
}
public AdsInsights setFieldEstimatedAdRecallers(String value) {
this.mEstimatedAdRecallers = value;
return this;
}
public String getFieldEstimatedAdRecallersLowerBound() {
return mEstimatedAdRecallersLowerBound;
}
public AdsInsights setFieldEstimatedAdRecallersLowerBound(String value) {
this.mEstimatedAdRecallersLowerBound = value;
return this;
}
public String getFieldEstimatedAdRecallersUpperBound() {
return mEstimatedAdRecallersUpperBound;
}
public AdsInsights setFieldEstimatedAdRecallersUpperBound(String value) {
this.mEstimatedAdRecallersUpperBound = value;
return this;
}
public String getFieldFrequency() {
return mFrequency;
}
public AdsInsights setFieldFrequency(String value) {
this.mFrequency = value;
return this;
}
public String getFieldFullViewImpressions() {
return mFullViewImpressions;
}
public AdsInsights setFieldFullViewImpressions(String value) {
this.mFullViewImpressions = value;
return this;
}
public String getFieldFullViewReach() {
return mFullViewReach;
}
public AdsInsights setFieldFullViewReach(String value) {
this.mFullViewReach = value;
return this;
}
public String getFieldGenderTargeting() {
return mGenderTargeting;
}
public AdsInsights setFieldGenderTargeting(String value) {
this.mGenderTargeting = value;
return this;
}
public String getFieldImpressions() {
return mImpressions;
}
public AdsInsights setFieldImpressions(String value) {
this.mImpressions = value;
return this;
}
public String getFieldInlineLinkClickCtr() {
return mInlineLinkClickCtr;
}
public AdsInsights setFieldInlineLinkClickCtr(String value) {
this.mInlineLinkClickCtr = value;
return this;
}
public String getFieldInlineLinkClicks() {
return mInlineLinkClicks;
}
public AdsInsights setFieldInlineLinkClicks(String value) {
this.mInlineLinkClicks = value;
return this;
}
public String getFieldInlinePostEngagement() {
return mInlinePostEngagement;
}
public AdsInsights setFieldInlinePostEngagement(String value) {
this.mInlinePostEngagement = value;
return this;
}
public String getFieldInstagramUpcomingEventRemindersSet() {
return mInstagramUpcomingEventRemindersSet;
}
public AdsInsights setFieldInstagramUpcomingEventRemindersSet(String value) {
this.mInstagramUpcomingEventRemindersSet = value;
return this;
}
public String getFieldInstantExperienceClicksToOpen() {
return mInstantExperienceClicksToOpen;
}
public AdsInsights setFieldInstantExperienceClicksToOpen(String value) {
this.mInstantExperienceClicksToOpen = value;
return this;
}
public String getFieldInstantExperienceClicksToStart() {
return mInstantExperienceClicksToStart;
}
public AdsInsights setFieldInstantExperienceClicksToStart(String value) {
this.mInstantExperienceClicksToStart = value;
return this;
}
public List getFieldInstantExperienceOutboundClicks() {
return mInstantExperienceOutboundClicks;
}
public AdsInsights setFieldInstantExperienceOutboundClicks(List value) {
this.mInstantExperienceOutboundClicks = value;
return this;
}
public AdsInsights setFieldInstantExperienceOutboundClicks(String value) {
Type type = new TypeToken>(){}.getType();
this.mInstantExperienceOutboundClicks = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public List getFieldInteractiveComponentTap() {
return mInteractiveComponentTap;
}
public AdsInsights setFieldInteractiveComponentTap(List value) {
this.mInteractiveComponentTap = value;
return this;
}
public AdsInsights setFieldInteractiveComponentTap(String value) {
Type type = new TypeToken>(){}.getType();
this.mInteractiveComponentTap = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public String getFieldLabels() {
return mLabels;
}
public AdsInsights setFieldLabels(String value) {
this.mLabels = value;
return this;
}
public String getFieldLandingPageViewActionsPerLinkClick() {
return mLandingPageViewActionsPerLinkClick;
}
public AdsInsights setFieldLandingPageViewActionsPerLinkClick(String value) {
this.mLandingPageViewActionsPerLinkClick = value;
return this;
}
public String getFieldLandingPageViewPerLinkClick() {
return mLandingPageViewPerLinkClick;
}
public AdsInsights setFieldLandingPageViewPerLinkClick(String value) {
this.mLandingPageViewPerLinkClick = value;
return this;
}
public String getFieldLandingPageViewPerPurchaseRate() {
return mLandingPageViewPerPurchaseRate;
}
public AdsInsights setFieldLandingPageViewPerPurchaseRate(String value) {
this.mLandingPageViewPerPurchaseRate = value;
return this;
}
public String getFieldLocation() {
return mLocation;
}
public AdsInsights setFieldLocation(String value) {
this.mLocation = value;
return this;
}
public String getFieldMarketingMessagesClickRateBenchmark() {
return mMarketingMessagesClickRateBenchmark;
}
public AdsInsights setFieldMarketingMessagesClickRateBenchmark(String value) {
this.mMarketingMessagesClickRateBenchmark = value;
return this;
}
public String getFieldMarketingMessagesCostPerDelivered() {
return mMarketingMessagesCostPerDelivered;
}
public AdsInsights setFieldMarketingMessagesCostPerDelivered(String value) {
this.mMarketingMessagesCostPerDelivered = value;
return this;
}
public String getFieldMarketingMessagesCostPerLinkBtnClick() {
return mMarketingMessagesCostPerLinkBtnClick;
}
public AdsInsights setFieldMarketingMessagesCostPerLinkBtnClick(String value) {
this.mMarketingMessagesCostPerLinkBtnClick = value;
return this;
}
public String getFieldMarketingMessagesDelivered() {
return mMarketingMessagesDelivered;
}
public AdsInsights setFieldMarketingMessagesDelivered(String value) {
this.mMarketingMessagesDelivered = value;
return this;
}
public String getFieldMarketingMessagesDeliveryRate() {
return mMarketingMessagesDeliveryRate;
}
public AdsInsights setFieldMarketingMessagesDeliveryRate(String value) {
this.mMarketingMessagesDeliveryRate = value;
return this;
}
public String getFieldMarketingMessagesLinkBtnClick() {
return mMarketingMessagesLinkBtnClick;
}
public AdsInsights setFieldMarketingMessagesLinkBtnClick(String value) {
this.mMarketingMessagesLinkBtnClick = value;
return this;
}
public String getFieldMarketingMessagesLinkBtnClickRate() {
return mMarketingMessagesLinkBtnClickRate;
}
public AdsInsights setFieldMarketingMessagesLinkBtnClickRate(String value) {
this.mMarketingMessagesLinkBtnClickRate = value;
return this;
}
public String getFieldMarketingMessagesMediaViewRate() {
return mMarketingMessagesMediaViewRate;
}
public AdsInsights setFieldMarketingMessagesMediaViewRate(String value) {
this.mMarketingMessagesMediaViewRate = value;
return this;
}
public String getFieldMarketingMessagesPhoneCallBtnClickRate() {
return mMarketingMessagesPhoneCallBtnClickRate;
}
public AdsInsights setFieldMarketingMessagesPhoneCallBtnClickRate(String value) {
this.mMarketingMessagesPhoneCallBtnClickRate = value;
return this;
}
public String getFieldMarketingMessagesQuickReplyBtnClick() {
return mMarketingMessagesQuickReplyBtnClick;
}
public AdsInsights setFieldMarketingMessagesQuickReplyBtnClick(String value) {
this.mMarketingMessagesQuickReplyBtnClick = value;
return this;
}
public String getFieldMarketingMessagesQuickReplyBtnClickRate() {
return mMarketingMessagesQuickReplyBtnClickRate;
}
public AdsInsights setFieldMarketingMessagesQuickReplyBtnClickRate(String value) {
this.mMarketingMessagesQuickReplyBtnClickRate = value;
return this;
}
public String getFieldMarketingMessagesRead() {
return mMarketingMessagesRead;
}
public AdsInsights setFieldMarketingMessagesRead(String value) {
this.mMarketingMessagesRead = value;
return this;
}
public String getFieldMarketingMessagesReadRate() {
return mMarketingMessagesReadRate;
}
public AdsInsights setFieldMarketingMessagesReadRate(String value) {
this.mMarketingMessagesReadRate = value;
return this;
}
public String getFieldMarketingMessagesReadRateBenchmark() {
return mMarketingMessagesReadRateBenchmark;
}
public AdsInsights setFieldMarketingMessagesReadRateBenchmark(String value) {
this.mMarketingMessagesReadRateBenchmark = value;
return this;
}
public String getFieldMarketingMessagesSent() {
return mMarketingMessagesSent;
}
public AdsInsights setFieldMarketingMessagesSent(String value) {
this.mMarketingMessagesSent = value;
return this;
}
public String getFieldMarketingMessagesSpend() {
return mMarketingMessagesSpend;
}
public AdsInsights setFieldMarketingMessagesSpend(String value) {
this.mMarketingMessagesSpend = value;
return this;
}
public String getFieldMarketingMessagesSpendCurrency() {
return mMarketingMessagesSpendCurrency;
}
public AdsInsights setFieldMarketingMessagesSpendCurrency(String value) {
this.mMarketingMessagesSpendCurrency = value;
return this;
}
public String getFieldMarketingMessagesWebsiteAddToCart() {
return mMarketingMessagesWebsiteAddToCart;
}
public AdsInsights setFieldMarketingMessagesWebsiteAddToCart(String value) {
this.mMarketingMessagesWebsiteAddToCart = value;
return this;
}
public String getFieldMarketingMessagesWebsiteInitiateCheckout() {
return mMarketingMessagesWebsiteInitiateCheckout;
}
public AdsInsights setFieldMarketingMessagesWebsiteInitiateCheckout(String value) {
this.mMarketingMessagesWebsiteInitiateCheckout = value;
return this;
}
public String getFieldMarketingMessagesWebsitePurchase() {
return mMarketingMessagesWebsitePurchase;
}
public AdsInsights setFieldMarketingMessagesWebsitePurchase(String value) {
this.mMarketingMessagesWebsitePurchase = value;
return this;
}
public String getFieldMarketingMessagesWebsitePurchaseValues() {
return mMarketingMessagesWebsitePurchaseValues;
}
public AdsInsights setFieldMarketingMessagesWebsitePurchaseValues(String value) {
this.mMarketingMessagesWebsitePurchaseValues = value;
return this;
}
public List getFieldMobileAppPurchaseRoas() {
return mMobileAppPurchaseRoas;
}
public AdsInsights setFieldMobileAppPurchaseRoas(List value) {
this.mMobileAppPurchaseRoas = value;
return this;
}
public AdsInsights setFieldMobileAppPurchaseRoas(String value) {
Type type = new TypeToken>(){}.getType();
this.mMobileAppPurchaseRoas = AdsActionStats.getGson().fromJson(value, type);
return this;
}
public String getFieldObjective() {
return mObjective;
}
public AdsInsights setFieldObjective(String value) {
this.mObjective = value;
return this;
}
public List getFieldObjectiveResultRate() {
return mObjectiveResultRate;
}
public AdsInsights setFieldObjectiveResultRate(List value) {
this.mObjectiveResultRate = value;
return this;
}
public List getFieldObjectiveResults() {
return mObjectiveResults;
}
public AdsInsights setFieldObjectiveResults(List value) {
this.mObjectiveResults = value;
return this;
}
public List getFieldOnsiteConversionMessagingDetectedPurchaseDeduped() {
return mOnsiteConversionMessagingDetectedPurchaseDeduped;
}
public AdsInsights setFieldOnsiteConversionMessagingDetectedPurchaseDeduped(List