NAV Navbar
Logo cerner
Ruby Shell

Wellness API v1

The HealtheIntent Wellness API enables the defining and management of wellness campaigns, rewards and personal health assessments.

URL: https://cernerdemo.api.us.healtheintent.com/wellness/v1

Campaign Configurations

A wellness campaign is an incentive program designed to motivate members to improve their health by completing incentivized activities. A campaign is an organized collection of incentivized activities grouped into categories, subcategories, and groupers. A category can have subcategories and a subcategory can have groupers. A campaign instance is generated using all the configuration data.

Create a Wellness Campaign

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns', headers: headers, body: {"names":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program."}],"descriptions":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program for Cerner Wellness Campaign."}],"startsAt":"2019-01-01T00:00:00","endsAt":"2019-12-31T00:00:00","reward":{"id":"f28bbe52-8bbd-11e9-bc42-526af7764f64"},"completionThreshold":1,"adjustmentReward":{"id":"77a233a3-54d4-4ad3-9e63-53bb71762290"},"timeZone":"Central Time (US & Canada)","icon":"campaign_2019_q1.jpg","populations":[{"populationId":"11e8901dafad94f7a9b701d255a00ad0","dataPartitionId":"31e8901dafad94f7a9b701d245a00ad9"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"names":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program."}],"descriptions":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program for Cerner Wellness Campaign."}],"startsAt":"2019-01-01T00:00:00","endsAt":"2019-12-31T00:00:00","reward":{"id":"f28bbe52-8bbd-11e9-bc42-526af7764f64"},"completionThreshold":1,"adjustmentReward":{"id":"77a233a3-54d4-4ad3-9e63-53bb71762290"},"timeZone":"Central Time (US & Canada)","icon":"campaign_2019_q1.jpg","populations":[{"populationId":"11e8901dafad94f7a9b701d255a00ad0","dataPartitionId":"31e8901dafad94f7a9b701d245a00ad9"}]}

Example response

{
  "id": "m123179c-9617-4ac5-8601-8054755a2123",
  "names": [
    {
      "locale": "en-US",
      "text": "2019 Healthe Living Rewards Program"
    }
  ],
  "descriptions": [
    {
      "locale": "en-US",
      "text": "2019 Healthe Living Rewards Program for Cerner Wellness Campaign."
    }
  ],
  "categoryId": "l093179c-9617-4ac5-8601-8054755a2098",
  "populations": [
    {
      "populationId": "l783179c-0917-4ac5-8601-8054755a2789",
      "dataPartitionId": "o463179c-9618-4ac5-8601-8054755a2890"
    }
  ],
  "reward": {
    "id": "z123179c-9617-4ac5-8601-8054755a2m12"
  },
  "adjustmentReward": {
    "id": "q987462i-9617-4ac5-8601-8054755a9876"
  },
  "completionThreshold": 1,
  "icon": "campaign_2019_q1.jpg",
  "startsAt": "2019-01-01T00:00:00Z",
  "endsAt": "2019-12-31T23:59:00Z",
  "timeZone": "Central Time (US & Canada)",
  "createdAt": "2018-12-15T12:23:12Z",
  "updatedAt": "2018-12-15T12:23:12Z"
}

POST /campaigns

Creates a wellness campaign for a HealtheIntent tenant. This request also creates the parent category so the children categories can be nested.

Parameters

Parameter In Type Required Default Description Accepted Values
body body postCampaigns true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created CampaignDefinition
400 Bad Request Bad Request. The campaign was not created. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- noDefaultLocale The default locale (en-US) is required for the name if it is used in the body.
- duplicateLocale The locales for the names must be unique.
- missingField Review and complete all required information to continue.
BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden

Retrieve a List of Wellness Campaigns

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "m123179c-9617-4ac5-8601-8054755a2123",
      "names": [
        {
          "locale": "en-US",
          "text": "2019 Healthe Living Rewards Program"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "2019 Healthe Living Rewards Program for Cerner Wellness Campaign."
        }
      ],
      "categoryId": "l093179c-9617-4ac5-8601-8054755a2098",
      "populations": [
        {
          "populationId": "l783179c-0917-4ac5-8601-8054755a2789",
          "dataPartitionId": "o463179c-9618-4ac5-8601-8054755a2890"
        }
      ],
      "reward": {
        "id": "z123179c-9617-4ac5-8601-8054755a2m12"
      },
      "adjustmentReward": {
        "id": "q987462i-9617-4ac5-8601-8054755a9876"
      },
      "completionThreshold": 1,
      "icon": "campaign_2019_q1.jpg",
      "startsAt": "2019-01-01T00:00:00Z",
      "endsAt": "2019-12-31T23:59:00Z",
      "timeZone": "Central Time (US & Canada)",
      "createdAt": "2018-12-15T12:23:12Z",
      "updatedAt": "2018-12-15T12:23:12Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns?offset=0&limit=20"
}

GET /campaigns

Retrieves a list of all the available wellness campaigns for a HealtheIntent tenant.

Parameters

Parameter In Type Required Default Description Accepted Values
campaignId query array[string] false N/A Filters by the ID of the wellness campaign. -
status query string false N/A Filters the retrieved wellness campaigns by status. CURRENT, CLOSED
locale query string false N/A Filters by locale. A locale is a two-letter language and two-letter region ID, for example, en-US. If this parameter is not specified, the default en-US locale is used. -
name query string false N/A Filters by the name of the campaigns. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -
orderBy query string false updatedAt A comma-separated list of fields by which to sort. startsAt, endsAt, createdAt, updatedAt

Response Statuses

Status Meaning Description Schema
200 OK OK CampaignDefinitions
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden

Delete a Wellness Campaign

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.delete('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/11e8902c9e2908c69718f13503066bee', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/11e8902c9e2908c69718f13503066bee \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /campaigns/{campaignId}

Deletes a wellness campaign by ID.

Parameters

Parameter In Type Required Default Description Accepted Values
campaignId path string true N/A The ID of the wellness campaign. -

Response Statuses

Status Meaning Description Schema
204 No Content No Content None
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Update a Wellness Campaign

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'If-Match' => {
  "type": "string"
}
} 

result = HTTParty.patch('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/21e8902c9e2908c69718f13503065be7', headers: headers, body: {"names":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program for Cerner Wellness Campaign."}],"descriptions":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program for Cerner Wellness Campaign."}],"startsAt":"2019-01-01T00:00:00","endsAt":"2019-12-31T23:59:00","reward":{"id":"77a233a3-54d4-4ad3-9e63-53bb71762290"},"adjustmentReward":{"id":"77a233a3-54d4-4ad3-9e63-53bb71762290"},"completionThreshold":1,"timeZone":"Central Time (US & Canada)","icon":"campaign_2019_q1.jpg","populations":[{"populationId":"11e8901dafad94f7a9b701d255a00ad0","dataPartitionId":"31e8901dafad94f7a9b701d245a00ad9"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PATCH https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/21e8902c9e2908c69718f13503065be7 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \ \
-H 'If-Match: [object Object]' \
-d {"names":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program for Cerner Wellness Campaign."}],"descriptions":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program for Cerner Wellness Campaign."}],"startsAt":"2019-01-01T00:00:00","endsAt":"2019-12-31T23:59:00","reward":{"id":"77a233a3-54d4-4ad3-9e63-53bb71762290"},"adjustmentReward":{"id":"77a233a3-54d4-4ad3-9e63-53bb71762290"},"completionThreshold":1,"timeZone":"Central Time (US & Canada)","icon":"campaign_2019_q1.jpg","populations":[{"populationId":"11e8901dafad94f7a9b701d255a00ad0","dataPartitionId":"31e8901dafad94f7a9b701d245a00ad9"}]}

PATCH /campaigns/{campaignId}

Updates a wellness campaign. This is a PATCH request and not a PUT request as many HealtheIntent APIs use, and the updated resource replaces the previous version. See JSON Merge Patch on the Internet Engineering Task Force (IETF) website for more information about PATCH requests.

Parameters

Parameter In Type Required Default Description Accepted Values
If-Match header string true N/A The ETag for a specific version of a resource. If a user or system attempts to update a version of a campaign and the campaign was already updated to a new version, an error occurs. -
campaignId path string true N/A The ID of the wellness campaign. -
body body patchCampaigns true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content No Content None
400 Bad Request Bad Request. The wellness campaign was not updated. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- noDefaultLocale The default locale (en-US) is required for the name if it is used in the body.
- duplicateLocale The locales for the names must be unique.
- missingField Review and complete all required information to continue.
BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound
409 Conflict Conflict Conflict

Retrieve a Single Wellness Campaign

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/11e8902c9e2908c69718f13503066bee', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/11e8902c9e2908c69718f13503066bee \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "m123179c-9617-4ac5-8601-8054755a2123",
  "names": [
    {
      "locale": "en-US",
      "text": "2019 Healthe Living Rewards Program"
    }
  ],
  "descriptions": [
    {
      "locale": "en-US",
      "text": "2019 Healthe Living Rewards Program for Cerner Wellness Campaign."
    }
  ],
  "categoryId": "l093179c-9617-4ac5-8601-8054755a2098",
  "populations": [
    {
      "populationId": "l783179c-0917-4ac5-8601-8054755a2789",
      "dataPartitionId": "o463179c-9618-4ac5-8601-8054755a2890"
    }
  ],
  "reward": {
    "id": "z123179c-9617-4ac5-8601-8054755a2m12"
  },
  "adjustmentReward": {
    "id": "q987462i-9617-4ac5-8601-8054755a9876"
  },
  "completionThreshold": 1,
  "icon": "campaign_2019_q1.jpg",
  "startsAt": "2019-01-01T00:00:00Z",
  "endsAt": "2019-12-31T23:59:00Z",
  "timeZone": "Central Time (US & Canada)",
  "createdAt": "2018-12-15T12:23:12Z",
  "updatedAt": "2018-12-15T12:23:12Z"
}

GET /campaigns/{campaignId}

Retrieves a single wellness campaign for a HealtheIntent tenant by ID.

Parameters

Parameter In Type Required Default Description Accepted Values
campaignId path string true N/A The ID of the wellness campaign. -

Response Statuses

Status Meaning Description Schema
200 OK OK CampaignDefinition
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Response Headers

Status Header Type Format Description
200 ETag string The ETag of a specific version of the campaign.

Create a Category for a Campaign

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories', headers: headers, body: {"names":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program."}],"descriptions":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program for Cerner Wellness Campaign."}],"startsAt":"2019-01-01T00:00:00","endsAt":"2019-12-31T23:00:00","parentCategoryId":"77a233a3-54d4-4ad3-9e63-53bb71762290","icon":"category.jpg","reward":{"id":"11b111c4-54d4-4ad3-9e63-53bb71762290"},"completionThreshold":1,"adjustmentReward":{"id":"22c222d5-54d4-4ad3-9e63-53bb71762290"},"objectives":[{"id":"a23222d5-23d4-ftd3-9e63-53bb71762290"},{"id":"62cd2e7c-8d39-11e9-bc42-526af7764f64"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"names":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program."}],"descriptions":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program for Cerner Wellness Campaign."}],"startsAt":"2019-01-01T00:00:00","endsAt":"2019-12-31T23:00:00","parentCategoryId":"77a233a3-54d4-4ad3-9e63-53bb71762290","icon":"category.jpg","reward":{"id":"11b111c4-54d4-4ad3-9e63-53bb71762290"},"completionThreshold":1,"adjustmentReward":{"id":"22c222d5-54d4-4ad3-9e63-53bb71762290"},"objectives":[{"id":"a23222d5-23d4-ftd3-9e63-53bb71762290"},{"id":"62cd2e7c-8d39-11e9-bc42-526af7764f64"}]}

Example response

{
  "id": "qwe3179c-9617-4ac5-8601-8054755a2a5c",
  "parentCategoryId": "b923179c-9617-6nc5-8601-8054755a1789",
  "position": 2,
  "names": [
    {
      "locale": "en-US",
      "text": "Reduce My Premium"
    }
  ],
  "descriptions": [
    {
      "locale": "en-US",
      "text": "Activities that help reduce your premium."
    }
  ],
  "reward": {
    "id": "b123werc-9617-4ac5-8601-8054755aabcd"
  },
  "adjustmentReward": {
    "id": "q113123i-9617-4ac5-8601-8054755a9876"
  },
  "completionThreshold": 1,
  "icon": "cat1.jep",
  "startsAt": "2019-01-01T00:00:00Z",
  "endsAt": "2019-12-31T23:59:00Z",
  "objectives": [
    {
      "position": 1,
      "objectiveDefinitionId": "a023179c-9617-4ac5-8601-8054755a2a5c"
    }
  ],
  "categories": [
    {}
  ],
  "createdAt": "2018-12-15T12:23:12Z",
  "updatedAt": "2018-12-15T12:23:12Z"
}

POST /campaigns/{campaignId}/categories

Creates a category for a campaign. Categories can be nested up to three levels.

Parameters

Parameter In Type Required Default Description Accepted Values
campaignId path string true N/A The ID of the wellness campaign. -
body body postCampaignsCampaignidCategories true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created CampaignCategory
400 Bad Request Bad Request. The category was not created. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- noDefaultLocale The default locale (en-US) is required for the name if it is used in the body.
- duplicateLocale The locales for the names must be unique.
- missingField Review and complete all required information to continue.
BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Retrieve a List of Categories for a Campaign

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "qwe3179c-9617-4ac5-8601-8054755a2a5c",
      "parentCategoryId": "b923179c-9617-6nc5-8601-8054755a1789",
      "position": 2,
      "names": [
        {
          "locale": "en-US",
          "text": "Reduce My Premium"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "Activities that help reduce your premium."
        }
      ],
      "reward": {
        "id": "b123werc-9617-4ac5-8601-8054755aabcd"
      },
      "adjustmentReward": {
        "id": "q113123i-9617-4ac5-8601-8054755a9876"
      },
      "completionThreshold": 1,
      "icon": "cat1.jep",
      "startsAt": "2019-01-01T00:00:00Z",
      "endsAt": "2019-12-31T23:59:00Z",
      "objectives": [
        {
          "position": 1,
          "objectiveDefinitionId": "a023179c-9617-4ac5-8601-8054755a2a5c"
        }
      ],
      "categories": [
        {}
      ],
      "createdAt": "2018-12-15T12:23:12Z",
      "updatedAt": "2018-12-15T12:23:12Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness-campaign/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness-campaign/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories?offset=0&limit=20"
}

GET /campaigns/{campaignId}/categories

Retrieves a list of categories for a campaign.

Parameters

Parameter In Type Required Default Description Accepted Values
campaignId path string true N/A The ID of the wellness campaign. -
locale query string false N/A Filters by locale. A locale is a two-letter language and two-letter region ID, for example, en-US. If this parameter is not specified, the default en-US locale is used. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -

Response Statuses

Status Meaning Description Schema
200 OK OK CampaignCategories
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden

Update a Category

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'If-Match' => {
  "type": "string"
}
} 

