lambda

package
v0.0.0-...-2ebb6ce Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 18, 2021 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package lambda defines intents, handles requests and calls Application functions accordingly.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewMux

func NewMux(app Application, sb *skill.SkillBuilder) alexa.Handler

NewMux returns a new handler for defined intents.

Types

type Application

type Application interface {
	log.Loggable
	stats.Statable

	Launch(l l10n.LocaleInstance) (alexa.Response, error)
	Help(l l10n.LocaleInstance) (alexa.Response, error)
	Stop(l l10n.LocaleInstance) (alexa.Response, error)
	SSMLDemo(l l10n.LocaleInstance) (alexa.Response, error)
	Demo(l l10n.LocaleInstance) (alexa.Response, error)
	AWSStatusRegionElicit(l l10n.LocaleInstance, r string) (alexa.Response, error)
	AWSStatusAreaElicit(l l10n.LocaleInstance, r string) (alexa.Response, error)
	SaySomething(l l10n.LocaleInstance, opts ...alfalfa.ResponseFunc) (alexa.Response, error)
	AWSStatus(l l10n.LocaleInstance, area, region string) (alexa.Response, error)
}

Application defines the interface used of the app.

type DefaultError

type DefaultError struct {
	Locale l10n.LocaleInstance
}

DefaultError is a generic error.

func (DefaultError) Error

func (m DefaultError) Error() string

Error returns a string.

func (DefaultError) Response

func (m DefaultError) Response(loc l10n.LocaleInstance) alexa.Response

Response returns a default error response.

Directories

Path Synopsis
Package middleware for lambda requests Package middleware for lambda requests
Package middleware for lambda requests Package middleware for lambda requests

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL