Hi there,
I am creating my first custom alexa skill.Kindly help me in the same.I have been getting this error every time. The intent response is generated but i am getting this error in logs.I really need help.KIndly help me to debug.
Hi there,
I am creating my first custom alexa skill.Kindly help me in the same.I have been getting this error every time. The intent response is generated but i am getting this error in logs.I really need help.KIndly help me to debug.
Share some code that does it. It seems that you are trying to read property 'type' which doesn't exist. Without seeing the code it is impossible to help you.
hi there,
{ "errorMessage": "Cannot read property 'type' of undefined", "errorType": "TypeError", "stackTrace": [ "Object.canHandle (/var/task/index.js:6:53)", "GenericRequestMapper.<anonymous> (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:69:61)", "step (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:44:23)", "Object.next (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:25:53)", "/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:19:71", "new Promise (<anonymous>)", "__awaiter (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:15:12)", "GenericRequestMapper.getRequestHandlerChain (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:58:16)", "GenericRequestDispatcher.<anonymous> (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/GenericRequestDispatcher.js:133:60)", "step (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/GenericRequestDispatcher.js:44:23)" ] }
i am always getting this error although the response is coming sometimes.also i ma getting audio response sometimes.
{ "errorMessage": "Cannot read property 'type' of undefined", "errorType": "TypeError", "stackTrace": [ "Object.canHandle (/var/task/index.js:6:53)", "GenericRequestMapper.<anonymous> (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:69:61)", "step (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:44:23)", "Object.next (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:25:53)", "/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:19:71", "new Promise (<anonymous>)", "__awaiter (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:15:12)", "GenericRequestMapper.getRequestHandlerChain (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:58:16)", "GenericRequestDispatcher.<anonymous> (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/GenericRequestDispatcher.js:133:60)", "step (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/GenericRequestDispatcher.js:44:23)" ] }
i am always getting this error though the response is coming.
Hi there,
{ "errorMessage": "Cannot read property 'type' of undefined", "errorType": "TypeError", "stackTrace": [ "Object.canHandle (/var/task/index.js:6:53)", "GenericRequestMapper.<anonymous> (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:69:61)", "step (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:44:23)", "Object.next (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:25:53)", "/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:19:71", "new Promise (<anonymous>)", "__awaiter (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:15:12)", "GenericRequestMapper.getRequestHandlerChain (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/request/mapper/GenericRequestMapper.js:58:16)", "GenericRequestDispatcher.<anonymous> (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/GenericRequestDispatcher.js:133:60)", "step (/var/task/node_modules/ask-sdk-runtime/dist/dispatcher/GenericRequestDispatcher.js:44:23)" ] }
I am always getting this error in response although my response is coming.Kindly help with this i am attaching the snaps.
Sure..Its actually coming with every handler
Remove the ";" character in the "return;" statements. It stop the code evaluation too early so your CheckHandler.handle function does not return a response.
Even i removed the error.It gives audio only response.What should i do.And the typeerror is not solved
Hey there, in your snap9.png, you are doing this
handlerInput.requestEnvelope.request.type == 'Check'
You mentioned in another forum thread by you that 'Check' is the name of the intent.
Instead you should be checking for intent name as below! Check out a sample that shows this.
handlerInput.requestEnvelope.request.intent.name == 'Check'
3 People are following this question.