logo
down
shadow

actions on google userStorage only during session


actions on google userStorage only during session

By : Perey
Date : September 30 2020, 10:00 PM
help you fix your problem Have those users enabled the Web & Activity setting and the include chrome history setting in the activity center? If these settings are not enabled the user storage won't persist to the next conversation and anything that you save will be lost.
code :


Share : facebook icon twitter icon
DialogFlow/Actions: Allow Google Assistant user to create Event in Google Calendar from Actions App

DialogFlow/Actions: Allow Google Assistant user to create Event in Google Calendar from Actions App


By : user413938
Date : March 29 2020, 07:55 AM
it helps some times Here are the "missing" steps after which I got this thing working. I am sure there must be alternate ways of doing this but I will suffice with this until I get some feedback here.
Note: Google Actions Console UI has changed so the screens in the original question maybe different (but are complete).
code :
string responseText = string.Empty;
string clientId = "DCuPWHknmv_k2xxxxxxxxxxxxxxxxx";     //Auth0 ClientId
string clientSecret = "7G3xlreFIULPZ9OtwlOxCX99xxxxxxxxxxxxxxxxxxx";    //Auth0 ClientSecret
string accessToken = jsonObject.SelectToken("originalRequest.data.user.accessToken").ToString();

try
{
    using (var httpClient = new HttpClient())
    {
        httpClient.DefaultRequestHeaders.Add("Authorization", "Bearer " + accessToken);
        var url = "https://xxx.auth0.com/userinfo";
        responseText = httpClient.GetStringAsync(url).Result;

        JObject jsonUserInfo = JObject.Parse(responseText);
        string userId = jsonUserInfo.SelectToken("sub").ToString();

        url = "https://xxx.auth0.com/oauth/token";
        var content = new FormUrlEncodedContent(new[]
        {
            new KeyValuePair<string, string>("client_id", clientId),
            new KeyValuePair<string, string>("client_secret", clientSecret),
            new KeyValuePair<string, string>("audience", "https://[domain].auth0.com/api/v2/"),
            new KeyValuePair<string, string>("grant_type", "client_credentials")
        });

        var postResult = httpClient.PostAsync(url, content).Result;
        jsonUserInfo = JObject.Parse(postResult.Content.ReadAsStringAsync().Result);
        accessToken = jsonUserInfo.SelectToken("access_token").ToString();

        httpClient.DefaultRequestHeaders.Remove("Authorization");
        httpClient.DefaultRequestHeaders.Add("Authorization", "Bearer " + accessToken);

        url = "https://xxx.auth0.com/api/v2/users/" + userId;
        jsonUserInfo = JObject.Parse(httpClient.GetStringAsync(url).Result);
        accessToken = jsonUserInfo.SelectToken("identities[0].access_token").ToString();
        userId = jsonUserInfo.SelectToken("identities[0].user_id").ToString();

        httpClient.DefaultRequestHeaders.Remove("Authorization");
        httpClient.DefaultRequestHeaders.Add("Authorization", "Bearer " + accessToken);

        url = "https://www.googleapis.com/calendar/v3/users/me/calendarList";
        responseText = httpClient.GetStringAsync(url).Result;
    }
}
Save data in userStorage outside the Google Assistant

Save data in userStorage outside the Google Assistant


By : Iron Manza
Date : March 29 2020, 07:55 AM
Hope this helps User storage is only available to you within your action. If you are interested in having this data available outside the context of your action, you may want to consider a third-party database service like Firebase.
Saving session data for Google Actions with Dialogflow and WebhookClient (v2 API)

Saving session data for Google Actions with Dialogflow and WebhookClient (v2 API)


By : Zachary Osgarby
Date : March 29 2020, 07:55 AM
will help you I had been saving my session variables as contexts, and it had been working fine in previous releases. , try
code :
conv.data = sessionVars;
google actions: conversation exit using actions sdk does not invoke actions.intent.CANCEL

google actions: conversation exit using actions sdk does not invoke actions.intent.CANCEL


By : Eco Chan
Date : March 29 2020, 07:55 AM
wish of those help Yes, you need to add something to your action.json for it to send you the CANCEL Intent. In your existing conversations object, add an inDialogIntents attribute with an array of objects giving the name of the CANCEL Intent. Something like this:
code :
"conversations": {
  "App": {
    "name": "...",
    "url": "...",
    "fulfillmentApiVersion": 2
    "inDialogIntents": [
      {
        "name": "actions.intent.CANCEL"
      }
    ]
  }
}
Unable to create a session entity with actions-on-google-nodejs

