API Endpoint: Medicare Enrollment
The medicare-enrollment endpoint checks whether a provider is enrolled in Medicare or has opted out, by NPI.
POST /api/v1/validate/medicare-enrollment
https://www.tincomply.com/api/v1/validate/medicare-enrollment
Checks a provider's Medicare status by NPI: enrolled privileges (Part B, DME, home health, power mobility, hospice), opt-out status with its effective and end dates, and Care Compare profile details.
Request body
| Field | Type | Description |
|---|---|---|
npirequired |
string | The 10-digit NPI. |
Response object: medicareEnrollmentResult
| Field | Type | Description |
|---|---|---|
found | bool | True when the NPI is enrolled in Medicare. |
invalidCheckDigit | bool | True when the NPI fails its check-digit test. |
providerName | string | Provider name on the Medicare record. |
optedOut | bool | True when the provider has opted out of Medicare. |
optOutEffectiveDate, optOutEndDate | datetime | Opt-out period. |
optOutSpecialty | string | Specialty on the opt-out affidavit. |
partB, dme, homeHealth, pmd, hospice | bool | Enrolled Medicare privileges. |
careCompare | object | credential, medicalSchool, graduationYear, primarySpecialty, secondarySpecialties, telehealth, acceptsAssignment and locations. |
retrievedOn | datetime | When we retrieved the record. |
message | string | Human-readable summary of the result. |
completed | bool | False when the upstream source was unavailable. The request is retried automatically; call request-details with the request id later to get the finished result. |
The sample shows an opted-out provider. Claims to federal programs for an opted-out provider's services are not payable, so treat optedOut as a stop for Medicare billing.
What to do with this result
| When you see | Do this |
|---|---|
| optedOut is true | Do not bill Medicare for this provider's services between optOutEffectiveDate and optOutEndDate. |
| found is false and optedOut is false | The provider is not enrolled. Medicare claims that list them will be denied; confirm enrollment before billing. |
| A privilege (partB, dme, homeHealth, pmd, hospice) is false | The provider cannot order or refer that service type for Medicare patients. |
| completed is false | The source was unavailable. Keep the request id and call request-details later; the result fills in once the retry succeeds. |
Sample request
curl -X POST https://www.tincomply.com/api/v1/validate/medicare-enrollment \
-H "X-API-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"npi":"1245319599"}'import requests
response = requests.post(
"https://www.tincomply.com/api/v1/validate/medicare-enrollment",
headers={"X-API-Key": "YOUR_API_KEY"},
json={
"npi": "1245319599",
},
)
response.raise_for_status()
print(response.json()["medicareEnrollmentResult"])using System.Text;
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "YOUR_API_KEY");
var body = """
{
"npi": "1245319599"
}
""";
var response = await client.PostAsync(
"https://www.tincomply.com/api/v1/validate/medicare-enrollment",
new StringContent(body, Encoding.UTF8, "application/json"));
Console.WriteLine(await response.Content.ReadAsStringAsync());const response = await fetch("https://www.tincomply.com/api/v1/validate/medicare-enrollment", {
method: "POST",
headers: {
"X-API-Key": "YOUR_API_KEY",
"Content-Type": "application/json",
},
body: JSON.stringify({
npi: "1245319599",
}),
});
const data = await response.json();
console.log(data.medicareEnrollmentResult);import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
public class Main {
public static void main(String[] args) throws Exception {
String body = """
{
"npi": "1245319599"
}
""";
HttpRequest request = HttpRequest.newBuilder(URI.create("https://www.tincomply.com/api/v1/validate/medicare-enrollment"))
.header("X-API-Key", "YOUR_API_KEY")
.header("Content-Type", "application/json")
.POST(HttpRequest.BodyPublishers.ofString(body))
.build();
HttpResponse<String> response = HttpClient.newHttpClient()
.send(request, HttpResponse.BodyHandlers.ofString());
// Parse with your JSON library (Jackson, Gson) and read medicareEnrollmentResult.
System.out.println(response.body());
}
}package main
import (
"bytes"
"encoding/json"
"fmt"
"log"
"net/http"
)
func main() {
body := []byte(`{
"npi": "1245319599"
}`)
req, err := http.NewRequest("POST", "https://www.tincomply.com/api/v1/validate/medicare-enrollment", bytes.NewReader(body))
if err != nil {
log.Fatal(err)
}
req.Header.Set("X-API-Key", "YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
resp, err := http.DefaultClient.Do(req)
if err != nil {
log.Fatal(err)
}
defer resp.Body.Close()
var data map[string]any
if err := json.NewDecoder(resp.Body).Decode(&data); err != nil {
log.Fatal(err)
}
fmt.Println(data["medicareEnrollmentResult"])
}$body = @'
{
"npi": "1245319599"
}
'@
$response = Invoke-RestMethod -Method Post `
-Uri "https://www.tincomply.com/api/v1/validate/medicare-enrollment" `
-Headers @{ "X-API-Key" = "YOUR_API_KEY" } `
-ContentType "application/json" `
-Body $body
$response.medicareEnrollmentResultSample response
{
"id": "jo6nPgXaj0OXUKZMyZCkXgDg",
"request": {
"npi": "1245319599",
"requestDate": "2026-10-06T03:03:13Z",
"requestedServices": "medicare-enrollment"
},
"medicareEnrollmentResult": {
"npi": "1245319599",
"message": "Opted out of Medicare",
"found": false,
"completed": true,
"invalidCheckDigit": false,
"providerName": "TEST PROVIDER",
"optedOut": true,
"optOutEffectiveDate": "2022-07-01T00:00:00",
"optOutEndDate": "2028-07-01T00:00:00",
"optOutSpecialty": "Psychiatry",
"careCompare": {
"credential": "MD",
"medicalSchool": "TEST UNIVERSITY SCHOOL OF MEDICINE",
"graduationYear": 2004,
"primarySpecialty": "INTERNAL MEDICINE",
"telehealth": true,
"acceptsAssignment": "Y",
"locations": [
{
"facilityName": "TEST MEDICAL GROUP",
"groupSize": 42,
"singleLine": "1 TEST WAY, SUITE 200, BALTIMORE, MD 21201-0000",
"phone": "4105550120"
}
]
},
"partB": false,
"dme": false,
"homeHealth": false,
"pmd": false,
"hospice": false,
"retrievedOn": "2026-10-06T03:03:13Z"
}
}Errors
Requests that cannot be processed return HTTP 400 with an object keyed by field name, each listing what was wrong. Authentication, permission and other status codes are covered in Errors & service status.
This endpoint requires an API key with the Validate permission.
See how this check works in the portal and what it costs: NPI & Medicare Verification