Loading & Connecting Facebook Pixel Conversions Data - facebook

I am trying to load the Facebook Pixel Conversions level data from the Marketing/Insights API but not able to do it at the level I want or even properly
I have various pixels created in the form of events eg: Leads, Registrations etc and need to track them
After reading the documentation for Ads Pixels and it's stats - I was able to load some basic fields for now - but still not able to pull the s
GET API Query : https://graph.facebook.com/v2.9/act_/adspixels?fields=name,id,creation_time,last_fired_time
This gives me all the correct Ads Pixel details but how do I pull all the stats for this in the form of Events, their occurrences etc - will I be using more query parameters in this URL or a new URL - tried multiple iterations but was not able to get anything to work for now.
Tried this API Query as per documentation -: https://graph.facebook.com/v2.9//stats - but does not work even with fields added etc
Another issue I had was I am not at all able to test my queries with Graph API explorer - it keeps telling me that "Timeout issue" or "some other errors" when I am trying to use the app etc there. Do I need to publish and approve the app before hitting FB Ads data via the API Explorer?
All your suggestions and feedback will be highly appreciated here

I was searching for some things related and encoutered your thread.. I will report my findings .. maybe you already know this, but here it goes.
As far as querying with Graph API explorer.. it doesn't seem to work with Marketing API. You need to create your own app, and enable market api, in order to get the necessary token.
I am following the instructions on the link you provided: stats
Second.. to get the stats I am using
graph.facebook.com/v2.11/{pixel-id}/stats?aggregation=pixel_fire
The aggregation is necessary to get results. I can get the "Page View" event listed that I am tracking on a website.
I was able to compare these results, with the ones showed to me on the events manager page of the pixel.
Hope this helps

Related

How to generate full report in owasp zap in any format

When i try to generate report in HTML,.XML or PDF I'm getting only alerts in the report. I would like to get all the information including passed attack also in the report.
For example in active scan there is around 500+ combination of URL being used but I'm getting only fee of them. I need all the 500+ URL and its results in the report
Any suggestion?
We dont generate that as a 'standard' report as no ones asked for that to date. However we do expose pretty much everything via the ZAP API, and if theres anything we dont currently expose then let us know and we'll fix that.
To get started with the API point your browser at the host:port that ZAP is listening on and follow the link to the API UI which will allow you to invoke any of the end points. We also have some info on the wiki: https://github.com/zaproxy/zaproxy/wiki/ApiDetails
If you have more detailed questions then the ZAP User Group is a good place to ask: https://groups.google.com/group/zaproxy-users

How to get pixel/offsite conversion stats from Facebook's ads API?

