Campaign data mismatch for same account id


#1

Hello there,

I am getting issue with campaign data for same account id. One of campaign data is coming perfect but for another campaign id’s data is not getting properly. Please help on the same.

Account Id: 18ce53ydbsd (dotspace)
Campaign Id (working); 5vukm (photographers)
Campaign Id (not working): 5r8l6 (outer space)

Please let me know if you need more details.

Thank you


#2

@endevmcc: Thanks for providing the account and campaign IDs. In order to help, we’ll need more information, though.

  • what data are you seeing a discrepancy with?
    • engagement data, billing data, or something else?
  • what is the nature of the discrepancy? what, specifically, is incorrect?
  • what time period are you requesting data for?

Also, please provide the full requests you’re using as well as the responses you’re seeing.


#3

Below are the data those are coming incorrect, code for request and response of the API. Please do let me know if you need more details. Also, let me know if I am doing wrong in request, if any.

Below are the data those are incorrent:
impressions, spend, engagements, clicks, url_clicks

Request Code:

$start_time = “2017-03-02T00:00:00-0400”; //[timezone] => America/New_York // $utc_time = -400
$end_time = “2017-03-03T00:00:00-0400”; //[timezone] => America/New_York // $utc_time = -400

$ACCOUNT_ID = ‘18ce53ydbsd’;// Account Id;
$ACCOUNT_NAME = ‘dotspace’;// Account Name;

// Create twitter ads client
$twitterAds = new TwitterAds(CONSUMER_KEY, CONSUMER_SECRET, ACCESS_TOKEN, ACCESS_TOKEN_SECRET);

//echo “

”;
// load up the account instance, campaign and line item
$account = $twitterAds->getAccounts($ACCOUNT_ID);
//print_r($account);
//$campaign = $account->getCampaigns();

//campaing Id: 5r8l6 - Incorrect data
//campaing Id: 5vukm - Correct data

