Stay organized with collections
Save and categorize content based on your preferences.
Index
Constructors
Properties
Constructors
constructor
-
Parameters
-
requestId: string
Request ID of the intent.
-
Optional errorCode: undefined | string
The cause for this error. For more details on error codes, see errors and exceptions.
-
Optional debugString: undefined | string
Human readable description of this error
Returns HandlerError
-
Properties
Optional debugString
Human readable description of this error
errorCode
The cause for this error
message
name
requestId
Request ID from the associated EXECUTE
intent.
Use the
HandlerError
class to return an error status from your intent handler code. Classes such as DeviceManager return an instance ofHandlerError
when an error occurs. For other errors that may occur in your app, you can create a new instance and return a rejectedPromise
.identifyHandler(request: IntentFlow.IdentifyRequest): Promise<IntentFlow.IdentifyResponse> { const scanData = request.inputs[0].payload.device.udpScanData; if (!scanData) { const err = new IntentFlow.HandlerError(request.requestId, ErrorCode.INVALID_REQUEST, 'Scan data not found'); return Promise.reject(err); } ... }
Errors returned by your app are visible in your cloud project logs. For more details, see the error logging developer guide.