skipper: github.com/zalando/skipper/predicates/cookie Index | Files

package cookie

import "github.com/zalando/skipper/predicates/cookie"

Package cookie implements prediate to check parsed cookie headers by name and value.

Index

Package Files

cookie.go

Constants

const Name = "Cookie"

The predicate can be referenced in eskip by the name "Cookie".

func New Uses

func New() routing.PredicateSpec

New creates a predicate specification, whose instances can be used to match parsed request cookies.

The cookie predicate accepts two arguments, the cookie name, with what a cookie must exist in the request, and an expression that the cookie value needs to match.

Eskip example:

Cookie("tcial", /^enabled$/) -> "https://www.example.org";

Package cookie imports 4 packages (graph) and is imported by 6 packages. Updated 2018-01-03. Refresh now. Tools for package owners.