$ids1 = array(‘5r8l6’,‘5vukm’,‘68kzh’); // Campaing Id
$name1 = array(‘outer space’,‘photographers’,‘co working space’); // Campaing Name
for($i=0;$i<count($ids1); $i++) {

$ids_arr = array($ids1[$i]);
$lineItems = $account->getLineItems("",$ids_arr);

$metrics = [Analytics::ANALYTICS_METRIC_GROUPS_ENGAGEMENT, Analytics::ANALYTICS_METRIC_GROUPS_BILLING, Analytics::ANALYTICS_METRIC_GROUPS_WEB_CONVERSIONS, Analytics::ANALYTICS_METRIC_GROUPS_MOBILE_CONVERSION, Analytics::ANALYTICS_METRIC_GROUPS_VIDEO, Analytics::ANALYTICS_METRIC_GROUPS_MEDIA, Analytics::ANALYTICS_METRIC_GROUPS_LIFE_TIME_VALUE_MOBILE_CONVERSION];

$ids = array_map(
function($o) {
return $o->getId();
},
$lineItems->getCollection()
);

$stats = LineItem::all_stats($account, $ids, $metrics, “”, $start_time, $end_time);

//print_r($stats);

//Stats Calcularion

foreach($stats as $stat)
{
$stat_arr = (array)$stat;

$new_data_arr = (array)$stat_arr['id_data'][0];
$metrics = (array)$new_data_arr['metrics'];

$billed_charge_local_micro = 0;
if(count($metrics['billed_charge_local_micro']) > 0) {
	foreach($metrics['billed_charge_local_micro'] as $key => $value) {
		$billed_charge_local_micro = $billed_charge_local_micro+intval($value);
	}
}
//print_r($metrics['impressions']);
$impressions = 0;
if(count($metrics['impressions']) > 0) {
	foreach($metrics['impressions'] as $key => $value) {
		$impressions = $impressions+intval($value);
	}
}
echo "impressions: ".$impressions."---";
$engagements = 0;
if(count($metrics['impressions']) > 0) {
	foreach($metrics['impressions'] as $key => $value) {
		$engagements = $engagements+intval($value);
	}
}
$spend = 0;
//print_r($metrics['billed_charge_local_micro']);
if(count($metrics['billed_charge_local_micro']) > 0) {
	foreach($metrics['billed_charge_local_micro'] as $key => $value) {
		$spend = $spend+intval($value);
	}
}

$billed_engagements = 0;
if(count($metrics['billed_engagements']) > 0) {
	foreach($metrics['billed_engagements'] as $key => $value) {
		$billed_engagements = $billed_engagements+intval($value);
	}
}
$retweets = 0;
if(count($metrics['retweets']) > 0) {
	foreach($metrics['retweets'] as $key => $value) {
		$retweets = $retweets+intval($value);
	}
}
$replies = 0;
if(count($metrics['replies']) > 0) {
	foreach($metrics['replies'] as $key => $value) {
		$replies = $replies+intval($value);
	}
}
$follows = 0;
if(count($metrics['follows']) > 0) {
	foreach($metrics['follows'] as $key => $value) {
		$follows = $follows+intval($value);
	}
}
$clicks = 0;
if(count($metrics['clicks']) > 0) {
	foreach($metrics['clicks'] as $key => $value) {
		$clicks = $clicks+intval($value);
	}
}
$likes = 0;
if(count($metrics['likes']) > 0) {
	foreach($metrics['likes'] as $key => $value) {
		$likes = $likes+intval($value);
	}
}
$card_engagements = 0;
if(count($metrics['card_engagements']) > 0) {
	foreach($metrics['card_engagements'] as $key => $value) {
		$card_engagements = $card_engagements+intval($value);
	}
}
$url_clicks = 0;
if(count($metrics['url_clicks']) > 0) {
	foreach($metrics['url_clicks'] as $key => $value) {
		$url_clicks = $url_clicks+intval($value);
	}
}
$app_clicks = 0;
if(count($metrics['app_clicks']) > 0) {
	foreach($metrics['app_clicks'] as $key => $value) {
		$app_clicks = $app_clicks+intval($value);
	}
}
$video_content_starts = 0;
if(count($metrics['video_content_starts']) > 0) {
	foreach($metrics['video_content_starts'] as $key => $value) {
		$video_content_starts = $video_content_starts+intval($value);
	}
}
$video_views_25 = 0;
if(count($metrics['video_views_25']) > 0) {
	foreach($metrics['video_views_25'] as $key => $value) {
		$video_views_25 = $video_views_25+intval($value);
	}
}
$video_views_50 = 0;
if(count($metrics['video_views_50']) > 0) {
	foreach($metrics['video_views_50'] as $key => $value) {
		$video_views_50 = $video_views_50+intval($value);
	}
}
$video_views_75 = 0;
if(count($metrics['video_views_75']) > 0) {
	foreach($metrics['video_views_75'] as $key => $value) {
		$video_views_75 = $video_views_75+intval($value);
	}
}
$video_views_100 = 0;
if(count($metrics['video_views_100']) > 0) {
	foreach($metrics['video_views_100'] as $key => $value) {
		$video_views_100 = $video_views_100+intval($value);
	}
}
$video_total_views = count($metrics['video_total_views']);
if(count($metrics['video_total_views']) > 0) {
	foreach($metrics['video_total_views'] as $key => $value) {
		$video_total_views = $video_total_views+intval($value);
	}
}
$leads = count($metrics['card_engagements']);
if(count($metrics['card_engagements']) > 0) {
	foreach($metrics['card_engagements'] as $key => $value) {
		$leads = $leads+intval($value);
	}
}
$pre_roll_video_views = 0;
if(count($metrics['video_mrc_views']) > 0) {
	foreach($metrics['video_mrc_views'] as $key => $value) {
		$pre_roll_video_views = $pre_roll_video_views+intval($value);
	}
}

$engagement_rate = $impressions != '0' && $engagements != '0' ? (double) $engagements / (double) $impressions : '0';
$link_click_rate = $impressions != '0' && $url_clicks != '0' ? (double) $url_clicks / (double) $impressions : '0';
$app_click_rate = $impressions != '0' && $app_clicks != '0' ? (double) $app_clicks / (double) $impressions : '0';
$lead_rate = $impressions != '0' && $card_engagements != '0' ? (double) $card_engagements / (double) $impressions : '0';
$follow_rate = $impressions != '0' && $follows != '0' ? (double) $follows / (double) $impressions : '0';
$cpe = $engagements != '0' && $billed_charge_local_micro != '0' ? (double) $billed_charge_local_micro / (double) $engagements : '0';
$cost_per_link_click = $url_clicks != '0' && $billed_charge_local_micro != '0' ? (double) $billed_charge_local_micro / (double) $url_clicks : '0';
$ecpac = $app_clicks != '0' && $billed_charge_local_micro != '0' ? (double) $billed_charge_local_micro / (double) $app_clicks : '0';
$cost_per_lead = $card_engagements != '0' && $billed_charge_local_micro != '0' ? (double) $billed_charge_local_micro / (double) $card_engagements : '0';
$cpf = $follows != '0' && $billed_charge_local_micro != '0' ? (double) $billed_charge_local_micro / (double) $follows : '0';
$spend_amount = 0;
if($spend > 0) {
	$spend_amount = round(($spend / 1000000),2);
}	
//echo $spend_amount."<br>";
echo "spend: ".$spend_amount;

}

------------------------------------Request code end -----------------------------------


#4

Response Code:

Array ( [0] => stdClass Object ( [id] => 5zyrj [id_data] => Array ( [0] => stdClass Object ( [segment] => [metrics] => stdClass Object ( [video_views_50] => [impressions] => Array ( [0] => 0 [1] => 0 [2] => 1 [3] => 0 [4] => 1 [5] => 24 [6] => 4 [7] => 131 [8] => 341 [9] => 189 [10] => 0 [11] => 0 [12] => 0 [13] => 0 [14] => 0 [15] => 0 [16] => 0 [17] => 0 [18] => 0 [19] => 0 [20] => 0 [21] => 0 [22] => 0 [23] => 0 ) [mobile_conversion_spent_credits] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_installs] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_content_views] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_lifetime_value_tutorials_completed] => stdClass Object ( [metric] => [order_quantity] => [sale_amount] => ) [mobile_conversion_add_to_wishlists] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_lifetime_value_checkouts_initiated] => stdClass Object ( [order_quantity] => [sale_amount] => [metric] => ) [mobile_conversion_lifetime_value_add_to_wishlists] => stdClass Object ( [metric] => [order_quantity] => [sale_amount] => ) [mobile_conversion_lifetime_value_logins] => stdClass Object ( [metric] => [sale_amount] => [order_quantity] => ) [mobile_conversion_checkouts_initiated] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [tweets_send] => [conversion_purchases] => stdClass Object ( [order_quantity_engagement] => [sale_amount_engagement] => [sale_amount_view] => [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => [metric] => [order_quantity_view] => ) [mobile_conversion_reservations] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_tutorials_completed] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [billed_charge_local_micro] => [qualified_impressions] => [video_views_75] => [conversion_sign_ups] => stdClass Object ( [order_quantity_engagement] => [sale_amount_engagement] => [sale_amount_view] => [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => [metric] => [order_quantity_view] => ) [media_engagements] => [follows] => [mobile_conversion_achievements_unlocked] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_lifetime_value_add_to_carts] => stdClass Object ( [metric] => [order_quantity] => [sale_amount] => ) [video_3s100pct_views] => [app_clicks] => [mobile_conversion_lifetime_value_sign_ups] => stdClass Object ( [sale_amount] => [order_quantity] => [metric] => ) [mobile_conversion_searches] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_lifetime_value_spent_credits] => stdClass Object ( [metric] => [sale_amount] => [order_quantity] => ) [mobile_conversion_site_visits] => stdClass Object ( [order_quantity] => [post_view] => [post_engagement] => [sale_amount] => ) [retweets] => [mobile_conversion_key_page_views] => stdClass Object ( [post_engagement] => [post_view] => ) [video_cta_clicks] => [mobile_conversion_lifetime_value_achievements_unlocked] => stdClass Object ( [order_quantity] => [metric] => [sale_amount] => ) [likes] => [mobile_conversion_add_to_carts] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_payment_info_additions] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_re_engages] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [video_content_starts] => [mobile_conversion_lifetime_value_updates] => stdClass Object ( [metric] => [sale_amount] => [order_quantity] => ) [video_views_25] => [mobile_conversion_shares] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [conversion_site_visits] => stdClass Object ( [order_quantity_engagement] => [sale_amount_engagement] => [sale_amount_view] => [post_view] => [order_quantity] => [post_engagement] => [sale_amount] => [metric] => [order_quantity_view] => ) [mobile_conversion_lifetime_value_content_views] => stdClass Object ( [order_quantity] => [metric] => [sale_amount] => ) [mobile_conversion_lifetime_value_invites] => stdClass Object ( [sale_amount] => [order_quantity] => [metric] => ) [engagements] => Array ( [0] => 0 [1] => 0 [2] => 0 [3] => 0 [4] => 0 [5] => 0 [6] => 0 [7] => 0 [8] => 1 [9] => 0 [10] => 0 [11] => 0 [12] => 0 [13] => 0 [14] => 0 [15] => 0 [16] => 0 [17] => 0 [18] => 0 [19] => 0 [20] => 0 [21] => 0 [22] => 0 [23] => 0 ) [mobile_conversion_lifetime_value_shares] => stdClass Object ( [sale_amount] => [order_quantity] => [metric] => ) [conversion_custom] => stdClass Object ( [order_quantity_engagement] => [sale_amount_engagement] => [sale_amount_view] => [post_view] => [order_quantity] => [post_engagement] => [sale_amount] => [metric] => [order_quantity_view] => ) [video_views_100] => [mobile_conversion_lifetime_value_searches] => stdClass Object ( [sale_amount] => [metric] => [order_quantity] => ) [mobile_conversion_lifetime_value_purchases] => stdClass Object ( [metric] => [order_quantity] => [sale_amount] => ) [clicks] => Array ( [0] => 0 [1] => 0 [2] => 0 [3] => 0 [4] => 0 [5] => 0 [6] => 0 [7] => 0 [8] => 1 [9] => 0 [10] => 0 [11] => 0 [12] => 0 [13] => 0 [14] => 0 [15] => 0 [16] => 0 [17] => 0 [18] => 0 [19] => 0 [20] => 0 [21] => 0 [22] => 0 [23] => 0 ) [mobile_conversion_sign_ups] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [media_views] => [card_engagements] => [mobile_conversion_lifetime_value_reservations] => stdClass Object ( [sale_amount] => [metric] => [order_quantity] => ) [mobile_conversion_lifetime_value_rates] => stdClass Object ( [order_quantity] => [metric] => [sale_amount] => ) [replies] => [mobile_conversion_lifetime_value_levels_achieved] => stdClass Object ( [sale_amount] => [order_quantity] => [metric] => ) [url_clicks] => [video_mrc_views] => [mobile_conversion_purchases] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_rates] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_logins] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [billed_engagements] => [mobile_conversion_updates] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_lifetime_value_payment_info_additions] => stdClass Object ( [sale_amount] => [metric] => [order_quantity] => ) [conversion_downloads] => stdClass Object ( [order_quantity_engagement] => [sale_amount_engagement] => [sale_amount_view] => [post_view] => [order_quantity] => [post_engagement] => [sale_amount] => [metric] => [order_quantity_view] => ) [mobile_conversion_levels_achieved] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_downloads] => stdClass Object ( [post_view] => [post_engagement] => [order_quantity] => [sale_amount] => ) [video_total_views] => [mobile_conversion_invites] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [carousel_swipes] => ) ) ) ) ) impressions: 691—spend: 0INSERT INTO twitter_report5(account_id, account_name, campaign_id, campaign_name, is_engagement, campaign_url, funding_instrument_id, funding_instrument_name, date, campaign_start_date, campaign_end_date, spend, impressions, engagements, billed_engagements, retweets, replies, follows, clicks, media_engagements, likes, card_engagements, unfollows, engagement_rate, link_clicks, app_clicks, leads, link_click_rate, app_click_rate, lead_rate, follow_rate, call_to_action, video_starts, video_played_25, video_played_50, video_played_75, video_completions, video_views, ecpe, cpe, cost_per_link_click, ecpac, cost_per_lead, cpf, product_type, currency, current_remaining_budget, current_bid, current_campaign_daily_budget, current_total_budget, site_visits_engage, site_visits_view, site_visits_engage_sale_amount, site_visits_view_sale_amount, site_visits_engage_order_quantity, site_visits_view_order_quantity, pre_roll_video_starts, pre_roll_video_played_25, pre_roll_video_played_50, pre_roll_video_played_75, video_played_100, pre_roll_video_completions, pre_roll_video_views) VALUES (‘18ce53ydbsd’,‘dotspace’,‘5r8l6’,‘outer space’,‘0’,‘0’,‘j2atq’,‘0’,‘2017-03-02’,‘2015-03-12 15:16:00’,‘0000-00-00 00:00:00’,‘0’,‘691’,‘691’,‘0’,‘0’,‘0’,‘0’,‘1’,‘0’,‘0’,‘0’,‘0’,‘1’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’)

