ChartVoyant Developers
Markdown

FHIR R4 & SMART

SMART App Launch

LiveONC certification in progress

Connect a patient's chosen app, or a clinician's app, to a ChartVoyant practice with SMART App Launch 2. The person signs in and consents, and your app receives a token scoped to what they approved.

Authorize https://auth.chartvoyant.com/oauth/authorize

At a glance

StatusLive in production for read access. Write scopes for SMART write are deployed and granted per practice and app.
VersionSMART App Launch 2 (STU2). SMART v2 scopes and SMART v1 read scopes are both accepted. SMART v1 write scopes are refused.
LaunchesStandalone patient, standalone clinician, and EHR launch from inside the chart.
Client typesPublic and native (none), confidential symmetric (client_secret_basic), confidential asymmetric (private_key_jwt, RS384 or ES384).
SecurityAuthorization code with PKCE S256 on every flow; plain or missing PKCE is rejected. aud must equal the practice's FHIR base. Redirect URIs must match registration exactly.
IdentityOpenID Connect with openid fhirUser. ID tokens are signed RS256.
CostNo fee and no revenue share.

Endpoints

Read them from discovery rather than hard-coding them:

EndpointURL
Discoveryhttps://fhir.chartvoyant.com/r4/{practice}/.well-known/smart-configuration
OpenID configurationhttps://auth.chartvoyant.com/.well-known/openid-configuration
Authorizehttps://auth.chartvoyant.com/oauth/authorize (GET or POST)
Tokenhttps://auth.chartvoyant.com/oauth/token
Introspecthttps://auth.chartvoyant.com/oauth/introspect
Revokehttps://auth.chartvoyant.com/oauth/revoke
Public signing keyshttps://auth.chartvoyant.com/oauth/jwks.json
Dynamic registrationhttps://auth.chartvoyant.com/oauth/register — creates an app disabled at every practice until ChartVoyant enables it there; see How to register an app.
Stylehttps://fhir.chartvoyant.com/r4/{practice}/.well-known/smart-style.json, so an embedded app can match the chart.

Launch flows

FlowHow it works
Patient standaloneThe patient signs in with their existing portal account, chooses the practice where applicable, and reviews consent. They can uncheck a resource class or narrow a supported category. The token carries the patient context; the app cannot name a different patient.
Clinician standaloneThe clinician completes staff sign-in and MFA, selects a patient, and consents. The ID token's fhirUser names their Practitioner resource.
EHR launchThe clinician opens a chart and selects your app's tile. ChartVoyant calls your launch URL with iss and an opaque launch. The token response includes patient, encounter when present, need_patient_banner, and smart_style_url.

Authorize request (synthetic placeholders)

GET https://auth.chartvoyant.com/oauth/authorize
  ?response_type=code
  &client_id=YOUR_CLIENT_ID
  &redirect_uri=https://your-app.example/callback
  &aud=https://fhir.chartvoyant.com/r4/your-practice
  &scope=launch/patient openid fhirUser offline_access patient/Patient.rs patient/Observation.rs
  &code_challenge=BASE64URL_SHA256_OF_VERIFIER&code_challenge_method=S256
  &state=RANDOM_STATE&nonce=RANDOM_NONCE

Native apps may use exact registered loopback (localhost or 127.0.0.1) or HTTPS callbacks. Custom URI schemes are not supported. The SMART on FHIR-4 developer guide includes complete PKCE code for each flow.

Scopes

ScopeMeaning
patient/{Type}.rsRead and search within the patient's context. .r and .s alone are accepted.
user/{Type}.rsRead and search what the authorizing clinician may access.
patient/*.read, user/*.readSMART v1 read forms.
?category=…Finer-grained constraints on supported Condition and Observation categories, enforced on search and read.
launch, launch/patientEHR launch context, or a patient picker in a standalone launch.
openid fhirUserSigned identity claims. These are not resource permissions.
offline_accessA refresh token for access while the user is away.
online_accessA refresh token bounded by the authorizing sign-in session.
patient/{Type}.cu, user/{Type}.cuCreate and update (.c, .u, or both) for seven types, through SMART write. Consent boxes start unchecked and are granted only where the practice and app allow them.
.write, .*, dSMART v1 write forms, wildcard writes, and delete are refused.

Tokens and revocation

  • Authorization codes expire after 120 seconds and work once.
  • Access tokens are opaque bearer tokens that last 3,600 seconds, or 300 seconds when they carry a write scope.
  • Offline refresh tokens are valid for 95 days from first issue, across rotation; each refresh invalidates the previous token.
  • Online refresh ends with the authorizing session.
  • Patients can revoke an app at any time in the patient portal under Connected apps. App disablement, sign-out, and account changes end access too.

How to register an app

  1. Read the guide

    The SMART on FHIR-4 developer guide and the public practice directory need no account, payment, or agreement.

  2. Request registration

    Email info@chartvoyant.com or use Support with your app name, developer contact, client type, exact redirect URIs, optional EHR launch URL, requested scopes, practice, and public JWKS/jwks_uri (if asymmetric). Send no patient records, private keys, or client secrets.

  3. We register and enable it

    We register and enable a complete eligible request within five business days under identical objective checks for every developer.

  4. Authorize and connect

    A patient or clinician authorizes your app at sign-in. Call the practice's FHIR base with the returned access token.

Registered through /oauth/register instead? An app created via dynamic client registration is disabled at every practice until ChartVoyant enables it there with an explicit list of scopes. Send the registration request above with the client ID you received.