Skip to content

Latest commit

 

History

History
112 lines (88 loc) · 3.22 KB

get-data-point-definitions.mdx

File metadata and controls

112 lines (88 loc) · 3.22 KB
title description
Get data point definitions
Retrieve the data dictionary for a pathway

For any given care flow/pathway a patient is included in, you might want to know what data points are captured in that pathway (i.e a data dictionary). Via the pathwayDataPointDefinitions query, you're able to retrieve all data points definitions for a given pathway version.

Release id

Every patient enrolled in a pathway is included in the last version of the pathway at the moment of pathway start. Because care flows/pathways can evolve over time, it might be that the oldest version of your pathway has a totally different data dictionary compared to the most recent version.

Therefore, to query all the data point definitions for a given pathway version, you need to specify the release_id as an input parameter for this query.

Version vs. release id

The version of a pathway is an auto-incremented and human-readable numerical value (eg: version 5). However, every version also has a unique identifier which is called the release_id. The version and release_id are returned in all pathway related queries.

Example: All patients included in version 5 of the pathway have the same release_id.

Query

query GetPathwayDataPointDefinitions(
  $release_id: String!
  $category: [String!]
  $value_type: [String!]
) {
  pathwayDataPointDefinitions(
    filters: { category: { in: $category }, value_type: { in: $value_type } }
    release_id: $release_id
  ) {
    data_point_definitions {
      id
      title
      key
      category
      valueType
      possibleValues {
        value
        label
      }
      range {
        min
        max
      }
      unit
      optional
      pii
      data_point_metadata {
        key
        value
      }
    }
  }
}

The data_point_metadata field can be used to retrieve additional information about a data point definition. This additional information can be configured in the Data Catalog section of Awell Studio, and a guide can be found in the Awell knowledge base.

Variables

Required parameters

A release_id needs to be specified in order to retrieve the data dictionary for a pathway.

{
  "release_id": "{{ RELEASE_ID }}"
}

Filters

The filter is optional: if you don't provide one, all data points with the specified release_id will be returned.

query GetPathwayDataPointDefinitions($release_id: String!) {
  pathwayDataPointDefinitions(release_id: $release_id) {
    data_point_definitions {
      ...DataPointDefinition
    }
  }
}

All in filter type accepts a list of values and results in an is any of search criteria.

When specifying multiple filters, the resulting criteria is the conjuction of all filters.

{
  "release_id": "{{ RELEASE_ID }}",
  "category": [
    "CALCULATION",
    "FORM",
    "PATIENT_PROFILE",
    "PATHWAY",
    "TRACK",
    "STEP"
  ],
  "value_type": ["BOOLEAN", "DATE", "NUMBER", "NUMBERS_ARRAY", "STRING"]
}

Pagination and sorting

There is no pagination or sorting available for this query. All matching patient pathways will be returned.

How to use

<HowToUse storyIds={['data-dictionary']} />