Array ( [0] => stdClass Object ( [id] => 659hh [id_data] => Array ( [0] => stdClass Object ( [segment] => [metrics] => stdClass Object ( [video_views_50] => [impressions] => Array ( [0] => 0 [1] => 0 [2] => 710 [3] => 0 [4] => 0 [5] => 29 [6] => 186 [7] => 525 [8] => 1138 [9] => 835 [10] => 542 [11] => 407 [12] => 710 [13] => 11 [14] => 0 [15] => 0 [16] => 0 [17] => 0 [18] => 0 [19] => 0 [20] => 0 [21] => 0 [22] => 0 [23] => 0 ) [mobile_conversion_spent_credits] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_installs] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_content_views] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_lifetime_value_tutorials_completed] => stdClass Object ( [metric] => [order_quantity] => [sale_amount] => ) [mobile_conversion_add_to_wishlists] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_lifetime_value_checkouts_initiated] => stdClass Object ( [order_quantity] => [sale_amount] => [metric] => ) [mobile_conversion_lifetime_value_add_to_wishlists] => stdClass Object ( [metric] => [order_quantity] => [sale_amount] => ) [mobile_conversion_lifetime_value_logins] => stdClass Object ( [metric] => [sale_amount] => [order_quantity] => ) [mobile_conversion_checkouts_initiated] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [tweets_send] => [conversion_purchases] => stdClass Object ( [order_quantity_engagement] => [sale_amount_engagement] => [sale_amount_view] => [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => [metric] => [order_quantity_view] => ) [mobile_conversion_reservations] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_tutorials_completed] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [billed_charge_local_micro] => Array ( [0] => 0 [1] => 0 [2] => 3822614 [3] => 0 [4] => 0 [5] => 0 [6] => 861056 [7] => 965764 [8] => 8732123 [9] => 4454412 [10] => 1164031 [11] => 0 [12] => 0 [13] => 0 [14] => 0 [15] => 0 [16] => 0 [17] => 0 [18] => 0 [19] => 0 [20] => 0 [21] => 0 [22] => 0 [23] => 0 ) [qualified_impressions] => [video_views_75] => [conversion_sign_ups] => stdClass Object ( [order_quantity_engagement] => [sale_amount_engagement] => [sale_amount_view] => [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => [metric] => [order_quantity_view] => ) [media_engagements] => [follows] => [mobile_conversion_achievements_unlocked] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_lifetime_value_add_to_carts] => stdClass Object ( [metric] => [order_quantity] => [sale_amount] => ) [video_3s100pct_views] => [app_clicks] => [mobile_conversion_lifetime_value_sign_ups] => stdClass Object ( [sale_amount] => [order_quantity] => [metric] => ) [mobile_conversion_searches] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_lifetime_value_spent_credits] => stdClass Object ( [metric] => [sale_amount] => [order_quantity] => ) [mobile_conversion_site_visits] => stdClass Object ( [order_quantity] => [post_view] => [post_engagement] => [sale_amount] => ) [retweets] => [mobile_conversion_key_page_views] => stdClass Object ( [post_engagement] => [post_view] => ) [video_cta_clicks] => [mobile_conversion_lifetime_value_achievements_unlocked] => stdClass Object ( [order_quantity] => [metric] => [sale_amount] => ) [likes] => Array ( [0] => 0 [1] => 0 [2] => 0 [3] => 0 [4] => 0 [5] => 0 [6] => 0 [7] => 1 [8] => 0 [9] => 0 [10] => 0 [11] => 0 [12] => 0 [13] => 0 [14] => 0 [15] => 0 [16] => 0 [17] => 0 [18] => 0 [19] => 0 [20] => 0 [21] => 0 [22] => 0 [23] => 0 ) [mobile_conversion_add_to_carts] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_payment_info_additions] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_re_engages] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [video_content_starts] => [mobile_conversion_lifetime_value_updates] => stdClass Object ( [metric] => [sale_amount] => [order_quantity] => ) [video_views_25] => [mobile_conversion_shares] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [conversion_site_visits] => stdClass Object ( [order_quantity_engagement] => [sale_amount_engagement] => [sale_amount_view] => [post_view] => [order_quantity] => [post_engagement] => [sale_amount] => [metric] => [order_quantity_view] => ) [mobile_conversion_lifetime_value_content_views] => stdClass Object ( [order_quantity] => [metric] => [sale_amount] => ) [mobile_conversion_lifetime_value_invites] => stdClass Object ( [sale_amount] => [order_quantity] => [metric] => ) [engagements] => Array ( [0] => 0 [1] => 0 [2] => 4 [3] => 0 [4] => 0 [5] => 0 [6] => 2 [7] => 6 [8] => 13 [9] => 3 [10] => 2 [11] => 1 [12] => 3 [13] => 0 [14] => 0 [15] => 0 [16] => 0 [17] => 0 [18] => 0 [19] => 0 [20] => 0 [21] => 0 [22] => 0 [23] => 0 ) [mobile_conversion_lifetime_value_shares] => stdClass Object ( [sale_amount] => [order_quantity] => [metric] => ) [conversion_custom] => stdClass Object ( [order_quantity_engagement] => [sale_amount_engagement] => [sale_amount_view] => [post_view] => [order_quantity] => [post_engagement] => [sale_amount] => [metric] => [order_quantity_view] => ) [video_views_100] => [mobile_conversion_lifetime_value_searches] => stdClass Object ( [sale_amount] => [metric] => [order_quantity] => ) [mobile_conversion_lifetime_value_purchases] => stdClass Object ( [metric] => [order_quantity] => [sale_amount] => ) [clicks] => Array ( [0] => 0 [1] => 0 [2] => 4 [3] => 0 [4] => 0 [5] => 0 [6] => 2 [7] => 6 [8] => 13 [9] => 3 [10] => 2 [11] => 1 [12] => 3 [13] => 0 [14] => 0 [15] => 0 [16] => 0 [17] => 0 [18] => 0 [19] => 0 [20] => 0 [21] => 0 [22] => 0 [23] => 0 ) [mobile_conversion_sign_ups] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [media_views] => [card_engagements] => [mobile_conversion_lifetime_value_reservations] => stdClass Object ( [sale_amount] => [metric] => [order_quantity] => ) [mobile_conversion_lifetime_value_rates] => stdClass Object ( [order_quantity] => [metric] => [sale_amount] => ) [replies] => [mobile_conversion_lifetime_value_levels_achieved] => stdClass Object ( [sale_amount] => [order_quantity] => [metric] => ) [url_clicks] => Array ( [0] => 0 [1] => 0 [2] => 2 [3] => 0 [4] => 0 [5] => 0 [6] => 1 [7] => 1 [8] => 6 [9] => 2 [10] => 1 [11] => 0 [12] => 1 [13] => 0 [14] => 0 [15] => 0 [16] => 0 [17] => 0 [18] => 0 [19] => 0 [20] => 0 [21] => 0 [22] => 0 [23] => 0 ) [video_mrc_views] => [mobile_conversion_purchases] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_rates] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_logins] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [billed_engagements] => Array ( [0] => 0 [1] => 0 [2] => 2 [3] => 0 [4] => 0 [5] => 0 [6] => 1 [7] => 1 [8] => 4 [9] => 2 [10] => 1 [11] => 0 [12] => 0 [13] => 0 [14] => 0 [15] => 0 [16] => 0 [17] => 0 [18] => 0 [19] => 0 [20] => 0 [21] => 0 [22] => 0 [23] => 0 ) [mobile_conversion_updates] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_lifetime_value_payment_info_additions] => stdClass Object ( [sale_amount] => [metric] => [order_quantity] => ) [conversion_downloads] => stdClass Object ( [order_quantity_engagement] => [sale_amount_engagement] => [sale_amount_view] => [post_view] => [order_quantity] => [post_engagement] => [sale_amount] => [metric] => [order_quantity_view] => ) [mobile_conversion_levels_achieved] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_downloads] => stdClass Object ( [post_view] => [post_engagement] => [order_quantity] => [sale_amount] => ) [video_total_views] => [mobile_conversion_invites] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [carousel_swipes] => ) ) ) ) ) impressions: 5093—spend: 20INSERT INTO twitter_report5(account_id, account_name, campaign_id, campaign_name, is_engagement, campaign_url, funding_instrument_id, funding_instrument_name, date, campaign_start_date, campaign_end_date, spend, impressions, engagements, billed_engagements, retweets, replies, follows, clicks, media_engagements, likes, card_engagements, unfollows, engagement_rate, link_clicks, app_clicks, leads, link_click_rate, app_click_rate, lead_rate, follow_rate, call_to_action, video_starts, video_played_25, video_played_50, video_played_75, video_completions, video_views, ecpe, cpe, cost_per_link_click, ecpac, cost_per_lead, cpf, product_type, currency, current_remaining_budget, current_bid, current_campaign_daily_budget, current_total_budget, site_visits_engage, site_visits_view, site_visits_engage_sale_amount, site_visits_view_sale_amount, site_visits_engage_order_quantity, site_visits_view_order_quantity, pre_roll_video_starts, pre_roll_video_played_25, pre_roll_video_played_50, pre_roll_video_played_75, video_played_100, pre_roll_video_completions, pre_roll_video_views) VALUES (‘18ce53ydbsd’,‘dotspace’,‘5vukm’,‘photographers’,‘0’,‘0’,‘j2atq’,‘0’,‘2017-03-02’,‘2015-06-23 14:23:00’,‘0000-00-00 00:00:00’,‘20’,‘5093’,‘5093’,‘11’,‘0’,‘0’,‘0’,‘34’,‘0’,‘1’,‘0’,‘0’,‘1’,‘14’,‘0’,‘0’,‘0.002748870999411’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘3926.9585705871’,‘1428571.4285714’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’)

