handlers

package
v0.8.15 Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2024 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const (
	QueryParamNamedOutputs    = config.ParamNameAdapters
	QueryParamInputType       = config.ParamNameInputType
	QueryParamOutputType      = config.ParamNameOutputType
	QueryParamOutputURL       = config.ParamNameOutputURL
	QueryParamToken           = config.ParamNameToken
	QueryParamDefaultActivity = config.ParamNameActivityDefault
	QueryParamDefaultIcon     = config.ParamNameIconDefault
)
View Source
const (
	DisplayName = "base_handler"
)

Variables

View Source
var (
	ShowDisplayName = false
)

Functions

func HomeHandler

func HomeHandler(ctx *fasthttp.RequestCtx)

HomeHandler is a fasthttp handler for handling the webhoo proxy homepage.

func IntegrationActivitySuffix

func IntegrationActivitySuffix(displayName string) string

Types

type Configuration

type Configuration struct {
	ConfigData config.Configuration
	AdapterSet adapters.AdapterSet
}

type Handler

type Handler struct {
	Config          config.Configuration
	AdapterSet      adapters.AdapterSet
	Key             string
	Normalize       Normalize
	MessageBodyType models.MessageBodyType
}

func NewTemplatedHandler

func NewTemplatedHandler(tmpl string) Handler

func (Handler) HandleAnyHTTP

func (h Handler) HandleAnyHTTP(aRes anyhttp.Response, aReq anyhttp.Request)

HandleNetHTTP is the method to respond to a fasthttp request.

func (Handler) HandleAwsLambda

HandleAwsLambda is the method to respond to a fasthttp request.

func (Handler) HandleCanonical

func (h Handler) HandleCanonical(hookData models.HookData) []models.ErrorInfo

HandleCanonical is the method to handle a processed request.

func (Handler) HandleFastHTTP

func (h Handler) HandleFastHTTP(ctx *fasthttp.RequestCtx)

HandleFastHTTP is the method to respond to a fasthttp request.

func (Handler) HandleNetHTTP

func (h Handler) HandleNetHTTP(res http.ResponseWriter, req *http.Request)

HandleNetHTTP is the method to respond to a fasthttp request.

type HandlerRequest

type HandlerRequest struct {
	Env         map[string]string // handler environment
	QueryParams url.Values        // query string params
	Body        []byte            // message, e.g. request body
}

func NewHandlerRequest

func NewHandlerRequest() HandlerRequest

Jump to

Keyboard shortcuts

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