Chatbase API to get analytics data? - chatbase

We are using Chatbase for multiple clients that we identify with a different version number.
See my previous question here: Track multiple context for the same Bot
We have a dashboard for all those clients and would like to show them their own data. A bit like Google analytics allows it.
So:
Is an API in the pipeline (I couldn't find any existing resources)
If not, in what alternative way could we get the data to present it?

We have a .csv export that is currently limited to the first 500 rows of your message variations report. It is on our roadmap to increase the scope of this report, however there is no official timeline for release.
Our recommendation for deploying an integration like you described in your message is as follows:
Have the user create a Chatbase account in order to obtain the API key
Have the user integrate their analytics on your platform by providing the API key
Send the messages from their bot to their Chatbase API
Provide the user deeplinks to the Chatbase reports from within your UI
Alternatively, you could configure your bot to send a redundant message to an internal database, or bigquery table to have access to all of your logs.
If you would like access to data you have sent to Chatbase up to this point, please contact chatbase-support#google.com and provide your bot's name and/or api key and we can provide a one-time export.

Related

Azure Api Management log user accessed api

Is there any rest api that can be used to fetch api access detail for a user. To know how many times a user accessed a api and how many success or failure request were there. i am not able to use log-to-eventhub.
Thanks to #MayankBargali-MSFT's Q&A answer to similar kind of issue and posting here to help other community members!
Azure APIM will do monitor the APIs published but only listed details are logged as per the APIManagementGatewayLogs.
Based on your requirement, leveage the APIM reporting API and refer to Microsoft Doc for more information on reporting API.
To know who the user accessed particular API in APIM recently, You can call the List by Request API by adding the filter (For example, last 4 days from this day, apiID, etc.).
The above response will provide the details like apiID, timeStamp, userID that helps to find the details.
Still paraphrasing #MayankBargali-MSFT from the post linked above:
To know how many time that user accessed the API, use List by User API where it gives the overall result in which we need to filter with the apiID, then you can get the API Level count.
Point to note here is:
Filter might not work for every column. Therefore, you must modify the outcome at your client's end to perform more filtering and obtain the appropriate result. For further information, kindly consult the relevant API document. As long as you don't delete the APIM instance, the data will continue to be maintained permanently.

Is it possible to add custom application data to an email via the Gmail API?

I am currently sending email via the Gmail API using the Google Node SDK. I am successful in doing so, but my application requires that I be able to attach specific identifiers to emails that I send in order to be able to track and process certain events correctly.
I have heard of custom metadata being added to emails sent through other services such as Mailchimp, Postmark, etc so it seems like some sort of standard to be able to do this in email. I however, have not been able to find how to do this via the Gmail API specifically. Is this even possible?
Answer:
No, you cannot add custom application data to messages sent via Gmail API.
Reference:
The corresponding Message resource doesn't include any property for custom metadata.
And the related methods send and insert don't allow this either.
Issue Tracker:
A related feature request was reported in Issue Tracker, I'd suggest you to star it:
Add Custom Metadata to Email Messages via Gmail Api
Workaround:
I'd suggest you to use labels to identify messages.

How to get User credentials in Azure chatbots

I have created a baisc QnA Bot using Azure services. But now after deploying the bot. I want it to be able to receive user mail id. So that I can give specific results on basis of the user currently using the bot.
Is it possible?
And what is the correct way of doing so.
Thanks in advance.
Please refer to the suggestion mentioned in this SO thread.
For details about how to obtain an access token for your bot, see Authenticate requests from your bot to the Bot Connector service.
Write directly to storage Azure blob transcript storage provides a specialized storage option that allows you to easily save and retrieve user conversations in the form of a recorded transcript.

Send push notifications to audience defined by BigQuery result

Is any possibility trigger push notifications for specific group of users which is defined by BigQuery result. Is any way how to connect Firebase push notifications and BigQuery without programming some own backend service?
Use case is notify users based on retention other parameters queried from BigQuery.
I reached dead end in searching. So I am asking for help from someone skilled in google services or just way where to continue.
Thank you.
Unfortunately, for now, BigQuery doesn't provide a notification system. You could create a feature request here.
Alternately, you could do this using some scripting, I found an interesting Stackoverflow topic, about sending an e-mail to users defined in a BQ table, by using Firebase Cloud Functions.
I hope it helps.

Watching hashtags with tweepy after API Update

Twitter is updating their API and by updating they mean shutting down some services such as the Streaming API.
Sadly enough, I am using these streaming APIs on my bot to watch either messages posted with a certain hashtag and messages sent by mentionning the account or commands sent by direct messages.
And I found no idea on how to migrate to the new API. Any idea ?
For now I'm using this :
mainStream = tweepy.Stream(auth=api.auth, listener= mainStreamListener())
mainStream.filter(track=[Hashtag], is_async=True)
cmdStream = tweepy.Stream(auth=api.auth, listener= cmdStreamListener())
cmdStream.userstream(is_async=True)
Only one of the two streaming APIs that you are using is currently about to be removed (user streams is being removed, filter is not, but is on Twitter's roadmap for replacement in the future).
If you are interested in how to migrate to the Account Activity API, Twitter has a migration guide here. The basic principle is that your code would need to register a webhook and subscription for the user's account activity messages, and then respond to Direct Message events (instead of the code you're currently implementing in the cmdStream section). I do not know whether the tweepy library currently has specific support for the Account Activity API.

Resources