Array ( [0] => stdClass Object ( [id] => 6jiiu [id_data] => Array ( [0] => stdClass Object ( [segment] => [metrics] => stdClass Object ( [video_views_50] => [impressions] => Array ( [0] => 95 [1] => 0 [2] => 62 [3] => 142 [4] => 102 [5] => 97 [6] => 108 [7] => 97 [8] => 134 [9] => 120 [10] => 159 [11] => 165 [12] => 173 [13] => 188 [14] => 195 [15] => 222 [16] => 225 [17] => 248 [18] => 231 [19] => 196 [20] => 117 [21] => 125 [22] => 131 [23] => 134 ) [mobile_conversion_spent_credits] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_installs] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_content_views] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_lifetime_value_tutorials_completed] => stdClass Object ( [metric] => [order_quantity] => [sale_amount] => ) [mobile_conversion_add_to_wishlists] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_lifetime_value_checkouts_initiated] => stdClass Object ( [order_quantity] => [sale_amount] => [metric] => ) [mobile_conversion_lifetime_value_add_to_wishlists] => stdClass Object ( [metric] => [order_quantity] => [sale_amount] => ) [mobile_conversion_lifetime_value_logins] => stdClass Object ( [metric] => [sale_amount] => [order_quantity] => ) [mobile_conversion_checkouts_initiated] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [tweets_send] => [conversion_purchases] => stdClass Object ( [order_quantity_engagement] => [sale_amount_engagement] => [sale_amount_view] => [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => [metric] => [order_quantity_view] => ) [mobile_conversion_reservations] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_tutorials_completed] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [billed_charge_local_micro] => Array ( [0] => 0 [1] => 0 [2] => 0 [3] => 0 [4] => 0 [5] => 0 [6] => 2250000 [7] => 0 [8] => 2250000 [9] => 0 [10] => 0 [11] => 0 [12] => 0 [13] => 0 [14] => 0 [15] => 0 [16] => 0 [17] => 0 [18] => 2250000 [19] => 0 [20] => 0 [21] => 0 [22] => 2250000 [23] => 0 ) [qualified_impressions] => [video_views_75] => [conversion_sign_ups] => stdClass Object ( [order_quantity_engagement] => [sale_amount_engagement] => [sale_amount_view] => [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => [metric] => [order_quantity_view] => ) [media_engagements] => [follows] => [mobile_conversion_achievements_unlocked] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_lifetime_value_add_to_carts] => stdClass Object ( [metric] => [order_quantity] => [sale_amount] => ) [video_3s100pct_views] => [app_clicks] => [mobile_conversion_lifetime_value_sign_ups] => stdClass Object ( [sale_amount] => [order_quantity] => [metric] => ) [mobile_conversion_searches] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_lifetime_value_spent_credits] => stdClass Object ( [metric] => [sale_amount] => [order_quantity] => ) [mobile_conversion_site_visits] => stdClass Object ( [order_quantity] => [post_view] => [post_engagement] => [sale_amount] => ) [retweets] => [mobile_conversion_key_page_views] => stdClass Object ( [post_engagement] => [post_view] => ) [video_cta_clicks] => [mobile_conversion_lifetime_value_achievements_unlocked] => stdClass Object ( [order_quantity] => [metric] => [sale_amount] => ) [likes] => Array ( [0] => 0 [1] => 0 [2] => 0 [3] => 0 [4] => 0 [5] => 0 [6] => 0 [7] => 0 [8] => 0 [9] => 0 [10] => 0 [11] => 0 [12] => 1 [13] => 0 [14] => 0 [15] => 0 [16] => 0 [17] => 0 [18] => 0 [19] => 0 [20] => 0 [21] => 0 [22] => 0 [23] => 0 ) [mobile_conversion_add_to_carts] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_payment_info_additions] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_re_engages] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [video_content_starts] => [mobile_conversion_lifetime_value_updates] => stdClass Object ( [metric] => [sale_amount] => [order_quantity] => ) [video_views_25] => [mobile_conversion_shares] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [conversion_site_visits] => stdClass Object ( [order_quantity_engagement] => [sale_amount_engagement] => [sale_amount_view] => [post_view] => [order_quantity] => [post_engagement] => [sale_amount] => [metric] => [order_quantity_view] => ) [mobile_conversion_lifetime_value_content_views] => stdClass Object ( [order_quantity] => [metric] => [sale_amount] => ) [mobile_conversion_lifetime_value_invites] => stdClass Object ( [sale_amount] => [order_quantity] => [metric] => ) [engagements] => Array ( [0] => 0 [1] => 0 [2] => 0 [3] => 1 [4] => 1 [5] => 0 [6] => 2 [7] => 1 [8] => 1 [9] => 1 [10] => 0 [11] => 0 [12] => 1 [13] => 1 [14] => 0 [15] => 1 [16] => 3 [17] => 2 [18] => 2 [19] => 0 [20] => 0 [21] => 0 [22] => 1 [23] => 0 ) [mobile_conversion_lifetime_value_shares] => stdClass Object ( [sale_amount] => [order_quantity] => [metric] => ) [conversion_custom] => stdClass Object ( [order_quantity_engagement] => [sale_amount_engagement] => [sale_amount_view] => [post_view] => [order_quantity] => [post_engagement] => [sale_amount] => [metric] => [order_quantity_view] => ) [video_views_100] => [mobile_conversion_lifetime_value_searches] => stdClass Object ( [sale_amount] => [metric] => [order_quantity] => ) [mobile_conversion_lifetime_value_purchases] => stdClass Object ( [metric] => [order_quantity] => [sale_amount] => ) [clicks] => Array ( [0] => 0 [1] => 0 [2] => 0 [3] => 1 [4] => 1 [5] => 0 [6] => 2 [7] => 1 [8] => 1 [9] => 1 [10] => 0 [11] => 0 [12] => 1 [13] => 1 [14] => 0 [15] => 1 [16] => 3 [17] => 2 [18] => 2 [19] => 0 [20] => 0 [21] => 0 [22] => 1 [23] => 0 ) [mobile_conversion_sign_ups] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [media_views] => [card_engagements] => [mobile_conversion_lifetime_value_reservations] => stdClass Object ( [sale_amount] => [metric] => [order_quantity] => ) [mobile_conversion_lifetime_value_rates] => stdClass Object ( [order_quantity] => [metric] => [sale_amount] => ) [replies] => [mobile_conversion_lifetime_value_levels_achieved] => stdClass Object ( [sale_amount] => [order_quantity] => [metric] => ) [url_clicks] => Array ( [0] => 0 [1] => 0 [2] => 0 [3] => 0 [4] => 0 [5] => 0 [6] => 1 [7] => 0 [8] => 1 [9] => 0 [10] => 0 [11] => 0 [12] => 0 [13] => 0 [14] => 0 [15] => 0 [16] => 0 [17] => 0 [18] => 1 [19] => 0 [20] => 0 [21] => 0 [22] => 1 [23] => 0 ) [video_mrc_views] => [mobile_conversion_purchases] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_rates] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_logins] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [billed_engagements] => Array ( [0] => 0 [1] => 0 [2] => 0 [3] => 0 [4] => 0 [5] => 0 [6] => 1 [7] => 0 [8] => 1 [9] => 0 [10] => 0 [11] => 0 [12] => 0 [13] => 0 [14] => 0 [15] => 0 [16] => 0 [17] => 0 [18] => 1 [19] => 0 [20] => 0 [21] => 0 [22] => 1 [23] => 0 ) [mobile_conversion_updates] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_lifetime_value_payment_info_additions] => stdClass Object ( [sale_amount] => [metric] => [order_quantity] => ) [conversion_downloads] => stdClass Object ( [order_quantity_engagement] => [sale_amount_engagement] => [sale_amount_view] => [post_view] => [order_quantity] => [post_engagement] => [sale_amount] => [metric] => [order_quantity_view] => ) [mobile_conversion_levels_achieved] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [mobile_conversion_downloads] => stdClass Object ( [post_view] => [post_engagement] => [order_quantity] => [sale_amount] => ) [video_total_views] => [mobile_conversion_invites] => stdClass Object ( [post_view] => [order_quantity] => [assisted] => [post_engagement] => [sale_amount] => ) [carousel_swipes] => ) ) ) ) ) impressions: 3466—spend: 9INSERT INTO twitter_report5(account_id, account_name, campaign_id, campaign_name, is_engagement, campaign_url, funding_instrument_id, funding_instrument_name, date, campaign_start_date, campaign_end_date, spend, impressions, engagements, billed_engagements, retweets, replies, follows, clicks, media_engagements, likes, card_engagements, unfollows, engagement_rate, link_clicks, app_clicks, leads, link_click_rate, app_click_rate, lead_rate, follow_rate, call_to_action, video_starts, video_played_25, video_played_50, video_played_75, video_completions, video_views, ecpe, cpe, cost_per_link_click, ecpac, cost_per_lead, cpf, product_type, currency, current_remaining_budget, current_bid, current_campaign_daily_budget, current_total_budget, site_visits_engage, site_visits_view, site_visits_engage_sale_amount, site_visits_view_sale_amount, site_visits_engage_order_quantity, site_visits_view_order_quantity, pre_roll_video_starts, pre_roll_video_played_25, pre_roll_video_played_50, pre_roll_video_played_75, video_played_100, pre_roll_video_completions, pre_roll_video_views) VALUES (‘18ce53ydbsd’,‘dotspace’,‘68kzh’,‘co working space’,‘0’,‘0’,‘j2atq’,‘0’,‘2017-03-02’,‘2015-06-23 14:29:00’,‘0000-00-00 00:00:00’,‘9’,‘3466’,‘3466’,‘4’,‘0’,‘0’,‘0’,‘18’,‘0’,‘1’,‘0’,‘0’,‘1’,‘4’,‘0’,‘0’,‘0.0011540680900173’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘2596.6532025389’,‘2250000’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’,‘0’)


#5

@juanshishido kindly check and advise how we can resolve this.


#6

@endevmcc: This is very, very difficult to read. Please format so we can help.


#7

@endevmcc Just for future reference, please use the triple back tick notation for any code blocks or samples. The forum supports the entire markdown syntax set.

Thanks!


#8

Campaign Name: outer space
Campaign Id: 5r8l6
Below response:

   Array
(
    [0] => stdClass Object
        (
            [id] => 5zyrj
            [id_data] => Array
                (
                    [0] => stdClass Object
                        (
                            [segment] => 
                            [metrics] => stdClass Object
                                (
                                    [video_views_50] => 
                                    [impressions] => Array
                                        (
                                            [0] => 0
                                            [1] => 0
                                            [2] => 1
                                            [3] => 0
                                            [4] => 1
                                            [5] => 24
                                            [6] => 4
                                            [7] => 131
                                            [8] => 341
                                            [9] => 189
                                            [10] => 0
                                            [11] => 0
                                            [12] => 0
                                            [13] => 0
                                            [14] => 0
                                            [15] => 0
                                            [16] => 0
                                            [17] => 0
                                            [18] => 0
                                            [19] => 0
                                            [20] => 0
                                            [21] => 0
                                            [22] => 0
                                            [23] => 0
                                        )

                                    [mobile_conversion_spent_credits] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_installs] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_content_views] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_lifetime_value_tutorials_completed] => stdClass Object
                                        (
                                            [metric] => 
                                            [order_quantity] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_add_to_wishlists] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_lifetime_value_checkouts_initiated] => stdClass Object
                                        (
                                            [order_quantity] => 
                                            [sale_amount] => 
                                            [metric] => 
                                        )

                                    [mobile_conversion_lifetime_value_add_to_wishlists] => stdClass Object
                                        (
                                            [metric] => 
                                            [order_quantity] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_lifetime_value_logins] => stdClass Object
                                        (
                                            [metric] => 
                                            [sale_amount] => 
                                            [order_quantity] => 
                                        )

                                    [mobile_conversion_checkouts_initiated] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [tweets_send] => 
                                    [conversion_purchases] => stdClass Object
                                        (
                                            [order_quantity_engagement] => 
                                            [sale_amount_engagement] => 
                                            [sale_amount_view] => 
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                            [metric] => 
                                            [order_quantity_view] => 
                                        )

                                    [mobile_conversion_reservations] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_tutorials_completed] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [billed_charge_local_micro] => 
                                    [qualified_impressions] => 
                                    [video_views_75] => 
                                    [conversion_sign_ups] => stdClass Object
                                        (
                                            [order_quantity_engagement] => 
                                            [sale_amount_engagement] => 
                                            [sale_amount_view] => 
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                            [metric] => 
                                            [order_quantity_view] => 
                                        )

                                    [media_engagements] => 
                                    [follows] => 
                                    [mobile_conversion_achievements_unlocked] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_lifetime_value_add_to_carts] => stdClass Object
                                        (
                                            [metric] => 
                                            [order_quantity] => 
                                            [sale_amount] => 
                                        )

                                    [video_3s100pct_views] => 
                                    [app_clicks] => 
                                    [mobile_conversion_lifetime_value_sign_ups] => stdClass Object
                                        (
                                            [sale_amount] => 
                                            [order_quantity] => 
                                            [metric] => 
                                        )

                                    [mobile_conversion_searches] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_lifetime_value_spent_credits] => stdClass Object
                                        (
                                            [metric] => 
                                            [sale_amount] => 
                                            [order_quantity] => 
                                        )

                                    [mobile_conversion_site_visits] => stdClass Object
                                        (
                                            [order_quantity] => 
                                            [post_view] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [retweets] => 
                                    [mobile_conversion_key_page_views] => stdClass Object
                                        (
                                            [post_engagement] => 
                                            [post_view] => 
                                        )

                                    [video_cta_clicks] => 
                                    [mobile_conversion_lifetime_value_achievements_unlocked] => stdClass Object
                                        (
                                            [order_quantity] => 
                                            [metric] => 
                                            [sale_amount] => 
                                        )

                                    [likes] => 
                                    [mobile_conversion_add_to_carts] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_payment_info_additions] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_re_engages] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [video_content_starts] => 
                                    [mobile_conversion_lifetime_value_updates] => stdClass Object
                                        (
                                            [metric] => 
                                            [sale_amount] => 
                                            [order_quantity] => 
                                        )

                                    [video_views_25] => 
                                    [mobile_conversion_shares] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [conversion_site_visits] => stdClass Object
                                        (
                                            [order_quantity_engagement] => 
                                            [sale_amount_engagement] => 
                                            [sale_amount_view] => 
                                            [post_view] => 
                                            [order_quantity] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                            [metric] => 
                                            [order_quantity_view] => 
                                        )

                                    [mobile_conversion_lifetime_value_content_views] => stdClass Object
                                        (
                                            [order_quantity] => 
                                            [metric] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_lifetime_value_invites] => stdClass Object
                                        (
                                            [sale_amount] => 
                                            [order_quantity] => 
                                            [metric] => 
                                        )

                                    [engagements] => Array
                                        (
                                            [0] => 0
                                            [1] => 0
                                            [2] => 0
                                            [3] => 0
                                            [4] => 0
                                            [5] => 0
                                            [6] => 0
                                            [7] => 0
                                            [8] => 1
                                            [9] => 0
                                            [10] => 0
                                            [11] => 0
                                            [12] => 0
                                            [13] => 0
                                            [14] => 0
                                            [15] => 0
                                            [16] => 0
                                            [17] => 0
                                            [18] => 0
                                            [19] => 0
                                            [20] => 0
                                            [21] => 0
                                            [22] => 0
                                            [23] => 0
                                        )

                                    [mobile_conversion_lifetime_value_shares] => stdClass Object
                                        (
                                            [sale_amount] => 
                                            [order_quantity] => 
                                            [metric] => 
                                        )

                                    [conversion_custom] => stdClass Object
                                        (
                                            [order_quantity_engagement] => 
                                            [sale_amount_engagement] => 
                                            [sale_amount_view] => 
                                            [post_view] => 
                                            [order_quantity] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                            [metric] => 
                                            [order_quantity_view] => 
                                        )

                                    [video_views_100] => 
                                    [mobile_conversion_lifetime_value_searches] => stdClass Object
                                        (
                                            [sale_amount] => 
                                            [metric] => 
                                            [order_quantity] => 
                                        )

                                    [mobile_conversion_lifetime_value_purchases] => stdClass Object
                                        (
                                            [metric] => 
                                            [order_quantity] => 
                                            [sale_amount] => 
                                        )

                                    [clicks] => Array
                                        (
                                            [0] => 0
                                            [1] => 0
                                            [2] => 0
                                            [3] => 0
                                            [4] => 0
                                            [5] => 0
                                            [6] => 0
                                            [7] => 0
                                            [8] => 1
                                            [9] => 0
                                            [10] => 0
                                            [11] => 0
                                            [12] => 0
                                            [13] => 0
                                            [14] => 0
                                            [15] => 0
                                            [16] => 0
                                            [17] => 0
                                            [18] => 0
                                            [19] => 0
                                            [20] => 0
                                            [21] => 0
                                            [22] => 0
                                            [23] => 0
                                        )

                                    [mobile_conversion_sign_ups] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [media_views] => 
                                    [card_engagements] => 
                                    [mobile_conversion_lifetime_value_reservations] => stdClass Object
                                        (
                                            [sale_amount] => 
                                            [metric] => 
                                            [order_quantity] => 
                                        )

                                    [mobile_conversion_lifetime_value_rates] => stdClass Object
                                        (
                                            [order_quantity] => 
                                            [metric] => 
                                            [sale_amount] => 
                                        )

                                    [replies] => 
                                    [mobile_conversion_lifetime_value_levels_achieved] => stdClass Object
                                        (
                                            [sale_amount] => 
                                            [order_quantity] => 
                                            [metric] => 
                                        )

                                    [url_clicks] => 
                                    [video_mrc_views] => 
                                    [mobile_conversion_purchases] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_rates] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_logins] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [billed_engagements] => 
                                    [mobile_conversion_updates] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_lifetime_value_payment_info_additions] => stdClass Object
                                        (
                                            [sale_amount] => 
                                            [metric] => 
                                            [order_quantity] => 
                                        )

                                    [conversion_downloads] => stdClass Object
                                        (
                                            [order_quantity_engagement] => 
                                            [sale_amount_engagement] => 
                                            [sale_amount_view] => 
                                            [post_view] => 
                                            [order_quantity] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                            [metric] => 
                                            [order_quantity_view] => 
                                        )

                                    [mobile_conversion_levels_achieved] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_downloads] => stdClass Object
                                        (
                                            [post_view] => 
                                            [post_engagement] => 
                                            [order_quantity] => 
                                            [sale_amount] => 
                                        )

                                    [video_total_views] => 
                                    [mobile_conversion_invites] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [carousel_swipes] => 
                                )

                        )

                )

        )

)

