# Practice endpoint directory

Canonical URL: https://docs.chartvoyant.com/endpoint-directory/
Endpoint: `GET https://chartvoyant.com/fhir/service-base-urls.json`

A public FHIR Bundle listing every active ChartVoyant practice and the exact FHIR base URL for each. It is how an app finds a patient's practice before it authorizes.

## At a glance

| Status | Live. |
| --- | --- |
| URL | `https://chartvoyant.com/fhir/service-base-urls.json` |
| Authentication | None. Free, with no registration. |
| Format | A FHIR R4 `collection` Bundle of `Organization` and `Endpoint` resources, served as `application/fhir+json`. |
| Freshness | Generated from active customer practices on every request, and may be cached for five minutes. New practices and name changes appear automatically. Internal synthetic test offices are excluded. |
| CORS | Readable cross-origin from any site. |

## Format

Each Organization points at its Endpoint (synthetic, abridged example):

```
{
  "resourceType": "Bundle",
  "type": "collection",
  "entry": [
    { "resource": { "resourceType": "Organization", "id": "EXAMPLE_ORG",
        "name": "Example Family Practice",
        "endpoint": [{ "reference": "Endpoint/EXAMPLE_ENDPOINT" }] } },
    { "resource": { "resourceType": "Endpoint", "id": "EXAMPLE_ENDPOINT",
        "status": "active",
        "payloadMimeType": ["application/fhir+json"],
        "address": "https://fhir.chartvoyant.com/r4/example-practice" } }
  ]
}
```

## How to use it

- **Choose the practice** Let the patient pick their practice by its Organization name. Never infer a practice from a patient identifier.

- **Take the Endpoint address unchanged** Resolve `Organization.endpoint` against the matching Endpoint entry. Its `address` is the FHIR base and the `aud` for authorization.

- **Discover** Fetch `{base}/.well-known/smart-configuration` and `{base}/metadata`, then follow [SMART App Launch](https://docs.chartvoyant.com/smart-app-launch/).
