• Public
  • Public/Protected
  • All

Class ControlInput

Defines an expanded input object passed around during processing by Controls.


  • Provides access to the HandlerInput and also conveniences such as simplified access to the Request object, a turn counter and a map of all controls in the control tree.


  • ControlInput




  • new ControlInput(handlerInput: HandlerInput, turnNumber: number, controlMap: object): ControlInput
  • Parameters

    • handlerInput: HandlerInput
    • turnNumber: number
    • controlMap: object

    Returns ControlInput


Readonly controls

controls: object

All the controls of the control tree, indexed by controlID.


  • This provides direct access to all other controls in the control tree which can be convenient for occasional use but it increases the coupling of specific controls.
  • When controls are close to one another, it is preferable to have their parents coordinate data transfer, e.g. by get() from one and set() on the other.
  • If controls that are not close to one another routinely need to share information it would be best to create an external datastore. Consider Redux or similar solutions.

Type declaration

Readonly handlerInput

handlerInput: HandlerInput

The input from {@link CustomSkillRequestHandler}

Readonly request

request: Request

The request object

This is a convenience for handlerInput.requestEnvelope.request.

Readonly turnNumber

turnNumber: number

The number of incoming requests during the user session.