#9

Campaign Name: photographers
Campaign Id: 5vukm
Below response:

Array
(
    [0] => stdClass Object
        (
            [id] => 659hh
            [id_data] => Array
                (
                    [0] => stdClass Object
                        (
                            [segment] => 
                            [metrics] => stdClass Object
                                (
                                    [video_views_50] => 
                                    [impressions] => Array
                                        (
                                            [0] => 0
                                            [1] => 0
                                            [2] => 710
                                            [3] => 0
                                            [4] => 0
                                            [5] => 29
                                            [6] => 186
                                            [7] => 525
                                            [8] => 1138
                                            [9] => 835
                                            [10] => 542
                                            [11] => 407
                                            [12] => 710
                                            [13] => 11
                                            [14] => 0
                                            [15] => 0
                                            [16] => 0
                                            [17] => 0
                                            [18] => 0
                                            [19] => 0
                                            [20] => 0
                                            [21] => 0
                                            [22] => 0
                                            [23] => 0
                                        )

                                    [mobile_conversion_spent_credits] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_installs] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )
                                    [mobile_conversion_content_views] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [mobile_conversion_lifetime_value_tutorials_completed] => stdClass Object
                                        (
                                            [metric] => 
                                            [order_quantity] => 
                                            [sale_amount] => 
                                        )
                                    [mobile_conversion_add_to_wishlists] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )
                                    [mobile_conversion_lifetime_value_checkouts_initiated] => stdClass Object
                                        (
                                            [order_quantity] => 
                                            [sale_amount] => 
                                            [metric] => 
                                        )

                                    [mobile_conversion_lifetime_value_add_to_wishlists] => stdClass Object
                                        (
                                            [metric] => 
                                            [order_quantity] => 
                                            [sale_amount] => 
                                        )
                                    [mobile_conversion_lifetime_value_logins] => stdClass Object
                                        (
                                            [metric] => 
                                            [sale_amount] => 
                                            [order_quantity] => 
                                        )
                                    [mobile_conversion_checkouts_initiated] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )
                                    [tweets_send] => 
                                    [conversion_purchases] => stdClass Object
                                        (
                                            [order_quantity_engagement] => 
                                            [sale_amount_engagement] => 
                                            [sale_amount_view] => 
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                            [metric] => 
                                            [order_quantity_view] => 
                                        )
                                    [mobile_conversion_reservations] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )
                                    [mobile_conversion_tutorials_completed] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )
                                    [billed_charge_local_micro] => Array
                                        (
                                            [0] => 0
                                            [1] => 0
                                            [2] => 3822614
                                            [3] => 0
                                            [4] => 0
                                            [5] => 0
                                            [6] => 861056
                                            [7] => 965764
                                            [8] => 8732123
                                            [9] => 4454412
                                            [10] => 1164031
                                            [11] => 0
                                            [12] => 0
                                            [13] => 0
                                            [14] => 0
                                            [15] => 0
                                            [16] => 0
                                            [17] => 0
                                            [18] => 0
                                            [19] => 0
                                            [20] => 0
                                            [21] => 0
                                            [22] => 0
                                            [23] => 0
                                        )
                                    [qualified_impressions] => 
                                    [video_views_75] => 
                                    [conversion_sign_ups] => stdClass Object
                                        (
                                            [order_quantity_engagement] => 
                                            [sale_amount_engagement] => 
                                            [sale_amount_view] => 
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                            [metric] => 
                                            [order_quantity_view] => 
                                        )
                                    [media_engagements] => 
                                    [follows] => 
                                    [mobile_conversion_achievements_unlocked] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )
                                    [mobile_conversion_lifetime_value_add_to_carts] => stdClass Object
                                        (
                                            [metric] => 
                                            [order_quantity] => 
                                            [sale_amount] => 
                                        )
                                    [video_3s100pct_views] => 
                                    [app_clicks] => 
                                    [mobile_conversion_lifetime_value_sign_ups] => stdClass Object
                                        (
                                            [sale_amount] => 
                                            [order_quantity] => 
                                            [metric] => 
                                        )
                                    [mobile_conversion_searches] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )
                                    [mobile_conversion_lifetime_value_spent_credits] => stdClass Object
                                        (
                                            [metric] => 
                                            [sale_amount] => 
                                            [order_quantity] => 
                                        )
                                    [mobile_conversion_site_visits] => stdClass Object
                                        (
                                            [order_quantity] => 
                                            [post_view] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )
                                    [retweets] => 
                                    [mobile_conversion_key_page_views] => stdClass Object
                                        (
                                            [post_engagement] => 
                                            [post_view] => 
                                        )
                                    [video_cta_clicks] => 
                                    [mobile_conversion_lifetime_value_achievements_unlocked] => stdClass Object
                                        (
                                            [order_quantity] => 
                                            [metric] => 
                                            [sale_amount] => 
                                        )
                                    [likes] => Array
                                        (
                                            [0] => 0
                                            [1] => 0
                                            [2] => 0
                                            [3] => 0
                                            [4] => 0
                                            [5] => 0
                                            [6] => 0
                                            [7] => 1
                                            [8] => 0
                                            [9] => 0
                                            [10] => 0
                                            [11] => 0
                                            [12] => 0
                                            [13] => 0
                                            [14] => 0
                                            [15] => 0
                                            [16] => 0
                                            [17] => 0
                                            [18] => 0
                                            [19] => 0
                                            [20] => 0
                                            [21] => 0
                                            [22] => 0
                                            [23] => 0
                                        )

                                    [mobile_conversion_add_to_carts] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )
                                    [mobile_conversion_payment_info_additions] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )
                                    [mobile_conversion_re_engages] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [video_content_starts] => 
                                    [mobile_conversion_lifetime_value_updates] => stdClass Object
                                        (
                                            [metric] => 
                                            [sale_amount] => 
                                            [order_quantity] => 
                                        )

                                    [video_views_25] => 
                                    [mobile_conversion_shares] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )
                                    [conversion_site_visits] => stdClass Object
                                        (
                                            [order_quantity_engagement] => 
                                            [sale_amount_engagement] => 
                                            [sale_amount_view] => 
                                            [post_view] => 
                                            [order_quantity] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                            [metric] => 
                                            [order_quantity_view] => 
                                        )

                                    [mobile_conversion_lifetime_value_content_views] => stdClass Object
                                        (
                                            [order_quantity] => 
                                            [metric] => 
                                            [sale_amount] => 
                                        )
                                    [mobile_conversion_lifetime_value_invites] => stdClass Object
                                        (
                                            [sale_amount] => 
                                            [order_quantity] => 
                                            [metric] => 
                                        )
                                    [engagements] => Array
                                        (
                                            [0] => 0
                                            [1] => 0
                                            [2] => 4
                                            [3] => 0
                                            [4] => 0
                                            [5] => 0
                                            [6] => 2
                                            [7] => 6
                                            [8] => 13
                                            [9] => 3
                                            [10] => 2
                                            [11] => 1
                                            [12] => 3
                                            [13] => 0
                                            [14] => 0
                                            [15] => 0
                                            [16] => 0
                                            [17] => 0
                                            [18] => 0
                                            [19] => 0
                                            [20] => 0
                                            [21] => 0
                                            [22] => 0
                                            [23] => 0
                                        )

                                    [mobile_conversion_lifetime_value_shares] => stdClass Object
                                        (
                                            [sale_amount] => 
                                            [order_quantity] => 
                                            [metric] => 
                                        )

                                    [conversion_custom] => stdClass Object
                                        (
                                         
                                        )

                                    [video_views_100] => 
                                    [mobile_conversion_lifetime_value_searches] => stdClass Object
                                        (
                                            [sale_amount] => 
                                            [metric] => 
                                            [order_quantity] => 
                                        )

                                    [mobile_conversion_lifetime_value_purchases] => stdClass Object
                                        (
                                            [metric] => 
                                            [order_quantity] => 
                                            [sale_amount] => 
                                        )

                                    [clicks] => Array
                                        (
                                            [0] => 0
                                            [1] => 0
                                            [2] => 4
                                            [3] => 0
                                            [4] => 0
                                            [5] => 0
                                            [6] => 2
                                            [7] => 6
                                            [8] => 13
                                            [9] => 3
                                            [10] => 2
                                            [11] => 1
                                            [12] => 3
                                            [13] => 0
                                            [14] => 0
                                            [15] => 0
                                            [16] => 0
                                            [17] => 0
                                            [18] => 0
                                            [19] => 0
                                            [20] => 0
                                            [21] => 0
                                            [22] => 0
                                            [23] => 0
                                        )

                                    [mobile_conversion_sign_ups] => stdClass Object
                                        (
                                            [post_view] => 
                                            [order_quantity] => 
                                            [assisted] => 
                                            [post_engagement] => 
                                            [sale_amount] => 
                                        )

                                    [media_views] => 
                                    [card_engagements] => 
                                    [mobile_conversion_lifetime_value_reservations] => stdClass Object
                                        (
                                            
                                        )

                                    [mobile_conversion_lifetime_value_rates] => stdClass Object
                                        (
                                           
                                        )

                                    [replies] => 
                                    [mobile_conversion_lifetime_value_levels_achieved] => stdClass Object
                                        (
                                            [sale_amount] => 
                                            [order_quantity] => 
                                            [metric] => 
                                        )

                                    [url_clicks] => Array
                                        (
                                            [0] => 0
                                            [1] => 0
                                            [2] => 2
                                            [3] => 0
                                            [4] => 0
                                            [5] => 0
                                            [6] => 1
                                            [7] => 1
                                            [8] => 6
                                            [9] => 2
                                            [10] => 1
                                            [11] => 0
                                            [12] => 1
                                            [13] => 0
                                            [14] => 0
                                            [15] => 0
                                            [16] => 0
                                            [17] => 0
                                            [18] => 0
                                            [19] => 0
                                            [20] => 0
                                            [21] => 0
                                            [22] => 0
                                            [23] => 0
                                        )

                                    [video_mrc_views] => 
                                    [mobile_conversion_purchases] => stdClass Object
                                        (
                                            
                                        )

                                    [mobile_conversion_rates] => stdClass Object
                                        (
                                            
                                        )

                                    [mobile_conversion_logins] => stdClass Object
                                        (
                                            
                                        )

                                    [billed_engagements] => Array
                                        (
                                            [0] => 0
                                            [1] => 0
                                            [2] => 2
                                            [3] => 0
                                            [4] => 0
                                            [5] => 0
                                            [6] => 1
                                            [7] => 1
                                            [8] => 4
                                            [9] => 2
                                            [10] => 1
                                            [11] => 0
                                            [12] => 0
                                            [13] => 0
                                            [14] => 0
                                            [15] => 0
                                            [16] => 0
                                            [17] => 0
                                            [18] => 0
                                            [19] => 0
                                            [20] => 0
                                            [21] => 0
                                            [22] => 0
                                            [23] => 0
                                        )

                                    [mobile_conversion_updates] => stdClass Object
                                        (
                                           
                                        )

                                    [mobile_conversion_lifetime_value_payment_info_additions] => stdClass Object
                                        (
                                          
                                        )

                                    [conversion_downloads] => stdClass Object
                                        ( 
                                        )

                                    [mobile_conversion_levels_achieved] => stdClass Object
                                        (
                                        )

                                    [mobile_conversion_downloads] => stdClass Object
                                        (
                                        )

                                    [video_total_views] => 
                                   
                                    [carousel_swipes] => 
                                )

                        )

                )

        )

)