Unable to create a session entity with actions-on-google-nodejs


By : Jignesh shah
Date : March 29 2020, 07:55 AM
I wish this helpful for you Keep in mind that the Session Entity must be set to the values you want before it is expected to be matched in an Intent. You probably should do this right when your Action starts, in your case. So if you have your "Welcome" intent, and a "State Option" intent, where the "Option" entity is in the "State Option" intent, you should update "Option" in the "Welcome" intent. You can't do it in the "State Option" intent, because it needs to have matched the Entity already.
The two libraries do completely different things, and can work well together. You will need to get the session path from the original request body, which you can get from conv.request using the a-o-g library, and the entity path, which you'd have to set in some way.
Related Posts Related Posts :
  • Help writing database queries for derby?
  • Issues with Trac (installed with BitNami)
  • Using Ghostscript in server mode to convert PDFs to PNGs
  • What's the case when using software licensed under GPL or LGPL
  • Is there any less or more convenient iDoc Script editor for Oracle 10g UCM?
  • What are the most popular RSS readers? (software/web apps)
  • MPICH vs OpenMPI
  • Why are not all texts of my MFC applicatiopn displayed using ClearType?
  • Should I focus on code quality while Rapid prototyping?
  • how to get response in QtWebKit
  • Silverlight - Access the Layout Grid's DataContext in a DataGrid CellTemplate's DataTemplate?
  • is it possible to set specific file extensions as exclusive check out only, with TFS
  • JasperReports: is it possible to use multiple data sources, or if not, to use collections in parameters?
  • Is there a 2d sprite library for webgl?
  • Error: NAND: could not write file /hd2/android-sdk-linux_86/add-ons/google_apis-7_r01/images//system.img, File exists
  • how to configure and use jstl in websphere
  • What does => mean in Ada?
  • Maven best practice for generating artifacts for multiple environments [prod, test, dev] with CI/Hudson support?
  • Maven best practice for generating multiple jars with different/filtered classes?
  • Usage of # in Pascal
  • Generics and polymorphism
  • Concurrent call to conversation
  • polymorphism relates inheritance
  • Maximum values in wherein clause of mysql
  • Forbid developer to commit code because of making weekly build
  • Automatically adjustment of wxPython Frame Size
  • how to import a file into mathematica and reference a column by header name
  • How to integrate junit/pmd/findbugs report into hudson build email?
  • In Symfony, sharing data across subdomains
  • In MediaWiki, is it possible to capture user search terms that don't return results?
  • How to check in what language a program (.exe) has been written. How to view the code?
  • Can I automap a tree hierarchy with Fluent NHibernate?
  • How to adjust the distribution of values in a random data stream?
  • Optimizing SMO with RBFKernel (C and gamma)
  • How to wait for one second on an 8051 microcontroller?
  • Major sites browser incompatibilities
  • What tools do you use to manage Change requests and Bug Reports
  • Silverlight -RIA Services-This EntitySet of type <> does not support the 'Add' operation
  • How to monitor windows manchine in grafana using prometheus?
  • Produce new word2vec model from existing one
  • Migrating Rails from Asset Pipeline to Webpacker: Uncaught ReferenceError: $ is not defined in rails-ujs.js
  • Extract lines with string and variable number pattern
  • Configuration priority - best practise
  • WebAssembly dynamic module unloading
  • Call SWS Via Sabre Red Workspace From Native API Bridge Application
  • How to set query timeout when using Presto CLI?
  • What's the difference between agent.add() and conv.ask() on dialogflow
  • Pymodbus - Read input register of Energy meter over rs485 on uart of raspberry pi3
  • Execute bash script on a dataproc cluster from a composer
  • Gremlin: select vertex based on comparison of two property values
  • How do you createRef in Suave Fable?
  • I am having trouble building Azerothcore on Windows 10 Home, VS 2017
  • Why is testcafe-docker.sh ignoring app-init-delay parameter?
  • DynamoDB Adjacency List Pattern
  • Is there a way for my aplication to detect beacons in Powerapps?
  • "Initialize interactive with Project" is missing for .Net Core Projects in Visual Studio 2019
  • Cosmos db Order by on 'computed field'
  • let a rpm to automatically install centos-release-scl-rh
  • What is the "Stage" folder inside MarkLogic Installed Directory? How does MarkLogic use this folder?
  • Implement requestHooks in cucumber/testCafe
  • shadow
    Privacy Policy - Terms - Contact Us © 35dp-dentalpractice.co.uk