skipper: Index | Files

package cookie

import ""

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


Package Files



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$/) -> "";

Package cookie imports 4 packages (graph) and is imported by 6 packages. Updated 2020-04-12. Refresh now. Tools for package owners.