Can we get "agent status report" and "agent performance report" through historical metrics using APIs in Amazon Connect? - amazon-web-services

I hope everyone is doing great.
I am working on Amazon Connect reporting APIs. The basic need to post this question is that I want to get agent performance and agent status report through historical metrics using APIs. I am trying to find an API that will give me agent status from midnight that is only possible through historical metrics.
I don't want to use Streams APIs. If anyone has any solution kindly respond to me, it would be very helpful for me. Thanks.

The current reporting API only provides one function for retrieving historical data, GetMetricData, and that function is only able to return queue or channel statistics. Agent specific data is only available via agent event stream and console-based reports at this time. So, unfortunately, there is no way to do what your describing with an API in Amazon Connect right now.

Related

GCP Notification channel

I have set up a notification channel for Console Cloud mobile Application:
Now I would like to be able to add the notification to alerting via Terraform, so I would like to get the notification channel id:
gcloud alpha monitoring channels list
This command returns all the channels, but this one not.
Also when trying to plan with Terraform, I can discover the id (projects/goout-cloud/notificationChannels/#####), however when I try to add it to any alert Terraform section, I will always get:
Error: Cannot import non-existent remote object
I consulted this question internally,
Any sort of interaction - including get, create and update to Mobile App Channels through the API is not possible and gives 404. This notification channel cannot be used by non-Google internal API clients. As such, automation is not currently possible.
The Cloud Stackdriver Monitoring team is aware of this limitation, but it solving this issue is not on the priority list, hence there is no ETA for implementation any time soon.
There is a Issue Tracker regarding this topic, if you want to receive updates, please star the issue.

How to write Kafka connector to integrate with Facebook API?

I am trying to write a Kafka connector to fetch data from the facebook. The problems are,
How to fetch data from facebook through their API without exceeding the limit of API hit provided by facebook? The connector should call facebook API for data after a specific time interval so that the number of hits won't exceed.
Each user can hit the facebook API with their Access Token so users can't share the same topic partition. So how to handle this scenario. Do we have to create one partition for each user?
I read a few guides and blogs to understand Kafka connect and write a connector.
Confluent- https://docs.confluent.io/current/connect/index.html
Kafka Documentation- https://kafka.apache.org/documentation/#connect
Conceptually It gave me an idea about what is Kafka connect, how it works and what are the important classes to write a Kafka connector. But still, I am confused that practically how to write and run a connector. I tried to find step by step development guide but didn't get.
Any tutorial or pdf If you could suggest which have detailed step by step development guide to write and run Kafka connector.
The only "official guide" is in those links you have
https://docs.confluent.io/current/connect/devguide.html#developing-a-simple-connector
I personally have no experience with the Facebook API, but I assume it uses REST, so you could make start by forking the kafka-connect-rest project, but the simplest answer to not exceed the limit would be to not send more requests than you are allowed within a given time period (add a timer to the code that waits between requests)
Also, one connector would only have one set of access keys. How you create the ConnectRecord objects to ultimately partition the records is up to you, but I don't think having an access key per user will scale very well. It might make more sense to have one key tied to one application, then each user will accept that that application has access to read certain details from their account.

Google Tag Manager clickstream to Amazon

So the questions has more to do with what services should i be using to have the efficient performance.
Context and goal:
So what i trying to do exactly is use tag manager custom HTML so after each Universal Analytics tag (event or pageview) send to my own EC2 server a HTTP request with a similar payload to what is send to Google Analytics.
What i think, planned and researched so far:
At this moment i have two big options,
Use Kinesis AWS which seems like a great idea but the problem is that it only drops the information in one redshift table and i would like to have at least 4 o 5 so i can differentiate pageviews from events etc ... My solution to this would be to divide from the server side each request to a separated stream.
The other option is to use Spark + Kafka. (Here is a detail explanation)
I know at some point this means im making a parallel Google Analytics with everything that implies. I still need to decide what information (im refering to which parameters as for example the source and medium) i should send, how to format it correctly, and how to process it correctly.
Questions and debate points:
Which options is more efficient and easiest to set up?
Send this information directly from the server of the page/app or send it from the user side making it do requests as i explained before.
Does anyone did something like this in the past? Any personal recommendations?
You'd definitely benefit from Google Analytics custom task feature instead of custom HTML. More on this from Simo Ahava. Also, Google Big Query is quite a popular destination for streaming hit data since it allows many 'on the fly computations such as sessionalization and there are many ready-to-use cases for BQ.

What is the best tool to use for real-time web statistics?

I operate a number of content websites that have several million user sessions and need a reliable way to monitor some real-time metrics on particular pieces of content (key metrics being: pageviews/unique pageviews over time, unique users, referrers).
The use case here is for the stats to be visible to authors/staff on the site, as well as to act as source data for real-time content popularity algorithms.
We already use Google Analytics, but this does not update quickly enough (4-24 hours depending on traffic volume). Google Analytics does offer a real-time reporting API, but this is currently in closed beta (I have requested access several times, but no joy yet).
New Relic appears to offer a few analytics products, but they are quite expensive ($149/500k pageviews - we have several times this).
Other answers I found on StackOverflow suggest building your own, but this was 3-5 years ago. Any ideas?
Heard some good things about Woopra and they offer 1.2m page views for the same price as Relic.
https://www.woopra.com/pricing/
If that's too expensive then it's live loading your logs and using an elastic search service to read them to get he data you want but you will need access to your logs whilst they are being written to.
A service like Loggly might suit you which would enable you to "live tail" your logs (view whilst being written) but again there is a cost to that.
Failing that you could do something yourself or get someone on freelancer to knock something up for you enabling logs to be read and displayed in a format you recognise.
https://www.portent.com/blog/analytics/how-to-read-a-web-site-log-file.htm
If the metrics that you need to track are just limited to the ones that you have listed (Page Views, Unique Users, Referrers) you may think of collecting the logs of your web servers and using a log analyzer.
There are several free tools available on the Internet to get real-time statistics out of those logs.
Take a look at www.elastic.co, for example.
Hope this helps!
Google Analytics offers real time data viewing now, if that's what you want?
https://support.google.com/analytics/answer/1638635?hl=en
I believe their API is now released as we are now looking at incorporating this!
If you have access to web server logs then you can actually set up Elastic Search as a search engine and along with log parser as Logstash and Kibana as Front end tool for analyzing the data.
For more information: please go through the elastic search link.
Elasticsearch weblink

Amazon Echo - Push a message to the device

I have integrated my amazon echo device with the amazon portal associated to my account. I was able to create my own custom question with the Alexa Skills Kit and process with an AWS Lambda function to generate a response.
My question is: is it possible to programatically "push" a message to the echo device? For example, I would like for it to speak without having to ask it a question. I'd like it to do something at a specific moment.
If it is possible, could you please share any sample code to achieve this?
It is not currently possible, but it is an oft requested feature on the AWS forums.
http://forums.developer.amazon.com/forums/thread.jspa;jsessionid=EC0D457A400B594DD0F0561EEB43A8FA?messageID=17713&#17713
I've not done this myself but it seems using the Alexa Voice Service could do the trick. It allows processing of voice from any type of audio capture and sends it to the Alexa Service. It seems possible you could record the proper phrase into a sound file and send that to AVS, thus triggering the Alexa service.
I know it's capable but Amazon hasn't offered it as a feature yet. If you go to the Echo web site http://alexa.amazon.com/spa/index.html#cards, Settings, Connected Home and select Discover devices, the echo will perform a command triggered from the web site and will speak when completed. I didn't have to say a word.
From what I read on an article about notifications here, they were going to do something that meant you still had to ask Alexa to tell you your notifications, which would build up throughout the day and cause your device to light up and chime to let you know you had a notification to listen to.
Rather than allowing Alexa to randomly blurt stuff out any time she feels like it.
Which kinda seems pointless if you don't get the notification at the exact time it was sent, for example a smart home connected device triggering an alert to let you know you left your door open too long or the app automatically reading you the weather when you get up and turn on the coffee pot in a morning, things like that. If you have to ask for the notifications you may as well just do the speaking and request stuff from the beginning.
Maybe I'm wrong but that's how it reads to me.
Surely we want, with opt-in permission per skill, to allow Alexa to just say whatever she likes whenever she likes from the skills we have set up receiving such commands, without us having to say oh I see I have notifications let me ask what those are.
Just for people who stumble across this question in 2021:
The solution is to use Amazon Proactive Events
Your Skill has to request for the notification permission, subscribe for a specific event and then you can generate a access token and POST events to the amazon API.
Took me some hours to find out because Amazon offers different things which all sound quite similar but some are deprecated (ASK CLI v1) and others are just for Alexa device manufacturers.
Wuhu! Sounds like Amazon may enable push notifications this Fall.
Digital Trends Article
Amazon is expected to establish guidelines for developers and manufacturers so that Alexa remains classy and doesn’t become an interrupting nag.