Skip to content

Commit

Permalink
caddyhttp: Updated the documentation for MatchQuery (#4295)
Browse files Browse the repository at this point in the history
  • Loading branch information
smebberson committed Aug 20, 2021
1 parent a056fcd commit c1cd192
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion modules/caddyhttp/matchers.go
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,19 @@ type (
// MatchMethod matches requests by the method.
MatchMethod []string

// MatchQuery matches requests by URI's query string.
// MatchQuery matches requests by the URI's query string. It takes a JSON object
// keyed by the query keys, with an array of string values to match for that key.
// Query key matches are exact, but wildcards may be used for value matches. Both
// keys and values may be placeholders.
// An example of the structure to match `?key=value&topic=api&query=something` is:
//
// ```json
// {
// "key": ["value"],
// "topic": ["api"],
// "query": ["*"]
// }
// ```
MatchQuery url.Values

// MatchHeader matches requests by header fields. It performs fast,
Expand Down

0 comments on commit c1cd192

Please sign in to comment.