Skip to main content
Find the policy for a payer, line of business, and medical code, then retrieve its medical-necessity criteria. This quickstart uses UnitedHealthcare commercial policy criteria for HCPCS code J0490 (belimumab) as an example.

Prerequisites

Before you begin, you’ll need:
  • An API key from Penelope (contact us at [email protected])
  • A tool to make HTTP requests (curl, Postman, or your preferred language)

Step 1: Authenticate

All Penelope API requests require authentication through the x-api-key header. Store your API key in an environment variable before you make a request:
If your key is valid, you receive a 200 response. See Authentication for error handling and security guidance.

Step 2: Find Matching Policies

Filter by the payer’s Stedi payer ID, line-of-business category, and medical code. This workflow assumes you know the payer ID and LOB category for the patient.
If you do not know these values, see Discover Payer and Line-of-Business Values below.
Search both COVERS and REFERENCES. A relevant policy can explicitly cover the code or mention it without making a coverage decision in the code list. Including both relationships prevents a relevant policy from being excluded. Results are relevance-ranked by default. Review each result’s title, summary, and code groups. Copy the complete policy_id from the result that best matches the service and patient context.

List Policies API

See every policy filter and response field

Step 3: Get the Policy Criteria

Pass the selected policy_id to the Get Policy endpoint. A policy_id contains the source, canonical policy ID, and effective date, so copy the complete value into the URL.
The response automatically includes criteria_text: the policy’s medical-necessity criteria as LLM-ready markdown. Evaluate this text against the patient’s medical notes to identify documentation gaps.

Get Policy API

Retrieve criteria text, code groups, and applicability for one policy

Additional Ways to Find a Policy

Discover Payer and Line-of-Business Values

Use List LOBs when you need to find a payer’s Stedi payer ID, LOB category, or a specific lob_id.
Response:
Use payer_id and lob for the Step 2 filters. Use lob_id when you need to restrict a policy search to one specific line of business.

List LOBs API

View all filtering options and response fields

Search Policies by Keyword

For exploratory research when you don’t have specific codes, use full-text search across policy titles and summaries.
Response:
Results are ranked by relevance score — a relative signal for ordering matches within a single response, not an absolute value to compare across searches. The applicability field shows which payers and lines of business this policy applies to. Combine with lob_ids to scope the search to specific lines of business. Set "include_code_groups": true to get associated codes. Each result includes a policy_id. Pass it to the Get Policy endpoint from Step 3 to retrieve the policy criteria.

List Policies API

Use the q parameter for full-text search across policy titles and summaries

Optional: Download the Policy Files

To work with the original source document rather than the extracted criteria, download the full file (PDF or HTML) using the policy’s policy_id.
Use variant=text to get an LLM-optimized markdown version:
The presigned URL is short-lived. Download the file promptly or request a fresh URL.

Download Policy API

Get temporary download links for policy documents

Next Steps

Key Concepts

Understand the data model and relationships

Data Coverage

See which payers and plans are covered

Examples

More examples

API Reference

Complete API documentation