What are time-based fields that Facebook Graph API uses to filter result set when including SINCE and UNTIL parameters on /videos endpoint? - facebook

When retrieving data from the /videos API endpoint using the SINCE and UNTIL parameters, what are the time-based data fields that the API is using to filter the result set?
In the example below, I am retrieving videos from July 28th through July 30th, but a video in the result set was created and last updated on August 2nd and there is a video published on July 29th that is excluded:
https://graph.facebook.com/v2.9/8429246183/videos?since=2017-07-28&until=2017-07-30&fields=created_time,updated_time&access_token=[token]
This is the only documentation I have found that discusses the SINCE and UNTIL parameters and that only says that they represent "a Unix timestamp or strtotime data value that points to the [start/end] of the range of time-based data."
https://developers.facebook.com/docs/graph-api/using-graph-api

Facebook has stated in the bug report submitted on this issue that the SINCE and UNTIL parameters filter on an unpublished field based on the time that a video draft was originally created or scheduled. While this is not the ideal behavior, they have said that they do not currently have plans to correct this in the immediate future.

Related

Retrieving Microsoft Live calendar events between 2 dates

I'm currently working on requesting a list of events between 2 dates via Microsoft Live's REST API. I am able to pull back a list of events through the following request URL:
https://apis.live.net/v5.0/me/events
However, this returns a list of events that does not have any specific date frame. For example, I'd want to call a request similar to this:
https://apis.live.net/v5.0/me/events?startDate=2015-02-15&endDate=2015-03-15
I haven't been able to find any useful Microsoft documentation in their disorganized mess of "documentation", so my questions are:
1 - What changes need to be made to the first endpoint above for something like this to work?
2 - What time format does Microsoft use for this kind of request?
Thanks!
I finally found the answer in the middle of a Microsoft documentation page.
Get a limited number of events based on their starting and ending times in Coordinated Universal Time (UTC) format by using the start_time and end_time parameters
To answer my own questions:
#1 - The following endpoint works:
https://apis.live.net/v5.0/me/events?start_time=2015-02-15T00:00:00Z&end_time=2015-03-15T00:00:00Z
#2 - The time format is as follows:
yyyy-MM-dd'T'HH:mm:ss'Z'

Facebook Api Graph Pull data from a timeframe

I am new to this stuff, I am trying to use Facebook api Graph to get the data for the last 30 days and link it to Klipfolio.
I am able to pull all the data but no matter what i try I can not seam to get FB to only return all of the data not just last 30 days or 7days.
am I able to a time frame parameters?
Any help would be appreciated, this is what I have to pull all the data,
/adaccounts?fields=amount_spent
Thanks
i don't use facebook adds so i can't exactly test with data . but facebook graph api supports time based pagination of the data . read the time based pagination section at the graph api v2.2 docs page. .
it provides with until and since parameters.
A time-paginated edge supports the following parameters:
until : A Unix timestamp or strtotime data value that points to the
end of the range of time-based data.
since : A Unix timestamp or
strtotime data value that points to the start of the range of
time-based data.
i checked it with end points like
me/feed?until=10/11/2011
and it works as expected . so test the parameter for your required data .

How does Tumblr determine the order of posts with the same post date outside the dashboard?

On the dashboard, Tumblr posts appear in the order in which they were created (regardless of the date attached to them). But on the front-end (e.g. at mysite.tumblr.com), I'm seeing inconsistent order for posts with the same post date and time.
On a test Tumblr, I created the following posts in this order (post IDs in parens):
Post A, dated 2013-08-14 7:00:00 (58279080752)
Post B, dated 2013-08-14 7:00:00 (58279382194)
Post C, dated 2013-08-15 7:00:00 (58314687302)
Post D, dated 2013-08-15 7:00:00 (58314687868)
On my dashboard, they appear in proper reverse-chronological order of creation (assuming the IDs are sequential), D->C->B->A, but when I view my theme, they're in the order D->C->A->B.
So it seems that yesterday's posts are in reverse order of creation/ID, but today's posts are in the natural order of creation/ID. What would explain this inconsistency?
Note: I'm not interested in changing the order (I know I can just change the post date/time to do that). I'm interested in understanding the criteria Tumblr uses to order posts when they have the same date and time, which I cannot find documented.
Update: Here is an actual Tumblr I've created which displays this behavior: http://postordertest.tumblr.com/
Unfortunately, I believe the answer to my own question is "no particular order".
I created another test Tumblr, this time with three posts per identical datetime. For August 15 7am, the posts are displayed in 3rd-1st-2nd order of ID. But for August 14 7am, posts appear in 1st-3rd-2nd order of ID. No apparent pattern or consistency.
Then, I created two more posts dated August 15 7am. After publishing post G, Tumblr displayed the posts in 4th-3rd-1st-2nd order of ID. Again, no apparent order, other than the fact that the newest post appeared first. But here's where things got strange. After publishing a final Post H (same date/time), the entire order of posts for that datetime changed: from 4th-3rd-1st-2nd to 1st-5th-2nd-3rd-4th.
At this point, I can only conclude that Tumblr displays posts on blogs with the same date/time in no particular (or even consistently arbitrary) order.
Tumblr determines the order of posts by Tumblr Post IDs in descending order.

Can response data from core reporting api be grouped?

Explanation:
I am able to query the Google Core reporting APIv3 using the client library to get data on pageviews for specific URLs of a website I am working on. I want to get data(pageviews) for each day within a specified range. So far I am simply looping through the range, sending individual request to the API. in each request I am setting the same value for the start date and the end date.
Problem:
Obviously this gets the job done, BUT it is certainly not the best way to go about it. Because, assumming I want to get data for the past 3 months for each of about 2000 URIs. Then I will need 360000 number of requests and that value is well over the limit quota defined by Google.
Potential solution: So one way I thought of solving this issue is probably to send a request setting start-date and end-date to be a week apart but the API will return a sum of the values rather than the individual values.
main question: So is there a way to insist that these values should not be added up and returned as a sum but rather returned (as associative array or something like that) separately for each.
I hope the question is clear and that there is a solution! Thank you!
Very straightforward:
Metric: ga:pageview, Dimension: ga:date, Set a filter for your pagepath, and set a start-date and end-date.
Example:
https://www.googleapis.com/analytics/v3/data/ga?ids=ga%3Axxyyzz&dimensions=ga%3Adate&metrics=ga%3Apageviews&filters=ga%3Apagepath%3D%3D%2Ffaq.html&start-date=2013-06-27&end-date=2013-07-11&max-results=50
This will return the pageviews for that the faq.html& page for each day in the time-frame.
You should check out the QueryExplorer. Great tool to find out how to structure queries.

Github API v3: fetch events from since date til date

Is it possible with Github API v3 to fetch events from since date til date?
Nothing in documentation: http://developer.github.com/v3/events/
You can not specify an end-date, however, since the results are paginated, you can stop requesting events after a certain date on your own.