I'm using the Python SDK for the Facebook ads api to get ad performance reports for Facebook ad campaigns.
The problem is that I can't find a way to get the number of pixel/offsite conversions, and I'm not even sure about where to look for it (campaign, adset, adgroup,ad creative..)
When I get stats on any level it is not included under "actions".
I looked through the documentation and only saw explanations for creating and defining pixels.
I'd appreciate any help you can provide.
If your pixel track conversions, you'll find them under the action response field if you use the field 'actions_group_by' set to 'action_type'. They come in the form of "offsite_conversion".
You can also use the ad reports endpoints to retrieve action counts and spend at different levels (time based and or by object, including ad): https://developers.facebook.com/docs/marketing-api/adreportstats/v2.2
Thanks for the answers.
Until now I was using the "get_stats" method and I didn't find this information there.
After posting here I looked at each level's object's methods and saw that there are a few different methods for getting ad stats:
One of the options is "get_conversion_stats", which is available at the account and adgroup levels. Additionally, from the account level it is possible to get the adset and adgroup's conversion data using "get_ad_campaign_conversion_stats" and "get_ad_group_conversion_stats".
(According to the "old" facebook ads terminology, where campaign is today's adset)
There might be more ways to get it, and I'd appreciate anyone telling me about the, but for now I'll be using these methods.
Hope this helps whoever encounters this issue next.
You can get these information from actions field of insight of each adset or ads.
For example: here is my command in facebook's developer site:

Adwords Impressions, Clicks and Cost, how to get these?

I'm developer for marketing company and I need some help with facebook ads. I've been trying to find method for getting data AUTOMATICALLY from facebook campaign that's created by the user.
I'm trying to create script that would get data for server.
So basically I need to get Impressions, Clicks and "Cost of clicks" from each day from facebook-ad-campaigns just by having user login data (username,password) and maybe the id-number of campaign being targeted.
Also if possible I'd like to know how you can shut down campaign(when cost of clicks is greater than budged used).
Are these operations possible? Can I use PHP/FQL for it? Can I get these via Url? If I need to use FQL, what tables I need to fetch data? Anything that can be performed without manually logging to facebook? If so, could I get some example code to do it for me? If it has something to do with Access Tokens, what kind of access rights do I need to grant for it?
Can it be possible to ask more questions in one question than you just did? Wow.
Answers are in order of them asked above. But I will not be answering any followup questions in this thread.
For most of your information can be found at: http://developers.facebook.com/docs/reference/ads-api/
In your code, set a trigger when it has reached that value in the adstatistics, then use the Ads API to shut it down using the pause feature
Yes, use the Ads API. http://developers.facebook.com/docs/reference/ads-api/
For some parts of it you can, for other parts you'll use Graph API object.
Yes, that's how the graph works.
Tables are listed in the documentation at http://developers.facebook.com/docs/reference/ads-api/
Nope.
Yep, example codes are there.
Yes, it sure does.
see https://developers.facebook.com/docs/reference/api/permissions

Facebook Graph API Data Incorrect

Small problem here. I have an event created on Facebook and am using the Graph API to get the number of attendees.
I get the list of attendees with PHP from https://graph.facebook.com/EVENTID/attending?access_token=TOKENHERE and it returns a list of names.
However, the number of attendees is about 6 people lower than what is shown on the Facebook event page. Why would these numbers not match? Is there something in particular I'm supposed to do in the code to get the entire list?
As answered in the comments:
This discrepancy is probably down to a number of the attendees having opted out of Facebook Platform, which means their data isn't passed to apps via the API. Can't be 100% sure without the Event ID, but its a likely reason. – Simon Cross
From the Graph API, the people who have not joined the event will not show up under /{eventid}/attending, you need to add in the users who are returned in /{eventid}/not_replied. The not_replied set seems to be a special set in the GraphAPI.. and if you look at the docs, there is a mention of only people who have joined the event.

Using GA Data Export API to Get All UA's

I am using the GA Data Export API to interact with Google Analytics and I'm making a lot of progress, I am using this URL Endpoint initially to pull all the profiles under an account:
https://www.google.com/analytics/feeds/accounts/default
This URL retrieves each GA ID (profile) and each UA. One thing I've realized is one account can contain multiple UAs and when this happens, this request pulls all profiles. We have a client who has about 115 profiles under like 10 different UAs, and the request takes about 30 seconds for the initial request (and then I believe it must be cached, because it speeds up considerably after this, but then the next day the same thing occurs).
Is there a way to get a list of UA's without pulling the profiles? This way I can query the UA specifically for the profiles instead of pulling each one.
Any advice on this would be really helpful!
Thanks
UPDATE: Here's some documentation on the specific call I am using right now:
http://code.google.com/apis/analytics/docs/gdata/gdataReferenceAccountFeed.html
UPDATE 1: I have found some interesting information in the docs
Once your application has verified
that the user has Analytics access,
its next step is to find out which
Analytics accounts the user has access
to. Remember, users can have access to
many different accounts, and within
them, many different profiles. For
this reason, your application cannot
access any report information without
first requesting the list of accounts
available to the user. The resulting
accounts feed returns that list, but
most importantly, the list also
contains the account profiles that the
user can view.
So this means that you have to use the default accounts call to get these back? Surely, somebody has had this issue before?
So apparently, you can query the account if you know the UA-ID, however there is no way to get back a list of only UA IDs.
One way you can do it is have the user enter their own UA ID instead of having them choose one; not as user-friendly as it could be but better than making the user wait 30 seconds!