Documentation
¶
Index ¶
- Constants
- func BodyToMessageBytesFastHTTP(bodyType MessageBodyType, ctx *fasthttp.RequestCtx) []byte
- func BodyToMessageBytesNetHTTP(bodyType MessageBodyType, req *http.Request) []byte
- func ErrorInfosToAwsAPIGatewayProxyResponse(errs ...ErrorInfo) events.APIGatewayProxyResponse
- func GetMapString2Simple(mapSS map[string]string, key string) string
- type AwsAPIGatewayProxyOutput
- type ErrorInfo
- type HookData
- func HookDataFromAwsLambdaEvent(bodyType MessageBodyType, awsReq events.APIGatewayProxyRequest) HookData
- func HookDataFromEawsyLambdaEvent(bodyType MessageBodyType, eawsyReq *apigatewayproxyevt.Event) HookData
- func HookDataFromFastHTTPReqCtx(bodyType MessageBodyType, ctx *fasthttp.RequestCtx) HookData
- func HookDataFromNetHTTPReq(bodyType MessageBodyType, req *http.Request) HookData
- type MessageBodyType
Constants ¶
View Source
const ( QueryParamOutputAdapters = "adapters" QueryParamInputType = "inputType" QueryParamOutputType = "outputType" QueryParamToken = "token" QueryParamOutputURL = "url" )
Variables ¶
This section is empty.
Functions ¶
func BodyToMessageBytesFastHTTP ¶
func BodyToMessageBytesFastHTTP(bodyType MessageBodyType, ctx *fasthttp.RequestCtx) []byte
func BodyToMessageBytesNetHTTP ¶ added in v0.2.2
func BodyToMessageBytesNetHTTP(bodyType MessageBodyType, req *http.Request) []byte
func ErrorInfosToAwsAPIGatewayProxyResponse ¶ added in v0.2.2
func ErrorInfosToAwsAPIGatewayProxyResponse(errs ...ErrorInfo) events.APIGatewayProxyResponse
Types ¶
type AwsAPIGatewayProxyOutput ¶
type AwsAPIGatewayProxyOutput struct { IsBase64Encoded bool `json:"isBase64Encoded"` StatusCode int `json:"statusCode"` Body string `json:"body"` Headers map[string]string `json:"headers"` }
func ErrorInfosToAwsAPIGatewayProxyOutput ¶ added in v0.2.2
func ErrorInfosToAwsAPIGatewayProxyOutput(errs ...ErrorInfo) AwsAPIGatewayProxyOutput
func ErrorInfosToAlexaResponse(errs ...ErrorInfo) AwsAPIGatewayProxyOutput {
type ErrorInfo ¶
func ErrorsInfoToResponseInfo ¶ added in v0.2.2
type HookData ¶
type HookData struct { InputType string InputBody []byte OutputType string OutputURL string OutputNames []string Token string InputMessage []byte OutputMessage cc.Message }
func HookDataFromAwsLambdaEvent ¶ added in v0.2.2
func HookDataFromAwsLambdaEvent(bodyType MessageBodyType, awsReq events.APIGatewayProxyRequest) HookData
func HookDataFromEawsyLambdaEvent ¶
func HookDataFromEawsyLambdaEvent(bodyType MessageBodyType, eawsyReq *apigatewayproxyevt.Event) HookData
func HookDataFromFastHTTPReqCtx ¶
func HookDataFromFastHTTPReqCtx(bodyType MessageBodyType, ctx *fasthttp.RequestCtx) HookData
func HookDataFromNetHTTPReq ¶ added in v0.2.2
func HookDataFromNetHTTPReq(bodyType MessageBodyType, req *http.Request) HookData
type MessageBodyType ¶
type MessageBodyType int
const ( JSON MessageBodyType = iota URLEncoded URLEncodedJSONPayload URLEncodedJSONPayloadOrJSON )
Click to show internal directories.
Click to hide internal directories.