---
title: RequestResourceUriProvider
description: Return a resource URL to include in policy decision requests to AM. The PolicyEnforcementFilter uses the returned resource URL as a key to identify cached policy decisions.
component: pinggateway
version: 2026
page_id: pinggateway:reference:RequestResourceUriProvider
canonical_url: https://docs.pingidentity.com/pinggateway/2026/reference/RequestResourceUriProvider.html
revdate: 2023-08-16T16:24:34Z
section_ids:
  usage: Usage
  properties: Properties
---

# RequestResourceUriProvider

Return a resource URL to include in policy decision requests to AM. The [PolicyEnforcementFilter](PolicyEnforcementFilter.html) uses the returned resource URL as a key to identify cached policy decisions.

To increase performance, use RequestResourceUriProvider in conjunction with AM policies to maximize the the cache hit ratio.

When a request matches a cached policy decision, PingGateway can reuse the decision without asking AM for a new decision. When caching is disabled, PingGateway must ask AM to make a decision for each request.

## Usage

```json
"resourceUriProvider": {
  "type": "RequestResourceUriProvider",
  "config": {
    "useOriginalUri": configuration expression<boolean>,
    "includeQueryParams": configuration expression<boolean>
  }
}
```

## Properties

* `useOriginalUri`: *configuration expression<[boolean](preface.html#definition-boolean)>, optional*

  When 'true\`, use the value of `UriRouterContext.originalUri` as the resource URL when requesting policy decisions from AM.

  When `false`, use the current `Request.uri` value. Consider that the value might have been modified by the `baseURI` of the route or by any other filter executed before the PolicyEnforcementFilter.

  Default: `false`

* `includeQueryParams`: *configuration expression<[boolean](preface.html#definition-boolean)>, optional*

  When `true`, include query parameters in the resource URL when requesting a policy decision from AM.

  When `false`, strip **all** query parameters from the resource URL when requesting a policy decision from AM. To strip some but not all query parameters, use [ScriptableResourceUriProvider](ScriptableResourceUriProvider.html).

  Default: `true`
