How to break down insights by day via Facebook api - facebook-ads-api

I want to get the daily insights data so I try to use the below edge to request record by record (day by day). If there is data for 30 days, I have to request 30 times.
/insights?fields=impressions,social_clicks,website_clicks,ctr&time_range={'since':'2015-01-01','until':'2015-01-01'}
But if I can break down by using the edge such as the below one, I would not have to request many times.
/insights?fields=impressions,social_clicks,website_clicks,ctr&breakdowns=DAY
Do you know how to break down the insights by day?

You can select how to break in days using a parameter, for getting daily info just use the parameter time_increment parameter with value 1.
/insights?fields=impressions,social_clicks,website_clicks,ctr&time_range={'since':'2015-01-01','until':'2015-01-30'}&time_increment=1
Reference:
https://developers.facebook.com/docs/marketing-api/reference/ad-account/insights/

Related

Elasticsearch Lucene query syntax to add and subtract N minutes with time field?

I am working on grafana dashboard in that, I passing start time and end time from one dashboard to another using template variable. This is how I passing the value
var-startTime=2020-07-23T05:07:04Z&var-endTime=2020-07-23T05:11:31Z
In another dashboard, I get the variable values and pass to Lucene query like
#timestamp:[$startTime TO $endTime]
It's working fine. But here I want to get data prior to 15 minutes from start time and 15 minutes later from end time. How could I add and subtract 15 minutes with this time? I need something like this.
#timestamp:[$startTime-15m TO $endTime+15m]
How can I achieve this?
In the Lucene expression language you can do exactly that using the || anchor:
#timestamp:[2020-07-23T05:07:04Z||-15m TO 2020-07-23T05:11:31Z||+15m]
So I guess you can have something like
#timestamp:[$startTime||-15m TO $endTime||+15m]

FHIR: return a list of patient resource based on last

Need some advice and help from you!
Two questions.
how can I retrieve a list of patient resources with 30 _counts and sorted by last modified date? I don't have any searching parameters such as identifier, family and given;
since my application in browser is a single page application, when the user scroll down and all the first 30 patients have been shown, I will make another call to get the next 30 patients. I don't need the first 30 patients and just want the records from 31 to 60. What parameters should I used in this paging search? Do we have something like "?_count=30&_page=2". Similarly, if I need the page 100, I don't want the servers sending me the first 99 pages.
Thanks in advance.
Autorun
GET [baseUrl]/Patient?_count=30&sort=_lastUpdated
The response will be a Bundle. Look at the Bundle.link with a Bundle.link.relation of "next". The Bundle.link.url will be the URL to use to get the next "page" of content. The format of the URL is undefined and will be server-specific.
Be aware that _count only constrains the base resource. If you query Patient and do a _revinclude on Observation, you'll get 30 patients - but you'll also get all the observations for all 30 of those patients - which could be 10k+ rows in your result set - so be careful with _include and _revinclude.

gapi-google-analytics-php-interface total number of records varying from time to time

I have made call to Google analtics API using https://github.com/erebusnz/gapi-google-analytics-php-interface and number of records i get on each call vary from time to time . Say in first call i get 800 records after some time i get 500 total records. I have not made any changes to parameters.Value each page is showing correct but count of some items are missing.
Am using example.report.php with my key and email .
Thanks
Jithin
Oho , I found the answer after a long time. i was calculating from 2005 Jan 1st.Everything works fine on calculating with reference to date of google analytics implementation on my site

Parse.com request per second limit?

Just trying to get some clarity regarding parse.com request per second limit.
Do they count a 'get' from the data browser as a request? Or is it just
a request that starts from the client side?
I'm working on a project that retrieves a combo of images and text and it's over 30 per second.(around 45).
Thanks
Any request to the parse server is counted and his limitation is described on the website ( with new pricing, default req/s = 30 , so 1800 requests per minute).
Basically you have to retrieve as many elements as possible/needed with less number of request to parse ( balanced with the necessity and performance of course ), up to the limit of 1000 rows for query.
Anyway imagine you already have the list of photo objects ( let's say ,a list of Photo as Parse object ) and each one keep the image file field, any call to the direct image url is not counted for the burst limit
Hope it helps

JIRA JQL Search by Date - How to search Updated Issues on 1 Hour

These are my Requirements:
I need to get Updated JIRA issues through RSS Every 1 Hour or Minutes.
So how can I filter the issues for my requirements?
What I tried so far:
I have filtered like, updated > startOfDay(-0d) and updated < now()
First time it returns the all issues i created or modified to me. But after that it returns all the previous issues along with modified issues.
I need only
issues which modified between now() and before 1 hour.
How can I create a JQL query like this?
You want the following:
updated >= "-1h"
Just write a query with where clause updated BETWEEN LocalDateTime.now().minusHours(1) AND LocalDateTime.now()?
Also you need to pass starting date (in my example LocalDateTime.now() from JodaTime is used) in order to get real start time instead of current time. It may be few seconds later and you will not find several issues updated on the beginning of last hour.

Resources