alexa / alexa-skills-kit-sdk-for-java

The Alexa Skills Kit SDK for Java helps you get a skill up and running quickly, letting you focus on skill logic instead of boilerplate code.
http://developer.amazon.com/ask
Apache License 2.0
818 stars 748 forks source link

Hello World Servlet - There was a problem with the requested skill's response #272

Closed rcrespir closed 2 years ago

rcrespir commented 3 years ago

I'm submitting a...

[ ] Performance issue

Expected Behavior

I am following the Hello World Skill Servlet step by step, and when testing the skill in dev portal using "open hello world" I should receive response: "Hello world".

I am using windows 10 on PC, with disabled firewall

Current Behavior

When testing the skill in dev portal using "open hello world" I get : "There was a problem with the requested skill's response" and POST /helloworldservlet/main 404 in ngrok.

This is what I have ( I am very new on Web service applications):

· Java Web Application using Maven, with sample source code of Hello World Skill Servlet · This is my web.xml config:

  <display-name>helloworldservlet</display-name>

    <servlet>
        <servlet-name>helloworldservlet</servlet-name>
        <servlet-class>com.ibercomp.ask.helloworldservlet.HelloWorldSkillServlet</servlet-class>
    </servlet>
    <servlet-mapping>
        <servlet-name>helloworldservlet</servlet-name>
        <url-pattern>/main</url-pattern>
    </servlet-mapping>

· Tomcat 9.0. server running, with HelloWorldSkillServlet.war inside /webapps ·This is my connectors configuration for Tomcat in server.xml:

    <Connector port="8080" protocol="HTTP/1.1"
               connectionTimeout="20000"
               redirectPort="8443" /> 

· ngrok running with ngrok http 8080

Version                       2.3.35
Region                        United States (us)
Web Interface                 http://127.0.0.1:4040
Forwarding                    http://cf14de59095d.ngrok.io -> http://localhost:8080
Forwarding                    https://cf14de59095d.ngrok.io -> http://localhost:8080

On developers portal I have the next config (Built successfully):

{
    "interactionModel": {
        "languageModel": {
            "invocationName": "hello world",
            "modelConfiguration": {
                "fallbackIntentSensitivity": {
                    "level": "LOW"
                }
            },
            "intents": [
                {
                    "name": "AMAZON.CancelIntent",
                    "samples": [
                        "cancel now"
                    ]
                },
                {
                    "name": "AMAZON.HelpIntent",
                    "samples": [
                        "Help now"
                    ]
                },
                {
                    "name": "AMAZON.StopIntent",
                    "samples": [
                        "Stop now"
                    ]
                },
                {
                    "name": "HelloWorldIntent",
                    "slots": [],
                    "samples": [
                        "what's up",
                        "hello",
                        "how are you",
                        "say hi world",
                        "say hi",
                        "hi",
                        "say hello world",
                        "say hello"
                    ]
                },
                {
                    "name": "AMAZON.NavigateHomeIntent",
                    "samples": []
                },
                {
                    "name": "AMAZON.FallbackIntent",
                    "samples": [
                        "Fall now"
                    ]
                }
            ],
            "types": []
        }
    }
}

And here my Endpoint configuration:

HTTPS > default region: https://cf14de59095d.ngrok.io/helloworldservlet/main "My development endpoint is a sub-domain..."

Context

What I am missing? It could be a router configuration issue or something port related?

Kind Regards

Your Environment

Java Info

kkocel commented 3 years ago

Did you observe any logs on ngrok?

doiron commented 2 years ago

this issue seems stale. Closing, please feel free to re-open if the issue persists