#10

@juanshishido & @imit8me - I have updated the formatting. Hope it helps. Let me know if you need any further information.


#11

@endevmcc: What’s not clear is what the nature of the issue is. We don’t know what we’re looking for. The thread title is “campaign data mismatch.” What’s not matching? You mentioned that, “impressions, spend, engagements, clicks, url_clicks” are incorrect. What are they supposed to be?


#12

Yes, correct. “impressions, spend, url_clicks” are not proper in campaign data.

Below are the actual data (2nd Mar 2017):
impressions: 1886
spend: $10
url_clicks: 13

Below are the data coming from API (2nd Mar 2017):
impressions: 691
spend: $0
url_clicks: 0


#13

Interesting, @endevmcc . Can you let us know where you’re getting the “actual data” from? Is this from the ads.twitter.com UI?


#14

@endevmcc: Are you requesting data for both ALL_ON_TWITTER and PUBLISHER_NETWORK? See this posts for additional information: Data Discrepancies Between UI and API and Spend from Ads API and UI do not match.


#15

I have checked both the entities, but still same issue (data mismatch)


#16

Yes, I am getting the actual data from ads.twitter.com


#17

@endevmcc: The other thing that could be happening is that, in the API, the end_time is typically exclusive (while being inclusive in the UI). In your example above, with start_time=2017-03-02 and end_time=2017-03-03 (ignoring the time stamp for now), you would get data for all of March 2nd, but not the 3rd. In your example response, notice that you’re seeing 24 elements in the populated arrays (assuming granularity=HOUR in the request).


