Patient Prism provides API access for teams that want to programmatically pull call and lead data into their own data warehouse, BI platform, or internal applications. This article covers the API surfaces available, how to set up access, and best practices for building a reliable ingestion pipeline.
New to the data access options? Start with Getting Your Data Out of Patient Prism: An Overview — for many recurring-ingestion use cases, Scheduled Exports is a simpler, no-code alternative.
The API Surfaces
| Surface | Type | Purpose |
|---|---|---|
| Call Records API | GraphQL | Fetch raw call data or pre-computed metrics |
| Transcripts API | REST | Retrieve the transcript for an individual call |
| Webhooks | Push | Have Patient Prism send data to your endpoint as events occur |
All API responses are returned as JSON. Both APIs already exist and are in active use — no custom development or additional cost is required to connect.
The GraphQL Call Records API
The GraphQL API is the same API that powers the Patient Prism platform itself — any report or metric you see in the platform can be fetched directly through the API. That gives you two distinct ways to use it:
- Raw data — Fetch the full list of call records with all associated data: caller and patient classification, booking status, connection status, call summary, UTM and attribution data, tags, topics, segments, estimated revenue, and more. Use this if you want to run your own analyses or index everything in an internal data lake.
- Pre-computed metrics — Because GraphQL lets you define your response object, you can craft a query that asks Patient Prism's backend to do the calculation for you. For example: total new patient opportunities booked and not booked, existing patient opportunities, connected vs. unconnected calls — grouped by location, segment, UTM campaign, or referring source. This is ideal for powering internal dashboards without ingesting and recomputing everything yourself.
Tip: Any filter you build in the platform's reporting interface can be replicated as a GraphQL query. If you're trying to compute something complex, build the filter in the platform first, then contact us for help translating it into an API query.
The Transcripts API
Full call transcripts are not included in the call records index due to their size, and they are not available through Scheduled Exports. To retrieve transcripts, you make a separate REST request per call: first fetch your list of calls from the GraphQL API, then iterate through that list and fetch each transcript individually.
Transcripts are available in multiple formats, including a format with agent and caller speech separated by speaker. Let us know which format fits your pipeline and we'll point you to the right option.
Webhooks
If you'd rather have Patient Prism push data to you, we can send webhooks to an endpoint you host. For most warehouse-ingestion use cases the API or Scheduled Exports is simpler, but webhooks are available if that's the more natural fit for your architecture.
Step 1: Create a Service Account
API tokens are scoped to the user who creates them — not to the company. If a token is created under an individual employee's account and that account is later deactivated, your integration breaks. For this reason, we strongly recommend creating a dedicated service account (e.g., "API User" or a BI alias) to own your API access.
When creating the service account:
- Assign the Company Admin role (the highest privilege level) so the account has access to all data.
- Enable the setting that allows the user to track along with all locations at all times, so the account has access to every location's data.
- The account requires a valid email address to log in — decide which alias you want it linked to before requesting creation.
Any existing Company Admin at your organization can create the service account, or you can email Patient Prism support with the email address you'd like it linked to and we'll create it for you.
Step 2: Generate an API Token
- Log in to Patient Prism as the service account.
- Go to the account's profile area.
- Create a new API token and give it a descriptive name.
- Store the token securely — this is the credential your application will use.
Step 3: Authenticate Your Requests
Both the GraphQL and transcript endpoints use Basic Authentication. Pass an authorization header containing your API token with each request.
<!-- TODO: Add endpoint URLs, exact auth header format, and example request. -->
Step 4: Request Documentation and Sample Payloads
To receive the full API documentation — including endpoint details, sample GraphQL queries, a sample call record object, and field descriptions — email Patient Prism support with the list of technical team members who should receive it. We can also provide:
- Mocked/hydrated sample data so you can see what a fully populated call record looks like before real data starts flowing.
- Field mapping assistance if you're migrating from another call tracking platform (such as Invoca or CallRail) and want help mapping their attribute names to Patient Prism's.
<!-- TODO: Replace with a direct link once the reworked documentation site is live. -->
Step 5: Set a Technical Notification Contact
Before going live, designate one or more technical notification contacts for your company:
- Go to Manage → Companies and select your company.
- Open Notifications.
- Add the users (e.g., your infrastructure alias) who should receive technical alerts.
These contacts are notified about integration-level issues — for example, broken authentication on an integration or significant, unexpected changes in data volume — so your team finds out right away if something breaks.
Understanding the Call Record Object
A call record includes, among other fields:
- Caller information — details about the caller.
- Location, phone number, and company data — where the call was routed and which tracking number received it.
- Dispositioning data — tags, topics, phrases, and segments identified on the call.
- Metadata — a key-value pair array containing high-level inference data such as the caller classification (new vs. existing patient) and connection status.
- Estimated value — the revenue estimate attached to the interaction based on your company's cost sheet and the services discussed.
- Attribution sessions — see below.
First and Last Analytic Sessions
Each call record includes a first analytic session and a last analytic session, each containing the first and last website visits within that session:
- First analytic session — the earliest session ever associated with that visitor's analytic token. Think of this as first-touch attribution.
- Last analytic session — the most recent session leading up to the call. Think of this as last-touch attribution.
Each session includes the referring source, UTM parameters, click IDs (Google Click ID, Facebook Click ID — null when not applicable, such as on organic visits), and user agent data.
Note that marketing attribution data only populates once the Patient Prism tracking snippet is installed on your website; until then, call records will contain data derivable from the call itself (classification, outcome, duration) but not campaign attribution.
Best Practices for Ingestion Pipelines
Give data time to settle — use a 24-hour buffer
When an interaction comes in, it kicks off roughly 130 machine-learning inferences. These typically complete within 30–40 seconds, but the backend is a queued job system, so completion within a fixed window isn't guaranteed.
More importantly, call data can legitimately change after the fact. For example: a new patient calls at 9:30 AM and doesn't book. A team member follows up at noon and converts them. The booking status on the original call flips from not booked to booked.
Best practice: when your ingestion job runs, pull data from the previous day backwards rather than up to the current moment. This gives analyses time to finalize and follow-up activity time to settle, so you're ingesting solidified data. If you re-pull recent date ranges, expect some records to have updated statuses compared to your last pull.
Handle pagination
The call records index is a paginated (scroll) API. Your integration will need to page through results when fetching large call lists.
Rate limits
Rate limits apply but are relatively liberal — typical daily ingestion workloads are unlikely to hit them.
Plan for schema mapping
Attribute names in Patient Prism will differ from other call tracking platforms. If you're replacing an existing integration, budget time to map fields — and send us a sample payload from your previous provider if you'd like help producing a side-by-side mapping.
Frequently Asked Questions
Can I get transcripts through Scheduled Exports instead? No. Transcripts are only available through the API. If you need both raw call data and transcripts, many teams use two API connections (one GraphQL for call records, one REST for transcripts) rather than mixing exports and API.
Can the API power a real-time dashboard? Yes. Because the platform's own reports run on the same GraphQL API, you can fetch live, pre-calculated metrics at runtime for an internal dashboard rather than ingesting raw data.
What format does the API return? JSON, for both call records and transcripts.
Who do I contact to get started? Email Patient Prism support to request service account creation, API documentation, sample queries, and sample payloads.