result = HTTParty.patch('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories/e933c828-d656-48a7-a875-01467419ed72', headers: headers, body: {"names":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program."}],"descriptions":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program for Cerner Wellness Campaign."}],"startsAt":"2019-01-01T00:00:00","endsAt":"2019-12-31T23:00:00","parentCategoryId":"77a233a3-54d4-4ad3-9e63-53bb71762290","position":2,"icon":"category.jpg","reward":{"id":"11b111c4-54d4-4ad3-9e63-53bb71762290"},"completionThreshold":1,"adjustmentReward":{"id":"22c222d5-54d4-4ad3-9e63-53bb71762290"},"objectives":[{"id":"a23222d5-23d4-ftd3-9e63-53bb71762290"},{"id":"62cd2e7c-8d39-11e9-bc42-526af7764f64"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PATCH https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories/e933c828-d656-48a7-a875-01467419ed72 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \ \
-H 'If-Match: [object Object]' \
-d {"names":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program."}],"descriptions":[{"locale":"en-US","text":"2019 Healthe Living Rewards Program for Cerner Wellness Campaign."}],"startsAt":"2019-01-01T00:00:00","endsAt":"2019-12-31T23:00:00","parentCategoryId":"77a233a3-54d4-4ad3-9e63-53bb71762290","position":2,"icon":"category.jpg","reward":{"id":"11b111c4-54d4-4ad3-9e63-53bb71762290"},"completionThreshold":1,"adjustmentReward":{"id":"22c222d5-54d4-4ad3-9e63-53bb71762290"},"objectives":[{"id":"a23222d5-23d4-ftd3-9e63-53bb71762290"},{"id":"62cd2e7c-8d39-11e9-bc42-526af7764f64"}]}

PATCH /campaigns/{campaignId}/categories/{categoryId}

Updates a category.

Parameters

Parameter In Type Required Default Description Accepted Values
If-Match header string true N/A The ETag for a specific version of a resource. If a user or system attempts to update a version of a category and the category was already updated to a new version, an error occurs. -
campaignId path string true N/A The ID of the wellness campaign. -
categoryId path string true N/A The ID of the category. -
body body patchCampaignsCampaignidCategories true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content No Content None
400 Bad Request Bad Request. The category was not created. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- noDefaultLocale The default locale (en-US) is required for the name if it is used in the body.
- duplicateLocale The locales for the names must be unique.
- missingField Review and complete all required information to continue.
BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Delete a Category From a Campaign

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.delete('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories/e933c828-d656-48a7-a875-01467419ed72', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories/e933c828-d656-48a7-a875-01467419ed72 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /campaigns/{campaignId}/categories/{categoryId}

Removes a category or category ID from a campaign.

Parameters

Parameter In Type Required Default Description Accepted Values
campaignId path string true N/A The ID of the wellness campaign. -
categoryId path string true N/A The ID of the category. -

Response Statuses

Status Meaning Description Schema
204 No Content No Content None
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Create an Objective or Goal for a Category

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories/e933c828-d656-48a7-a875-01467419ed72/objective-definitions', headers: headers, body: {"titles":[{"locale":"en-US","text":"Annual Flu Vaccination"}],"descriptions":[{"locale":"en-US","text":"Receive your annual flu vaccination and earn 25 points."}],"sourceDefinition":{"id":"z123179c-9617-4ac5-8601-8054755a2456","kind":"QUESTIONNAIRE"},"frequency":"DAILY","isRepeatableWithinFrequency":true,"startsAt":"2019-01-01T00:00:00","endsAt":"2019-12-31T23:00:00","maxCompletionCount":10,"primaryObjectiveId":"37a233a3-54d4-4ad3-9e63-53bb71762290","sources":"[ SPECIFIC_PROVIDER, CLAIM, SELF_ENTERED, APP_DEVICE, COACH_ENTERED, ADMINISTRATOR_UPLOADED, EMR_DW_INTEGRATION ]","conditions":[{"value":"50","operator":">","target":100,"subtype":"SYSTOLIC","consumerConditionType":"AGE"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories/e933c828-d656-48a7-a875-01467419ed72/objective-definitions \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"titles":[{"locale":"en-US","text":"Annual Flu Vaccination"}],"descriptions":[{"locale":"en-US","text":"Receive your annual flu vaccination and earn 25 points."}],"sourceDefinition":{"id":"z123179c-9617-4ac5-8601-8054755a2456","kind":"QUESTIONNAIRE"},"frequency":"DAILY","isRepeatableWithinFrequency":true,"startsAt":"2019-01-01T00:00:00","endsAt":"2019-12-31T23:00:00","maxCompletionCount":10,"primaryObjectiveId":"37a233a3-54d4-4ad3-9e63-53bb71762290","sources":"[ SPECIFIC_PROVIDER, CLAIM, SELF_ENTERED, APP_DEVICE, COACH_ENTERED, ADMINISTRATOR_UPLOADED, EMR_DW_INTEGRATION ]","conditions":[{"value":"50","operator":">","target":100,"subtype":"SYSTOLIC","consumerConditionType":"AGE"}]}

Example response

{
  "id": "c44718e2-623f-4202-a4bb-db3e5816d258",
  "sourceDefinition": {
    "id": "abc3179c-9617-4ac5-8601-8054755a2xyz",
    "type": "QUESTIONNAIRE"
  },
  "frequency": "DAILY",
  "maxCompletionCount": 10,
  "primaryObjectiveId": "a923179c-9600-4ac5-8601-8054755a2a5c",
  "conditions": [
    {
      "value": 100,
      "operator": ">",
      "target": 100,
      "consumerConditionType": "AGE",
      "subtype": "SYSTOLIC"
    }
  ],
  "sources": [
    "SPECIFIC_PROVIDER",
    "CLAIM",
    "SELF_ENTERED",
    "APP_DEVICE",
    "COACH_ENTERED"
  ]
}

POST /campaigns/{campaignId}/categories/{categoryId}/objective-definitions

Creates an objective or goal for a category of a wellness campaign.

Parameters

Parameter In Type Required Default Description Accepted Values
campaignId path string true N/A The ID of the wellness campaign. -
categoryId path string true N/A The ID of the category. -
body body postCampaignsCampaignidCategoriesCategoryidObjectiveDefinitions true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created CreatedObjective
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Retrieve a List of Objectives or Goals for a Category

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories/e933c828-d656-48a7-a875-01467419ed72/objective-definitions', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories/e933c828-d656-48a7-a875-01467419ed72/objective-definitions \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "c44718e2-623f-4202-a4bb-db3e5816d258",
      "position": 1,
      "titles": [
        {
          "locale": "en-US",
          "text": "Complete PHA"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "Complete PHA to earn 100 points."
        }
      ],
      "sourceDefinition": {
        "id": "abc3179c-9617-4ac5-8601-8054755a2xyz",
        "kind": "QUESTIONNAIRE"
      },
      "startsAt": "2019-01-01T00:00:00Z",
      "endsAt": "2019-12-31T23:59:00Z",
      "frequency": "QUARTERLY",
      "maxCompletionCount": 10,
      "primaryObjectiveId": "x123456q-9617-4ac5-8601-80547512345",
      "conditions": [
        {
          "value": 100,
          "operator": ">",
          "target": 100,
          "consumerConditionType": "AGE",
          "subtype": "SYSTOLIC"
        }
      ],
      "sources": [
        "SELF_ENTERED"
      ],
      "createdAt": "2018-12-15T12:23:12Z",
      "updatedAt": "2018-12-15T12:23:12Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories/e933c828-d656-48a7-a875-01467419ed72/objective-definitions?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories/e933c828-d656-48a7-a875-01467419ed72/objective-definitions?offset=0&limit=20"
}

GET /campaigns/{campaignId}/categories/{categoryId}/objective-definitions

Retrieves a list of objectives or goals for a category of a wellness campaign.

Parameters

Parameter In Type Required Default Description Accepted Values
campaignId path string true N/A The ID of the wellness campaign. -
categoryId path string true N/A The ID of the category. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -
orderBy query string false updatedAt A comma-separated list of fields by which to sort. updatedAt, -updatedAt

Response Statuses

Status Meaning Description Schema
200 OK OK Objectives
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Delete an Objective Definition From a Category

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.delete('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories/e933c828-d656-48a7-a875-01467419ed72/objective-definitions/3d17b72e-02e5-40b0-ab9b-35530a2c39cc', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories/e933c828-d656-48a7-a875-01467419ed72/objective-definitions/3d17b72e-02e5-40b0-ab9b-35530a2c39cc \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /campaigns/{campaignId}/categories/{categoryId}/objective-definitions/{objectiveDefinitionId}

Deletes an objective definition from a category of a wellness campaign.

Parameters

Parameter In Type Required Default Description Accepted Values
campaignId path string true N/A The ID of the wellness campaign. -
categoryId path string true N/A The ID of the category. -
objectiveDefinitionId path string true N/A The ID of the objective. -

Response Statuses

Status Meaning Description Schema
204 No Content No Content None
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Update an Objective in a Category

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'If-Match' => {
  "type": "string"
}
} 

result = HTTParty.patch('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories/e933c828-d656-48a7-a875-01467419ed72/objective-definitions/3d17b72e-02e5-40b0-ab9b-35530a2c39cc', headers: headers, body: {"titles":[{"locale":"en-US","text":"Annual Flu Vaccination."}],"descriptions":[{"locale":"en-US","text":"Receive your annual flu vaccination and earn 25 points."}],"sourceDefinition":{"id":"z123179c-9617-4ac5-8601-8054755a2456","kind":"QUESTIONNAIRE"},"frequency":"DAILY","isRepeatableWithinFrequency":true,"startsAt":"2019-01-01T00:00:00","endsAt":"2019-12-31T23:00:00","maxCompletionCount":10,"sources":"[ SPECIFIC_PROVIDER, CLAIM ]","conditions":[{"value":"50","operator":">","target":100,"subtype":"SYSTOLIC","consumerConditionType":"AGE"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PATCH https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaigns/1233179c-9617-4ac5-8601-8054755a2asd/categories/e933c828-d656-48a7-a875-01467419ed72/objective-definitions/3d17b72e-02e5-40b0-ab9b-35530a2c39cc \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \ \
-H 'If-Match: [object Object]' \
-d {"titles":[{"locale":"en-US","text":"Annual Flu Vaccination."}],"descriptions":[{"locale":"en-US","text":"Receive your annual flu vaccination and earn 25 points."}],"sourceDefinition":{"id":"z123179c-9617-4ac5-8601-8054755a2456","kind":"QUESTIONNAIRE"},"frequency":"DAILY","isRepeatableWithinFrequency":true,"startsAt":"2019-01-01T00:00:00","endsAt":"2019-12-31T23:00:00","maxCompletionCount":10,"sources":"[ SPECIFIC_PROVIDER, CLAIM ]","conditions":[{"value":"50","operator":">","target":100,"subtype":"SYSTOLIC","consumerConditionType":"AGE"}]}

PATCH /campaigns/{campaignId}/categories/{categoryId}/objective-definitions/{objectiveDefinitionId}

Updates an objective or goal in a category of a wellness campaign.

Parameters

Parameter In Type Required Default Description Accepted Values
If-Match header string true N/A The ETag for a specific version of a resource. If a user or system attempts to update a version of an objective and the objective was already updated to a new version, an error occurs. -
campaignId path string true N/A The ID of the wellness campaign. -
categoryId path string true N/A The ID of the category. -
objectiveDefinitionId path string true N/A The ID of the objective. -
body body patchCampaignsCampaignidCategoriesCategoryidObjectiveDefinitions true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content No Content None
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Retrieve a List of Campaign Instances

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-instances', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-instances \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "a12141b0-2cb3-44be-9f4f-0eef101c309d",
      "campaignId": "q093179c-9617-4ac5-8601-8054755a2123",
      "categoryId": "8d805c5a-3090-4aed-b5bf-52737594fa39",
      "names": [
        {
          "locale": "en-US",
          "text": "2019 Healthe Living Rewards Program"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "2019 Healthe Living Rewards Program for Cerner Wellness Campaign."
        }
      ],
      "completionThreshold": 1,
      "startsAt": "2019-01-01T00:00:00Z",
      "endsAt": "2019-12-31T23:59:00Z",
      "reward": {
        "id": "11e8902c9e2908c69718f13503066bee",
        "value": "1",
        "limit": "10",
        "units": [
          {
            "singularName": "dollar",
            "pluralName": "dollars",
            "locale": "en-US"
          }
        ]
      },
      "adjustmentReward": {
        "id": "11e8902c9e2908c69718f13503066bee",
        "value": "1",
        "limit": "10",
        "units": [
          {
            "singularName": "dollar",
            "pluralName": "dollars",
            "locale": "en-US"
          }
        ]
      },
      "timeZone": "Central Time (US & Canada)",
      "icon": "campaign_2019_q1.jpg",
      "populations": [
        {
          "populationId": "l783179c-0917-4ac5-8601-8054755a2789",
          "dataPartitionId": "o463179c-9618-4ac5-8601-8054755a2890"
        }
      ],
      "createdAt": "2018-12-15T12:23:12Z",
      "updatedAt": "2018-12-15T12:23:12Z",
      "categories": [
        {
          "id": "b923179c-9617-4ac5-8601-8054755a2234",
          "parentCategoryId": "a123179c-9633-4ac5-8601-8054755a2a5c",
          "names": [
            {
              "locale": "en-US",
              "text": "2019 Healthe Living Rewards Program"
            }
          ],
          "descriptions": [
            {
              "locale": "en-US",
              "text": "2019 Healthe Living Rewards Program for Cerner Wellness Campaign."
            }
          ],
          "reward": {
            "id": "11e8902c9e2908c69718f13503066bee",
            "value": "1",
            "limit": "10",
            "units": [
              {
                "singularName": "dollar",
                "pluralName": "dollars",
                "locale": "en-US"
              }
            ]
          },
          "adjustmentReward": {
            "id": "11e8902c9e2908c69718f13503066bee",
            "value": "1",
            "limit": "10",
            "units": [
              {
                "singularName": "dollar",
                "pluralName": "dollars",
                "locale": "en-US"
              }
            ]
          },
          "completionThreshold": 1,
          "icon": "category_2019_q1.jpg",
          "startsAt": "2019-01-01T00:00:00Z",
          "endsAt": "2019-12-31T23:59:00Z",
          "createdAt": "2018-12-15T12:23:12Z",
          "updatedAt": "2018-12-15T12:23:12Z",
          "objectives": [
            {
              "id": "c44718e2-623f-4202-a4bb-db3e5816d258",
              "activity_definition_id": "a66718e2-532d-2232-b6rt-dfe24343234",
              "position": 1,
              "titles": [
                {
                  "locale": "en-US",
                  "text": "Complete PHA"
                }
              ],
              "descriptions": [
                {
                  "locale": "en-US",
                  "text": "Complete PHA to earn 100 points."
                }
              ],
              "sourceDefinition": {
                "id": "c923179c-9617-4ac5-8601-8054755a2a5c",
                "kind": "QUESTIONNAIRE"
              },
              "frequency": "QUARTERLY",
              "maxCompletionCount": 10,
              "primaryObjectiveId": "x123456q-9617-4ac5-8601-80547512345",
              "alternatives": [
                {}
              ],
              "conditions": [
                {
                  "value": 100,
                  "operator": ">",
                  "target": 100,
                  "consumerConditionType": "AGE",
                  "subtype": "SYSTOLIC"
                }
              ],
              "sources": [
                "SELF_ENTERED"
              ],
              "incentive": {
                "id": "20556922-21e0-46dc-9224-7b914bb67b5d",
                "objectiveId": "12356922-21e0-46dc-9224-7b914bb67b5d",
                "rewardLimitPerFrequency": 5,
                "reward": {
                  "id": "11e8902c9e2908c69718f13503066bee",
                  "value": "1",
                  "limit": "10",
                  "units": [
                    {
                      "singularName": "dollar",
                      "pluralName": "dollars",
                      "locale": "en-US"
                    }
                  ]
                }
              }
            }
          ],
          "categories": [
            {}
          ]
        }
      ],
      "objectives": [
        {
          "id": "c44718e2-623f-4202-a4bb-db3e5816d258",
          "activity_definition_id": "a66718e2-532d-2232-b6rt-dfe24343234",
          "position": 1,
          "titles": [
            {
              "locale": "en-US",
              "text": "Complete PHA"
            }
          ],
          "descriptions": [
            {
              "locale": "en-US",
              "text": "Complete PHA to earn 100 points."
            }
          ],
          "sourceDefinition": {
            "id": "c923179c-9617-4ac5-8601-8054755a2a5c",
            "kind": "QUESTIONNAIRE"
          },
          "frequency": "QUARTERLY",
          "maxCompletionCount": 10,
          "primaryObjectiveId": "x123456q-9617-4ac5-8601-80547512345",
          "alternatives": [
            {}
          ],
          "conditions": [
            {
              "value": 100,
              "operator": ">",
              "target": 100,
              "consumerConditionType": "AGE",
              "subtype": "SYSTOLIC"
            }
          ],
          "sources": [
            "SELF_ENTERED"
          ],
          "incentive": {
            "id": "20556922-21e0-46dc-9224-7b914bb67b5d",
            "objectiveId": "12356922-21e0-46dc-9224-7b914bb67b5d",
            "rewardLimitPerFrequency": 5,
            "reward": {
              "id": "11e8902c9e2908c69718f13503066bee",
              "value": "1",
              "limit": "10",
              "units": [
                {
                  "singularName": "dollar",
                  "pluralName": "dollars",
                  "locale": "en-US"
                }
              ]
            }
          }
        }
      ]
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness-campaign/v1/campaign-instances?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness-campaign/v1/campaign-instances?offset=0&limit=20"
}

GET /campaign-instances

Retrieves a list of campaign instances.

Parameters

Parameter In Type Required Default Description Accepted Values
campaignId query string false N/A Filters by the ID of the wellness campaign. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -
orderBy query string false createdAt A comma-separated list of fields by which to sort. createdAt, -createdAt

Response Statuses

Status Meaning Description Schema
200 OK OK CampaignInstances
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden

Publish a Campaign

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-instances', headers: headers, body: {"campaignId":"4f97d9ec-8bc2-11e9-bc42-526af7764f64"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-instances \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"campaignId":"4f97d9ec-8bc2-11e9-bc42-526af7764f64"}

POST /campaign-instances

Publishes a campaign with the specified ID. A published campaign is available to members.

Parameters

Parameter In Type Required Default Description Accepted Values
body body postCampaignInstances true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content No Content None
400 Bad Request Bad Request. The campaign was not published. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- errorCreateReference The reference could not be created.
- categoryDate Category dates must be within the parent category dates.
- objectiveNotFound The category’s objective or objective cannot be found.
- incentiveNotFound The category’s incentive or incentives cannot be found.
- rewardNotFound The category’s reward cannot be found.
- translationNotFound The category’s translations cannot be found.
- objectiveDate Objective dates must be within the category dates.
BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden

Retrieve a Single Campaign Instance

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-instances/11e8902c9e2908c69718f13503066bee', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-instances/11e8902c9e2908c69718f13503066bee \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "a12141b0-2cb3-44be-9f4f-0eef101c309d",
  "campaignId": "q093179c-9617-4ac5-8601-8054755a2123",
  "categoryId": "8d805c5a-3090-4aed-b5bf-52737594fa39",
  "names": [
    {
      "locale": "en-US",
      "text": "2019 Healthe Living Rewards Program"
    }
  ],
  "descriptions": [
    {
      "locale": "en-US",
      "text": "2019 Healthe Living Rewards Program for Cerner Wellness Campaign."
    }
  ],
  "completionThreshold": 1,
  "startsAt": "2019-01-01T00:00:00Z",
  "endsAt": "2019-12-31T23:59:00Z",
  "reward": {
    "id": "11e8902c9e2908c69718f13503066bee",
    "value": "1",
    "limit": "10",
    "units": [
      {
        "singularName": "dollar",
        "pluralName": "dollars",
        "locale": "en-US"
      }
    ]
  },
  "adjustmentReward": {
    "id": "11e8902c9e2908c69718f13503066bee",
    "value": "1",
    "limit": "10",
    "units": [
      {
        "singularName": "dollar",
        "pluralName": "dollars",
        "locale": "en-US"
      }
    ]
  },
  "timeZone": "Central Time (US & Canada)",
  "icon": "campaign_2019_q1.jpg",
  "populations": [
    {
      "populationId": "l783179c-0917-4ac5-8601-8054755a2789",
      "dataPartitionId": "o463179c-9618-4ac5-8601-8054755a2890"
    }
  ],
  "createdAt": "2018-12-15T12:23:12Z",
  "updatedAt": "2018-12-15T12:23:12Z",
  "categories": [
    {
      "id": "b923179c-9617-4ac5-8601-8054755a2234",
      "parentCategoryId": "a123179c-9633-4ac5-8601-8054755a2a5c",
      "names": [
        {
          "locale": "en-US",
          "text": "2019 Healthe Living Rewards Program"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "2019 Healthe Living Rewards Program for Cerner Wellness Campaign."
        }
      ],
      "reward": {
        "id": "11e8902c9e2908c69718f13503066bee",
        "value": "1",
        "limit": "10",
        "units": [
          {
            "singularName": "dollar",
            "pluralName": "dollars",
            "locale": "en-US"
          }
        ]
      },
      "adjustmentReward": {
        "id": "11e8902c9e2908c69718f13503066bee",
        "value": "1",
        "limit": "10",
        "units": [
          {
            "singularName": "dollar",
            "pluralName": "dollars",
            "locale": "en-US"
          }
        ]
      },
      "completionThreshold": 1,
      "icon": "category_2019_q1.jpg",
      "startsAt": "2019-01-01T00:00:00Z",
      "endsAt": "2019-12-31T23:59:00Z",
      "createdAt": "2018-12-15T12:23:12Z",
      "updatedAt": "2018-12-15T12:23:12Z",
      "objectives": [
        {
          "id": "c44718e2-623f-4202-a4bb-db3e5816d258",
          "activity_definition_id": "a66718e2-532d-2232-b6rt-dfe24343234",
          "position": 1,
          "titles": [
            {
              "locale": "en-US",
              "text": "Complete PHA"
            }
          ],
          "descriptions": [
            {
              "locale": "en-US",
              "text": "Complete PHA to earn 100 points."
            }
          ],
          "sourceDefinition": {
            "id": "c923179c-9617-4ac5-8601-8054755a2a5c",
            "kind": "QUESTIONNAIRE"
          },
          "frequency": "QUARTERLY",
          "maxCompletionCount": 10,
          "primaryObjectiveId": "x123456q-9617-4ac5-8601-80547512345",
          "alternatives": [
            {}
          ],
          "conditions": [
            {
              "value": 100,
              "operator": ">",
              "target": 100,
              "consumerConditionType": "AGE",
              "subtype": "SYSTOLIC"
            }
          ],
          "sources": [
            "SELF_ENTERED"
          ],
          "incentive": {
            "id": "20556922-21e0-46dc-9224-7b914bb67b5d",
            "objectiveId": "12356922-21e0-46dc-9224-7b914bb67b5d",
            "rewardLimitPerFrequency": 5,
            "reward": {
              "id": "11e8902c9e2908c69718f13503066bee",
              "value": "1",
              "limit": "10",
              "units": [
                {
                  "singularName": "dollar",
                  "pluralName": "dollars",
                  "locale": "en-US"
                }
              ]
            }
          }
        }
      ],
      "categories": [
        {}
      ]
    }
  ],
  "objectives": [
    {
      "id": "c44718e2-623f-4202-a4bb-db3e5816d258",
      "activity_definition_id": "a66718e2-532d-2232-b6rt-dfe24343234",
      "position": 1,
      "titles": [
        {
          "locale": "en-US",
          "text": "Complete PHA"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "Complete PHA to earn 100 points."
        }
      ],
      "sourceDefinition": {
        "id": "c923179c-9617-4ac5-8601-8054755a2a5c",
        "kind": "QUESTIONNAIRE"
      },
      "frequency": "QUARTERLY",
      "maxCompletionCount": 10,
      "primaryObjectiveId": "x123456q-9617-4ac5-8601-80547512345",
      "alternatives": [
        {}
      ],
      "conditions": [
        {
          "value": 100,
          "operator": ">",
          "target": 100,
          "consumerConditionType": "AGE",
          "subtype": "SYSTOLIC"
        }
      ],
      "sources": [
        "SELF_ENTERED"
      ],
      "incentive": {
        "id": "20556922-21e0-46dc-9224-7b914bb67b5d",
        "objectiveId": "12356922-21e0-46dc-9224-7b914bb67b5d",
        "rewardLimitPerFrequency": 5,
        "reward": {
          "id": "11e8902c9e2908c69718f13503066bee",
          "value": "1",
          "limit": "10",
          "units": [
            {
              "singularName": "dollar",
              "pluralName": "dollars",
              "locale": "en-US"
            }
          ]
        }
      }
    }
  ]
}

GET /campaign-instances/{campaignInstanceId}

Retrieves a single campaign instance by ID.

Parameters

Parameter In Type Required Default Description Accepted Values
campaignInstanceId path string true N/A The ID of the campaign instance. -

Response Statuses

Status Meaning Description Schema
200 OK OK CampaignInstance
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Campaign Memberships

Campaign membership indicates that a consumer is a participant in a wellness campaign.

Add a Campaign Member

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-memberships', headers: headers, body: {"campaignId":"77a233a3-54d4-4ad3-9e63-53bb71762290","consumerId":"88a233a3-54d4-4ad3-9e63-53bb71762290"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-memberships \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"campaignId":"77a233a3-54d4-4ad3-9e63-53bb71762290","consumerId":"88a233a3-54d4-4ad3-9e63-53bb71762290"}

Example response

{
  "id": "11e8902c9e2908c69718f13503066bee",
  "campaignId": "22e8902c9e2908c69718f13503066bee",
  "consumerId": "33e8902c9e2908c69718f13503066bee",
  "createdAt": "2018-12-15T12:23:12Z",
  "updatedAt": "2018-05-15T12:23:12Z"
}

POST /campaign-memberships

Adds a consumer to a specific campaign by creating a campaign membership for the campaign.

Parameters

Parameter In Type Required Default Description Accepted Values
body body postCampaignMemberships true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created CampaignMembership
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden

Retrieve a List of Campaign Memberships

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-memberships', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-memberships \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "11e8902c9e2908c69718f13503066bee",
      "campaignId": "22e8902c9e2908c69718f13503066bee",
      "consumerId": "33e8902c9e2908c69718f13503066bee",
      "createdAt": "2018-12-15T12:23:12Z",
      "updatedAt": "2018-05-15T12:23:12Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-memberships?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-memberships?offset=0&limit=20"
}

GET /campaign-memberships

Retrieves a list of campaign memberships.

Parameters

Parameter In Type Required Default Description Accepted Values
campaignId query array[string] false N/A The ID of the incentive campaign. -
consumerId query array[string] false N/A The ID of the consumer. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -
orderBy query string false updatedAt A comma-separated list of fields by which to sort. updatedAt, -updatedAt, campaignId, consumerId

Response Statuses

Status Meaning Description Schema
200 OK OK CampaignMemberships
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden

Remove a Campaign Member

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.delete('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-memberships/11e8902c9e2908c69718f13503066bee', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-memberships/11e8902c9e2908c69718f13503066bee \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /campaign-memberships/{membershipId}

Removes a consumer from a campaign by deleting the specified campaign membership.

Parameters

Parameter In Type Required Default Description Accepted Values
membershipId path string true N/A The ID of the campaign membership. -

Response Statuses

Status Meaning Description Schema
204 No Content No Content None
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Retrieve a Single Campaign Membership

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-memberships/11e8902c9e2908c69718f13503066bee', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-memberships/11e8902c9e2908c69718f13503066bee \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "11e8902c9e2908c69718f13503066bee",
  "campaignId": "22e8902c9e2908c69718f13503066bee",
  "consumerId": "33e8902c9e2908c69718f13503066bee",
  "createdAt": "2018-12-15T12:23:12Z",
  "updatedAt": "2018-05-15T12:23:12Z"
}

GET /campaign-memberships/{membershipId}

Retrieves a single campaign membership by ID.

Parameters

Parameter In Type Required Default Description Accepted Values
membershipId path string true N/A The ID of the campaign membership. -

Response Statuses

Status Meaning Description Schema
200 OK OK CampaignMembership
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Wellness Incentive Rewards

Wellness incentive rewards are tangible offers for completing incentivized activities. Rewards can be used to further entice the campaign member to achieve their and the campaign’s goals.

Create a Reward Definition

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/reward-definitions', headers: headers, body: {"value":1,"limit":10,"units":[{"singularName":"dollar","pluralName":"dollars","locale":"en-US"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/reward-definitions \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"value":1,"limit":10,"units":[{"singularName":"dollar","pluralName":"dollars","locale":"en-US"}]}

Example response

{
  "id": "11e8902c9e2908c69718f13503066bee",
  "value": "1",
  "limit": "10",
  "units": [
    {
      "singularName": "dollar",
      "pluralName": "dollars",
      "locale": "en-US"
    }
  ]
}

POST /reward-definitions

Adds a wellness incentive reward definition.

Parameters

Parameter In Type Required Default Description Accepted Values
body body postRewardDefinitions true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created RewardDefinition
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden

Retrieves a List of Reward Definitions

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/reward-definitions', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/reward-definitions \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "11e8902c9e2908c69718f13503066bee",
      "value": "1",
      "limit": "10",
      "units": [
        {
          "singularName": "dollar",
          "pluralName": "dollars",
          "locale": "en-US"
        }
      ]
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness-rewards/v1/rewards?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness-rewards/v1/rewards?offset=0&limit=20"
}

GET /reward-definitions

Retrieves a list of wellness incentive reward definitions.

Parameters

Parameter In Type Required Default Description Accepted Values
id query array[string] false N/A Filters by the ID or IDs of one or many reward definitions. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -
orderBy query string false updatedAt A comma-separated list of fields by which to sort. createdAt, updatedAt

Response Statuses

Status Meaning Description Schema
200 OK OK RewardDefinitions
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden

Delete a Reward Definition

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.delete('https://cernerdemo.api.us.healtheintent.com/wellness/v1/reward-definitions/ffe6a5d1-d8f7-44c7-a7a4-37ec99bcc925', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us.healtheintent.com/wellness/v1/reward-definitions/ffe6a5d1-d8f7-44c7-a7a4-37ec99bcc925 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /reward-definitions/{rewardDefinitionId}

Deletes a wellness incentive reward definition by ID.

Parameters

Parameter In Type Required Default Description Accepted Values
rewardDefinitionId path string true N/A The ID of the reward definition. -

Response Statuses

Status Meaning Description Schema
204 No Content No Content None
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Update a Reward Definition

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.patch('https://cernerdemo.api.us.healtheintent.com/wellness/v1/reward-definitions/ffe6a5d1-d8f7-44c7-a7a4-37ec99bcc925', headers: headers, body: {"value":1,"limit":10,"units":[{"singularName":"dollar","pluralName":"dollars","locale":"en-US"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PATCH https://cernerdemo.api.us.healtheintent.com/wellness/v1/reward-definitions/ffe6a5d1-d8f7-44c7-a7a4-37ec99bcc925 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"value":1,"limit":10,"units":[{"singularName":"dollar","pluralName":"dollars","locale":"en-US"}]}

PATCH /reward-definitions/{rewardDefinitionId}

Updates a wellness incentive reward definition by ID.

Parameters

Parameter In Type Required Default Description Accepted Values
rewardDefinitionId path string true N/A The ID of the reward definition. -
body body patchRewardDefinitions true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content No Content. None
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Retrieve a Single Reward Definition

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/reward-definitions/ffadf1b7-b812-4eed-a769-f6a6c4c04b97', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/reward-definitions/ffadf1b7-b812-4eed-a769-f6a6c4c04b97 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "11e8902c9e2908c69718f13503066bee",
  "value": "1",
  "limit": "10",
  "units": [
    {
      "singularName": "dollar",
      "pluralName": "dollars",
      "locale": "en-US"
    }
  ]
}

GET /reward-definitions/{rewardDefinitionId}

Retrieves a single wellness incentive reward definition by ID.

Parameters

Parameter In Type Required Default Description Accepted Values
rewardDefinitionId path string true N/A The ID of the reward definition. -

Response Statuses

Status Meaning Description Schema
200 OK OK RewardDefinition
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Retrieves a List of Rewards

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/rewards', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/rewards \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "11ab9385-8c94-41c6-96b1-ab881ab93d88",
      "consumer": {
        "id": "6fe5d564-348d-41d9-888b-1f9bd45e985c"
      },
      "reward": {
        "id": "e394eda2-9053-4ab5-ac01-1e5284c746a1"
      },
      "earned": "2",
      "effective": "1",
      "createdAt": "2018-12-15T12:23:12Z",
      "updatedAt": "2018-12-15T12:23:12Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness-rewards/v1/consumer-rewards?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness-rewards/v1/consumer-rewards?offset=0&limit=20"
}

GET /rewards

Retrieves a list of wellness incentive rewards.

Parameters

Parameter In Type Required Default Description Accepted Values
rewardId query array[string] false N/A Filters by the ID of the reward definition. -
consumerId query array[string] false N/A Filters by the ID of the consumer. -
campaignId query string false N/A Filters by the ID of the wellness campaign. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -

Response Statuses

Status Meaning Description Schema
200 OK OK ConsumerIncentiveRewardLists
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden

Retrieve a Single Reward

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/rewards/ffe6a5d1-d8f7-44c7-a7a4-37ec99bcc925', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/rewards/ffe6a5d1-d8f7-44c7-a7a4-37ec99bcc925 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "11ab9385-8c94-41c6-96b1-ab881ab93d88",
  "consumer": {
    "id": "6fe5d564-348d-41d9-888b-1f9bd45e985c"
  },
  "reward": {
    "id": "e394eda2-9053-4ab5-ac01-1e5284c746a1"
  },
  "earned": "2",
  "effective": "1",
  "createdAt": "2018-12-15T12:23:12Z",
  "updatedAt": "2018-12-15T12:23:12Z",
  "transactions": [
    {
      "id": "5c82129d-e200-4905-b405-6004e45b3410",
      "delta": "1",
      "referenceSystem": {
        "id": "abc3179c-9617-4ac5-8601-8054755a2xyz",
        "kind": "STEPS"
      },
      "createdAt": "2018-12-15T12:23:12Z",
      "updatedAt": "2018-12-15T12:23:12Z"
    }
  ]
}

GET /rewards/{rewardId}

Retrieves a single wellness incentive reward by ID.

Parameters

Parameter In Type Required Default Description Accepted Values
rewardId path string true N/A The ID of the reward. -

Response Statuses

Status Meaning Description Schema
200 OK OK ConsumerIncentiveReward
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden
404 Not Found Not Found NotFound

Campaign Objectives

A campaign objective is an incentivized activity associated with a wellness campaign. Consumers receive incentive rewards by completing the objectives of a wellness campaign.

Retrieve a List of Campaign Objectives

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-objectives', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-objectives \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "consumer": {
        "id": "6fe5d564-348d-41d9-888b-1f9bd45e985c"
      },
      "objectiveDefinition": {
        "id": "c3368a32-78ca-4bfd-9d2a-47170d179f33",
        "sourceDefinition": {
          "id": "e1ab427f-5b22-468e-87a0-8968a6137933",
          "kind": "QUESTIONNAIRE"
        }
      },
      "overallStatus": "IN_PROGRESS",
      "overallCompletionCount": 10,
      "detailsByFrequency": [
        {
          "status": "IN_PROGRESS",
          "frequencyBeginsAt": "2019-08-01",
          "completionCount": 5,
          "activityCount": 3,
          "adminAwardedCount": 2,
          "consumerActivitySourceDefinitions": [
            {
              "id": "e54ac10a-31a3-499e-bb52-3821baef7009"
            }
          ]
        }
      ]
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-objectives?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-objectives?offset=0&limit=20"
}

GET /campaign-objectives

Retrieves a list of campaign objectives and their summarizing data.

Parameters

Parameter In Type Required Default Description Accepted Values
consumerId query array[string] false N/A Filters by the ID of the consumer. -
objectiveId query array[string] false N/A Filters by the ID of the objective. -
sourceDefinitionKind query string false N/A Filters by the source system in which the objective is defined. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -

Response Statuses

Status Meaning Description Schema
200 OK OK ObjectiveStatuses
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden

Complete a Campaign Objective

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-objectives', headers: headers, body: {"consumer":{"id":"12342f22-93ca-4aa7-81ff-5811a9be1899"},"locale":"en-US","activity":{"sourceDefinition":{"id":"b7e15f69-841c-4244-8ace-350d071452ab","kind":"wellness#learningModules"},"id":"ea4a8ba6-eaed-46d2-832c-a7b52445f006","performedOn":"2019-01-01T00:00:00Z","name":"Dentist Visit","details":"Semi Annual Checkup","providerName":"Dr. Smith, University City Hospital","providerLocation":"Kansas City, KC - 34444","status":"PENDING"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/campaign-objectives \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"consumer":{"id":"12342f22-93ca-4aa7-81ff-5811a9be1899"},"locale":"en-US","activity":{"sourceDefinition":{"id":"b7e15f69-841c-4244-8ace-350d071452ab","kind":"wellness#learningModules"},"id":"ea4a8ba6-eaed-46d2-832c-a7b52445f006","performedOn":"2019-01-01T00:00:00Z","name":"Dentist Visit","details":"Semi Annual Checkup","providerName":"Dr. Smith, University City Hospital","providerLocation":"Kansas City, KC - 34444","status":"PENDING"}}

Example response

{
  "items": [
    {
      "campaign": {
        "id": "b923179c-9617-4ac5-8601-8054755a2a5c"
      },
      "completionCount": 5,
      "pointsAchieved": 200,
      "unit": {
        "unitSingularName": "dollar",
        "unitPluralName": "dollars"
      }
    }
  ]
}

POST /campaign-objectives

Completes a campaign objective.

Parameters

Parameter In Type Required Default Description Accepted Values
body body postCampaignObjectives true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created IncentiveCalculationList
400 Bad Request Bad Request BadRequest
401 Unauthorized Unauthorized Unauthorized
403 Forbidden Forbidden Forbidden

Personal Health Assessment

A personal health assessment (PHA) is a structured set of questions and instructions presented to collect answers from HealtheIntent consumers. The PHA endpoints enable the creation and presentation of PHAs and their answers.

Retrieve a List of PHA Definitions

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "e61dd2fa-702d-11e9-a923-1681be663d3e",
      "phaId": "ace20324-a0b9-11e8-98d0-529269fb1459",
      "name": "Cerner Demo Personal Health Assessment 2019",
      "locale": "en-US",
      "description": "Cerner Demo Personal Health Assessment 2019 is a wellness assessment to evaluate the overall physical and mental health of a person.",
      "code": {
        "system": "urn:ietf:rfc:3986",
        "code": "2-16-840-1-113883-6-1",
        "display": "Personal Health Assessment"
      }
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions?offset=0&limit=20"
}

GET /pha-definitions

Retrieves a list of all the available PHA definitions.

Parameters

Parameter In Type Required Default Description Accepted Values
phaId query string false N/A Filters by the ID of a PHA. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -

Response Statuses

Status Meaning Description Schema
200 OK Success PhaDefinitions
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError

Create a PHA Definition

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions', headers: headers, body: {"name":"Cerner Demo Personal Health Assessment 2019","locale":"en-US","description":"Cerner Demo Personal Health Assessment 2019 is a wellness assessment to evaluate the overall physical and mental health of a person.","code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Cerner Demo Personal Health Assessment 2019","locale":"en-US","description":"Cerner Demo Personal Health Assessment 2019 is a wellness assessment to evaluate the overall physical and mental health of a person.","code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"}}

Example response

{
  "id": "e61dd2fa-702d-11e9-a923-1681be663d3e",
  "phaId": "ace20324-a0b9-11e8-98d0-529269fb1459",
  "name": "Cerner Demo Personal Health Assessment 2019",
  "locale": "en-US",
  "description": "Cerner Demo Personal Health Assessment 2019 is a wellness assessment to evaluate the overall physical and mental health of a person.",
  "code": {
    "system": "urn:ietf:rfc:3986",
    "code": "2-16-840-1-113883-6-1",
    "display": "Personal Health Assessment"
  }
}

POST /pha-definitions

Creates a new PHA definition. A PHA definition is a structured set of questions and instructions that is presented to help collect answers from HealtheIntent consumers.

Parameters

Parameter In Type Required Default Description Accepted Values
body body postPhaDefinitions true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created PhaDefinition
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError

Delete a PHA Definition

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.delete('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /pha-definitions/{phaDefinitionId}

Deletes a PHA definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -

Response Statuses

Status Meaning Description Schema
204 No Content Deleted None
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Update a PHA Definition

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.put('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e', headers: headers, body: {"name":"Cerner Demo Personal Health Assessment 2019","locale":"en-US","description":"Cerner Demo Personal Health Assessment 2019 is a wellness assessment to evaluate the overall physical and mental health of a person.","code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Cerner Demo Personal Health Assessment 2019","locale":"en-US","description":"Cerner Demo Personal Health Assessment 2019 is a wellness assessment to evaluate the overall physical and mental health of a person.","code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"}}

PUT /pha-definitions/{phaDefinitionId}

Updates a PHA definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
body body putPhaDefinitions true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated None
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a Single PHA Definition

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "e61dd2fa-702d-11e9-a923-1681be663d3e",
  "phaId": "ace20324-a0b9-11e8-98d0-529269fb1459",
  "name": "Cerner Demo Personal Health Assessment 2019",
  "locale": "en-US",
  "description": "Cerner Demo Personal Health Assessment 2019 is a wellness assessment to evaluate the overall physical and mental health of a person.",
  "code": {
    "system": "urn:ietf:rfc:3986",
    "code": "2-16-840-1-113883-6-1",
    "display": "Personal Health Assessment"
  }
}

GET /pha-definitions/{phaDefinitionId}

Retrieves a single PHA definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -

Response Statuses

Status Meaning Description Schema
200 OK Success PhaDefinition
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a List of PHA Sections

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/sections', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/sections \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
      "name": "Nutrition",
      "description": "The nutritional assessment is an evaluation of dietary intake and nutrition status to identify the presence of malnutrition, obesity, and so on.",
      "position": 1,
      "code": {
        "system": "urn:ietf:rfc:3986",
        "code": "2-16-840-1-113883-6-1",
        "display": "Personal Health Assessment"
      }
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/sections?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/sections?offset=0&limit=20"
}

GET /pha-definitions/{phaDefinitionId}/sections

Retrieves a list of all the available sections of a PHA definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -

Response Statuses

Status Meaning Description Schema
200 OK Success PhaSections
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError

Create a PHA Section

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/sections', headers: headers, body: {"name":"Nutrition","description":"The nutritional assessment is an evaluation of dietary intake and nutrition status to identify the presence of malnutrition, obesity, and so on.","position":1,"code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/sections \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Nutrition","description":"The nutritional assessment is an evaluation of dietary intake and nutrition status to identify the presence of malnutrition, obesity, and so on.","position":1,"code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"}}

Example response

{
  "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
  "name": "Nutrition",
  "description": "The nutritional assessment is an evaluation of dietary intake and nutrition status to identify the presence of malnutrition, obesity, and so on.",
  "position": 1,
  "code": {
    "system": "urn:ietf:rfc:3986",
    "code": "2-16-840-1-113883-6-1",
    "display": "Personal Health Assessment"
  }
}

POST /pha-definitions/{phaDefinitionId}/sections

Creates a new PHA section for a PHA definition. A PHA section is a structured group that contains subsections and questions for a PHA.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
body body postPhaDefinitionsPhadefinitionidSections true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created PhaSection
400 Bad Request Bad Request. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- PositionNotUnique A section already exists for the specified position.
BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Delete a PHA Section

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.delete('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/sections/9a7be7c8-5c65-11e9-8647-d663bd873d93', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/sections/9a7be7c8-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /pha-definitions/{phaDefinitionId}/sections/{sectionId}

Deletes a PHA section for a PHA definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
sectionId path string true N/A The ID of the PHA section. -

Response Statuses

Status Meaning Description Schema
204 No Content Deleted None
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Update a PHA Section

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.put('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/sections/9a7be7c8-5c65-11e9-8647-d663bd873d93', headers: headers, body: {"name":"Nutrition","description":"The nutritional assessment is an evaluation of dietary intake and nutrition status to identify the presence of malnutrition, obesity, and so on.","position":1,"code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/sections/9a7be7c8-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Nutrition","description":"The nutritional assessment is an evaluation of dietary intake and nutrition status to identify the presence of malnutrition, obesity, and so on.","position":1,"code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"}}

PUT /pha-definitions/{phaDefinitionId}/sections/{sectionId}

Updates a PHA section for a PHA definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
sectionId path string true N/A The ID of the PHA section. -
body body putPhaDefinitionsPhadefinitionidSections true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated None
400 Bad Request Bad Request. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- PositionNotUnique A section already exists for the specified position.
BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a Single PHA Section

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/sections/9a7be7c8-5c65-11e9-8647-d663bd873d93', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/sections/9a7be7c8-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
  "name": "Nutrition",
  "description": "The nutritional assessment is an evaluation of dietary intake and nutrition status to identify the presence of malnutrition, obesity, and so on.",
  "position": 1,
  "code": {
    "system": "urn:ietf:rfc:3986",
    "code": "2-16-840-1-113883-6-1",
    "display": "Personal Health Assessment"
  }
}

GET /pha-definitions/{phaDefinitionId}/sections/{sectionId}

Retrieves a single PHA section of a PHA definition for a HealtheIntent tenant.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
sectionId path string true N/A The ID of the PHA section. -

Response Statuses

Status Meaning Description Schema
200 OK Success PhaSection
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a List of PHA Subsections

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/subsections', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/subsections \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "9a7be7c8-5c65-11e9-8647-d663bd873d93",
      "name": "Nutrition-Fats",
      "description": "Nutrition-Fats is the subset of nutrition questions that evaluates fats in the diet of *HealtheIntent* consumers.",
      "position": 1,
      "code": {
        "system": "urn:ietf:rfc:3986",
        "code": "2-16-840-1-113883-6-1",
        "display": "Personal Health Assessment"
      },
      "section": {
        "id": "12345678-120b-4c1e-81e4-3d3ae9c7580e"
      }
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/subsections?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/subsections?offset=0&limit=20"
}