#18

@endevmcc: Did this date nuance help resolve the issue?


#19

Thank you for your reply.

I have checked with the date requested with granularity=HOUR but still issue is not resolved.


#20

@endevmcc: Let’s focus on the campaign (ID 5r8l6) you’re saying has incorrect data.

According to this screen shot, this campaign received 1,886 impressions on 2017-03-02. As mentioned previously, we need to make two requests—one for ALL_ON_TWITTER placement and one for PUBLISHER_NETWORK placement.

ALL_ON_TWITTER

$ twurl -H ads-api.twitter.com "/1/stats/accounts/18ce53ydbsd?entity=CAMPAIGN&entity_ids=5r8l6&start_time=2017-03-02&end_time=2017-03-03&granularity=TOTAL&metric_groups=ENGAGEMENT&placement=ALL_ON_TWITTER" | jq
{
  "data_type": "stats",
  "time_series_length": 1,
  "data": [
    {
      "id": "5r8l6",
      "id_data": [
        {
          "segment": null,
          "metrics": {
            "impressions": [
              691
            ],
            "tweets_send": null,
            "qualified_impressions": null,
            "follows": null,
            "app_clicks": null,
            "retweets": null,
            "likes": null,
            "engagements": [
              1
            ],
            "clicks": [
              1
            ],
            "card_engagements": null,
            "replies": null,
            "url_clicks": null,
            "carousel_swipes": null
          }
        }
      ]
    }
  ],
  "request": {
    "params": {
      "start_time": "2017-03-02T05:00:00Z",
      "segmentation_type": null,
      "entity_ids": [
        "5r8l6"
      ],
      "end_time": "2017-03-03T05:00:00Z",
      "country": null,
      "placement": "ALL_ON_TWITTER",
      "granularity": "TOTAL",
      "entity": "CAMPAIGN",
      "platform": null,
      "metric_groups": [
        "ENGAGEMENT"
      ]
    }
  }
}

PUBLISHER_NETWORK

$ twurl -H ads-api.twitter.com "/1/stats/accounts/18ce53ydbsd?entity=CAMPAIGN&entity_ids=5r8l6&start_time=2017-03-02&end_time=2017-03-03&granularity=TOTAL&metric_groups=ENGAGEMENT&placement=PUBLISHER_NETWORK" | jq
{
  "data_type": "stats",
  "time_series_length": 1,
  "data": [
    {
      "id": "5r8l6",
      "id_data": [
        {
          "segment": null,
          "metrics": {
            "impressions": [
              1195
            ],
            "tweets_send": null,
            "qualified_impressions": null,
            "follows": null,
            "app_clicks": null,
            "retweets": null,
            "likes": null,
            "engagements": [
              13
            ],
            "clicks": [
              13
            ],
            "card_engagements": null,
            "replies": null,
            "url_clicks": [
              13
            ],
            "carousel_swipes": null
          }
        }
      ]
    }
  ],
  "request": {
    "params": {
      "start_time": "2017-03-02T05:00:00Z",
      "segmentation_type": null,
      "entity_ids": [
        "5r8l6"
      ],
      "end_time": "2017-03-03T05:00:00Z",
      "country": null,
      "placement": "PUBLISHER_NETWORK",
      "granularity": "TOTAL",
      "entity": "CAMPAIGN",
      "platform": null,
      "metric_groups": [
        "ENGAGEMENT"
      ]
    }
  }
}

This shows 691 ALL_ON_TWITTER impressions and 1,195 PUBLISHER_NETWORK impressions, for a total of 1,886, which matches what’s shown on ads.twitter.com.