Documentation
¶
Index ¶
- func AlexaError(type_ types.ErrorType, headerMessageId string, message string, ...) *amsapi.Response
- func AudioError(type_ types.ErrorType, headerMessageId string, message string, ...) *amsapi.Response
- func MediaError(type_ types.ErrorType, headerMessageId string, message string, ...) *amsapi.Response
- type ErrorPayload
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AlexaError ¶
func AlexaError(type_ types.ErrorType, headerMessageId string, message string, subtypes ...types.ErrorType) *amsapi.Response
AlexaError returns a general error response body. https://developer.amazon.com/en-US/docs/alexa/music-skills/api-error-response.html#general-errors
func AudioError ¶
func AudioError(type_ types.ErrorType, headerMessageId string, message string, retryPeriod types.AudioSkipRetryPeriod) *amsapi.Response
AudioError returns audio specific response body. https://developer.amazon.com/en-US/docs/alexa/music-skills/api-error-response.html#audio-specific-errors
Types ¶
type ErrorPayload ¶
type ErrorPayload struct {
Type types.ErrorType `json:"type"`
SubTypes []types.ErrorType `json:"subtypes,omitempty"`
Message string `json:"message"`
RetryPeriod types.AudioSkipRetryPeriod `json:"retryPeriod,omitempty"`
}
ErrorPayload is the response payload used by AlexaError, MediaError, and AudioError. SubTypes and RetryPeriod are only valid for certain error types.
Click to show internal directories.
Click to hide internal directories.