I'm trying to retrieve business invoices using a curl command and testing this on Facebook Graph API Explorer. This is the query that I'm using
<FB_Business_ID>/business_invoices?start_date=2019-06-01&end_date=2019-07-01
The query is taken from this document
https://developers.facebook.com/docs/marketing-api/business-manager/get-started#invoice
I'm making this call using the 14.0 version, I also tried on 13.0 and 12.0, and I have all the necessary permission to create this call. Every time on making a call, I get a single data object
Related
I want to get the Bulk Report for "content_owner_estimated_revenue_a1" in Youtube's Reporting API.
I created a report making job with the jobs.create method in the official YouTube APIs Explorer.
https://developers.google.com/youtube/reporting/v1/reference/rest/v1/jobs/create
A few days later, I got the URL of the report with the method jobs.reports.get in the APIs Explorer as well, gave Bearer's access token and issued a get request to the URL to download the CSV.
https://developers.google.com/youtube/reporting/v1/reference/rest/v1/jobs.reports/get
However, I could only get a header of the following format, although it should contain data.
date,channel_id,video_id,claimed_status,uploader_type,country_code,estimated_partner_revenue,estimated_partner_ad_revenue,estimated_partner_ad_auction_revenue,estimated_partner_ad_reserved_revenue,estimated_youtube_ad_revenue,estimated_monetized_playbacks,estimated_playback_based_cpm,ad_impressions,estimated_cpm,estimated_partner_red_revenue,estimated_partner_transaction_revenue
Of course, I got the token with the content owner's account and also entered the ID in onBehalfOfContentOwner and made an API request.
I have also confirmed that the revenue is being generated from the channel analytics page in Youtube Studio.
How can I fix this problem?
I am ultimately trying to build a custom integration with BIM360 Field to track and monitor field issues generated on a specific project.
Currently in the trial stage I am using Postman to make URI calls, mostly based on Sam Nseir's post Export BIM 360 Project Data via Autodesk Forge
I have everything from that post working correctly, Authentication, Projects list, and was able to extract my Hub Id with a https://developer.api.autodesk.com/project/v1/hubs call.
I am getting hung up trying to determine my Container ID based on this Forge Help Doc. I am only ever able to return a empty Data set "data":[] as shown in the output image below. I have tried adapting the filter logic from the help docs, but end up with the exact same result.
Output Image
I am using an Autodesk sample project, which I am the account admin of, so I don't believe permissions should be an issue. My custom integration has Account admin, and Document management access.
I wanted to use Graph Api to fetch the groups where user is member. But since 2.4, FB has deprecated the user_groups permission. In Graph Api Explorer, when I tried it with v2.3, it returns the results as expected. After seeing this, I implemented the same in my app with the version parameter of GraphRequest. Doing this, did not show me the results, instead they showed the error of permission.
What should I do then? Is there any way to use v2.3 for Graph Api? As per the sdk, my current Graph Api is 2.9
Use user_managed_groups instead, there is no other way. You can only access groups you manage and you cannot go back to an older API version. Even with an older App it would be pointless, see deprecation info in the changelog: https://developers.facebook.com/docs/apps/changelog
I am interested in fetching all data available on this page (https://developers.facebook.com/docs/opengraph/insights/) with Facebook API. Is it possible to get raw data to use with my own graphing tools?
Yes. You can query the insights table using either the Graph API or FQL.
The insights documentation is not very clear, and in FQL especially, you need to manually ask for data points one period at a time. The FQL documentation is worth reading even if you're using the API since it defines all the different metrics which are available.
Visit the Graph API Explorer, get an access token with the Extended Permission read_insights and type /PAGE_ID_OR_USERNAME/insights into the search box. You'll see a bit of what is available.
You can drill down by adding parameters to the end of the url. For instance /PAGE_ID_OR_USERNAME/insights/page_fan_adds_unique/day?since=-1 month gets you a json object with the unique page fan adds each day for about the past month.
You are only able to get insights data for a page where you have admin rights.
Facts:
I'm running a FB contest where users are entered into a drawing simply by liking a specific post.
I can call $postid/likes in the Graph API Explorer while using the token generated by the Graph API Explorer and receive the proper information. It's a simple result with user id/name pair which is all I need to generate a random winner.
I'm running a daily cron that collects all new likes for the post and puts them in a database so that I can track the number of entrants and pull out a winner from the pool easily. The script works and I get the expected data if I copy out the token from the Graph API Explorer call above and plug it into the script.
Problem:
Since the script above works when I copy out the active temporary token from the Graph API Explorer, shouldn't I be able to do this programmatically? I can't figure out how I am supposed authenticate when my daily cron runs (no user interaction) in order to get a new, valid, non-expired token. Since this is a cron running from the server, I obviously can't authenticate through a user dialog.
You can create an app and then authenticate as that app. Access tokens granted to an app don't expire so you'll be able to code that into your cron job.
Tread carefully with this. It looks like your contest violates the Facebook promotions guidelines:
You must not condition registration or entry upon the user liking a Wall post.