# Get access policy

Canonical page: https://docs.ovok.com/slim-apis/policy/get-access-policy

| Method | Path |
| --- | --- |
| `GET` | `/v1/slim/policy/:id` |

[Authentication](/authentication) · [Access policies](/access-policies)

Returns one access policy (role) with the practitioners who hold it.

**Auth:** Bearer token for a practitioner, project admin or System Owner session. The caller's access policy must grant `Practitioner:create`, the right to invite users (project admins skip this check).
**Scope:** The policy must belong to the caller's project (from the token), its parent project or one of its direct child projects.

## Request [#request]

### Path parameters [#path-parameters]

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | `string (uuid)` | Yes | Access policy id. |

## Behaviour [#behaviour]

- Read-only.
- Returns `{ policy, members }`. `policy` is the full `AccessPolicy`. `members` lists the `Practitioner` members whose membership points to it, as `{ reference, display }`.
- A policy that exists in a project outside your scope answers 403. An id that matches no policy answers 404.
- `members` lists only memberships whose `accessPolicy` is this policy. A membership that reaches the policy only through an `access` entry is not listed.


## Example [#example]

```bash
curl -X GET 'https://api.sandbox.ovok.com/v1/slim/policy/3f1c2b7e-8d4a-4c1e-9b2f-6a7d5e4c3b21' \
  -H "Authorization: Bearer ${OVOK_TOKEN}"
```

## Successful response [#successful-response]

`200` — Access policy retrieved successfully.

```json
{
  "policy": {
    "resourceType": "AccessPolicy",
    "id": "3f1c2b7e-8d4a-4c1e-9b2f-6a7d5e4c3b21",
    "name": "Night shift",
    "resource": [
      { "resourceType": "Patient", "interaction": ["read", "search", "update"] },
      { "resourceType": "Device", "interaction": ["read", "search"], "readonly": true },
      { "resourceType": "Consent", "interaction": ["read", "search", "create", "update"] }
    ],
    "meta": {
      "project": "1e6b8d30-2c4f-4a95-8d7e-b0a2c4e6f918",
      "author": { "reference": "Practitioner/5b8d2f90-1a3c-4e67-8d4b-7c9e0a2f1b63" },
      "lastUpdated": "2026-10-01T08:00:00.000Z"
    }
  },
  "members": [
    { "reference": "Practitioner/5b8d2f90-1a3c-4e67-8d4b-7c9e0a2f1b63", "display": "Demo Nurse" }
  ]
}
```

Optional fields are omitted when they have no value. They are not sent as `null`. See [AccessPolicy model and membership](/access-policies/policy-model) for what the rule fields mean.

| Field | Type | Description |
| --- | --- | --- |
| `policy` | `object` | The access policy, as stored. It is the policy resource passed through as is, so the FHIR server can add standard fields that are not listed here (for example `meta.versionId`). |
| `policy.resourceType` | `"AccessPolicy"` | Always `AccessPolicy`. |
| `policy.id` | `string (uuid)` | Policy id. |
| `policy.name` | `string` | Policy name. |
| `policy.resource` | `object[]` | The resource rules. Absent when the policy has none. |
| `policy.resource[].resourceType` | `string` | Resource type the rule covers, for example `Patient`. `*` covers every resource type. |
| `policy.resource[].interaction` | `string[]` | Allowed interactions: `read`, `create`, `update`, `delete`, `search`, `history`, `vread`. Absent when the stored rule has none. |
| `policy.resource[].criteria` | `string` | Optional FHIR search expression that limits which resources the rule applies to. Present only on rules created outside this API. |
| `policy.resource[].readonly` | `boolean` | Optional. `true` limits the rule to read-only behaviour. Present only on rules created outside this API. |
| `policy.meta` | `object` | Resource metadata. |
| `policy.meta.project` | `string (uuid)` | Id of the project the policy belongs to. |
| `policy.meta.author` | `object` | The profile that wrote the policy. |
| `policy.meta.author.reference` | `string` | Reference to the author, for example `Practitioner/<id>`. |
| `policy.meta.lastUpdated` | `string (ISO 8601 date-time)` | When the policy was last written. |
| `members` | `object[]` | The practitioners who hold the policy. Empty when nobody does. Other kinds of profile are not listed. |
| `members[].reference` | `string` | Practitioner reference, `Practitioner/<id>`. |
| `members[].display` | `string` | Display name, from the membership or the practitioner's name. Absent when neither has one. |

## Errors [#errors]

| Status | Meaning |
| --- | --- |
| [`401`](/errors/unauthenticated) | The bearer token is missing or invalid. |
| [`403`](/errors/forbidden) | The session is not a practitioner, admin or System Owner session, its access policy lacks `Practitioner:create`, or the policy is outside the caller's project scope. |
| [`404`](/errors/not-found) | No access policy has this id. |
| [`422`](/errors/validation-failed) | `id` is not a UUID. |
| [`503`](/errors/service-unavailable) | Your access policy could not be read, or the service is temporarily over capacity. Retry shortly, and honour `Retry-After` when it is present. |