GET /pha-definitions/{phaDefinitionId}/subsections

Retrieves a list of all the available subsections for a PHA definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -

Response Statuses

Status Meaning Description Schema
200 OK Success PhaSubsections
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError

Create a PHA Subsection

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/subsections', headers: headers, body: {"name":"Nutrition-Fats","description":"Nutrition-Fats is the subset of nutrition questions that evaluates fats in the diet of *HealtheIntent* consumers.","position":1,"code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"},"section":{"id":"12345678-120b-4c1e-81e4-3d3ae9c7580e"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/subsections \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Nutrition-Fats","description":"Nutrition-Fats is the subset of nutrition questions that evaluates fats in the diet of *HealtheIntent* consumers.","position":1,"code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"},"section":{"id":"12345678-120b-4c1e-81e4-3d3ae9c7580e"}}

Example response

{
  "id": "9a7be7c8-5c65-11e9-8647-d663bd873d93",
  "name": "Nutrition-Fats",
  "description": "Nutrition-Fats is the subset of nutrition questions that evaluates fats in the diet of *HealtheIntent* consumers.",
  "position": 1,
  "code": {
    "system": "urn:ietf:rfc:3986",
    "code": "2-16-840-1-113883-6-1",
    "display": "Personal Health Assessment"
  },
  "section": {
    "id": "12345678-120b-4c1e-81e4-3d3ae9c7580e"
  }
}

POST /pha-definitions/{phaDefinitionId}/subsections

