Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add APL_USER_EVENT type request and require session if request type is it #138

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/core/SkillRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ export class RequestType {
public static AUDIO_PLAYER_PLAYBACK_NEARLY_FINISHED = "AudioPlayer.PlaybackNearlyFinished";
public static AUDIO_PLAYER_PLAYBACK_STARTED = "AudioPlayer.PlaybackStarted";
public static AUDIO_PLAYER_PLAYBACK_STOPPED = "AudioPlayer.PlaybackStopped";
public static APL_USER_EVENT = "Alexa.Presentation.APL.UserEvent";
}

export enum SessionEndedReason {
Expand Down Expand Up @@ -203,6 +204,7 @@ export class SkillRequest {
// we will make one first if there is not. It will then be ended.
return (this._json.request.type === RequestType.LAUNCH_REQUEST
|| this._json.request.type === RequestType.DISPLAY_ELEMENT_SELECTED_REQUEST
|| this._json.request.type === RequestType.APL_USER_EVENT
|| this._json.request.type === RequestType.INTENT_REQUEST
|| this._json.request.type === RequestType.SESSION_ENDED_REQUEST);
}
Expand Down