---
title: "Execute a policy"
method: GET
path: "/v1/data/{path}"
---

# Execute a policy

`GET /v1/data/{path}`

## Path parameters

- `path` string, urlPath, required

## Query parameters

- `pretty` boolean
- `provenance` boolean
- `explain` 'notes' | 'fails' | 'full' | 'debug'
- `metrics` boolean
- `instrument` boolean
- `strict-builtin-errors` boolean

## Headers

- `Accept-Encoding` 'gzip'

## Response `200`

Success.
The server also returns 200 if the path refers to an undefined document. In this case, the response will not contain a result property.

- SuccessfulPolicyResponse
  - `result` union — The base or virtual document referred to by the URL path. If the path is undefined, this key will be omitted.
    - boolean
    - string
    - number
    - unknown[]
      - unknown
    - object
  - `metrics` object — If query metrics are enabled, this field contains query performance metrics collected during the parse, compile, and evaluation steps.
  - `decision_id` string — If decision logging is enabled, this field contains a string that uniquely identifies the decision. The identifier will be included in the decision log event for this decision. Callers can use the identifier for correlation purposes.
  - `provenance` Provenance — Provenance information can be requested on individual API calls and are returned inline with the API response. To obtain provenance information on an API call, specify the `provenance=true` query parameter when executing the API call.
    - `version` string
    - `build_commit` string
    - `build_timestamp` string, date-time
    - `build_host` string
    - `bundles` object

## Other responses

- `400` — Bad Request
- `500` — Server Error

---

[API](https://skmtc.dev/open-policy-agent/apis/eopa-rest-api.md) · [All operations](https://skmtc.dev/open-policy-agent/apis/eopa-rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/open-policy-agent/eopa-rest-api/revisions/040f3d9e6786/schema)
