alexa-verifier set the "verify" flag to true and calling from a non echo throws an error
See original GitHub issueI used the example code here:
var AlexaAppServer = require("alexa-app-server");
var server = new AlexaAppServer( {
port:3000
,verify: true
,public_html: "public"
// Use preRequest to load user data on each request and add it to the request json.
// In reality, this data would come from a db or files, etc.
,preRequest: function(json,req,res) {
//console.log("preRequest fired");
//json.userDetails = { "name":"Bob Smith" };
}
// Add a dummy attribute to the response
,postRequest: function(json,req,res) {
//json.dummy = "text";
}
} );
server.start();
and added the verify flag so that I can pass the skills certification. When I try to make a request through postman it does fail (which is good) but It’s not throwing a 500, instead it throws the following error:
ReferenceError: er is not defined
at Object.handle (/my/path/node_modules/alexa-app-server/index.js:97:57)
at next_layer (/my/path/node_modules/alexa-app-server/node_modules/express/lib/router/route.js:103:13)
at Route.dispatch (/my/path/node_modules/alexa-app-server/node_modules/express/lib/router/route.js:107:5)
at /my/path/node_modules/alexa-app-server/node_modules/express/lib/router/index.js:195:24
at Function.proto.process_params (/my/path/node_modules/alexa-app-server/node_modules/express/lib/router/index.js:251:12)
at next (/my/path/node_modules/alexa-app-server/node_modules/express/lib/router/index.js:189:19)
at Layer.handle (/my/path/node_modules/alexa-app-server/index.js:79:15)
at trim_prefix (/my/path/node_modules/alexa-app-server/node_modules/express/lib/router/index.js:226:17)
at /my/path/node_modules/alexa-app-server/node_modules/express/lib/router/index.js:198:9
at Function.proto.process_params (/my/path/node_modules/alexa-app-server/node_modules/express/lib/router/index.js:251:12)
at next (/my/path/node_modules/alexa-app-server/node_modules/express/lib/router/index.js:189:19)
at next (/my/path/node_modules/alexa-app-server/node_modules/express/lib/router/index.js:166:38)
at Layer.staticMiddleware [as handle] (/my/path/node_modules/alexa-app-server/node_modules/serve-static/index.js:55:61)
at trim_prefix (/my/path/node_modules/alexa-app-server/node_modules/express/lib/router/index.js:226:17)
at /my/path/node_modules/alexa-app-server/node_modules/express/lib/router/index.js:198:9
at Function.proto.process_params (/my/path/node_modules/alexa-app-server/node_modules/express/lib/router/index.js:251:12)
at next (/my/path/node_modules/alexa-app-server/node_modules/express/lib/router/index.js:189:19)
at IncomingMessage.<anonymous> (/my/path/node_modules/alexa-app-server/index.js:184:5)
at emitNone (events.js:86:13)
at IncomingMessage.emit (events.js:185:7)
at endReadableNT (_stream_readable.js:974:12)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
Issue Analytics
- State:
- Created 7 years ago
- Comments:15 (3 by maintainers)
Top Results From Across the Web
Error trying to verify phone number
When trying to access the calling / messaging tab in the Alexa app I get the message "An error occurred trying to verify...
Read more >SyntaxError: Cannot use import statement outside a module
Verify that you have the latest version of Node.js installed (or, ... add "--experimental-modules" flag to the Node.js call.
Read more >Untitled
Aleva brands are all anchored by a set of core values to ensure the best ... Amazon really wants people to use the...
Read more >Untitled
Alexa CLI Says everything was packaged with no errors. ... She set out to create a fun package for people of varying age...
Read more >Untitled
She set out to create a fun package for people of varying age ranges to find food that sparks onder and fun no...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I’m saying that I don’t know much about it, I didn’t write this code or actually used it myself 😉 Others like @tejashah88 or @mreinstein will know a lot more!
Closed via https://github.com/alexa-js/alexa-app-server/pull/51, thanks @mreinstein.