Comments (2)
Hi,
This is because the Assistant App is expecting an options variable which is expecting the properties of options to contain request
and response
.
These two lines:
const appAi = new App({ request, response });
const appAi = new App({ req, res });
are giving completely different inputs
They are using ES6 property definitions short notation and are equivalent to:
const appAi = new App({ request: request, response: response });
const appAi = new App({ req: req, res: res });
If you have variables with the names req
and res
that you want to pass in, then do:
const appAi = new App({
request: req,
response: res
});
Can you elaborate on what you mean by With the others handlers that do not use this module everything works both with "req" or "request"
?
from actions-on-google-nodejs.
I get it, thanks for the prompt response. My mistake, other that I am a noob with JS, is that I took the sample from your documentation and not from the read.me in this project that is more clear.
The last part was to try to give you as much info as possible, what I was trying to say, is that in the other hanlders, were I was using the variables req and res I was not getting any sort of problem.
from actions-on-google-nodejs.
Related Issues (20)
- Support configuring loggers HOT 1
- Sign homegraph request using IAM API HOT 2
- Link Out Suggestion not working as expected
- smarthome Action: onSync response is invalid (according to GCP logs explorer) HOT 1
- How to bypass middleware and only get JSON response HOT 1
- queryText being sent to Dialogflow is not the original user query HOT 4
- Response is malformed HOT 1
- Smart Home: Cache authorization tokens HOT 14
- Smart Home: Allow to set https agent options HOT 1
- Error, Entity not found
- TypeError: Cannot read property '0' of undefined HOT 1
- npm audit has been reporting vulnerabilities since at least October 2020, please can we update dependencies? HOT 7
- account link success but action response error
- onDisconnect bug
- unable to trigger actions.intent.NO_MATCH HOT 2
- Can't find user access token in requests to fulfilment webhooks HOT 1
- Upgrade "google-auth-library" dependency to latest major version
- TypeError: Cannot read properties of undefined (reading '0')
- Turtorial on authentication
- Typescript doesn't compile with `strictNullChecks: true`
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from actions-on-google-nodejs.