# YarpRouteMatch

- Module: [Aspire.Hosting.Yarp](/reference/api/go/aspire.hosting.yarp.md)
- Version: `17.0.0`
- Kind: `struct`
- Source: [GitHub](https://github.com/microsoft/aspire/tree/2d325b13709752ba6d9a943635c5e2940a2530c0)

Represents route match criteria for a YARP route.

## Definition

```go
type YarpRouteMatch struct {
    Path            *string                         `json:"Path"`
    Methods         []string                        `json:"Methods"`
    Hosts           []string                        `json:"Hosts"`
    Headers         []*YarpRouteHeaderMatch         `json:"Headers"`
    QueryParameters []*YarpRouteQueryParameterMatch `json:"QueryParameters"`
}
```

## Fields

- `Path`: `*string` -- Gets or sets the path pattern to match.
- `Methods`: `[]string` -- Gets or sets the HTTP methods to match.
- `Hosts`: `[]string` -- Gets or sets the host headers to match.
- `Headers`: [`[]*YarpRouteHeaderMatch`](/reference/api/go/aspire.hosting.yarp/yarprouteheadermatch.md) -- Gets or sets the header match criteria.
- `QueryParameters`: [`[]*YarpRouteQueryParameterMatch`](/reference/api/go/aspire.hosting.yarp/yarproutequeryparametermatch.md) -- Gets or sets the query parameter match criteria.