Creates a new PHA subsection for a PHA definition. A PHA subsection is a structured subgroup in a PHA section that contains questions for a PHA.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
body body postPhaDefinitionsPhadefinitionidSubsections true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created PhaSubsection
400 Bad Request Bad Request. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- SectionNotFound The PHA section specified for the subsection does not exist.
- PositionNotUnique A section already exists for the specified position.
BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Delete a PHA Subsection

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.delete('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/subsections/ace20324-a0b9-11e8-98d0-529269fb1459', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/subsections/ace20324-a0b9-11e8-98d0-529269fb1459 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /pha-definitions/{phaDefinitionId}/subsections/{subsectionId}

Deletes a PHA subsection for a PHA definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
subsectionId path string true N/A The ID of the PHA subsection. -

Response Statuses

Status Meaning Description Schema
204 No Content Deleted None
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Update a PHA Subsection

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.put('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/subsections/ace20324-a0b9-11e8-98d0-529269fb1459', headers: headers, body: {"name":"Nutrition-Fats","description":"Nutrition-Fats is the subset of nutrition questions that evaluates fats in the diet of *HealtheIntent* consumers.","position":1,"code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"},"section":{"id":"12345678-120b-4c1e-81e4-3d3ae9c7580e"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/subsections/ace20324-a0b9-11e8-98d0-529269fb1459 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Nutrition-Fats","description":"Nutrition-Fats is the subset of nutrition questions that evaluates fats in the diet of *HealtheIntent* consumers.","position":1,"code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"},"section":{"id":"12345678-120b-4c1e-81e4-3d3ae9c7580e"}}

PUT /pha-definitions/{phaDefinitionId}/subsections/{subsectionId}

Updates a PHA subsection for a PHA definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
subsectionId path string true N/A The ID of the PHA subsection. -
body body putPhaDefinitionsPhadefinitionidSubsections true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated None
400 Bad Request Bad Request. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- SectionNotFound The PHA section specified for the subsection does not exist.
- PositionNotUnique A section already exists for the specified position.
BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a Single PHA Subsection

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/subsections/ace20324-a0b9-11e8-98d0-529269fb1459', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/subsections/ace20324-a0b9-11e8-98d0-529269fb1459 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "9a7be7c8-5c65-11e9-8647-d663bd873d93",
  "name": "Nutrition-Fats",
  "description": "Nutrition-Fats is the subset of nutrition questions that evaluates fats in the diet of *HealtheIntent* consumers.",
  "position": 1,
  "code": {
    "system": "urn:ietf:rfc:3986",
    "code": "2-16-840-1-113883-6-1",
    "display": "Personal Health Assessment"
  },
  "section": {
    "id": "12345678-120b-4c1e-81e4-3d3ae9c7580e"
  }
}

GET /pha-definitions/{phaDefinitionId}/subsections/{subsectionId}

Retrieves a single PHA subsection for a PHA definition.

Parameters

Parameter In Type Required Default Description Accepted Values
subsectionId path string true N/A The ID of the PHA subsection. -
phaDefinitionId path string true N/A The ID of the PHA definition. -

Response Statuses

Status Meaning Description Schema
200 OK Success PhaSubsection
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a List of PHA Questions

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/questions', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/questions \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
      "text": "How many times do you eat junk food in a week?",
      "type": "RANGE",
      "description": "Junk food is food that is highly processed; high in calories, sugars, salt, and trans fat; and low in nutrients.",
      "acceptsMultipleAnswers": true,
      "required": true,
      "position": 1,
      "section": {
        "id": "12345678-120b-4c1e-81e4-3d3ae9c7580e"
      },
      "subsection": {
        "id": "9a7be4e4-5c65-11e9-8647-d663bd873d93"
      },
      "code": {
        "system": "urn:ietf:rfc:3986",
        "code": "2-16-840-1-113883-6-1",
        "display": "Personal Health Assessment"
      },
      "options": [
        {
          "id": "bce10324-a0b9-11e8-98d0-529269fb1459",
          "choice": {
            "points": 5,
            "text": "Between 1 and 25"
          },
          "range": {
            "low": 1,
            "high": 7,
            "text": "Number of days in a week."
          }
        }
      ]
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/questions?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/questions?offset=0&limit=20"
}

GET /pha-definitions/{phaDefinitionId}/questions

Retrieves a list of all of the available questions.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -

Response Statuses

Status Meaning Description Schema
200 OK Success PhaQuestions
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError

Create a PHA Question

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/questions', headers: headers, body: {"text":"How many times do you eat junk food in a week?","type":"RANGE","description":"Junk food is food that is highly processed; high in calories, sugars, salt, and trans fat; and low in nutrients.","acceptsMultipleAnswers":true,"required":true,"position":1,"section":{"id":"12345678-120b-4c1e-81e4-3d3ae9c7580e"},"subsection":{"id":"9a7be4e4-5c65-11e9-8647-d663bd873d93"},"code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"},"options":[{"choice":{"points":5,"text":"Between 1 and 25"},"range":{"low":1,"high":7,"text":"Number of days in a week."}}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/questions \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"text":"How many times do you eat junk food in a week?","type":"RANGE","description":"Junk food is food that is highly processed; high in calories, sugars, salt, and trans fat; and low in nutrients.","acceptsMultipleAnswers":true,"required":true,"position":1,"section":{"id":"12345678-120b-4c1e-81e4-3d3ae9c7580e"},"subsection":{"id":"9a7be4e4-5c65-11e9-8647-d663bd873d93"},"code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"},"options":[{"choice":{"points":5,"text":"Between 1 and 25"},"range":{"low":1,"high":7,"text":"Number of days in a week."}}]}

Example response

{
  "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
  "text": "How many times do you eat junk food in a week?",
  "type": "RANGE",
  "description": "Junk food is food that is highly processed; high in calories, sugars, salt, and trans fat; and low in nutrients.",
  "acceptsMultipleAnswers": true,
  "required": true,
  "position": 1,
  "section": {
    "id": "12345678-120b-4c1e-81e4-3d3ae9c7580e"
  },
  "subsection": {
    "id": "9a7be4e4-5c65-11e9-8647-d663bd873d93"
  },
  "code": {
    "system": "urn:ietf:rfc:3986",
    "code": "2-16-840-1-113883-6-1",
    "display": "Personal Health Assessment"
  },
  "options": [
    {
      "id": "bce10324-a0b9-11e8-98d0-529269fb1459",
      "choice": {
        "points": 5,
        "text": "Between 1 and 25"
      },
      "range": {
        "low": 1,
        "high": 7,
        "text": "Number of days in a week."
      }
    }
  ]
}

POST /pha-definitions/{phaDefinitionId}/questions

Creates a new PHA question. A PHA question defines the information necessary to guide the collection of answers from a HealtheIntent consumer about their health and wellness habits.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
body body postPhaDefinitionsPhadefinitionidQuestions true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created PhaQuestion
400 Bad Request Bad Request. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- SectionNotFound The PHA section specified for the question does not exist.
- SubsectionNotFound The PHA subsection specified for the question does not exist.
- PositionNotUnique A question already exists for the specified position.
- MissingOption An option was not specified for a range, choice, or open choice question.
- InvalidOptionType The type of option (choice or range) is not valid for the specified type of question.
BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Delete a PHA Question

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.delete('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/questions/ace20324-a0b9-11e8-98d0-529269fb1459', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/questions/ace20324-a0b9-11e8-98d0-529269fb1459 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /pha-definitions/{phaDefinitionId}/questions/{questionId}

Deletes a PHA question.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
questionId path string true N/A The ID of the PHA question. -

Response Statuses

Status Meaning Description Schema
204 No Content Deleted None
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Update a PHA Question

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.put('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/questions/ace20324-a0b9-11e8-98d0-529269fb1459', headers: headers, body: {"text":"How many times do you eat junk food in a week?","type":"RANGE","description":"Junk food is food that is highly processed; high in calories, sugars, salt, and trans fat; and low in nutrients.","acceptsMultipleAnswers":true,"required":true,"position":1,"section":{"id":"12345678-120b-4c1e-81e4-3d3ae9c7580e"},"subsection":{"id":"9a7be4e4-5c65-11e9-8647-d663bd873d93"},"code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"},"options":[{"choice":{"points":5,"text":"Between 1 and 25"},"range":{"low":1,"high":7,"text":"Number of days in a week."}}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/questions/ace20324-a0b9-11e8-98d0-529269fb1459 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"text":"How many times do you eat junk food in a week?","type":"RANGE","description":"Junk food is food that is highly processed; high in calories, sugars, salt, and trans fat; and low in nutrients.","acceptsMultipleAnswers":true,"required":true,"position":1,"section":{"id":"12345678-120b-4c1e-81e4-3d3ae9c7580e"},"subsection":{"id":"9a7be4e4-5c65-11e9-8647-d663bd873d93"},"code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"Personal Health Assessment"},"options":[{"choice":{"points":5,"text":"Between 1 and 25"},"range":{"low":1,"high":7,"text":"Number of days in a week."}}]}

PUT /pha-definitions/{phaDefinitionId}/questions/{questionId}

Updates a PHA question.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
questionId path string true N/A The ID of the PHA question. -
body body putPhaDefinitionsPhadefinitionidQuestions true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated None
400 Bad Request Bad Request. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- SectionNotFound The PHA section specified for the question does not exist.
- SubsectionNotFound The PHA subsection specified for the question does not exist.
- PositionNotUnique A question already exists for the specified position.
- MissingOption An option was not specified for a range, choice, or open choice question.
- InvalidOptionType The type of option (choice or range) is not valid for the specified type of question.
BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a Single PHA Question

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/questions/ace20324-a0b9-11e8-98d0-529269fb1459', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/questions/ace20324-a0b9-11e8-98d0-529269fb1459 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
  "text": "How many times do you eat junk food in a week?",
  "type": "RANGE",
  "description": "Junk food is food that is highly processed; high in calories, sugars, salt, and trans fat; and low in nutrients.",
  "acceptsMultipleAnswers": true,
  "required": true,
  "position": 1,
  "section": {
    "id": "12345678-120b-4c1e-81e4-3d3ae9c7580e"
  },
  "subsection": {
    "id": "9a7be4e4-5c65-11e9-8647-d663bd873d93"
  },
  "code": {
    "system": "urn:ietf:rfc:3986",
    "code": "2-16-840-1-113883-6-1",
    "display": "Personal Health Assessment"
  },
  "options": [
    {
      "id": "bce10324-a0b9-11e8-98d0-529269fb1459",
      "choice": {
        "points": 5,
        "text": "Between 1 and 25"
      },
      "range": {
        "low": 1,
        "high": 7,
        "text": "Number of days in a week."
      }
    }
  ]
}

GET /pha-definitions/{phaDefinitionId}/questions/{questionId}

Retrieves a single PHA question.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
questionId path string true N/A The ID of the PHA question. -

Response Statuses

Status Meaning Description Schema
200 OK Success PhaQuestion
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a List of PHA Rules

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/rules', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/rules \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "11120324-a0b9-11e8-98d0-529269fb1459",
      "relation": "AND",
      "conditions": [
        {
          "question": {
            "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
          },
          "type": "ONE_OF",
          "values": [
            {
              "option": {
                "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
              },
              "operator": "GT",
              "value": 12
            }
          ]
        }
      ],
      "action": {
        "questions": [
          {
            "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
          }
        ]
      }
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/rules?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/rules?offset=0&limit=20"
}

GET /pha-definitions/{phaDefinitionId}/rules

Retrieves a list of all the available rules for a PHA definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -

Response Statuses

Status Meaning Description Schema
200 OK Success PhaRules
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError

Create a PHA Rule

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/rules', headers: headers, body: {"relation":"AND","conditions":[{"question":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"type":"ONE_OF","values":[{"option":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"operator":"GT","value":12}]}],"action":{"questions":[{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"}]}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/rules \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"relation":"AND","conditions":[{"question":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"type":"ONE_OF","values":[{"option":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"operator":"GT","value":12}]}],"action":{"questions":[{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"}]}}

Example response

{
  "id": "11120324-a0b9-11e8-98d0-529269fb1459",
  "relation": "AND",
  "conditions": [
    {
      "question": {
        "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
      },
      "type": "ONE_OF",
      "values": [
        {
          "option": {
            "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
          },
          "operator": "GT",
          "value": 12
        }
      ]
    }
  ],
  "action": {
    "questions": [
      {
        "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
      }
    ]
  }
}

POST /pha-definitions/{phaDefinitionId}/rules

Creates a new rule for a PHA definition. A rule defines the logic used to customize and control the behavior of a PHA such as displaying or not displaying questions based on a respondent’s answers.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
body body postPhaDefinitionsPhadefinitionidRules true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created PhaRule
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError

Delete a PHA Rule

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.delete('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/rules/11120324-a0b9-11e8-98d0-529269fb1459', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/rules/11120324-a0b9-11e8-98d0-529269fb1459 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /pha-definitions/{phaDefinitionId}/rules/{ruleId}

Deletes a PHA rule for a PHA definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
ruleId path string true N/A The ID of the PHA rule. -

Response Statuses

Status Meaning Description Schema
204 No Content Deleted None
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Update a PHA Rule

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.put('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/rules/11120324-a0b9-11e8-98d0-529269fb1459', headers: headers, body: {"relation":"AND","conditions":[{"question":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"type":"ONE_OF","values":[{"option":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"operator":"GT","value":12}]}],"action":{"questions":[{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"}]}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/rules/11120324-a0b9-11e8-98d0-529269fb1459 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"relation":"AND","conditions":[{"question":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"type":"ONE_OF","values":[{"option":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"operator":"GT","value":12}]}],"action":{"questions":[{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"}]}}

PUT /pha-definitions/{phaDefinitionId}/rules/{ruleId}

Updates a PHA rule for a PHA definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
ruleId path string true N/A The ID of the PHA rule. -
body body putPhaDefinitionsPhadefinitionidRules true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated None
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a Single PHA Rule

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/rules/11120324-a0b9-11e8-98d0-529269fb1459', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/rules/11120324-a0b9-11e8-98d0-529269fb1459 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "11120324-a0b9-11e8-98d0-529269fb1459",
  "relation": "AND",
  "conditions": [
    {
      "question": {
        "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
      },
      "type": "ONE_OF",
      "values": [
        {
          "option": {
            "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
          },
          "operator": "GT",
          "value": 12
        }
      ]
    }
  ],
  "action": {
    "questions": [
      {
        "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
      }
    ]
  }
}

GET /pha-definitions/{phaDefinitionId}/rules/{ruleId}

Retrieves a single PHA rule for a PHA definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaDefinitionId path string true N/A The ID of the PHA definition. -
ruleId path string true N/A The ID of the PHA rule. -

Response Statuses

Status Meaning Description Schema
200 OK Success PhaRule
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Create a Published Personal Health Assessment

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/published-personal-health-assessments', headers: headers, body: {"phaDefinition":{"id":"e61dd2fa-702d-11e9-a923-1681be663d3e"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/published-personal-health-assessments \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"phaDefinition":{"id":"e61dd2fa-702d-11e9-a923-1681be663d3e"}}

Example response

{
  "id": "ace20324-a0b9-11e8-98d0-529269fb1459"
}

POST /published-personal-health-assessments

Creates a new published personal health assessment. A published personal health assessment is a health assessment that is ready to be used in a production environment.

Parameters

Parameter In Type Required Default Description Accepted Values
body body postPublishedPersonalHealthAssessments true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created PublishedPersonalHealthAssessment
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError

Retrieve a Single Published Personal Health Assessment

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/published-personal-health-assessments/69c7f20d-a568-4bfd-ae0b-4475e0e2dd7f', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/published-personal-health-assessments/69c7f20d-a568-4bfd-ae0b-4475e0e2dd7f \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
  "phaDefinition": {
    "id": "e61dd2fa-702d-11e9-a923-1681be663d3e",
    "phaId": "ace20324-a0b9-11e8-98d0-529269fb1459",
    "name": "Cerner Demo Personal Health Assessment 2019",
    "locale": "en-US",
    "description": "Cerner Demo Personal Health Assessment 2019 is a wellness assessment to evaluate the overall physical and mental health of a person.",
    "code": {
      "system": "urn:ietf:rfc:3986",
      "code": "2-16-840-1-113883-6-1",
      "display": "Personal Health Assessment"
    },
    "sections": [
      {
        "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
        "name": "Nutrition",
        "description": "The nutritional assessment is an evaluation of dietary intake and nutrition status to identify the presence of malnutrition, obesity, and so on.",
        "position": 1,
        "code": {
          "system": "urn:ietf:rfc:3986",
          "code": "2-16-840-1-113883-6-1",
          "display": "Personal Health Assessment"
        },
        "questions": [
          {
            "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
            "text": "How many times do you eat junk food in a week?",
            "type": "RANGE",
            "description": "Junk food is food that is highly processed; high in calories, sugars, salt, and trans fat; and low in nutrients.",
            "acceptsMultipleAnswers": true,
            "required": true,
            "position": 1,
            "section": {
              "id": "12345678-120b-4c1e-81e4-3d3ae9c7580e"
            },
            "subsection": {
              "id": "9a7be4e4-5c65-11e9-8647-d663bd873d93"
            },
            "code": {
              "system": "urn:ietf:rfc:3986",
              "code": "2-16-840-1-113883-6-1",
              "display": "Personal Health Assessment"
            },
            "options": [
              {
                "id": "bce10324-a0b9-11e8-98d0-529269fb1459",
                "choice": {
                  "points": 5,
                  "text": "Between 1 and 25"
                },
                "range": {
                  "low": 1,
                  "high": 7,
                  "text": "Number of days in a week."
                }
              }
            ],
            "rule": {
              "id": "11120324-a0b9-11e8-98d0-529269fb1459",
              "relation": "AND",
              "conditions": [
                {
                  "question": {
                    "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
                  },
                  "type": "ONE_OF",
                  "values": [
                    {
                      "option": {
                        "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
                      },
                      "operator": "GT",
                      "value": 12
                    }
                  ]
                }
              ]
            }
          }
        ],
        "subsections": [
          {
            "id": "9a7be7c8-5c65-11e9-8647-d663bd873d93",
            "name": "Nutrition-Fats",
            "description": "Nutrition-Fats is the subset of nutrition questions that evaluates fats in the diet of *HealtheIntent* consumers.",
            "position": 1,
            "code": {
              "system": "urn:ietf:rfc:3986",
              "code": "2-16-840-1-113883-6-1",
              "display": "Personal Health Assessment"
            },
            "section": {
              "id": "12345678-120b-4c1e-81e4-3d3ae9c7580e"
            },
            "questions": [
              {
                "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
                "text": "How many times do you eat junk food in a week?",
                "type": "RANGE",
                "description": "Junk food is food that is highly processed; high in calories, sugars, salt, and trans fat; and low in nutrients.",
                "acceptsMultipleAnswers": true,
                "required": true,
                "position": 1,
                "section": {
                  "id": "12345678-120b-4c1e-81e4-3d3ae9c7580e"
                },
                "subsection": {
                  "id": "9a7be4e4-5c65-11e9-8647-d663bd873d93"
                },
                "code": {
                  "system": "urn:ietf:rfc:3986",
                  "code": "2-16-840-1-113883-6-1",
                  "display": "Personal Health Assessment"
                },
                "options": [
                  {
                    "id": "bce10324-a0b9-11e8-98d0-529269fb1459",
                    "choice": {
                      "points": 5,
                      "text": "Between 1 and 25"
                    },
                    "range": {
                      "low": 1,
                      "high": 7,
                      "text": "Number of days in a week."
                    }
                  }
                ],
                "rule": {
                  "id": "11120324-a0b9-11e8-98d0-529269fb1459",
                  "relation": "AND",
                  "conditions": [
                    {
                      "question": {
                        "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
                      },
                      "type": "ONE_OF",
                      "values": [
                        {
                          "option": {
                            "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
                          },
                          "operator": "GT",
                          "value": 12
                        }
                      ]
                    }
                  ]
                }
              }
            ]
          }
        ]
      }
    ]
  }
}

GET /published-personal-health-assessments/{publishedPersonalHealthAssessmentId}

Retrieves a single published personal health assessment.

Parameters

Parameter In Type Required Default Description Accepted Values
publishedPersonalHealthAssessmentId path string true N/A The ID of the published PHA. -

Response Statuses

Status Meaning Description Schema
200 OK Success PublishedPersonalHealthAssessment
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a List of PHA Response Definitions

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "e3e44e50-5c65-11e9-8647-d663bd873d93",
      "authoredAt": "2018-07-16T19:20:00+01:00",
      "publishedPhaDefinition": {
        "id": "6091627d-b20b-4c1e-81e4-3d3ae9c7580e",
        "name": "Cerner Demo Personal Health Assessment 2019"
      },
      "consumer": {
        "id": "08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"
      },
      "completedPhaResponses": [
        {
          "id": "cf98baee-c461-11e9-aa8c-2a2ae2dbcce4",
          "authoredAt": "2018-07-16T19:20:00+01:00"
        }
      ]
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions?offset=0&limit=20"
}

GET /pha-response-definitions

Retrieves a list of all the available PHA Response Definitions.

Parameters

Parameter In Type Required Default Description Accepted Values
phaId query string false N/A Filters by the ID of a PHA. -
phaDefinitionId query string false N/A Filters by the ID of a PHA definition. -
consumerId query string false N/A Filters by the ID of a HealtheIntent consumer. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -

Response Statuses

Status Meaning Description Schema
200 OK Success. PhaResponseDefinitions
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError

Create a PHA Response Definition

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions', headers: headers, body: {"authoredAt":"2018-07-16T19:20:00+01:00","consumer":{"id":"08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"},"phaDefinition":{"id":"6091627d-b20b-4c1e-81e4-3d3ae9c7580e","name":"Cerner Demo Personal Health Assessment 2019"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"authoredAt":"2018-07-16T19:20:00+01:00","consumer":{"id":"08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"},"phaDefinition":{"id":"6091627d-b20b-4c1e-81e4-3d3ae9c7580e","name":"Cerner Demo Personal Health Assessment 2019"}}

Example response

{
  "id": "e3e44e50-5c65-11e9-8647-d663bd873d93",
  "authoredAt": "2018-07-16T19:20:00+01:00",
  "publishedPhaDefinition": {
    "id": "6091627d-b20b-4c1e-81e4-3d3ae9c7580e",
    "name": "Cerner Demo Personal Health Assessment 2019"
  },
  "consumer": {
    "id": "08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"
  },
  "completedPhaResponses": [
    {
      "id": "cf98baee-c461-11e9-aa8c-2a2ae2dbcce4",
      "authoredAt": "2018-07-16T19:20:00+01:00"
    }
  ]
}

POST /pha-response-definitions

Creates a new PHA response definition. A PHA response is a set of answers given by a HealtheIntent consumer to the questions presented in a PHA. Use this endpoint the first time a consumer starts a new published PHA.

Parameters

Parameter In Type Required Default Description Accepted Values
body body postPhaResponseDefinitions true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created PhaResponseDefinition
400 Bad Request Bad Request. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- PhaDefinitionNotFound The PHA definition specified for the response does not exist.
BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError

Delete a PHA Response Definition

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.delete('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /pha-response-definitions/{phaResponseDefinitionId}

Deletes a PHA response definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaResponseDefinitionId path integer(int32) true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Deleted None
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Update a PHA Response Definition

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.put('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93', headers: headers, body: {"authoredAt":"2018-07-16T19:20:00+01:00","consumer":{"id":"08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"},"phaDefinition":{"id":"6091627d-b20b-4c1e-81e4-3d3ae9c7580e","name":"Cerner Demo Personal Health Assessment 2019"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"authoredAt":"2018-07-16T19:20:00+01:00","consumer":{"id":"08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"},"phaDefinition":{"id":"6091627d-b20b-4c1e-81e4-3d3ae9c7580e","name":"Cerner Demo Personal Health Assessment 2019"}}

PUT /pha-response-definitions/{phaResponseDefinitionId}

Updates a PHA response definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaResponseDefinitionId path string true N/A The ID of the PHA response definition. -
body body putPhaResponseDefinitions true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated None
400 Bad Request Bad Request. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- PhaDefinitionNotFound The PHA definition specified for the response does not exist.
BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a Single PHA Response Definition

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "e3e44e50-5c65-11e9-8647-d663bd873d93",
  "authoredAt": "2018-07-16T19:20:00+01:00",
  "publishedPhaDefinition": {
    "id": "6091627d-b20b-4c1e-81e4-3d3ae9c7580e",
    "name": "Cerner Demo Personal Health Assessment 2019"
  },
  "consumer": {
    "id": "08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"
  },
  "completedPhaResponses": [
    {
      "id": "cf98baee-c461-11e9-aa8c-2a2ae2dbcce4",
      "authoredAt": "2018-07-16T19:20:00+01:00"
    }
  ]
}

GET /pha-response-definitions/{phaResponseDefinitionId}

Retrieves a single PHA response definition.

Parameters

Parameter In Type Required Default Description Accepted Values
phaResponseDefinitionId path string true N/A The ID of the PHA response definition. -

Response Statuses

Status Meaning Description Schema
200 OK Success PhaResponseDefinition
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a List of PHA Response Sections

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-sections', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-sections \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "9a7bdd28-5c65-11e9-8647-d663bd873d93",
      "section": {
        "id": "12345678-120b-4c1e-81e4-3d3ae9c7580e"
      },
      "status": "COMPLETED",
      "answers": [
        {
          "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
          "question": {
            "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
          },
          "values": [
            {
              "option": {
                "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
              },
              "value": "3"
            }
          ]
        }
      ]
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-sections?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-sections?offset=0&limit=20"
}

GET /pha-response-definitions/{phaResponseDefinitionId}/response-sections

Retrieves a list of all of the available PHA response sections.

Parameters

Parameter In Type Required Default Description Accepted Values
phaResponseDefinitionId path string true N/A The ID of the PHA response definition. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -

Response Statuses

Status Meaning Description Schema
200 OK Success PhaResponseSections
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError

Create a PHA Response Section

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-sections', headers: headers, body: {"status":"COMPLETED","section":{"id":"12345678-120b-4c1e-81e4-3d3ae9c7580e"},"answers":[{"id":"ace20324-a0b9-11e8-98d0-529269fb1459","question":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"values":[{"option":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"value":"3"}]}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-sections \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"status":"COMPLETED","section":{"id":"12345678-120b-4c1e-81e4-3d3ae9c7580e"},"answers":[{"id":"ace20324-a0b9-11e8-98d0-529269fb1459","question":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"values":[{"option":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"value":"3"}]}]}

Example response

{
  "id": "9a7bdd28-5c65-11e9-8647-d663bd873d93",
  "section": {
    "id": "12345678-120b-4c1e-81e4-3d3ae9c7580e"
  },
  "status": "COMPLETED",
  "answers": [
    {
      "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
      "question": {
        "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
      },
      "values": [
        {
          "option": {
            "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
          },
          "value": "3"
        }
      ]
    }
  ]
}

POST /pha-response-definitions/{phaResponseDefinitionId}/response-sections

Creates a new PHA response section for a PHA response. A PHA response section is a structured group that contains answers to questions in a particular section of a PHA.

Parameters

Parameter In Type Required Default Description Accepted Values
phaResponseDefinitionId path string true N/A The ID of the PHA response definition. -
body body postPhaResponseDefinitionsPharesponsedefinitionidResponseSections true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created PhaResponseSection
400 Bad Request Bad Request. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- PhaSectionNotFound The PHA section specified for the response section does not exist.
- PhaQuestionNotFound The PHA question specified for the answer does not exist in the section.
- OptionNotFound The option specified in the answer does not exist.
- InvalidValue The value specified in the answer is not valid for the type of the question.
- ValueNotInRange The value specified in the answer is not within the range specified by the question.
BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Delete a PHA Response Section

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.delete('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-sections/9a7bdd28-5c65-11e9-8647-d663bd873d93', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-sections/9a7bdd28-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /pha-response-definitions/{phaResponseDefinitionId}/response-sections/{responseSectionId}

Deletes a PHA response section for a PHA response.

Parameters

Parameter In Type Required Default Description Accepted Values
phaResponseDefinitionId path integer(int32) true N/A No description -
responseSectionId path integer(int32) true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Deleted None
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Update a PHA Response Section

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.put('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-sections/9a7bdd28-5c65-11e9-8647-d663bd873d93', headers: headers, body: {"status":"COMPLETED","section":{"id":"12345678-120b-4c1e-81e4-3d3ae9c7580e"},"answers":[{"id":"ace20324-a0b9-11e8-98d0-529269fb1459","question":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"values":[{"option":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"value":"3"}]}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-sections/9a7bdd28-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"status":"COMPLETED","section":{"id":"12345678-120b-4c1e-81e4-3d3ae9c7580e"},"answers":[{"id":"ace20324-a0b9-11e8-98d0-529269fb1459","question":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"values":[{"option":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"value":"3"}]}]}

PUT /pha-response-definitions/{phaResponseDefinitionId}/response-sections/{responseSectionId}

Updates a PHA response section for a PHA response.

Parameters

Parameter In Type Required Default Description Accepted Values
phaResponseDefinitionId path string true N/A The ID of the PHA response definition. -
responseSectionId path string true N/A The ID of the PHA response section. -
body body putPhaResponseDefinitionsPharesponsedefinitionidResponseSections true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated None
400 Bad Request Bad Request. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- PhaSectionNotFound The PHA section specified for the response section does not exist.
- PhaQuestionNotFound The PHA question specified for the answer does not exist in the section.
- OptionNotFound The option specified in the answer does not exist.
- InvalidValue The value specified in the answer is not valid for the type of the question.
- ValueNotInRange The value specified in the answer is not within the range specified by the question.
BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a Single PHA Response Section

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-sections/9a7bdd28-5c65-11e9-8647-d663bd873d93', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-sections/9a7bdd28-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "9a7bdd28-5c65-11e9-8647-d663bd873d93",
  "section": {
    "id": "12345678-120b-4c1e-81e4-3d3ae9c7580e"
  },
  "status": "COMPLETED",
  "answers": [
    {
      "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
      "question": {
        "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
      },
      "values": [
        {
          "option": {
            "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
          },
          "value": "3"
        }
      ]
    }
  ]
}

GET /pha-response-definitions/{phaResponseDefinitionId}/response-sections/{responseSectionId}

Retrieves a single PHA response section for a PHA response.

Parameters

Parameter In Type Required Default Description Accepted Values
phaResponseDefinitionId path string true N/A The ID of the PHA response definition. -
responseSectionId path string true N/A The ID of the PHA response section. -

Response Statuses

Status Meaning Description Schema
200 OK Success PhaResponseSection
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a List of PHA Response Subsections

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-subsections', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-subsections \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "9a7be688-5c65-11e9-8647-d663bd873d93",
      "status": "COMPLETED",
      "subsection": {
        "id": "9a7be4e4-5c65-11e9-8647-d663bd873d93"
      },
      "answers": [
        {
          "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
          "question": {
            "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
          },
          "values": [
            {
              "option": {
                "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
              },
              "value": "3"
            }
          ]
        }
      ]
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-subsections?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-subsections?offset=0&limit=20"
}

GET /pha-response-definitions/{phaResponseDefinitionId}/response-subsections

Retrieves a list of all the available PHA response subsections for a PHA response.

Parameters

Parameter In Type Required Default Description Accepted Values
phaResponseDefinitionId path string true N/A The ID of the PHA response definition. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -

Response Statuses

Status Meaning Description Schema
200 OK Success. PhaResponseSubsections
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError

Create a PHA Response Subsection

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-subsections', headers: headers, body: {"subsection":{"id":"9a7be4e4-5c65-11e9-8647-d663bd873d93"},"status":"COMPLETED","answers":[{"id":"ace20324-a0b9-11e8-98d0-529269fb1459","question":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"values":[{"option":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"value":"3"}]}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-subsections \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"subsection":{"id":"9a7be4e4-5c65-11e9-8647-d663bd873d93"},"status":"COMPLETED","answers":[{"id":"ace20324-a0b9-11e8-98d0-529269fb1459","question":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"values":[{"option":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"value":"3"}]}]}

Example response

{
  "id": "9a7be688-5c65-11e9-8647-d663bd873d93",
  "status": "COMPLETED",
  "subsection": {
    "id": "9a7be4e4-5c65-11e9-8647-d663bd873d93"
  },
  "answers": [
    {
      "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
      "question": {
        "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
      },
      "values": [
        {
          "option": {
            "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
          },
          "value": "3"
        }
      ]
    }
  ]
}

POST /pha-response-definitions/{phaResponseDefinitionId}/response-subsections

Creates a new PHA response subsection for a PHA response. A PHA response subsection is a structured group that contains answers to questions in a particular subsection of a PHA.

Parameters

Parameter In Type Required Default Description Accepted Values
phaResponseDefinitionId path string true N/A The ID of the PHA response definition. -
body body postPhaResponseDefinitionsPharesponsedefinitionidResponseSubsections true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created PhaResponseSubsection
400 Bad Request Bad Request. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- PhaSubsectionNotFound The PHA subsection specified for the response subsection does not exist.
- PhaQuestionNotFound The PHA question specified for the answer does not exist in the subsection.
- OptionNotFound The option specified in the answer does not exist.
- InvalidValue The value specified in the answer is not valid for the type of the question.
- ValueNotInRange The value specified in the answer is not within the range specified by the question.
BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Delete a PHA Response Subsection

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.delete('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-subsections/9a7bdd28-5c65-11e9-8647-d663bd873d93', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-subsections/9a7bdd28-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /pha-response-definitions/{phaResponseDefinitionId}/response-subsections/{responseSubsectionId}

Deletes a PHA response subsection for a PHA response.

Parameters

Parameter In Type Required Default Description Accepted Values
phaResponseDefinitionId path integer(int32) true N/A No description -
responseSubsectionId path integer(int32) true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Deleted None
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Update a PHA Response Subsection

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.put('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-subsections/9a7bdd28-5c65-11e9-8647-d663bd873d93', headers: headers, body: {"subsection":{"id":"9a7be4e4-5c65-11e9-8647-d663bd873d93"},"status":"COMPLETED","answers":[{"id":"ace20324-a0b9-11e8-98d0-529269fb1459","question":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"values":[{"option":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"value":"3"}]}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-subsections/9a7bdd28-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"subsection":{"id":"9a7be4e4-5c65-11e9-8647-d663bd873d93"},"status":"COMPLETED","answers":[{"id":"ace20324-a0b9-11e8-98d0-529269fb1459","question":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"values":[{"option":{"id":"12865678-120b-4c1e-81e4-3d3ae9c7580e"},"value":"3"}]}]}

PUT /pha-response-definitions/{phaResponseDefinitionId}/response-subsections/{responseSubsectionId}

Updates a PHA response subsection for a PHA response.

Parameters

Parameter In Type Required Default Description Accepted Values
phaResponseDefinitionId path string true N/A The ID of the PHA response definition. -
responseSubsectionId path string true N/A The ID of the PHA response subsection. -
body body putPhaResponseDefinitionsPharesponsedefinitionidResponseSubsections true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated. None
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a Single PHA Response Subsection

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-subsections/9a7bdd28-5c65-11e9-8647-d663bd873d93', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/pha-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-subsections/9a7bdd28-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "9a7be688-5c65-11e9-8647-d663bd873d93",
  "status": "COMPLETED",
  "subsection": {
    "id": "9a7be4e4-5c65-11e9-8647-d663bd873d93"
  },
  "answers": [
    {
      "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
      "question": {
        "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
      },
      "values": [
        {
          "option": {
            "id": "12865678-120b-4c1e-81e4-3d3ae9c7580e"
          },
          "value": "3"
        }
      ]
    }
  ]
}

GET /pha-response-definitions/{phaResponseDefinitionId}/response-subsections/{responseSubsectionId}

Retrieves a single PHA response subsection for a PHA response.

Parameters

Parameter In Type Required Default Description Accepted Values
phaResponseDefinitionId path string true N/A The ID of the PHA response definition. -
responseSubsectionId path string true N/A The ID of the PHA response subsection. -

Response Statuses

Status Meaning Description Schema
200 OK Success PhaResponseSubsection
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Create a Completed PHA Response

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/completed-pha-responses', headers: headers, body: {"phaResponse":{"id":"e3e44e50-5c65-11e9-8647-d663bd873d93"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/completed-pha-responses \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"phaResponse":{"id":"e3e44e50-5c65-11e9-8647-d663bd873d93"}}

Example response

{
  "id": "a364d8d2-9da5-4188-aed2-252e81b4d976",
  "phaResponseDefinition": {
    "id": "e3e44e50-5c65-11e9-8647-d663bd873d93"
  }
}

POST /completed-pha-responses

Creates a new completed PHA response. A completed PHA response is a response to a published health assessment that is marked as complete by the HealtheIntent consumer and is ready for further processing such as risk assessment and health and wellness activity assignments. Use this endpoint every time a consumer submits a PHA response.

Parameters

Parameter In Type Required Default Description Accepted Values
body body postCompletedPhaResponses true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created CompletedPhaResponse
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError

Retrieve a Single Completed PHA Response

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/completed-pha-responses/a364d8d2-9da5-4188-aed2-252e81b4d976', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/completed-pha-responses/a364d8d2-9da5-4188-aed2-252e81b4d976 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "a364d8d2-9da5-4188-aed2-252e81b4d976",
  "phaResponseDefinition": {
    "id": "e3e44e50-5c65-11e9-8647-d663bd873d93"
  }
}

GET /completed-pha-responses/{completedPhaResponseId}

Retrieves a single completed PHA response.

Parameters

Parameter In Type Required Default Description Accepted Values
completedPhaResponseId path string true N/A The ID of the completed PHA response. -

Response Statuses

Status Meaning Description Schema
200 OK Success CompletedPhaResponse
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Wellness Screening Results

Wellness screening results are a feature that includes a defined set of observations used to determine areas of risk for a wellness member.

Retrieve a List of Completion Criteria

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/screening-results-completion-criteria', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/screening-results-completion-criteria \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "da799f06-5f53-41cb-9335-4cd291b91578",
      "code": {
        "code": "2085-9",
        "system": "2.16.840.1.113883.6.1"
      }
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/screening-results-completion-criteria?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us.healtheintent.com/wellness/v1/screening-results-completion-criteria?offset=0&limit=20"
}

GET /screening-results-completion-criteria

Retrieves all of the available completion criteria for a HealtheIntent tenant.

Parameters

Parameter In Type Required Default Description Accepted Values
code query string false N/A Filters by the system and value of the code. Use URL encoding, separate the system and value with a : (%3A when URL-encoded), and use the following format: [code system]%3A[code value]. See the following example: ?code=SNOWMED%3A20034578. -
offset query integer(int32) false 0 The number of results to skip from the beginning of the list of results (typically for the purpose of paging). The minimum offset is 0. There is no maximum offset. -
limit query integer(int32) false 20 The maximum number of results to display per page. The minimum limit is 1. The maximum limit is 100. -

Response Statuses

Status Meaning Description Schema
200 OK Success. CompletionCriterions
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError

Create a Completion Criterion

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.post('https://cernerdemo.api.us.healtheintent.com/wellness/v1/screening-results-completion-criteria', headers: headers, body: {"code":{"code":"2085-9","system":"2.16.840.1.113883.6.1"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us.healtheintent.com/wellness/v1/screening-results-completion-criteria \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"code":{"code":"2085-9","system":"2.16.840.1.113883.6.1"}}

POST /screening-results-completion-criteria

Creates a screening completion criterion for a HealtheIntent tenant. The screening results completion criteria define a set of observations required for awarding incentives.

Parameters

Parameter In Type Required Default Description Accepted Values
body body postScreeningResultsCompletionCriteria true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created CompletionCriterion
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError

Delete a Completion Criterion

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.delete('https://cernerdemo.api.us.healtheintent.com/wellness/v1/screening-results-completion-criteria/ffadf1b7-b812-4eed-a769-f6a6c4c04b97', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us.healtheintent.com/wellness/v1/screening-results-completion-criteria/ffadf1b7-b812-4eed-a769-f6a6c4c04b97 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /screening-results-completion-criteria/{screeningResultsCompletionCriteriaId}

Deletes a single completion criterion for a HealtheIntent tenant.

Parameters

Parameter In Type Required Default Description Accepted Values
screeningResultsCompletionCriteriaId path string true N/A The ID of the completion criterion. -

Response Statuses

Status Meaning Description Schema
204 No Content Deleted None
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Update a Completion Criterion

Example Request:




require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Content-Type' => 'application/json',
  'Accept' => 'application/json'
} 

result = HTTParty.put('https://cernerdemo.api.us.healtheintent.com/wellness/v1/screening-results-completion-criteria/ffadf1b7-b812-4eed-a769-f6a6c4c04b97', headers: headers, body: {"code":{"code":"2085-9","system":"2.16.840.1.113883.6.1"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us.healtheintent.com/wellness/v1/screening-results-completion-criteria/ffadf1b7-b812-4eed-a769-f6a6c4c04b97 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"code":{"code":"2085-9","system":"2.16.840.1.113883.6.1"}}

PUT /screening-results-completion-criteria/{screeningResultsCompletionCriteriaId}

Updates a single completion criterion for a HealtheIntent tenant.

Parameters

Parameter In Type Required Default Description Accepted Values
screeningResultsCompletionCriteriaId path string true N/A The ID of the completion criterion. -
body body putScreeningResultsCompletionCriteria true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Success None
400 Bad Request Bad Request BadRequestError
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Retrieve a Single Completion Criterion

Example Request:


require 'httparty' # Using HTTParty 0.16.2
require 'json'

headers = {
  'Authorization' => '<auth_header>',
  'Accept' => 'application/json'
} 

result = HTTParty.get('https://cernerdemo.api.us.healtheintent.com/wellness/v1/screening-results-completion-criteria/ffadf1b7-b812-4eed-a769-f6a6c4c04b97', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us.healtheintent.com/wellness/v1/screening-results-completion-criteria/ffadf1b7-b812-4eed-a769-f6a6c4c04b97 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

GET /screening-results-completion-criteria/{screeningResultsCompletionCriteriaId}

Retrieves a single completion criterion for a HealtheIntent tenant.

Parameters

Parameter In Type Required Default Description Accepted Values
screeningResultsCompletionCriteriaId path string true N/A The ID of the completion criterion. -

Response Statuses

Status Meaning Description Schema
200 OK Success CompletionCriterion
401 Unauthorized Unauthorized UnauthorizedError
403 Forbidden Forbidden ForbiddenError
404 Not Found Not Found NotFoundError

Schema Definitions

postCampaigns

Name Type Required Description Accepted Values
names [object] true A list of campaign names for the different locales. -
» locale string true A two-letter language and two-letter region ID, for example, en-US. The locale should match the ISO 639-1 specification. See ISO 639 Language Codes on the ISO website for more information. -
» text string true The name of the campaign for the specified locale. The maximum length is 191 characters. -
descriptions [object] false A list of campaign descriptions for the different locales. -
» locale string true The locale. Locales should be defined as described on the Language Tags in HTML and XML page on the W3C website. -
» text string true The descriptions of the campaign for the specified locale. The maximum length is 191 characters. -
startsAt string true The date and time when the campaign starts, in ISO 8601 format. -
endsAt string true The date and time when the campaign ends, in ISO 8601 format. -
reward object false The reward the consumer earns when the objective is completed. -
» id string true The ID of the reward. -
completionThreshold integer(int32) false The minimum number of objectives that the consumer needs to complete to complete the category. -
adjustmentReward object false The reward that is used to make points adjustments to the category. If reward is specified, this must also be specified. -
» id string true The ID of the reward. -
timeZone string true The time zone in which this campaign is created. -
icon string false The file name of the icon. -
populations [object] false A list of populations for the campaign. -
» populationId string true The ID of the population. -
» dataPartitionId string true The ID of the data partition -

CampaignDefinition

Name Type Required Description Accepted Values
id string true The ID of the campaign. -
names [Translation] true The name of the campaign. -
descriptions [Translation] false The description of the campaign. -
categoryId string true The ID of the root category for the campaign. -
populations [Population] false The populations associated with the campaign. -
reward string false The ID of the maximum point definition for the campaign. -
adjustmentReward string false The ID of the reward that is used to make points adjustments for the campaign. -
completionThreshold integer(int32) false The completion threshold number for the campaign. -
icon string false The file name of the icon. -
startsAt string true The date and time when the campaign starts, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
endsAt string true The date and time when the campaign ends, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
timeZone string false The time zone in which this campaign is created. -
createdAt string false The date and time when the campaign was created, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
updatedAt string false The date and time when the campaign was last updated, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -

Translation

Name Type Required Description Accepted Values
locale string true The locale. -
text string true The text for the locale. -

Population

Name Type Required Description Accepted Values
populationId string true The ID of the population. -
dataPartitionId string true The ID of the data partition. -

Unauthorized

Name Type Required Description Accepted Values
code integer(int32) true The HTTP response status code that represents the error. -
message string true A human-readable description of the error. -
errorDetails [string] false A list of additional error details. -

Forbidden

Name Type Required Description Accepted Values
code integer(int32) true The HTTP response status code that represents the error. -
message string true A human-readable description of the error. -
errorDetails [string] false A list of additional error details. -

BadRequest

Name Type Required Description Accepted Values
code integer(int32) true The HTTP response status code that represents the error. -
message string true A human-readable description of the error. -
errorDetails [string] false A list of additional error details. -

CampaignDefinitions

Name Type Required Description Accepted Values
items [CampaignDefinition] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

NotFound

Name Type Required Description Accepted Values
code integer(int32) true The HTTP response status code that represents the error. -
message string true A human-readable description of the error. -
errorDetails [string] false A list of additional error details. -

patchCampaigns

Name Type Required Description Accepted Values
names [object] false A list of campaign names for the different locales. -
» locale string true The locale. Locales should be defined as described on the Language Tags in HTML and XML page on the W3C website. -
» text string true The name of the campaign for the specified locale. The maximum length is 191 characters. -
descriptions [object] false A list of campaign descriptions for the different locales. -
» locale string true The locale. Locales should be defined as described on the Language Tags in HTML and XML page on the W3C website. -
» text string true The description of the campaign for the specified locale. The maximum length is 65,535 characters. -
startsAt string false The date and time when the campaign starts, in ISO 8601 format. -
endsAt string false The date and time when the campaign ends, in ISO 8601 format. -
reward object false The reward the consumer earns when the objective is completed. -
» id string true The ID of the reward. -
adjustmentReward object false The reward that is used to make points adjustments to the category. If reward is specified, this must also be specified. -
» id string true The ID of the reward. -
completionThreshold integer(int32) false The minimum number of objectives that the consumer needs to complete to complete the category. -
timeZone string false The time zone in which this campaign is created. -
icon string false The file name of the icon. -
populations [object] false A list of populations for the campaign. -
» populationId string true The ID of the population. -
» dataPartitionId string true The ID of the data partition -

Conflict

Name Type Required Description Accepted Values
code integer(int32) true The HTTP response status code that represents the error. -
message string true A human-readable description of the error. -
errorDetails [string] false A list of additional error details. -

postCampaignsCampaignidCategories

Name Type Required Description Accepted Values
names [object] true A list of category names for the different locales. -
» locale string true A two-letter language and two-letter region ID, for example, en-US. The locale should match the ISO 639-1 specification. See ISO 639 Language Codes on the ISO website for more information. -
» text string true The name of the category for the specified locale. The maximum length is 191 characters. -
descriptions [object] false A list of category descriptions for the different locales. -
» locale string true A two-letter language and two-letter region ID, for example, en-US. The locale should match the ISO 639-1 specification. See ISO 639 Language Codes on the ISO website for more information. -
» text string true The descriptions of the category for the specified locale. The maximum length is 191 characters. -
startsAt string true The date and time when the category starts, in ISO 8601 format. -
endsAt string true The date and time when the category ends, in ISO 8601 format. -
parentCategoryId string false The ID of the parent category. Categories can be nested up to three levels. -
icon string false The URL of the file name of the icon. -
reward object false The reward for maximum point definition. -
» id string true The ID of the reward. -
completionThreshold integer(int32) false The minimum number of objectives that the consumer needs to complete to complete the category. -
adjustmentReward object false The reward that is used to make points adjustments to the category. If reward is specified, this must also be specified. -
» id string true The ID of the reward. -
objectives [object] false The array of objectives. -
» id string true The ID of the objective. -

CampaignCategory

Name Type Required Description Accepted Values
id string true The ID of the category. -
parentCategoryId string false The parent ID of the category. -
position integer(int32) false The numeric position of the category in relation to its siblings. -
names Translation true The name of the category. -
descriptions Translation true The description of the category. -
reward string false The reward for the maximum point definition for the category. -
adjustmentReward string false The reward that is used to make points adjustments for the category. -
completionThreshold integer(int32) false The completion threshold number for the category. -
icon string false The file name of the icon. -
startsAt string false The date and time when the category starts, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
endsAt string false The date and time when the category ends, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
objectives [ObjectiveId] false The list of objectives associated with the category. -
categories [CampaignCategory] false The child categories associated with the category. -
createdAt string false The date and time when the category was created, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
updatedAt string false The date and time when the category was last updated, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -

ObjectiveId

Name Type Required Description Accepted Values
position integer(int32) true The position of the objective in its associated category. -
objectiveDefinitionId string true The ID of the objective definition. -

CampaignCategories

Name Type Required Description Accepted Values
items [CampaignCategory] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

patchCampaignsCampaignidCategories

Name Type Required Description Accepted Values
names [object] false A list of category names for the different locales. -
» locale string true A two-letter language and two-letter region ID, for example, en-US. The locale should match the ISO 639-1 specification. See ISO 639 Language Codes on the ISO website for more information. -
» text string true The name of the category for the specified locale. The maximum length is 191 characters. -
descriptions [object] false A list of category descriptions for the different locales. -
» locale string true A two-letter language and two-letter region ID, for example, en-US. The locale should match the ISO 639-1 specification. See ISO 639 Language Codes on the ISO website for more information. -
» text string true The descriptions of the category for the specified locale. The maximum length is 191 characters. -
startsAt string false The date and time when the category starts, in ISO 8601 format. -
endsAt string false The date and time when the category ends, in ISO 8601 format. -
parentCategoryId string false The ID of the parent category. Categories can be nested up to three levels. -
position integer(int32) false The numeric position of the category in relation to its siblings. -
icon string false The URL of file name of the icon. -
reward object false The reward for maximum point definition. -
» id string true The ID of the reward. -
completionThreshold integer(int32) false The minimum number of objectives that the consumer needs to complete to complete the category. -
adjustmentReward object false The reward that is used to make points adjustments to the category. If reward is specified, this must also be specified. -
» id string true The ID of the reward. -
objectives [object] false The array of objectives. -
» id string true The ID of the objective. -

postCampaignsCampaignidCategoriesCategoryidObjectiveDefinitions

Name Type Required Description Accepted Values
titles [object] true A list of objective names for the different locales. -
» locale string true A two-letter language and two-letter region ID, for example, en-US. The locale should match the ISO 639-1 specification. See ISO 639 Language Codes on the ISO website for more information. -
» text string true The title of the objective for the specified locale. The maximum length is 191 characters. -
descriptions [object] false A list of objective descriptions for the different locales. -
» locale string true A two-letter language and two-letter region ID, for example, en-US. The locale should match the ISO 639-1 specification. See ISO 639 Language Codes on the ISO website for more information. -
» text string true The descriptions of the objective for the specified locale. The maximum length is 191 characters. -
sourceDefinition object true The source system in which the activity is defined. -
» id string false The ID of the source system -
» kind string true The type of the source system in which the activity is defined, for example, EDUCATION_MODULE or QUESTIONNAIRE. -
frequency string true How often the objective can be completed. DAILY, WEEKLY, MONTHLY, QUARTERLY, BI_ANNUALLY, ANNUALLY, ONE_TIME
isRepeatableWithinFrequency boolean true Indicates whether the objective can be completed multiple times within the objective frequency. -
requiresVerification boolean false When set to true, the objective must be verified and marked as complete by an admin or care provider. -
startsAt string true The date and time when the objective starts, in ISO 8601 format. -
endsAt string true The date and time when the objective ends, in ISO 8601 format. -
maxCompletionCount integer(int32) false The maximum number of times this objective can be completed. This can be used only for completion-based objectives. -
primaryObjectiveId string false The ID of an existing valid objective. An objective with the primaryObjectiveId attribute is an alternative objective. -
sources [string] false The sources permitted to meet an objective. If this is not specified, all sources are permitted. SPECIFIC_PROVIDER, CLAIM, SELF_ENTERED, APP_DEVICE, COACH_ENTERED, ADMINISTRATOR_UPLOADED, EMR_DW_INTEGRATION
conditions [object] false A list of conditions for the objective. -
» value string false The value for the condition. -
» operator string false The conditional operator for the objective. If the consumerConditionType is GENDER or DIABETIC, the MATCHES operator must be used. If the consumerConditionType is AGE, one of the following operators must be used: [‘>’, ‘<’, ‘<=’, ‘>=’]. -
» target string false The target range of the objective. -
» subtype string false The subtype against which the condition type is compared, for example, SYSTOLIC or DIASTOLIC. -
» consumerConditionType string false The type of conditions related to consumer. -

CreatedObjective

Name Type Required Description Accepted Values
id string true The ID of the objective. -
sourceDefinition object false The source system in which the activity is defined. -
frequency string false The frequency of the objective. DAILY, WEEKLY, MONTHLY, QUARTERLY, BI_ANNUALLY, ANNUALLY, ONE_TIME
isRepeatableWithinFrequency boolean false Indicates whether the objective can be completed multiple times within the objective frequency. -
maxCompletionCount integer(int32) false The maximum number of times the objective can be completed over the entire period of the campaign. -
primaryObjectiveId string false The ID of an existing valid objective. An objective with the primaryObjectiveId attribute is an alternative objective. -
conditions Condition false The conditions of the objective. -
sources string false The data sources that are allowed by the system. The following sources are possible:
- SPECIFIC_PROVIDER: Indicates that the data is from a service provider.
- CLAIM: Indicates that the data is from a claim.
- APP_DEVICE: Indicates that the data is from a device such as a Fitbit.
- COACH_ENTERED: Indicates that the data was entered by a health coach.
- ADMINISTRATOR_UPLOADED: Indicates that the data was entered by an administrator.
- EMR_DW_INTEGRATION: Indicates that the data is from an integrated EHR system.
SPECIFIC_PROVIDER, CLAIM, SELF_ENTERED, APP_DEVICE, COACH_ENTERED, ADMINISTRATOR_UPLOADED, EMR_DW_INTEGRATION

Condition

Name Type Required Description Accepted Values
value integer(int32) true The value of the condition. -
operator string true The conditional operator of the objective. =, >, <, <=, >=, INCREASE_PERCENTAGE, DECREASE_PERCENTAGE, IMPROVE_PERCENTAGE, MATCHES
target integer(int32) true The target range of the objective. -
consumerConditionType string false The type of conditions related to the consumer. AGE, GENDER, DIABETIC
subtype string false The subtype against which the condition type is compared, for example, SYSTOLIC or DIASTOLIC. -

Objectives

Name Type Required Description Accepted Values
items [Objective] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

Objective

Name Type Required Description Accepted Values
id string true The ID of the objective. -
position integer(int32) true The number position of the objective. -
titles [Translation] true The name of the objective. -
descriptions [Translation] false The description of the objective. -
sourceDefinition object false The source system in which the activity is defined. -
startsAt string true The date and time when the campaign starts, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
endsAt string true The date and time when the campaign ends, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
frequency string false The frequency of the objective. DAILY, WEEKLY, MONTHLY, QUARTERLY, BI_ANNUALLY, ANNUALLY, ONE_TIME
isRepeatableWithinFrequency boolean false Indicates whether the objective can be completed multiple times within the objective frequency. -
maxCompletionCount integer(int32) false The maximum number of times the objective can be completed over the entire period of the campaign. -
primaryObjectiveId string false The ID of an existing valid objective. An objective with the primaryObjectiveId attribute is an alternative objective. -
acceptsAllSources boolean false Indicates whether all sources are acceptable. -
requiresVerification boolean false The indicator of whether this objective needs a verification. -
alternatives Objective false The list of alternative objectives associated with the objective. -
conditions [Condition] false The conditions of the objective. -
sources string false The data sources that are allowed by the system. The following sources are possible:
- SPECIFIC_PROVIDER: Indicates that the data is from a service provider.
- CLAIM: Indicates that the data is from a claim.
- APP_DEVICE: Indicates that the data is from a device such as a Fitbit.
- COACH_ENTERED: Indicates that the data was entered by a health coach.
- ADMINISTRATOR_UPLOADED: Indicates that the data was entered by an administrator.
- EMR_DW_INTEGRATION: Indicates that the data is from an integrated EHR system.
SPECIFIC_PROVIDER, CLAIM, SELF_ENTERED, APP_DEVICE, COACH_ENTERED, ADMINISTRATOR_UPLOADED, EMR_DW_INTEGRATION
createdAt string false The date and time when the objective was created, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
updatedAt string false The date and time when the objective was last updated, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -

patchCampaignsCampaignidCategoriesCategoryidObjectiveDefinitions

Name Type Required Description Accepted Values
titles [object] false A list of objective names for the different locales. -
» locale string true A two-letter language and two-letter region ID, for example, en-US. The locale should match the ISO 639-1 specification. See ISO 639 Language Codes on the ISO website for more information. -
» text string true The title of the objective for the specified locale. The maximum length is 191 characters. -
descriptions [object] false A list of objective descriptions for the different locales. -
» locale string true A two-letter language and two-letter region ID, for example, en-US. The locale should match the ISO 639-1 specification. See ISO 639 Language Codes on the ISO website for more information. -
» text string true The descriptions of the objective for the specified locale. The maximum length is 191 characters. -
sourceDefinition object false The source system in which the activity is defined. -
» id string false The ID of the source system. -
» kind string true The type of the source system in which the activity is defined, for example, EDUCATION_MODULE or QUESTIONNAIRE. -
frequency string false The frequency of the objective. DAILY, WEEKLY, MONTHLY, QUARTERLY, BI_ANNUALLY, ANNUALLY, ONE_TIME
isRepeatableWithinFrequency boolean false Indicates whether the objective can be completed multiple times within the objective frequency. -
requiresVerification boolean false When set to true, the objective must be verified and marked as complete by an admin or care provider. -
startsAt string false The date and time when the objective starts, in ISO 8601 format. -
endsAt string false The date and time when the objective ends, in ISO 8601 format. -
maxCompletionCount integer(int32) false The maximum number of times the objective can be completed. This can be used only for completion-based objectives. -
sources [string] false The sources that are permitted to meet an objective. If this is not specified, all sources are permitted. The following sources are possible:
- SPECIFIC_PROVIDER: Indicates that the data is from a service provider.
- CLAIM: Indicates that the data is from a claim.
- APP_DEVICE: Indicates that the data is from a device such as a Fitbit.
- COACH_ENTERED: Indicates that the data was entered by a health coach.
- ADMINISTRATOR_UPLOADED: Indicates that the data was entered by an administrator.
- EMR_DW_INTEGRATION: Indicates that the data is from an integrated EHR system.
SPECIFIC_PROVIDER, CLAIM, SELF_ENTERED, APP_DEVICE, COACH_ENTERED, ADMINISTRATOR_UPLOADED, EMR_DW_INTEGRATION
conditions [object] false A list of conditions for the objective. -
» value string false The value for the condition. -
» operator string false The conditional operator of the objective. If the consumerConditionType is GENDER or DIABETIC, the MATCHES operator must be used. If the consumerConditionType is AGE, one of the following operators must be used: [‘>’, ‘<’, ‘<=’, ‘>=’]. -
» target string false The target range of the objective. -
» subtype string false The subtype against which the condition type is compared, for example, SYSTOLIC or DIASTOLIC. -
» consumerConditionType string false The type of conditions related to consumer. -

CampaignInstances

Name Type Required Description Accepted Values
items [CampaignInstance] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

CampaignInstance

Name Type Required Description Accepted Values
id string true The ID of the campaign instance. -
campaignId string true The ID of the campaign. -
categoryId string true The ID of the category associated with the campaign. -
names [Translation] true The name of the campaign. -
descriptions [Translation] false The description of the campaign. -
completionThreshold integer(int32) false The completion threshold number for the campaign. -
startsAt string true The date and time when the campaign starts, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
endsAt string true The date and time when the campaign ends, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
reward RewardDefinition false Retrieves a single wellness incentive reward definition by ID. -
adjustmentReward RewardDefinition false Retrieves a single wellness incentive reward definition by ID. -
timeZone string false The time zone in which the campaign is created. -
icon string false The file name of the icon. -
populations [Population] false The populations associated with the campaign instance. -
createdAt string false The date and time when the campaign was created, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
updatedAt string false The date and time when the campaign was last updated, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
categories [Category] true The list of categories for the campaign. -
objectives [ObjectiveDefinition] true The list of objectives for the campaign. -

RewardDefinition

Name Type Required Description Accepted Values
id string true The ID of the reward. -
value integer(int32) true The value of the reward that is awarded every time the reward is earned. -
limit integer(int32) true The maximum number of rewards that can be earned. -
units [UnitReference] true No description -

UnitReference

Name Type Required Description Accepted Values
singularName string false No description -
pluralName string false No description -
locale string false No description -

Category

Name Type Required Description Accepted Values
id string true The ID of the category. -
parentCategoryId string false The ID of the parent category of the category. -
names [Translation] true The name of the category. -
descriptions [Translation] false The description of the category. -
reward RewardDefinition false Retrieves a single wellness incentive reward definition by ID. -
adjustmentReward RewardDefinition false Retrieves a single wellness incentive reward definition by ID. -
completionThreshold integer(int32) false The completion threshold number for the category. -
icon string false The file name of the icon. -
startsAt string false The date and time when the category starts, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
endsAt string false The date and time when the category ends, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
createdAt string false The date and time when the category was created, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
updatedAt string false The date and time when the category was last updated, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
objectives [ObjectiveDefinition] false The list of objectives associated with the category. -
categories [Category] false The child categories associated with the category. -

ObjectiveDefinition

Name Type Required Description Accepted Values
id string true The ID of the objective. -
activity_definition_id string true The ID of the activity definition. -
position integer(int32) true The number position of the objective. -
titles [Translation] true The name of the objective. -
descriptions [Translation] false The description of the objective. -
sourceDefinition object true The source systems, for example, QUESTIONNAIRE. -
frequency string false How often the objective can be completed. DAILY, WEEKLY, MONTHLY, QUARTERLY, BI_ANNUALLY, ANNUALLY, ONE_TIME
isRepeatableWithinFrequency boolean false Indicates whether the objective can be completed multiple times within the objective frequency. -
maxCompletionCount integer(int32) false The maximum number of times the objective can be completed over the entire period of the campaign. -
primaryObjectiveId string false The ID of an existing valid objective. An objective with the primaryObjectiveId attribute is an alternative objective. -
acceptsAllSources boolean false Indicates whether all sources are acceptable. -
requiresVerification boolean false Indicates whether the objective must be verified before completion. -
alternatives [ObjectiveDefinition] false The list of alternative objectives associated with the objective. -
conditions [Condition] false The conditions of the objective -
sources string false The data sources that are allowed by the system. The following sources are possible:
- SPECIFIC_PROVIDER: Indicates that the data is from a service provider.
- CLAIM: Indicates that the data is from a claim.
- APP_DEVICE: Indicates that the data is from a device such as a Fitbit.
- COACH_ENTERED: Indicates that the data was entered by a health coach.
- ADMINISTRATOR_UPLOADED: Indicates that the data was entered by an administrator.
- EMR_DW_INTEGRATION: Indicates that the data is from an integrated EHR system.
SPECIFIC_PROVIDER, CLAIM, SELF_ENTERED, APP_DEVICE, COACH_ENTERED, ADMINISTRATOR_UPLOADED, EMR_DW_INTEGRATION
incentive Incentive false The incentive for completing the objective. -

Incentive

Name Type Required Description Accepted Values
id string true The ID of the incentive. -
objectiveId string true The ID of the objective. -
rewardLimitPerFrequency integer(int32) true The maximum number of times a consumer can earn points for completing the objective in a frequency. -
reward RewardDefinition false Retrieves a single wellness incentive reward definition by ID. -

postCampaignInstances

Name Type Required Description Accepted Values
campaignId string true The ID of the wellness campaign that is to be published. -

postCampaignMemberships

Name Type Required Description Accepted Values
campaignId string true The ID of an incentive campaign. -
consumerId string true The ID of a HealtheIntent consumer. See Consumer API for more information. -

CampaignMembership

Name Type Required Description Accepted Values
id string true The ID of the campaign membership. -
campaignId string true The ID of the incentive campaign. -
consumerId string true The ID of the consumer. -
createdAt string false The date and time when the campaign membership was created, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
updatedAt string false The date and time when the campaign membership was last updated, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -

CampaignMemberships

Name Type Required Description Accepted Values
items [CampaignMembership] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

postRewardDefinitions

Name Type Required Description Accepted Values
value integer(int32) true The value of the reward earned. -
limit integer(int32) true The maximum number of rewards that can be earned. -
units [object] true A list of unit locales supported for the reward. -
» singularName string true The singular name for the currency unit for rewards. -
» pluralName string true The plural name for the currency unit for the rewards. -
» locale string true The locale for the currency unit. -

RewardDefinitions

Name Type Required Description Accepted Values
items [RewardDefinition] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

patchRewardDefinitions

Name Type Required Description Accepted Values
value integer(int32) false The value of the reward earned. -
limit integer(int32) false The maximum number of rewards that can be earned. -
units [object] false A list of unit locales supported for the reward. -
» singularName string true The singular name for the currency unit for the rewards. -
» pluralName string true The plural name for the currency unit for the rewards. -
» locale string true The locale for the currency unit. -

ConsumerIncentiveRewardLists

Name Type Required Description Accepted Values
items [ConsumerIncentiveRewardList] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

ConsumerIncentiveRewardList

Name Type Required Description Accepted Values
id string true The ID of the reward. -
consumer ConsumerReference false The related resource of the consumer. -
reward RewardReference false The related resource of the reward. -
earned integer(int32) true The earned reward. This is the total number of points that the consumer earned, regardless of the limit for the reward. -
effective integer(int32) true The effective of the earned reward. This is the number of points that the consumer earns after the limit of the reward is applied. For example, if the consumer earns 11 points but the limit is 10, the consumer earns 10 points. -
createdAt string(date-time) false The date and time when the consumer reward was earned, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
updatedAt string(date-time) false The date and time when the consumer reward was updated, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -

ConsumerReference

Name Type Required Description Accepted Values
id string true The ID of the consumer. -

RewardReference

Name Type Required Description Accepted Values
id string true The ID of the reward. -

ConsumerIncentiveReward

Name Type Required Description Accepted Values
id string true The ID of the reward. -
consumer ConsumerReference false The related resource of the consumer. -
reward RewardReference false The related resource of the reward. -
earned integer(int32) true The earned reward. This is the total number of points that the consumer earned, regardless of the limit for the reward. -
effective integer(int32) true The effective of the earned reward. This is the number of points that the consumer earns after the limit of the reward is applied. For example, if the consumer earns 11 points but the limit is 10, the consumer earns 10 points. -
createdAt string(date-time) false The date and time when the consumer reward was earned, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
updatedAt string(date-time) false The date and time when the consumer reward was updated, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
transactions [Transaction] false An array that contains every transaction of the consumer reward. -

Transaction

Name Type Required Description Accepted Values
id string true The ID of the reward. -
delta integer(int32) true The delta of the reward. This is the change in the reward total that the transaction causes and can be negative or positive. -
referenceSystem string true The reference system in which reward is identified. -
createdAt string(date-time) false The date and time when the consumer reward was earned, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -
updatedAt string(date-time) false The date and time when the consumer reward was updated, in ISO 8601 YYYY-MM-DDThh:mm:ss.SSSZ format. -

ObjectiveStatuses

Name Type Required Description Accepted Values
items [ObjectiveStatus] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

ObjectiveStatus

Name Type Required Description Accepted Values
consumer string true The ID of the consumer. -
objectiveDefinition ObjectiveReference true The reference of the objective definition. -
overallStatus string true The overall status of the objective for the consumer. This applies only to completion-based objectives. IN_PROGRESS, COMPLETED
overallCompletionCount integer(int32) false The number of times an objective was completed by the consumer. -
detailsByFrequency [ObjectiveInstance] false A list of the instances of a consumer’s fulfillment of an objective. -

ObjectiveReference

Name Type Required Description Accepted Values
id string true The ID of the objective definition. -
sourceDefinition string true The source system in which the objective is defined. -

ObjectiveInstance

Name Type Required Description Accepted Values
status string true The status of the consumer objective. IN_PROGRESS, COMPLETED
frequencyBeginsAt string false The beginning date of the frequency for the objective. -
completionCount integer(int32) false The number of times the objective is achieved in the given frequency. This is the sum of the activityCount and adminAwardedCount values. -
activityCount integer(int32) false The number of times the consumer accomplishes the objective in the given frequency. -
adminAwardedCount integer(int32) false The number of exemptions awarded by an administrator for the goal in the given frequency. -
consumerActivitySourceDefinitions [object] false The definition IDs that correspond to the consumer activity sources for the consumer objective. -

postCampaignObjectives

Name Type Required Description Accepted Values
consumer object true The ID of the consumer. -
» id string true The ID of the consumer. -
locale string false A two-letter language and two-letter region ID. Only en-US is supported currently. -
activity object true The details of the consumer activity. -
» id string false The ID of the consumer activity. -
» performedOn string false The date on which the activity is performed. -
» name string false The name of the activity. -
» details string false The description of the activity. -
» providerName string false The name of the provider for the activity. -
» providerLocation string false The location of the provider for the activity. -
» status string false The verification status for the consumer activity. PENDING, APPROVED, DENIED
» sourceDefinition object false No description -
»» id string true The ID of the source system. -
»» kind string true The type of the source system in which the activity is defined, for example, [wellness#learningModules, wellness#HealthyHabit]. -

IncentiveCalculationList

Name Type Required Description Accepted Values
items [IncentiveCalculation] true No description -

IncentiveCalculation

Name Type Required Description Accepted Values
campaign string true The ID of the campaign. -
completionCount integer(int32) false The total number of times an objective was completed in the frequency. -
pointsAchieved integer(int32) false The number of incentive points that were achieved. -
unit UnitReference false No description -

PhaDefinitions

Name Type Required Description Accepted Values
items [PhaDefinition] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

PhaDefinition

Name Type Required Description Accepted Values
id string true The ID of the PHA definition. -
phaId string true The ID of the PHA. -
name string true The name of the PHA. The value of this attribute is unique for every phaId value. -
locale string true The locale of the PHA. -
description string false The human-readable description of the PHA. -
code Code false The PHA code from a single, specified (not fixed) code system. -

Code

Name Type Required Description Accepted Values
code string true The unique ID of the code. -
display string false A human-readable representation of the code. -
system string true The ID of the coding system that gives meaning to the code. -

BadRequestError

Name Type Required Description Accepted Values
code integer(int32) true The HTTP response status code that represents the error. -
message string true A human-readable description of the error. -
errorDetails [BadRequestErrorDetail] false A list of additional error details. -

ErrorDetail

Name Type Required Description Accepted Values
domain string false A subsystem or context where an error occurred. -
reason string false A codified value that represents the specific error that caused the current error status. -
message string false A human-readable description of an error. -
locationType string false The location or type of the field that caused an error. query, header, path, formData, body
location string false The name of the field that caused an error. -

BadRequestErrorDetail

Name Type Required Description Accepted Values
domain string false A subsystem or context where an error occurred. -
reason string false A codified value that represents the specific error that caused the current error status. -
message string false A human-readable description of an error. -
locationType string false The location or type of the field that caused an error. query, header, path, formData, body
location string false The name of the field that caused an error. -

UnauthorizedError

Name Type Required Description Accepted Values
code integer(int32) true The HTTP response status code that represents the error. -
message string true A human-readable description of the error. -
errorDetails [UnauthorizedErrorDetail] false A list of additional error details. -

UnauthorizedErrorDetail

Name Type Required Description Accepted Values
domain string false A subsystem or context where an error occurred. -
reason string false A codified value that represents the specific error that caused the current error status. -
message string false A human-readable description of an error. -
locationType string false The location or type of the field that caused an error. query, header, path, formData, body
location string false The name of the field that caused an error. -

ForbiddenError

Name Type Required Description Accepted Values
code integer(int32) true The HTTP response status code that represents the error. -
message string true A human-readable description of the error. -
errorDetails [ForbiddenErrorDetail] false A list of additional error details. -

ForbiddenErrorDetail

Name Type Required Description Accepted Values
domain string false A subsystem or context where an error occurred. -
reason string false A codified value that represents the specific error that caused the current error status. -
message string false A human-readable description of an error. -
locationType string false The location or type of the field that caused an error. query, header, path, formData, body
location string false The name of the field that caused an error. -

postPhaDefinitions

Name Type Required Description Accepted Values
name string true The name of the PHA. The value of this attribute is unique for every phaId value. -
locale string true The locale of the PHA. -
description string false The human-readable description of the PHA. -
code object false A code represents a concept for the PHA definition from a single, specified code system. -
» code string true The unique ID of the code. -
» system string true The unique ID of the coding system that gives meaning to the code. -
» display string false A human-readable representation of the code. -

NotFoundError

Name Type Required Description Accepted Values
code integer(int32) true The HTTP response status code that represents the error. -
message string true A human-readable description of the error. -
errorDetails [NotFoundErrorDetail] false A list of additional error details. -

NotFoundErrorDetail

Name Type Required Description Accepted Values
domain string false A subsystem or context where an error occurred. -
reason string false A codified value that represents the specific error that caused the current error status. -
message string false A human-readable description of an error. -
locationType string false The location or type of the field that caused an error. query, header, path, formData, body
location string false The name of the field that caused an error. -

putPhaDefinitions

Name Type Required Description Accepted Values
name string true The name of the PHA. The value of this attribute is unique for every phaId value. -
locale string true The locale of the PHA. -
description string false The human-readable description of the PHA. -
code object false A code represents a concept for the PHA definition from a single, specified code system. -
» code string true The unique ID of the code. -
» system string true The unique ID of the coding system that gives meaning to the code. -
» display string false A human-readable representation of the code. -

PhaSections

Name Type Required Description Accepted Values
items [PhaSection] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

PhaSection

Name Type Required Description Accepted Values
id string true The ID of the PHA section. -
name string true The name of the PHA section. -
description string false The human-readable description of the PHA section. -
position integer(int32) true A position of a section indicates that the section must be at the given position in the sequence of sections in the PHA. The position must be unique within the PHA. -
code Code false The code of the PHA section from a single, specified (not fixed) code system. -

postPhaDefinitionsPhadefinitionidSections

Name Type Required Description Accepted Values
name string true The name of the PHA section. -
description string false The human-readable description of the PHA section. -
position integer(int32) true A position of a section indicates that the section must be at the given position in the sequence of sections in the PHA. The position must be unique within the PHA. -
code object false A code represents a concept for the PHA section from a single, specified code system. -
» code string true The unique ID of the code. -
» system string true The unique ID of the coding system that gives meaning to the code. -
» display string false A human-readable representation of the code. -

putPhaDefinitionsPhadefinitionidSections

Name Type Required Description Accepted Values
name string true The name of the PHA section. -
description string false The human-readable description of the PHA section. -
position integer(int32) true A position of a section indicates that the section must be at the given position in the sequence of sections in the PHA. The position must be unique within the PHA. -
code object false A code represents a concept for the PHA section from a single, specified code system. -
» code string true The unique ID of the code. -
» system string true The unique ID of the coding system that gives meaning to the code. -
» display string false A human-readable representation of the code. -

PhaSubsections

Name Type Required Description Accepted Values
items [PhaSubsection] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

PhaSubsection

Name Type Required Description Accepted Values
id string true The ID of the PHA subsection. -
name string true The name of the PHA subsection. -
description string false The human-readable description of the PHA subsection. -
position integer(int32) true A position of a section indicates that the subsection must be at the given position in the sequence of subsections in the PHA section. The position must be unique within the section in which the subsection is grouped. -
code Code false The code of the PHA subsection from a single, specified (not fixed) code system. -
section PhaSectionReference true A reference to the PHA section. -

PhaSectionReference

Name Type Required Description Accepted Values
id string true The ID of the PHA section. -

postPhaDefinitionsPhadefinitionidSubsections

Name Type Required Description Accepted Values
name string true The name of the PHA subsection. -
description string false The human-readable description of the PHA subsection. -
position integer(int32) true A position of a section indicates that the subsection must be at the given position in the sequence of subsections in the PHA section. The position must be unique within the section in which the subsection is grouped. -
code object false The code of the PHA subsection from a single, specified (not fixed) code system. -
» code string true The unique ID of the code. -
» system string true The unique ID of the coding system that gives meaning to the code. -
» display string false A human-readable representation of the code. -
section object true A reference to the PHA section. -
» id string true The ID of the PHA section. -

putPhaDefinitionsPhadefinitionidSubsections

Name Type Required Description Accepted Values
name string true The name of the PHA subsection. -
description string false The human-readable description of the PHA subsection. -
position integer(int32) true A position of a section indicates that the subsection must be at the given position in the sequence of subsections in the PHA section. The position must be unique within the section in which the subsection is grouped. -
code object false The code of the PHA subsection from a single, specified (not fixed) code system. -
» code string true The unique ID of the code. -
» system string true The unique ID of the coding system that gives meaning to the code. -
» display string false A human-readable representation of the code. -
section object true A reference to the PHA section. -
» id string true The ID of the PHA section. -

PhaQuestions

Name Type Required Description Accepted Values
items [PhaQuestion] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

PhaQuestion

Name Type Required Description Accepted Values
id string true The ID of the PHA question. -
text string true The human-readable text of the question. -
type string true The type of the question in the PHA. The following types are available:
- TEXT A question with a long, potentially multiparagraph free-text answer.
- STRING A question with a short free-text answer. The maximum length is 255 characters.
- DATE_TIME A question with a date and time answer.
- CHOICE A question with a choice from a list of options as an answer.
- DATE A question with a date answer.
- OPEN_CHOICE A question with a choice from a list of options (as with the CHOICE type) or a free-text answer.
- RANGE A question with an answer that is a numeric value between a high and a low value.
TEXT, STRING, DATE_TIME, CHOICE, RANGE, DATE, OPEN_CHOICE
description string false A free-text description of the PHA question that provides instructions or additional context for a user to answer the question. -
acceptsMultipleAnswers boolean true Indicates whether the question can have more than one answer. -
required boolean true Indicates whether the question must be answered in a completed response. -
position integer(int32) true Indicates that the question must be at the given position in the sequence of questions in the section or subsection. The position must be unique within the section or the subsection in which the question is grouped. -
section PhaSectionReference false A reference to the PHA section. A question should be in either a section or a subsection. -
subsection PhaSubsectionReference false A reference to the PHA subsection. A question should be in either a section or a subsection. -
code Code false The code for the PHA question from a single, specified (not fixed) code system. -
options [Option] false The possible answers to the PHA question. -

PhaSubsectionReference

Name Type Required Description Accepted Values
id string true The ID of the PHA subsection. -

Option

Name Type Required Description Accepted Values
id string true The ID of the PHA option. -
choice Choice false A permitted choice that can be chosen as an answer to the question. -
range Range false The permitted range in which the answer can be chosen for the question. -

Choice

Name Type Required Description Accepted Values
points integer(int32) false The total points earned by selecting this choice as an answer to the question. -
text string true A free-text description of the choice. -

Range

Name Type Required Description Accepted Values
low number(float) true The lowest possible value for the answer. The boundary is inclusive. -
high number(float) true The highest possible value for the answer. The boundary is inclusive. -
text string true A human-readable description of the range. -

postPhaDefinitionsPhadefinitionidQuestions

Name Type Required Description Accepted Values
text string true The human-readable text of the question. -
type string true The type of the question in the PHA. The following types are available:
- TEXT A question with a long, potentially multiparagraph free-text answer.
- STRING A question with a short free-text answer. The maximum length is 255 characters.
- DATE_TIME A question with a date and time answer.
- CHOICE A question with a choice from a list of options as an answer.
- DATE A question with a date answer.
- OPEN_CHOICE A question with a choice from a list of options (as with the CHOICE type) or a free-text answer.
- RANGE A question with an answer that is a numeric value between a high and a low value.
TEXT, STRING, DATE_TIME, CHOICE, RANGE, DATE, OPEN_CHOICE
description string false A free-text description of the PHA question that provides instructions or additional context for a user to answer the question. -
acceptsMultipleAnswers boolean false Indicates whether the question can have more than one answer. -
required boolean false Indicates whether the question must be answered in a completed response. -
position integer(int32) true Indicates that the question must be at the given position in the sequence of questions in the section or subsection. The position must be unique within the section or the subsection in which the question is grouped. -
section object false A reference to the PHA section. A question should be in either a section or a subsection. -
» id string true The ID of the PHA section. -
subsection object false A reference to the PHA subsection. A question should be in either a section or a subsection. -
» id string true The ID of the PHA subsection. -
code object false The code for the PHA question from a single, specified (not fixed) code system. -
» code string true The unique ID of the code. -
» system string true The unique ID of the coding system that gives meaning to the code. -
» display string false A human-readable representation of the code. -
options [object] false The possible answers to the PHA question. -
» choice [object] false A permitted choice that can be chosen as an answer to the question. -
»» points integer(int32) false The total points earned by selecting this choice as an answer to the question. -
»» text string true A free-text description of the choice. -
» range [object] false The permitted range in which the answer can be chosen for the question. -
»» low number(float) true The lowest possible value for the answer. The boundary is inclusive. -
»» high number(float) true The highest possible value for the answer. The boundary is inclusive. -
»» text string true A human-readable description of the range. -

putPhaDefinitionsPhadefinitionidQuestions

Name Type Required Description Accepted Values
text string true The human-readable text of the question. -
type string true The type of the question in the PHA. The following types are available:
- TEXT A question with a long, potentially multiparagraph free-text answer.
- STRING A question with a short free-text answer. The maximum length is 255 characters.
- DATE_TIME A question with a date and time answer.
- CHOICE A question with a choice from a list of options as an answer.
- DATE A question with a date answer.
- OPEN_CHOICE A question with a choice from a list of options (as with the CHOICE type) or a free-text answer.
- RANGE A question with an answer that is a numeric value between a high and a low value.
TEXT, STRING, DATE_TIME, CHOICE, RANGE, DATE, OPEN_CHOICE
description string false A free-text description of the PHA question that provides instructions or additional context for a user to answer the question. -
acceptsMultipleAnswers boolean false Indicates whether the question can have more than one answer. -
required boolean false Indicates whether the question must be answered in a completed response. -
position integer(int32) true Indicates that the question must be at the given position in the sequence of questions in the section or subsection. The position must be unique within the section or the subsection in which the question is grouped. -
section object false A reference to the PHA section. A question should be in either a section or a subsection. -
» id string true The ID of the PHA section. -
subsection object false A reference to the PHA subsection. A question should be in either a section or a subsection. -
» id string true The ID of the PHA subsection. -
code object false The code for the PHA question from a single, specified (not fixed) code system. -
» code string true The unique ID of the code. -
» system string true The unique ID of the coding system that gives meaning to the code. -
» display string false A human-readable representation of the code. -
options [object] false The possible answers to the PHA question. -
» choice [object] false A permitted choice that can be chosen as an answer to the question. -
»» points integer(int32) false The total points earned by selecting this choice as an answer to the question. -
»» text string true A free-text description of the choice. -
» range [object] false The permitted range in which the answer can be chosen for the question. -
»» low number(float) true The lowest possible value for the answer. The boundary is inclusive. -
»» high number(float) true The highest possible value for the answer. The boundary is inclusive. -
»» text string true A human-readable description of the range. -

PhaRules

Name Type Required Description Accepted Values
items [PhaRule] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

PhaRule

Name Type Required Description Accepted Values
id string true The ID of the PHA rule. -
relation string false The relationship among multiple conditions for the rule. The relation can be either AND or OR. A combination of both is not supported. AND indicates that all conditions associated with this rule must be satisfied before the action can be taken. OR indicates that only one of the conditions associated with this rule must be satisfied before the action can be performed. AND, OR
conditions [Condition] true Conditions define the list of constraints that must be satisfied by the answers in the PHA response before the action associated with the rule can be performed. -
action Action true The action to perform when the conditions are met for the rule. -

Action

Name Type Required Description Accepted Values
questions [PhaQuestionReference] true A reference to the PHA questions for which the action is performed. Currently, the only action that can be performed is to display the PHA questions. -

PhaQuestionReference

Name Type Required Description Accepted Values
id string true The ID of the PHA question. -

postPhaDefinitionsPhadefinitionidRules

Name Type Required Description Accepted Values
relation string true The relationship among multiple conditions for the rule. The relation can be either AND or OR. A combination of both is not supported. AND indicates that all conditions associated with this rule must be satisfied before the action can be taken. OR indicates that only one of the conditions associated with this rule must be satisfied before the action can be performed. AND, OR
conditions [object] true Conditions define the list of constraints that must be satisfied by the answers in the PHA response before the action associated with the rule can be performed. -
» question [object] true A reference to the PHA question whose answers are used to satisfy the condition. -
»» id string true The ID of the PHA question. -
» values [object] true The values to be compared with the answer of the question to determine if the condition is satisfied. -
»» option [object] true A reference to the option. -
»»» id string true The ID of the PHA option. -
»» operator string false The comparison predicate with which to compare the answer in the referenced question. The following values are possible:
GT The answer is greater than the comparison value.
LT The answer is less than the comparison value.
GE The answer is greater than or equal to the comparison value.
LE The answer is less than or equal to the comparison value.
EQ The answer is equal to the comparison value.
NE The answer is not equal to the comparison value.
-
»» value string false The value against which to compare the answer. -
» type string true The type of relationship among the condition constraints. ALL_OF indicates that all constraints associated with the condition must be satisfied. ONE_OF indicates that only one of the constraints associated with the condition must be satisfied. -
action [object] true The action to perform when the conditions are met for the rule. -
» questions [object] true A reference to the PHA questions for which the action is performed. Currently, the only action that can be performed is to display the PHA questions. -
»» id string true The ID of the PHA question. -

putPhaDefinitionsPhadefinitionidRules

Name Type Required Description Accepted Values
relation string true The relationship among multiple conditions for the rule. The relation can be either AND or OR. A combination of both is not supported. AND indicates that all conditions associated with this rule must be satisfied before the action can be taken. OR indicates that only one of the conditions associated with this rule must be satisfied before the action can be performed. AND, OR
conditions [object] true Conditions define the list of constraints that must be satisfied by the answers in the PHA response before the action associated with the rule can be performed. -
» question [object] true A reference to the PHA question whose answers are used to satisfy the condition. -
»» id string true The ID of the PHA question. -
» values [object] true The values to be compared with the answer of the question to determine if the condition is satisfied. -
»» option [object] true A reference to the option. -
»»» id string true The ID of the PHA option. -
»» operator string false The comparison predicate with which to compare the answer in the referenced question. The following values are possible:
GT The answer is greater than the comparison value.
LT The answer is less than the comparison value.
GE The answer is greater than or equal to the comparison value.
LE The answer is less than or equal to the comparison value.
EQ The answer is equal to the comparison value.
NE The answer is not equal to the comparison value.
-
»» value string false The value against which to compare the answer. -
» type string true The type of relationship among the condition constraints. ALL_OF indicates that all constraints associated with the condition must be satisfied. ONE_OF indicates that only one of the constraints associated with the condition must be satisfied. -
action [object] true The action to perform when the conditions are met for the rule. -
» questions [object] true A reference to the PHA questions for which the action is performed. Currently, the only action that can be performed is to display the PHA questions. -
»» id string true The ID of the PHA question. -

postPublishedPersonalHealthAssessments

Name Type Required Description Accepted Values
phaDefinition object true A reference to the PHA definition that is used to create a published PHA. -
» id string true The ID of the PHA definition. -

PublishedPersonalHealthAssessment

Name Type Required Description Accepted Values
id string true The ID of the published PHA. -
phaDefinition Definition false A reference to the PHA definition that is used to create a published PHA. -

Definition

Name Type Required Description Accepted Values
id string true The ID of the PHA definition. -
phaId string true The ID of the PHA. -
name string true The name of the PHA. The value of this attribute is unique for every phaId value. -
locale string true The locale of the PHA. -
description string false The human-readable description of the PHA. -
code Code false The PHA code from a single, specified (not fixed) code system. -
sections [Section] false Sections are structured groups of subsections and questions for a PHA. -

Section

Name Type Required Description Accepted Values
id string true The ID of the PHA section. -
name string true The name of the PHA section. -
description string false The human-readable description of the PHA section. -
position integer(int32) true A position of a section indicates that the section must be at the given position in the sequence of sections in the PHA. The position must be unique within the PHA. -
code Code false The code of the PHA section from a single, specified (not fixed) code system. -
questions [Question] false Questions define the information necessary to guide the collection of answers from a HealtheIntent consumer about their health and wellness habits. -
subsections [Subsection] false Subsections are structured subgroups in PHA sections that contain the questions for a PHA. -

Question

Name Type Required Description Accepted Values
id string true The ID of the PHA question. -
text string true The human-readable text of the question. -
type string true The type of the question in the PHA. The following types are available:
- TEXT A question with a long, potentially multiparagraph free-text answer.
- STRING A question with a short free-text answer. The maximum length is 255 characters.
- DATE_TIME A question with a date and time answer.
- CHOICE A question with a choice from a list of options as an answer.
- DATE A question with a date answer.
- OPEN_CHOICE A question with a choice from a list of options (as with the CHOICE type) or a free-text answer.
- RANGE A question with an answer that is a numeric value between a high and a low value.
TEXT, STRING, DATE_TIME, CHOICE, RANGE, DATE, OPEN_CHOICE
description string false A free-text description of the PHA question that provides instructions or additional context for a user to answer the question. -
acceptsMultipleAnswers boolean true Indicates whether the question can have more than one answer. -
required boolean true Indicates whether the question must be answered in a completed response. -
position integer(int32) true Indicates that the question must be at the given position in the sequence of questions in the section or subsection. The position must be unique within the section or the subsection in which the question is grouped. -
section PhaSectionReference false A reference to the PHA section. A question should be in either a section or a subsection. -
subsection PhaSubsectionReference false A reference to the PHA subsection. A question should be in either a section or a subsection. -
code Code false The code for the PHA question from a single, specified (not fixed) code system. -
options [Option] false The possible answers to the PHA question. -
rule Rule false A rule defines the logic that is used to customize and control the behavior of the survey, for example, displaying or not displaying sections or questions based on the respondent’s answers, -

Rule

Name Type Required Description Accepted Values
id string true The ID of the PHA rule. -
relation string false The relationship among multiple conditions for the rule. The relation can be either AND or OR. A combination of both is not supported. AND indicates that all conditions associated with this rule must be satisfied before the action can be taken. OR indicates that only one of the conditions associated with this rule must be satisfied before the action can be performed. AND, OR
conditions [Condition] true Conditions define the list of constraints that must be satisfied by the answers in the PHA response before the action associated with the rule can be performed. -

Subsection

Name Type Required Description Accepted Values
id string true The ID of the PHA subsection. -
name string true The name of the PHA subsection. -
description string false The human-readable description of the PHA subsection. -
position integer(int32) true A position of a section indicates that the subsection must be at the given position in the sequence of subsections in the PHA section. The position must be unique within the section in which the subsection is grouped. -
code Code false The code of the PHA subsection from a single, specified (not fixed) code system. -
section PhaSectionReference true A reference to the PHA section. -
questions [Question] false Questions define the information necessary to guide the collection of answers from a HealtheIntent consumer about their health and wellness habits. -

PhaResponseDefinitions

Name Type Required Description Accepted Values
items [PhaResponseDefinition] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

PhaResponseDefinition

Name Type Required Description Accepted Values
id string true The ID of the PHA response definition. -
authoredAt string true The date and time when the PHA response was submitted or updated. The date and time must be in ISO 8601 YYYY-MM-DDThh:mm:ssTZD format, for example, 1997-07-16T19:20:30+01:00. -
publishedPhaDefinition PhaDefinitionReference true A reference to the PHA definition. -
consumer ConsumerReference true A reference to the HealtheIntent consumer. -
completedPhaResponses [CompletedPhaResponseReference] false A reference to the completed PHA response. -

PhaDefinitionReference

Name Type Required Description Accepted Values
id string true The ID of the PHA definition. -
name string true The name of the PHA. The value of this attribute is unique for every phaId value. -

CompletedPhaResponseReference

Name Type Required Description Accepted Values
id string true The ID of the completed PHA response. -
authoredAt string true The date and time when the PHA response was completed. The date and time must be in ISO 8601 YYYY-MM-DDThh:mm:ssTZD format, for example, 1997-07-16T19:20:30+01:00. -

postPhaResponseDefinitions

Name Type Required Description Accepted Values
authoredAt string true The date and time when the PHA response was submitted or updated. The date and time must be in ISO 8601 YYYY-MM-DDThh:mm:ssTZD format, for example, 1997-07-16T19:20:30+01:00. -
consumer object true A reference to the HealtheIntent consumer. -
» id string true The ID of the HealtheIntent consumer. -
phaDefinition object true A reference to the PHA definition. -
» id string true The ID of the PHA definition. -

putPhaResponseDefinitions

Name Type Required Description Accepted Values
authoredAt string true The date and time when the PHA response was submitted or updated. The date and time must be in ISO 8601 YYYY-MM-DDThh:mm:ssTZD format, for example, 1997-07-16T19:20:30+01:00. -
consumer object true A reference to the HealtheIntent consumer. -
» id string true The ID of the HealtheIntent consumer. -
phaDefinition object true A reference to the PHA definition. -
» id string true The ID of the PHA definition. -

PhaResponseSections

Name Type Required Description Accepted Values
items [PhaResponseSection] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

PhaResponseSection

Name Type Required Description Accepted Values
id string true The ID of the PHA response section. -
section PhaSectionReference true A reference to the PHA section. -
status string true The current state of the PHA response section. Currently, the following statuses are supported:
- NOT_STARTED Indicates that the HealtheIntent consumer has not started answering the PHA section.
- IN_PROGRESS Indicates that the HealtheIntent consumer is currently answering the PHA Section.
- COMPLETED Indicates that the HealtheIntent consumer has finished answering the PHA section.
NOT_STARTED, IN_PROGRESS, COMPLETED, ENTERED_IN_ERROR
answers [PhaAnswer] false The answers given by the HealtheIntent consumer to questions in the PHA section. -

PhaAnswer

Name Type Required Description Accepted Values
id string true The ID of the PHA answer. -
question PhaQuestionReference true A reference to the PHA question that is answered. -
values [AnswerValue] true The values of the answer. -

AnswerValue

Name Type Required Description Accepted Values
option OptionReference false A reference to the option that is chosen as the answer. -
value string false A value that represents the answer to the question. The following values are accepted for different types of questions:
- TEXT A long, potentially multiparagraph free-text answer. The maximum length is 65,535 characters.
- STRING A short free-text answer. The maximum length is 255 characters.
- DATE_TIME A date and time answer in ISO 8601 YYYY-MM-DDThh:mm:ssTZD format.
- CHOICE No answer value can be specified for this type of question.
- DATE A date answer in ISO 8601 YYYY-MM-DD format.
- OPEN_CHOICE A long, potentially multiparagraph free-text answer that is paired with options. The maximum length is 65,535 characters.
- RANGE A number between a high and a low value specified by the question with a precision that does not exceed 10 and a scale that does not exceed 3.
-

OptionReference

Name Type Required Description Accepted Values
id string true The ID of the option. -

postPhaResponseDefinitionsPharesponsedefinitionidResponseSections

Name Type Required Description Accepted Values
status string false The current state of the PHA response section. Currently, the following statuses are supported:
- NOT_STARTED Indicates that the HealtheIntent consumer has not started answering the PHA section.
- IN_PROGRESS Indicates that the HealtheIntent consumer is currently answering the PHA Section.
- COMPLETED Indicates that the HealtheIntent consumer has finished answering the PHA section.
NOT_STARTED, IN_PROGRESS, COMPLETED, ENTERED_IN_ERROR
section object true A reference to the PHA section. -
» id string true The ID of the PHA section. -
answers [object] false The answers given by the HealtheIntent consumer to questions in the PHA section. -
» question [object] true A reference to the PHA question that is answered. -
»» id string true The ID of the PHA question. -
» values [object] true The values of the answer. -
»» option [object] false A reference to the option that is chosen as the answer. -
»»» id string true The ID of the PHA option. -
»» value string false A value that represents the answer to the question. The following values are accepted for different types of questions:
- TEXT A long, potentially multiparagraph free-text answer. The maximum length is 65,535 characters.
- STRING A short free-text answer. The maximum length is 255 characters.
- DATE_TIME A date and time answer in ISO 8601 YYYY-MM-DDThh:mm:ssTZD format.
- CHOICE No answer value can be specified for this type of question.
- DATE A date answer in ISO 8601 YYYY-MM-DD format.
- OPEN_CHOICE A long, potentially multiparagraph free-text answer that is paired with options. The maximum length is 65,535 characters.
- RANGE A number between a high and a low value specified by the question with a precision that does not exceed 10 and a scale that does not exceed 3.
-

putPhaResponseDefinitionsPharesponsedefinitionidResponseSections

Name Type Required Description Accepted Values
status string false The current state of the PHA response section. Currently, the following statuses are supported:
- NOT_STARTED Indicates that the HealtheIntent consumer has not started answering the PHA section.
- IN_PROGRESS Indicates that the HealtheIntent consumer is currently answering the PHA Section.
- COMPLETED Indicates that the HealtheIntent consumer has finished answering the PHA section.
NOT_STARTED, IN_PROGRESS, COMPLETED, ENTERED_IN_ERROR
section object true A reference to the PHA section. -
» id string true The ID of the PHA section. -
answers [object] false The answers given by the HealtheIntent consumer to questions in the PHA section. -
» question [object] true A reference to the PHA question that is answered. -
»» id string true The ID of the PHA question. -
» values [object] true The values of the answer. -
»» option [object] false A reference to the option that is chosen as the answer. -
»»» id string true The ID of the PHA option. -
»» value string false A value that represents the answer to the question. The following values are accepted for different types of questions:
- TEXT A long, potentially multiparagraph free-text answer. The maximum length is 65,535 characters.
- STRING A short free-text answer. The maximum length is 255 characters.
- DATE_TIME A date and time answer in ISO 8601 YYYY-MM-DDThh:mm:ssTZD format.
- CHOICE No answer value can be specified for this type of question.
- DATE A date answer in ISO 8601 YYYY-MM-DD format.
- OPEN_CHOICE A long, potentially multiparagraph free-text answer that is paired with options. The maximum length is 65,535 characters.
- RANGE A number between a high and a low value specified by the question with a precision that does not exceed 10 and a scale that does not exceed 3.
-

PhaResponseSubsections

Name Type Required Description Accepted Values
items [PhaResponseSubsection] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

PhaResponseSubsection

Name Type Required Description Accepted Values
id string true The ID of the PHA response subsection. -
status string true The current state of the PHA response subsection. Currently, the following statuses are supported:
- NOT_STARTED Indicates that the HealtheIntent consumer has not started answering the PHA subsection.
- IN_PROGRESS Indicates that the HealtheIntent consumer is currently answering the PHA subsection.
- COMPLETED Indicates that the HealtheIntent consumer has finished answering the PHA subsection.
NOT_STARTED, IN_PROGRESS, COMPLETED, ENTERED_IN_ERROR
subsection PhaSubsectionReference true A reference to the PHA subsection. -
answers [PhaAnswer] false The answers given by the HealtheIntent consumer to questions in the PHA subsection. -

postPhaResponseDefinitionsPharesponsedefinitionidResponseSubsections

Name Type Required Description Accepted Values
subsection object true A reference to the PHA subsection. -
» id string true The ID of the PHA subsection. -
status string false The current state of the PHA response subsection. Currently, the following statuses are supported:
- NOT_STARTED Indicates that the HealtheIntent consumer has not started answering the PHA subsection.
- IN_PROGRESS Indicates that the HealtheIntent consumer is currently answering the PHA subsection.
- COMPLETED Indicates that the HealtheIntent consumer has finished answering the PHA subsection.
NOT_STARTED, IN_PROGRESS, COMPLETED, ENTERED_IN_ERROR
answers [object] false The answers given by the HealtheIntent consumer to questions in the PHA subsection. -
» question [object] true A reference to the PHA question that is answered. -
»» id string true The ID of the PHA question. -
» values [object] true The values of the answer. -
»» option [object] false A reference to the option that is chosen as the answer. -
»»» id string true The ID of the PHA option. -
»» value string false A value that represents the answer to the question. The following values are accepted for different types of questions:
- TEXT A long, potentially multiparagraph free-text answer. The maximum length is 65,535 characters.
- STRING A short free-text answer. The maximum length is 255 characters.
- DATE_TIME A date and time answer in ISO 8601 YYYY-MM-DDThh:mm:ssTZD format.
- CHOICE No answer value can be specified for this type of question.
- DATE A date answer in ISO 8601 YYYY-MM-DD format.
- OPEN_CHOICE A long, potentially multiparagraph free-text answer that is paired with options. The maximum length is 65,535 characters.
- RANGE A number between a high and a low value specified by the question with a precision that does not exceed 10 and a scale that does not exceed 3.
-

putPhaResponseDefinitionsPharesponsedefinitionidResponseSubsections

Name Type Required Description Accepted Values
subsection object true A reference to the PHA subsection. -
» id string true The ID of the PHA subsection. -
status string false The current state of the PHA response subsection. Currently, the following statuses are supported:
- NOT_STARTED Indicates that the HealtheIntent consumer has not started answering the PHA subsection.
- IN_PROGRESS Indicates that the HealtheIntent consumer is currently answering the PHA subsection.
- COMPLETED Indicates that the HealtheIntent consumer has finished answering the PHA subsection.
NOT_STARTED, IN_PROGRESS, COMPLETED, ENTERED_IN_ERROR
answers [object] false The answers given by the HealtheIntent consumer to questions in the PHA subsection. -
» question [object] true A reference to the PHA question that is answered. -
»» id string true The ID of the PHA question. -
» values [object] true The values of the answer. -
»» option [object] false A reference to the option that is chosen as the answer. -
»»» id string true The ID of the PHA option. -
»» value string false A value that represents the answer to the question. The following values are accepted for different types of questions:
- TEXT A long, potentially multiparagraph free-text answer. The maximum length is 65,535 characters.
- STRING A short free-text answer. The maximum length is 255 characters.
- DATE_TIME A date and time answer in ISO 8601 YYYY-MM-DDThh:mm:ssTZD format.
- CHOICE No answer value can be specified for this type of question.
- DATE A date answer in ISO 8601 YYYY-MM-DD format.
- OPEN_CHOICE A long, potentially multiparagraph free-text answer that is paired with options. The maximum length is 65,535 characters.
- RANGE A number between a high and a low value specified by the question with a precision that does not exceed 10 and a scale that does not exceed 3.
-

postCompletedPhaResponses

Name Type Required Description Accepted Values
phaResponse object true A reference to the completed PHA response. -
» id string true The ID of the PHA response definition. -

CompletedPhaResponse

Name Type Required Description Accepted Values
id string true The ID of the completed PHA response. -
phaResponse Response true A reference to the completed PHA response. -

Response

Name Type Required Description Accepted Values
id string true The ID of the PHA response definition. -
authoredAt string true The date and time when the PHA response was submitted or updated. The date and time must be in ISO 8601 YYYY-MM-DDThh:mm:ssTZD format, for example, 1997-07-16T19:20:30+01:00. -
publishedPhaDefinition PhaDefinitionReference true A reference to the PHA definition. -
consumer ConsumerReference true A reference to the HealtheIntent consumer. -
responseSections [ResponseSection] false Sections are structured groups in PHA responses that contain answers for a PHA. -
responseSubsections [ResponseSubsection] false Subsections are structured subgroups in PHA response sections that contain the answers for a PHA. -

ResponseSection

Name Type Required Description Accepted Values
id string true The ID of the PHA response section. -
section PhaSectionReference true A reference to the PHA section. -
status string true The current state of the PHA response section. Currently, the following statuses are supported:
- NOT_STARTED Indicates that the HealtheIntent consumer has not started answering the PHA section.
- IN_PROGRESS Indicates that the HealtheIntent consumer is currently answering the PHA Section.
- COMPLETED Indicates that the HealtheIntent consumer has finished answering the PHA section.
NOT_STARTED, IN_PROGRESS, COMPLETED, ENTERED_IN_ERROR
answers [PhaAnswer] false The answers given by the HealtheIntent consumer to questions in the PHA section. -

ResponseSubsection

Name Type Required Description Accepted Values
id string true The ID of the PHA response subsection. -
status string true The current state of the PHA response subsection. Currently, the following statuses are supported:
- NOT_STARTED Indicates that the HealtheIntent consumer has not started answering the PHA subsection.
- IN_PROGRESS Indicates that the HealtheIntent consumer is currently answering the PHA subsection.
- COMPLETED Indicates that the HealtheIntent consumer has finished answering the PHA subsection.
NOT_STARTED, IN_PROGRESS, COMPLETED, ENTERED_IN_ERROR
subsection PhaSubsectionReference true A reference to the PHA subsection. -
answers [PhaAnswer] false The answers given by the HealtheIntent consumer to questions in the PHA subsection. -

CompletionCriterions

Name Type Required Description Accepted Values
items [CompletionCriterion] true An array containing the current page of results. -
totalResults integer(int32) false The total number of results for the specified parameters. -
firstLink string true The first page of results. -
lastLink string false The last page of results. -
prevLink string false The previous page of results. -
nextLink string false The next page of results. -

CompletionCriterion

Name Type Required Description Accepted Values
id string true The ID of the completion criterion. -
code ScreeningCode true The code of the screening configuration from a single, specified code system. -

ScreeningCode

Name Type Required Description Accepted Values
code string true The unique ID of the code. -
system string true The ID of the coding system that gives meaning to the code. -

postScreeningResultsCompletionCriteria

Name Type Required Description Accepted Values
code object true The code of the screening configuration from a single, specified code system. -
» code string true The unique ID of the code. -
» system string true The ID of the coding system that gives meaning to the code. -

putScreeningResultsCompletionCriteria

Name Type Required Description Accepted Values
code object true The code of the screening configuration from a single, specified code system. -
» code string true The unique ID of the code. -
» system string true The ID of the coding system that gives meaning to the code. -

PhaResponseDefinitionReference

Name Type Required Description Accepted Values
id string true The ID of the PHA response definition. -

PhaResponseSectionReference

Name Type Required Description Accepted Values
id string true The ID of the PHA response section. -

PhaResponseSubsectionReference

Name Type Required Description Accepted Values
id string true The ID of the PHA response subsection. -