Skip to content

Instantly share code, notes, and snippets.

@kinisoftware
Last active March 4, 2019 09:38
Show Gist options
  • Select an option

  • Save kinisoftware/cfbb41343331084880f13cbba6524f5f to your computer and use it in GitHub Desktop.

Select an option

Save kinisoftware/cfbb41343331084880f13cbba6524f5f to your computer and use it in GitHub Desktop.
public class NewReleasesIntentHandler implements RequestHandler {
...
@Override
public Optional<Response> handle(HandlerInput input) {
Request request = input.getRequestEnvelope().getRequest();
IntentRequest intentRequest = (IntentRequest) request;
Intent intent = intentRequest.getIntent();
Map<String, Slot> slots = intent.getSlots();
Slot releasesDate = slots.get("releasesDate");
String dateValue = releasesDate.getValue();
System.out.println("Slot value:" + dateValue);
...
return responseBuilder.build();
}
...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment