Skip to main content
POST
/
v3
/
lab_tests
from vital.client import Vital
from vital.environment import VitalEnvironment
from vital.types.lab_test_collection_method import LabTestCollectionMethod
from vital.types.lab_test_sample_type import LabTestSampleType
from vital.types.us_address import UsAddress


client = Vital(
  api_key="YOUR_API_KEY",
  environment=VitalEnvironment.SANDBOX
)

data = client.lab_tests.create(
    provider_ids=["000110"],
    name="<name>",
    method=LabTestCollectionMethod.TESTKIT,
    description="<description>"
)
{
  "id": "2e82a1d4-e2e6-421c-9c54-2210d667ce48",
  "slug": "a94e3005-labcorp-panel",
  "name": "Labcorp panel",
  "sample_type": "serum",
  "method": "at_home_phlebotomy",
  "price": 0.0,
  "is_active": true,
  "status": "active",
  "fasting": false,
  "lab": {
    "id": 27,
    "slug": "labcorp",
    "name": "Labcorp",
    "first_line_address": "labcorp address",
    "city": "Lincolnshire",
    "zipcode": "60069",
    "collection_methods": ["at_home_phlebotomy", "walk_in_test"],
    "sample_types": ["serum", "saliva", "urine"]
  },
  "markers": [
    {
      "id": 195,
      "name": "Abnormal Bleeding Profile",
      "slug": "abnormal-bleeding-profile",
      "description": "Abnormal Bleeding Profile",
      "lab_id": 27,
      "provider_id": "116004",
      "type": "biomarker",
      "unit": null,
      "price": "N/A",
      "aoe": null,
      "a_la_carte_enabled": true
    }
  ],
  "is_delegated": false,
  "auto_generated": false
}
from vital.client import Vital
from vital.environment import VitalEnvironment
from vital.types.lab_test_collection_method import LabTestCollectionMethod
from vital.types.lab_test_sample_type import LabTestSampleType
from vital.types.us_address import UsAddress


client = Vital(
  api_key="YOUR_API_KEY",
  environment=VitalEnvironment.SANDBOX
)

data = client.lab_tests.create(
    provider_ids=["000110"],
    name="<name>",
    method=LabTestCollectionMethod.TESTKIT,
    description="<description>"
)
{
  "id": "2e82a1d4-e2e6-421c-9c54-2210d667ce48",
  "slug": "a94e3005-labcorp-panel",
  "name": "Labcorp panel",
  "sample_type": "serum",
  "method": "at_home_phlebotomy",
  "price": 0.0,
  "is_active": true,
  "status": "active",
  "fasting": false,
  "lab": {
    "id": 27,
    "slug": "labcorp",
    "name": "Labcorp",
    "first_line_address": "labcorp address",
    "city": "Lincolnshire",
    "zipcode": "60069",
    "collection_methods": ["at_home_phlebotomy", "walk_in_test"],
    "sample_types": ["serum", "saliva", "urine"]
  },
  "markers": [
    {
      "id": 195,
      "name": "Abnormal Bleeding Profile",
      "slug": "abnormal-bleeding-profile",
      "description": "Abnormal Bleeding Profile",
      "lab_id": 27,
      "provider_id": "116004",
      "type": "biomarker",
      "unit": null,
      "price": "N/A",
      "aoe": null,
      "a_la_carte_enabled": true
    }
  ],
  "is_delegated": false,
  "auto_generated": false
}

Authorizations

x-vital-api-key
string
header
required

Vital Team API Key

Body

application/json
name
string
required
method
enum<string>
required

The method used to perform a lab test. ℹ️ This enum is non-exhaustive.

Available options:
testkit,
walk_in_test,
at_home_phlebotomy,
on_site_collection
description
string
required
marker_ids
integer[] | null
provider_ids
string[] | null
fasting
boolean | null
default:false

Response

Successful Response

id
string<uuid>
required
slug
string
required
name
string
required
sample_type
enum<string>
required
Available options:
dried_blood_spot,
arm_collector,
serum,
saliva,
urine
method
enum<string>
required
Available options:
testkit,
walk_in_test,
at_home_phlebotomy,
on_site_collection
price
number
required
is_active
boolean
required

Deprecated. Use status instead.

status
enum<string>
required
Available options:
active,
pending_approval,
inactive
lab
object | null
required
Example:
{
"city": "San Francisco",
"collection_methods": ["testkit"],
"first_line_address": "123 Main St",
"id": 1,
"name": "LabCorp",
"sample_types": ["saliva"],
"slug": "labcorp",
"zipcode": "91789"
}
markers
ClientFacingMarker · object[] | null
required
fasting
boolean
default:false

Defines whether a lab test requires fasting.

is_delegated
boolean
default:false

Denotes whether a lab test requires using non-Vital physician networks. If it does then it's delegated - no otherwise.

auto_generated
boolean
default:false

Whether the lab test was auto-generated by Vital

has_collection_instructions
boolean | null

Whether or not the lab test has collection instructions.

common_tat_days
integer | null

The common turnaround time in days for the lab test. This is the expected time for the lab to process the test and return results.

worst_case_tat_days
integer | null

The worst-case turnaround time in days for the lab test. This is the maximum time the lab may take to process the test and return results.

I