API Reference

Access Claims

Each transportation provider has one or many Funding Sources in MediRoutes to manage and logically organize trips. In MediRoutes, a funding source is synonymous with a Payer - the entity who is actually paying the transportation provider to perform the trip. Funding sources are often brokers, healthcare organizations, private payers and managed care facilities.

Since a MediRoutes API user may work with one or many transportation providers, API access (also known as 'claims') is granted to users at the transportation provider level and associated funding source level.

API users on behalf of brokers may have access to a single funding source for many transportation providers. API users who work for or with a single transportation provider may be granted access to only their own MediRoutes data by granting access to all funding sources for that single transportation provider.

Access Endpoint

The access endpoint will return a nested list of all transportation providers and associated funding sources your API user has access to. Each transportation provider has a Transportation Provider Name and an API Key. Each Funding Source has a Funding Source Name and a Funding Source ID.

To see which transportation providers and funding sources you have access to, simply hit the GET Access endpoint:

A. Get Access Using a client (or Swagger/Postman for testing), GET https://api.mediroutes.com/api/v1/access using the API version number and the bearer token in the Authorization field:

  1. version = (currently "1")
  2. Authorization = "bearer " (see screenshot below)*

B. MediRoutes API returns a list of Transportation Providers, their unique API Key and all currently accessible Funding Sources as well as their associated Funding Source IDs

Please Note: the word "bearer" and a space " " must come before the bearer token in the Authorization parameter. This applies to all endpoints that require Authorization.

Request

GET{root_url}/v{version}/access
ParameterTypeDescriptionNotes
versionintAPI version; currently = "1"REQUIRED
Authorizationstringbearer {access token}REQUIRED

Expected Response Codes

CodeDescription
200Request was successful; API Key(s) and Funding Source(s) returned.
401"You do not have access to this resource." Request was unsuccessful; Either token is invalid, the word "bearer " is missing, or token is expired.
500Unknown error; Contact MediRoutes.

Expected Response Body

ParameterTypeDescription
APIKeystringUnique ID of a Transportation Provider
TranportationProviderNamestringName of Transportation Provider
FundingSources-Collection of Funding Sources per Transportation Provider
.FundingSourceIdintUnique ID of a Funding Source
.FundingSourceNamestringName of Transportation Provider's Funding Source

Sample 200 Response Body - Token Endpoint

The following sample response shows what a user would receive back from the Access endpoint if they had access to two transportation providers with one or two funding sources.

[
  {
    "APIKey": "00e1015d588f456444b6b3a7207762c1",
    "TranportationProviderName": "Transportation Provider Co #1",
    "FundingSources": [
      {
        "FundingSourceId": 918,
        "FundingSourceName": "Broker ABC"
      }
    ]
  },
  {
    "APIKey": "233346f3e577f4c77af64c6f43454d454b",
    "TranportationProviderName": "Fictional Transportation Company #2",
    "FundingSources": [
      {
        "FundingSourceId": 1629,
        "FundingSourceName": "State Medicaid"
      },
      {
        "FundingSourceId": 1628,
        "FundingSourceName": "Broker ABC"
      }
    ]
  }
]

The API Key for each transportation provider will be used in conjunction with the bearer token to hit all other endpoints in the API. Funding Source Name is also required for several of the API calls such as inserting a trip or adding a new patient.

Please Note: If an additional transportation provider and/or funding source is added to your API user access, you will need to obtain a new token to see these new claims reflected in the Access endpoint response.