Project Template APIs
You can retrieve information about project templates through the following APIs.
Get Project Templates
This API returns a list of project templates in the specified organization.
HTTP Request
GET /v3/project_templates?organizationId={ID}
Query Parameters
Key |
Required |
Description |
---|---|---|
ID |
yes | Internal organization identifier. Copy from URLs. (It's the 123 in this example: https://lab.ovation.io/orgs/123/dashboard.) |
Example Response
{ "project_templates": [ { "id": 1, "projectName": "Covid", "templateName": "Covid form 1" }, { "id": 2, "projectName": "PGx", "templateName": "PGx form 1" } ] }
Get Requisition Schema
This API returns the JSON schema for the requisitions in the specified template. Inbound payloads and outbound responses that describe requisitions should adhere to this schema. You can use this information to manually confirm your JSON or use an automatic JSON schema validator.
HTTP Request
GET /v3/project_templates/{templateID}/requisition_schema
Query Parameters
Key |
Required |
Description |
---|---|---|
templateID |
yes | Internal project template identifier. Copy from URLs. (It's the 789 in this example: https://lab.ovation.io/orgs/123/projects/456/requisition-settings/789/template-information) |
Example Response
{ "$schema": "http://json-schema.org/draft-04/schema#", "description": "Schema for Project Template ABC", "type": "object", "required": [ "requisition" ], "properties": { "requisition": { "type": "object", "required": [ "requestedTests", "providerAccount", "provider", "patient", "samples", "billingInformation" ], "properties": { "identifier": { "type": [ "string", "null" ] }, "requestedTests": { "type": "array", "items": { "type": "object", "required": [ "panelCode" ], "properties": { "panelCode": { "type": "string", "enum": [ "panel 1", "panel 2", ... ] }, "tests": { "type": "array", "items": { "type": "object", "required": [], "properties": { "testCode": { "type": [ "string", "null" ] } } } } } } }, "diagnosis": { "type": "array", "items": { "type": "string" } }, "medications": { "type": "array", "items": { "type": "object", "required": [], "properties": { "name": { "type": [ "string", "null" ] }, "rxcui": { "type": [ "string", "null" ] } } } }, "customAttributes": { "type": "object", "required": [], "properties": { "other_exam": { "type": [ "string", "null" ] }, "custom attribute 1": { "type": "boolean" }, "custom attribute 2": { "type": "boolean" }, ... } }, "providerAccount": { "type": "object", "required": [], "properties": { "name": { "type": [ "string", "null" ] }, "accountNumber": { "type": [ "string", "null" ] } } }, "provider": { "type": "object", "required": [ "npi" ], "properties": { "npi": { "type": "string" } } }, "patient": { "type": "object", "required": [], "properties": { "identifier": { "type": [ "string", "null" ] }, "customAttributes": { "type": "object", "required": [], "properties": { "custom attribute 1": { "type": [ "string", "null" ] }, "custom attribute 2": { "type": "boolean" }, ... } }, "mrn": { "type": [ "string", "null" ] }, "firstName": { "type": [ "string", "null" ] }, "middleName": { "type": [ "string", "null" ] }, "lastName": { "type": [ "string", "null" ] }, "dateOfBirth": { "type": [ "string", "null" ] }, "streetAddress": { "type": [ "string", "null" ] }, "streetAddressLine2": { "type": [ "string", "null" ] }, "city": { "type": [ "string", "null" ] }, "state": { "type": [ "string", "null" ] }, "country": { "type": [ "string", "null" ] }, "zipCode": { "type": [ "string", "null" ] }, "phoneNumber": { "type": [ "string", "null" ] }, "gender": { "type": [ "string", "null" ], "enum": [ "M", "MALE", "F", "FEMALE", "U", "UNDISCLOSED", null, "null", "" ] }, "ethnicity": { "type": [ "string", "null" ], "enum": [ "hispanic", "nothispanic", "undisclosed", null, "null", "" ] }, "race": { "type": [ "string", "null" ], "enum": [ "white", "asian", "native", "black", "islander", "undisclosed", null, "null", "" ] }, "email": { "type": [ "string", "null" ] } } }, "samples": { "type": "array", "items": { "type": "object", "required": [ "attribute name of required field 1", "attribute name of required field 2", ... ], "properties": { "identifier": { "type": [ "string" ] }, "group": { "type": "string", "enum": [ "sample group name 1", "sample group name 2", ... ] }, "label": { "type": "string", "enum": [ "allowed label 1", "allowed label 2", ... ] }, "containerType": { "type": "string", "enum": [ "allowed container type 1", "allowed container type 2", ... ] }, "containerBarcodeLabel": { "type": "string" }, "receivedDateTime": { "type": "string" }, "collectionDateTime": { "type": "string" }, "customAttributes": { "type": "object", "required": [], "properties": { "custom attribute 1": { "type": [ "string", "null" ] }, "custom attribute 2": { "type": "boolean" }, ... } } } } }, "billingInformation": { "type": "object", "required": [ "billTo" ], "properties": { "billTo": { "type": "string", "enum": [ "Bill Insurance" ] }, "insuranceInformations": { "type": "array", "items": { "type": "object", "required": [ "insuranceProviderName", "insuranceType" ], "properties": { "insuranceProviderName": { "type": "string" }, "insuranceType": { "type": "string", "enum": [ "Primary", "Secondary" ] }, "preAuthorization": { "type": "object", "required": [], "properties": { "authorizationNumber": { "type": [ "string", "null" ] }, "effectiveStartDate": { "type": [ "string", "null" ] }, "effectiveEndDate": { "type": [ "string", "null" ] }, "numAllowedTests": { "type": [ "string", "null" ] }, "contactName": { "type": [ "string", "null" ] }, "contactPhoneNumber": { "type": [ "string", "null" ] } } }, "idNumber": { "type": [ "string", "null" ] }, "subscriberNumber": { "type": [ "string", "null" ] }, "groupNumber": { "type": [ "string", "null" ] }, "relationshipToInsured": { "type": [ "string", "null" ] }, "otherRelationshipToInsured": { "type": [ "string", "null" ] }, "nameOfPersonInsured": { "type": [ "string", "null" ] }, "dobOfInsured": { "type": [ "string", "null" ] }, "insuredEmail": { "type": [ "string", "null" ] }, "insuredStreetAddress": { "type": [ "string", "null" ] }, "insuredCity": { "type": [ "string", "null" ] }, "insuredState": { "type": [ "string", "null" ] }, "insuredZipCode": { "type": [ "string", "null" ] }, "insuredSex": { "type": [ "string", "null" ] }, "reimbursementEligibilityVerified": { "type": [ "string", "null" ] } } } } } }, "hasSecondaryUseNotification": { "type": [ "string", "null", "boolean", "integer" ], "enum": [ 0, 1, 2, 3, true, "true", "t", "yes", "y", false, "false", "f", "no", "n", null, "null", "" ] }, "secondaryUseEntitlements": { "type": [ "string", "null" ] }, "hasMedicalConsent": { "type": [ "string", "null", "boolean", "integer" ], "enum": [ 0, 1, 3, true, "true", "t", "yes", "y", false, "false", "f", "no", "n", null, "null", "" ] } } }, "markAsSigned": { "type": "boolean" } } }