requesttransformer

package
v0.0.0-...-b06ef97 Latest Latest
Warning

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

Go to latest
Published: Jan 31, 2018 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewRequestTransformer

func NewRequestTransformer(config Config) func(http.Handler) http.Handler

NewRequestTransformer creates a new instance of RequestTransformer

Types

type Config

type Config struct {
	Add     Options `json:"add"`
	Append  Options `json:"append"`
	Remove  Options `json:"remove"`
	Replace Options `json:"replace"`
}

Config represent the configuration of the modify headers middleware

type Options

type Options struct {
	Headers     map[string]string `json:"headers"`
	QueryString map[string]string `json:"querystring"`
}

Options represents the available options to transform

Jump to

Keyboard shortcuts

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