NAV
Ruby Shell

Consumer Engagement API v1

The Consumer Engagement service provides a way to directly interact with your consumers to encourage them to be involved and invested in their health journeys. This service allows you to inform and update consumers, coordinate events and challenges, and provide interactive educational content.

URL: https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1

Event

An event is an activity that is intended to support the discovery and development of healthy habits. The event resources can be used to create and manage single session and multisession events to engage consumers. In addition, they can be used to send outreach emails to consumers registered for an event on a specific date in future.

Create an Event Location

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-1.healtheintent.com/consumer-engagement/v1/event-locations', headers: headers, body: {"name":"Innovations Healthe Clinic","names":[{"locale":"en-US","value":"Localized value."}],"description":"Clinic located in the North tower lobby of the Cerner Innovations Campus.","descriptions":[{"locale":"en-US","value":"Localized value."}],"address":{"lines":["8779 Hillcrest Road","Innovations Campus"],"city":"Kansas City","district":"Jackson County","state":"MO","country":"US","postalCode":"64138"},"restrictedToCatalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-locations \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Innovations Healthe Clinic","names":[{"locale":"en-US","value":"Localized value."}],"description":"Clinic located in the North tower lobby of the Cerner Innovations Campus.","descriptions":[{"locale":"en-US","value":"Localized value."}],"address":{"lines":["8779 Hillcrest Road","Innovations Campus"],"city":"Kansas City","district":"Jackson County","state":"MO","country":"US","postalCode":"64138"},"restrictedToCatalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}]}

POST /event-locations

Creates a new event location where an event can be held. The event location represents a physical or virtual address.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created. ConsumerEngagementPublicApi_Entities_V1_Events_Location
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a List of Event Locations

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-1.healtheintent.com/consumer-engagement/v1/event-locations', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "cea6f1d9-f986-4695-be33-0c2034579323",
      "name": "Innovations Healthe Clinic",
      "description": "Clinic located in the North tower lobby of the Cerner Innovations Campus.",
      "names": [
        {
          "locale": "en-US",
          "value": "Localized value."
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "value": "Localized value."
        }
      ],
      "address": {
        "lines": [
          "8779 Hillcrest Road",
          "Innovations Campus"
        ],
        "city": "Kansas City",
        "district": "Jackson County",
        "state": "MO",
        "country": "US",
        "postalCode": "64138"
      },
      "restrictedToCatalogs": [
        {
          "id": "cef0be9e-9bec-4f5e-8004-0252cab4b991"
        }
      ]
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-locations?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-locations?offset=0&limit=20"
}

GET /event-locations

Retrieves all of the event locations where an event can be held.

Parameters

Parameter In Type Required Default Description Accepted Values
availableForCatalog query array[string] false N/A Filters by those locations available for the specified catalog. -
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. Locations
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Update an Event Location

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-1.healtheintent.com/consumer-engagement/v1/event-locations/cea6f1d9-f986-4695-be33-0c2034579323', headers: headers, body: {"name":"Innovations Healthe Clinic","names":[{"locale":"en-US","value":"Localized value."}],"description":"Clinic located in the North tower lobby of the Cerner Innovations Campus.","descriptions":[{"locale":"en-US","value":"Localized value."}],"address":{"lines":["8779 Hillcrest Road","Innovations Campus"],"city":"Kansas City","district":"Jackson County","state":"MO","country":"US","postalCode":"64138"},"restrictedToCatalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-locations/cea6f1d9-f986-4695-be33-0c2034579323 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Innovations Healthe Clinic","names":[{"locale":"en-US","value":"Localized value."}],"description":"Clinic located in the North tower lobby of the Cerner Innovations Campus.","descriptions":[{"locale":"en-US","value":"Localized value."}],"address":{"lines":["8779 Hillcrest Road","Innovations Campus"],"city":"Kansas City","district":"Jackson County","state":"MO","country":"US","postalCode":"64138"},"restrictedToCatalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}]}

PUT /event-locations/{locationId}

Updates the information for an event location.

Parameters

Parameter In Type Required Default Description Accepted Values
locationId path string true N/A The ID of the location. -
body body putEventLocations true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated. ConsumerEngagementPublicApi_Entities_V1_Events_Location
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Single Event Location

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-1.healtheintent.com/consumer-engagement/v1/event-locations/cea6f1d9-f986-4695-be33-0c2034579323', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-locations/cea6f1d9-f986-4695-be33-0c2034579323 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

GET /event-locations/{locationId}

Retrieves an event location by its ID. Used to retrieve information for a single event location.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success. ConsumerEngagementPublicApi_Entities_V1_Events_Location
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Create an Event 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-1.healtheintent.com/consumer-engagement/v1/event-categories', headers: headers, body: {"name":"Preventive Health","names":[{"locale":"en-US","value":"Localized value."}],"code":{"code":"310422005","display":"Prevention/screening","system":"2.16.840.1.113883.6.96"},"restrictedToCatalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-categories \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Preventive Health","names":[{"locale":"en-US","value":"Localized value."}],"code":{"code":"310422005","display":"Prevention/screening","system":"2.16.840.1.113883.6.96"},"restrictedToCatalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}]}

POST /event-categories

Creates a new event category that classifies events. The event category groups events based on the event’s classification.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created. ConsumerEngagementPublicApi_Entities_V1_Events_Category
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a List of Event Categories

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-1.healtheintent.com/consumer-engagement/v1/event-categories', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "da4cac69-462d-4e3e-8870-a39fad628354",
      "name": "Preventive Health",
      "names": [
        {
          "locale": "en-US",
          "value": "Localized value."
        }
      ],
      "code": {
        "code": "310422005",
        "display": "Prevention/screening",
        "system": "2.16.840.1.113883.6.96"
      },
      "restrictedToCatalogs": [
        {
          "id": "cef0be9e-9bec-4f5e-8004-0252cab4b991"
        }
      ]
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-categories?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-categories?offset=0&limit=20"
}

GET /event-categories

Retrieves all of the event categories that can classify an event.

Parameters

Parameter In Type Required Default Description Accepted Values
availableForCatalog query array[string] false N/A Filters by those categories available for the specified catalog. -
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. Categories
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Update an Event 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.put('https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-categories/da4cac69-462d-4e3e-8870-a39fad628354', headers: headers, body: {"name":"Preventive Health","names":[{"locale":"en-US","value":"Localized value."}],"code":{"code":"310422005","display":"Prevention/screening","system":"2.16.840.1.113883.6.96"},"restrictedToCatalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-categories/da4cac69-462d-4e3e-8870-a39fad628354 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Preventive Health","names":[{"locale":"en-US","value":"Localized value."}],"code":{"code":"310422005","display":"Prevention/screening","system":"2.16.840.1.113883.6.96"},"restrictedToCatalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}]}

PUT /event-categories/{categoryId}

Updates the information for an event category.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Updated. ConsumerEngagementPublicApi_Entities_V1_Events_Category
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Single Event 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-1.healtheintent.com/consumer-engagement/v1/event-categories/da4cac69-462d-4e3e-8870-a39fad628354', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-categories/da4cac69-462d-4e3e-8870-a39fad628354 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

GET /event-categories/{categoryId}

Retrieves an event category by its ID. Used to retrieve information for a single event category.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success. ConsumerEngagementPublicApi_Entities_V1_Events_Category
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Create an Event Catalog

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-1.healtheintent.com/consumer-engagement/v1/event-catalogs', headers: headers, body: {"name":"2019 Incentivized Events Catalog","description":"Catalog to group incentivized events in 2019."}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-catalogs \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"2019 Incentivized Events Catalog","description":"Catalog to group incentivized events in 2019."}

POST /event-catalogs

Creates a new event catalog that can group events and event series. Events and event series can be included in event catalogs to group the events and event series. To remove an event or event series from an event catalog, the event or event series must be updated to remove the event catalog reference.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created. ConsumerEngagementPublicApi_Entities_V1_Events_Catalog
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a List of Event Catalogs

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-1.healtheintent.com/consumer-engagement/v1/event-catalogs', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "cef0be9e-9bec-4f5e-8004-0252cab4b991",
      "name": "2019 Incentivized Events Catalog",
      "description": "Catalog to group incentivized events in 2019."
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-catalogs?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-catalogs?offset=0&limit=20"
}

GET /event-catalogs

Retrieves all of the event catalogs that can group events and event series.

Parameters

Parameter In Type Required Default Description Accepted Values
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. Catalogs
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Update an Event Catalog

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-1.healtheintent.com/consumer-engagement/v1/event-catalogs/cef0be9e-9bec-4f5e-8004-0252cab4b991', headers: headers, body: {"name":"2019 Incentivized Events Catalog","description":"Catalog to group incentivized events in 2019."}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-catalogs/cef0be9e-9bec-4f5e-8004-0252cab4b991 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"2019 Incentivized Events Catalog","description":"Catalog to group incentivized events in 2019."}

PUT /event-catalogs/{catalogId}

Updates the information for an event catalog.

Parameters

Parameter In Type Required Default Description Accepted Values
catalogId path string true N/A The ID of the catalog. -
body body putEventCatalogs true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated. ConsumerEngagementPublicApi_Entities_V1_Events_Catalog
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve an Event Catalog

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-1.healtheintent.com/consumer-engagement/v1/event-catalogs/cef0be9e-9bec-4f5e-8004-0252cab4b991', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-catalogs/cef0be9e-9bec-4f5e-8004-0252cab4b991 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

GET /event-catalogs/{catalogId}

Retrieves an event catalog by its ID. Used to retrieve information for a single event catalog.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success. ConsumerEngagementPublicApi_Entities_V1_Events_Catalog
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Create an Event

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-1.healtheintent.com/consumer-engagement/v1/events', headers: headers, body: {"name":"Stress Management Seminar 2019","description":"This seminar is designed to contribute to the mental health development of individuals. Attendees will learn techniques to manage and cope with stressful situations.","names":[{"locale":"en-US","value":"Localized value."}],"descriptions":[{"locale":"en-US","value":"Localized value."}],"leader":{"name":"Dr. Jane Elizabeth Smith","telecoms":[{"system":"EMAIL","value":"jane.smith@rockhurst.edu"}]},"registrationStatus":"OPEN","startsAt":"2019-01-15T08:00:00","endsAt":"2019-10-15T16:00:00","timeZone":"America/New_York","multislot":true,"status":"ACTIVE","location":{"id":"cea6f1d9-f986-4695-be33-0c2034579323"},"category":{"id":"da4cac69-462d-4e3e-8870-a39fad628354"},"catalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}],"series":{"id":"11a3bbec-5378-47ac-89bb-b03b5dcec1cf"},"scopes":[{"id":"gtf0tg5e-7hnt-44re-6623-2789htb4b465"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/events \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Stress Management Seminar 2019","description":"This seminar is designed to contribute to the mental health development of individuals. Attendees will learn techniques to manage and cope with stressful situations.","names":[{"locale":"en-US","value":"Localized value."}],"descriptions":[{"locale":"en-US","value":"Localized value."}],"leader":{"name":"Dr. Jane Elizabeth Smith","telecoms":[{"system":"EMAIL","value":"jane.smith@rockhurst.edu"}]},"registrationStatus":"OPEN","startsAt":"2019-01-15T08:00:00","endsAt":"2019-10-15T16:00:00","timeZone":"America/New_York","multislot":true,"status":"ACTIVE","location":{"id":"cea6f1d9-f986-4695-be33-0c2034579323"},"category":{"id":"da4cac69-462d-4e3e-8870-a39fad628354"},"catalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}],"series":{"id":"11a3bbec-5378-47ac-89bb-b03b5dcec1cf"},"scopes":[{"id":"gtf0tg5e-7hnt-44re-6623-2789htb4b465"}]}

POST /events

Creates a new event, which allows consumers to view information about the event. For a consumer to register for the event, an event slot must be created.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created. ConsumerEngagementPublicApi_Entities_V1_Events_Event
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a List of Events

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-1.healtheintent.com/consumer-engagement/v1/events', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8",
      "name": "Stress Management Seminar 2019",
      "description": "This seminar is designed to contribute to the mental health development of individuals. Attendees will learn techniques to manage and cope with stressful situations.",
      "names": [
        {
          "locale": "en-US",
          "value": "Localized value."
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "value": "Localized value."
        }
      ],
      "leader": {
        "name": "Dr. Jane Elizabeth Smith",
        "telecoms": [
          {
            "system": "EMAIL",
            "value": "jane.smith@rockhurst.edu"
          }
        ]
      },
      "registrationStatus": "OPEN",
      "startsAt": "2019-01-15T08:00:00",
      "endsAt": "2019-10-15T16:00:00",
      "timeZone": "America/New_York",
      "multislot": true,
      "location": {
        "id": "cea6f1d9-f986-4695-be33-0c2034579323",
        "name": "Innovations Healthe Clinic",
        "description": "Clinic located in the North tower lobby of the Cerner Innovations Campus.",
        "names": [
          {
            "locale": "en-US",
            "value": "Localized value."
          }
        ],
        "descriptions": [
          {
            "locale": "en-US",
            "value": "Localized value."
          }
        ],
        "address": {
          "lines": [
            "8779 Hillcrest Road",
            "Innovations Campus"
          ],
          "city": "Kansas City",
          "district": "Jackson County",
          "state": "MO",
          "country": "US",
          "postalCode": "64138"
        },
        "restrictedToCatalogs": [
          {
            "id": "cef0be9e-9bec-4f5e-8004-0252cab4b991"
          }
        ]
      },
      "category": {
        "id": "da4cac69-462d-4e3e-8870-a39fad628354",
        "name": "Preventive Health",
        "names": [
          {
            "locale": "en-US",
            "value": "Localized value."
          }
        ],
        "code": {
          "code": "310422005",
          "display": "Prevention/screening",
          "system": "2.16.840.1.113883.6.96"
        },
        "restrictedToCatalogs": [
          {
            "id": "cef0be9e-9bec-4f5e-8004-0252cab4b991"
          }
        ]
      },
      "catalogs": [
        {
          "id": "cef0be9e-9bec-4f5e-8004-0252cab4b991"
        }
      ],
      "series": {
        "id": "11a3bbec-5378-47ac-89bb-b03b5dcec1cf"
      },
      "scopes": [
        {
          "id": "gtf0tg5e-7hnt-44re-6623-2789htb4b465"
        }
      ],
      "status": "ACTIVE"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/events?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/events?offset=0&limit=20"
}

GET /events

Retrieves all of the events that meet the specified parameters. Used to display available events to consumers. The retrieved events include the location and category information.

Parameters

Parameter In Type Required Default Description Accepted Values
from query string false N/A Filters the retrieved events to only those with at least one slot whose start time is on or after the specified date and time. The value must be in ISO 8601 YYYY-MM-DDThh:mm:ssZ format. -
to query string false N/A Filters the retrieved events to only those with at least one slot whose end time is on or before the specified date and time. The value must be in ISO 8601 YYYY-MM-DDThh:mm:ssZ format. -
categoryId query string false N/A Filters by the ID of the category. -
locationId query string false N/A Filters by the ID of the location. -
registrationStatus query string false N/A Filters by the registration status of the event. If the registration status is OPEN, only events that take place in the future are returned. -
catalogId query array[string] false N/A Filters by the ID of the catalog. -
scopeId query array[string] false N/A Filters by the ID of the scope. -
seriesId query array[string] false N/A Filters by the ID or IDs of one or many series. -
partOfSeries query boolean false N/A Filters the retrieved events to only those that are part of a series. -
status query string false N/A Filters by the status of the event. -
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. Events
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Update an Event

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-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8', headers: headers, body: {"name":"Stress Management Seminar 2019","description":"This seminar is designed to contribute to the mental health development of individuals. Attendees will learn techniques to manage and cope with stressful situations.","names":[{"locale":"en-US","value":"Localized value."}],"descriptions":[{"locale":"en-US","value":"Localized value."}],"leader":{"name":"Dr. Jane Elizabeth Smith","telecoms":[{"system":"EMAIL","value":"jane.smith@rockhurst.edu"}]},"registrationStatus":"OPEN","startsAt":"2019-01-15T08:00:00","endsAt":"2019-10-15T16:00:00","timeZone":"America/New_York","multislot":true,"status":"ACTIVE","location":{"id":"cea6f1d9-f986-4695-be33-0c2034579323"},"category":{"id":"da4cac69-462d-4e3e-8870-a39fad628354"},"catalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}],"series":{"id":"11a3bbec-5378-47ac-89bb-b03b5dcec1cf"},"scopes":[{"id":"gtf0tg5e-7hnt-44re-6623-2789htb4b465"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Stress Management Seminar 2019","description":"This seminar is designed to contribute to the mental health development of individuals. Attendees will learn techniques to manage and cope with stressful situations.","names":[{"locale":"en-US","value":"Localized value."}],"descriptions":[{"locale":"en-US","value":"Localized value."}],"leader":{"name":"Dr. Jane Elizabeth Smith","telecoms":[{"system":"EMAIL","value":"jane.smith@rockhurst.edu"}]},"registrationStatus":"OPEN","startsAt":"2019-01-15T08:00:00","endsAt":"2019-10-15T16:00:00","timeZone":"America/New_York","multislot":true,"status":"ACTIVE","location":{"id":"cea6f1d9-f986-4695-be33-0c2034579323"},"category":{"id":"da4cac69-462d-4e3e-8870-a39fad628354"},"catalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}],"series":{"id":"11a3bbec-5378-47ac-89bb-b03b5dcec1cf"},"scopes":[{"id":"gtf0tg5e-7hnt-44re-6623-2789htb4b465"}]}

PUT /events/{eventId}

Updates information for an event as well as any series, catalog, location, and category associations. Any slots associated with the event are not affected by this update.

Parameters

Parameter In Type Required Default Description Accepted Values
eventId path string true N/A The ID of the event. -
body body putEvents true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated. ConsumerEngagementPublicApi_Entities_V1_Events_Event
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Delete an Event

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-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /events/{eventId}

Deletes an event. This request is intended for events that are created in error. Events with registrations cannot be deleted. If an event has registrations, the event should be updated to set the status field to CANCELLED.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content No Content ConsumerEngagementPublicApi_Entities_V1_Events_Event
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Single Event

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-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

GET /events/{eventId}

Retrieves a single event by its ID. Can be used to get information for a single event. This request retrieves only information about the Event resource. Location and category information is not included.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success. ConsumerEngagementPublicApi_Entities_V1_Events_Event
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Create an Event Slot

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-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8/slots', headers: headers, body: {"description":"The session will begin at 8:00 a.m. and is expected to end by 4:00 p.m. Light breakfast and lunch will be provided. Please let us know if you have any dietary restrictions.","descriptions":[{"locale":"en-US","value":"Localized value."}],"maxRegistrations":100,"startsAt":"2019-09-15T08:00:00","endsAt":"2019-09-15T16:00:00","registrationEndsAt":"2019-09-14T08:00:00","timeZone":"America/New_York","status":"ACTIVE"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8/slots \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"description":"The session will begin at 8:00 a.m. and is expected to end by 4:00 p.m. Light breakfast and lunch will be provided. Please let us know if you have any dietary restrictions.","descriptions":[{"locale":"en-US","value":"Localized value."}],"maxRegistrations":100,"startsAt":"2019-09-15T08:00:00","endsAt":"2019-09-15T16:00:00","registrationEndsAt":"2019-09-14T08:00:00","timeZone":"America/New_York","status":"ACTIVE"}

POST /events/{eventId}/slots

Creates a new event slot for an event. An event slot provides the period of time when the event is hosted as well as registration information.

Parameters

Parameter In Type Required Default Description Accepted Values
eventId path string true N/A The ID of the event. -
body body postEventsEventidSlots true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created. ConsumerEngagementPublicApi_Entities_V1_Events_Slot
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a List of Event Slots

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-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8/slots', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8/slots \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "337c98f3-b1aa-4ab2-9c9c-1a973457cfe7",
      "description": "The session will begin at 8:00 a.m. and is expected to end by 4:00 p.m. Light breakfast and lunch will be provided. Please let us know if you have any dietary restrictions.",
      "descriptions": [
        {
          "locale": "en-US",
          "value": "Localized value."
        }
      ],
      "maxRegistrations": 100,
      "availableRegistrations": 100,
      "startsAt": "2019-09-15T08:00:00",
      "endsAt": "2019-09-15T16:00:00",
      "registrationEndsAt": "2019-09-14T08:00:00",
      "timeZone": "America/New_York",
      "status": "ACTIVE"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8/slots?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8/slots?offset=0&limit=20"
}

GET /events/{eventId}/slots

Retrieves all of the event slots for the specified event ID. Can be used to display the event slots to a consumer.

Parameters

Parameter In Type Required Default Description Accepted Values
eventId path string true N/A The ID of the event. -
status query string false N/A Filters by the status of the slot. -
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. Slots
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Update an Event Slot

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-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8/slots/337c98f3-b1aa-4ab2-9c9c-1a973457cfe7', headers: headers, body: {"description":"The session will begin at 8:00 a.m. and is expected to end by 4:00 p.m. Light breakfast and lunch will be provided. Please let us know if you have any dietary restrictions.","descriptions":[{"locale":"en-US","value":"Localized value."}],"maxRegistrations":100,"startsAt":"2019-09-15T08:00:00","endsAt":"2019-09-15T16:00:00","registrationEndsAt":"2019-09-14T08:00:00","timeZone":"America/New_York","status":"ACTIVE"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8/slots/337c98f3-b1aa-4ab2-9c9c-1a973457cfe7 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"description":"The session will begin at 8:00 a.m. and is expected to end by 4:00 p.m. Light breakfast and lunch will be provided. Please let us know if you have any dietary restrictions.","descriptions":[{"locale":"en-US","value":"Localized value."}],"maxRegistrations":100,"startsAt":"2019-09-15T08:00:00","endsAt":"2019-09-15T16:00:00","registrationEndsAt":"2019-09-14T08:00:00","timeZone":"America/New_York","status":"ACTIVE"}

PUT /events/{eventId}/slots/{slotId}

Updates the information for an event slot. The event that the event slot belongs to is not affected by this update.

Parameters

Parameter In Type Required Default Description Accepted Values
eventId path string true N/A The ID of the event. -
slotId path string true N/A The ID of the event slot. -
body body putEventsEventidSlots true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated. ConsumerEngagementPublicApi_Entities_V1_Events_Slot
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Delete an Event Slot

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-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8/slots/337c98f3-b1aa-4ab2-9c9c-1a973457cfe7', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8/slots/337c98f3-b1aa-4ab2-9c9c-1a973457cfe7 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /events/{eventId}/slots/{slotId}

Deletes an event slot. This request is intended for event slots that are created in error. Event slots with registrations cannot be deleted. If an event slot has registrations, the event slot should be updated to set the status field to CANCELLED.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content No Content ConsumerEngagementPublicApi_Entities_V1_Events_Slot
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Single Event Slot

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-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8/slots/337c98f3-b1aa-4ab2-9c9c-1a973457cfe7', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/events/bf6357e2-57ea-4c8e-b79d-2c4f817fa4f8/slots/337c98f3-b1aa-4ab2-9c9c-1a973457cfe7 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

GET /events/{eventId}/slots/{slotId}

Retrieves a single event slot by its event and slot IDs. Can be used to retrieve information for a single event slot.

Parameters

Parameter In Type Required Default Description Accepted Values
eventId path string true N/A The ID of the event. -
slotId path string true N/A The ID of the event slot. -

Response Statuses

Status Meaning Description Schema
200 OK Success. ConsumerEngagementPublicApi_Entities_V1_Events_Slot
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Create Multiple Slots for an Event

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-1.healtheintent.com/consumer-engagement/v1/event-slots', headers: headers, body: {"slots":[{"event":{"id":"35eb9e2d-0bb4-4e30-8245-fd07525da9fe"},"descriptions":[{"locale":"en-US","value":"Localized value."}],"maxRegistrations":100,"availableRegistrations":100,"startsAt":"2019-09-15T08:00:00","endsAt":"2019-09-15T16:00:00","registrationEndsAt":"2019-09-14T08:00:00","timeZone":"America/New_York","status":"ACTIVE"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-slots \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"slots":[{"event":{"id":"35eb9e2d-0bb4-4e30-8245-fd07525da9fe"},"descriptions":[{"locale":"en-US","value":"Localized value."}],"maxRegistrations":100,"availableRegistrations":100,"startsAt":"2019-09-15T08:00:00","endsAt":"2019-09-15T16:00:00","registrationEndsAt":"2019-09-14T08:00:00","timeZone":"America/New_York","status":"ACTIVE"}]}

POST /event-slots

Creates multiple slots for a single event. Each event slot shows the time when the event is hosted as well as registration information. The event is specified by its ID within the Post body, and the event ID for all slots should be the same. The ordering of the response will be the same as the ordering of the request. The request can contain as many slots necessary for a singular event. If one of the slots is invalid, no slots will be created.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created. ConsumerEngagementPublicApi_Entities_V1_Events_EventSlotList
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Create an Event Series

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-1.healtheintent.com/consumer-engagement/v1/event-series', headers: headers, body: {"name":"Screenings 2019","description":"Screening 2019 is a two-session event that involves body measurements and the collection of a small blood sample. The biometric screening results help provide detailed assessments of a person's health and improve health outcomes.","names":[{"locale":"en-US","value":"Localized value."}],"descriptions":[{"locale":"en-US","value":"Localized value."}],"leader":{"name":"Dr. Jane Elizabeth Smith","telecoms":[{"system":"EMAIL","value":"jane.smith@rockhurst.edu"}]},"registrationStatus":"OPEN","status":"ACTIVE","catalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}],"scopes":[{"id":"gtf0tg5e-7hnt-44re-6623-2789htb4b465"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-series \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Screenings 2019","description":"Screening 2019 is a two-session event that involves body measurements and the collection of a small blood sample. The biometric screening results help provide detailed assessments of a person's health and improve health outcomes.","names":[{"locale":"en-US","value":"Localized value."}],"descriptions":[{"locale":"en-US","value":"Localized value."}],"leader":{"name":"Dr. Jane Elizabeth Smith","telecoms":[{"system":"EMAIL","value":"jane.smith@rockhurst.edu"}]},"registrationStatus":"OPEN","status":"ACTIVE","catalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}],"scopes":[{"id":"gtf0tg5e-7hnt-44re-6623-2789htb4b465"}]}

POST /event-series

Creates a new event series, which groups events. An event series is used to link related events so they can be interacted with together.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created. ConsumerEngagementPublicApi_Entities_V1_Events_Series
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a List of Event Series

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-1.healtheintent.com/consumer-engagement/v1/event-series', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "86bf670f-36bb-4b6a-b597-2c811353b4c6",
      "name": "Screenings 2019",
      "description": "Screening 2019 is a two-session event that involves body measurements and the collection of a small blood sample. The biometric screening results help provide detailed assessments of a person's health and improve health outcomes.",
      "names": [
        {
          "locale": "en-US",
          "value": "Localized value."
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "value": "Localized value."
        }
      ],
      "registrationStatus": "OPEN",
      "leader": {
        "name": "Dr. Jane Elizabeth Smith",
        "telecoms": [
          {
            "system": "EMAIL",
            "value": "jane.smith@rockhurst.edu"
          }
        ]
      },
      "catalogs": [
        {
          "id": "cef0be9e-9bec-4f5e-8004-0252cab4b991"
        }
      ],
      "scopes": [
        {
          "id": "gtf0tg5e-7hnt-44re-6623-2789htb4b465"
        }
      ],
      "status": "ACTIVE"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-series?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-series?offset=0&limit=20"
}

GET /event-series

Retrieves all of the event series that meet the specified parameters. Can be used to display available event series to consumers.

Parameters

Parameter In Type Required Default Description Accepted Values
from query string false N/A Filters the retrieved series to only those with all events with at least one slot that starts on or after the specified date and time. The value must be in ISO 8601 YYYY-MM-DDThh:mm:ssZ format. If any event in the series starts after this date and time, the series is retrieved. -
to query string false N/A Filters the retrieved series to only those with all events with at least one slot that ends on or before the specified date and time. The value must be in ISO 8601 YYYY-MM-DDThh:mm:ssZ format. If any event in the series ends before this date and time, the series is retrieved. -
categoryId query string false N/A Filters by the ID of the category. If any event in the series is in this category, the series is retrieved. -
locationId query string false N/A Filters by the ID of the location. If any event in the series occurs at this location, the series is retrieved. -
registrationStatus query string false N/A Filters by the registration status of the series. If the registration status is OPEN, only series that take place in the future are returned. -
catalogId query array[string] false N/A Filters by the ID of the catalog. If any event in the series is in this catalog, the series is retrieved. -
scopeId query array[string] false N/A Filters by the ID of scope. If any event in the series is in this scope, the series is retrieved. -
eventId query string false N/A Filters by the ID of the event. If any event in the series has the ID that is specified for this query parameter, the series is retrieved. -
status query string false N/A Filters by the status of the event series. -
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. Series
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Update an Event Series

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-1.healtheintent.com/consumer-engagement/v1/event-series/86bf670f-36bb-4b6a-b597-2c811353b4c6', headers: headers, body: {"name":"Screenings 2019","description":"Screening 2019 is a two-session event that involves body measurements and the collection of a small blood sample. The biometric screening results help provide detailed assessments of a person's health and improve health outcomes.","names":[{"locale":"en-US","value":"Localized value."}],"descriptions":[{"locale":"en-US","value":"Localized value."}],"leader":{"name":"Dr. Jane Elizabeth Smith","telecoms":[{"system":"EMAIL","value":"jane.smith@rockhurst.edu"}]},"registrationStatus":"OPEN","status":"ACTIVE","catalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}],"scopes":[{"id":"gtf0tg5e-7hnt-44re-6623-2789htb4b465"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-series/86bf670f-36bb-4b6a-b597-2c811353b4c6 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Screenings 2019","description":"Screening 2019 is a two-session event that involves body measurements and the collection of a small blood sample. The biometric screening results help provide detailed assessments of a person's health and improve health outcomes.","names":[{"locale":"en-US","value":"Localized value."}],"descriptions":[{"locale":"en-US","value":"Localized value."}],"leader":{"name":"Dr. Jane Elizabeth Smith","telecoms":[{"system":"EMAIL","value":"jane.smith@rockhurst.edu"}]},"registrationStatus":"OPEN","status":"ACTIVE","catalogs":[{"id":"cef0be9e-9bec-4f5e-8004-0252cab4b991"}],"scopes":[{"id":"gtf0tg5e-7hnt-44re-6623-2789htb4b465"}]}

PUT /event-series/{seriesId}

Updates the information for an event series. Any events that are included in this event series are not affected by this update.

Parameters

Parameter In Type Required Default Description Accepted Values
seriesId path string true N/A The ID of the event series. -
body body putEventSeries true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated. ConsumerEngagementPublicApi_Entities_V1_Events_Series
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Delete an Event Series

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-1.healtheintent.com/consumer-engagement/v1/event-series/86bf670f-36bb-4b6a-b597-2c811353b4c6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-series/86bf670f-36bb-4b6a-b597-2c811353b4c6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /event-series/{seriesId}

Deletes an event series. This request is intended for event series that are created in error. Event series with registrations cannot be deleted. If an event series has registrations, the event series should be updated to set the status field to CANCELLED.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content No Content ConsumerEngagementPublicApi_Entities_V1_Events_Series
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Single Event Series

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-1.healtheintent.com/consumer-engagement/v1/event-series/86bf670f-36bb-4b6a-b597-2c811353b4c6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-series/86bf670f-36bb-4b6a-b597-2c811353b4c6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

GET /event-series/{seriesId}

Retrieves an event series by its ID. Can be used to retrieve information for a single event series.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success. ConsumerEngagementPublicApi_Entities_V1_Events_Series
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Create an Event Registration

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-1.healtheintent.com/consumer-engagement/v1/event-registrations', headers: headers, body: {"consumer":{"id":"08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"},"slot":{"id":"1914d1c6-43ca-4925-acd2-9183b3841312","event":{"id":"35eb9e2d-0bb4-4e30-8245-fd07525da9fe","seriesId":"11a3bbec-5378-47ac-89bb-b03b5dcec1cf"}}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-registrations \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"consumer":{"id":"08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"},"slot":{"id":"1914d1c6-43ca-4925-acd2-9183b3841312","event":{"id":"35eb9e2d-0bb4-4e30-8245-fd07525da9fe","seriesId":"11a3bbec-5378-47ac-89bb-b03b5dcec1cf"}}}

POST /event-registrations

Creates a new event registration, which reserves an event slot for a consumer. Can be used to plan for who is attending an event. When the event slot is full or the slot’s registration period is expired, an error is sent. If the associated event or event slot is updated, the event registration is retained.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created. ConsumerEngagementPublicApi_Entities_V1_Events_Registration
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a List of Event Registrations

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-1.healtheintent.com/consumer-engagement/v1/event-registrations', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "2c26d041-fb14-4d63-8d55-c59905c3de22",
      "consumer": {
        "id": "08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"
      },
      "slot": {
        "id": "1914d1c6-43ca-4925-acd2-9183b3841312",
        "event": {
          "id": "35eb9e2d-0bb4-4e30-8245-fd07525da9fe",
          "seriesId": "11a3bbec-5378-47ac-89bb-b03b5dcec1cf"
        }
      }
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-registrations?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-registrations?offset=0&limit=20"
}

GET /event-registrations

Retrieves all of the event registrations that meet the specified parameters. Can be used to display event registrations to a consumer or to plan for an event.

Parameters

Parameter In Type Required Default Description Accepted Values
eventId query string false N/A Filters by the ID of the event. If any event in the series has the ID that is specified for this query parameter, the series is retrieved. -
seriesId query string false N/A Filters by the ID of a series. -
slotId query string false N/A Filters by the ID of the event slot. -
consumerId query string false N/A Filters by 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. -

Response Statuses

Status Meaning Description Schema
200 OK Success. Registrations
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Delete an Event Registration

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-1.healtheintent.com/consumer-engagement/v1/event-registrations/2c26d041-fb14-4d63-8d55-c59905c3de22', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-registrations/2c26d041-fb14-4d63-8d55-c59905c3de22 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /event-registrations/{registrationId}

Deletes an event registration, which unregisters the consumer from the event slot.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Deleted. ConsumerEngagementPublicApi_Entities_V1_Events_Registration
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Single Event Registration

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-1.healtheintent.com/consumer-engagement/v1/event-registrations/2c26d041-fb14-4d63-8d55-c59905c3de22', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-registrations/2c26d041-fb14-4d63-8d55-c59905c3de22 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

GET /event-registrations/{registrationId}

Retrieves a single event registration by its ID. Can be used to retrieve information for a single event registration.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success. ConsumerEngagementPublicApi_Entities_V1_Events_Registration
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Create a List of Event Attendances

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-1.healtheintent.com/consumer-engagement/v1/event-attendances', headers: headers, body: {"attendances":[{"consumer":{"id":"08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"},"slot":{"id":"1914d1c6-43ca-4925-acd2-9183b3841312","event":{"id":"35eb9e2d-0bb4-4e30-8245-fd07525da9fe","seriesId":"11a3bbec-5378-47ac-89bb-b03b5dcec1cf"}}}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-attendances \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"attendances":[{"consumer":{"id":"08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"},"slot":{"id":"1914d1c6-43ca-4925-acd2-9183b3841312","event":{"id":"35eb9e2d-0bb4-4e30-8245-fd07525da9fe","seriesId":"11a3bbec-5378-47ac-89bb-b03b5dcec1cf"}}}]}

POST /event-attendances

Creates a list of event attendance, which records that the consumer attended the event. An event registration is not required to create an event attendance. If multiple attendances are passed to this call, and a single attendance fails, no attendances will be created.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created. ConsumerEngagementPublicApi_Entities_V1_Events_AttendanceList
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a List of Event Attendances

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-1.healtheintent.com/consumer-engagement/v1/event-attendances', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "e9c16850-0082-47eb-b091-ae4db5c70ecb",
      "consumer": {
        "id": "08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"
      },
      "slot": {
        "id": "1914d1c6-43ca-4925-acd2-9183b3841312",
        "event": {
          "id": "35eb9e2d-0bb4-4e30-8245-fd07525da9fe",
          "seriesId": "11a3bbec-5378-47ac-89bb-b03b5dcec1cf"
        }
      }
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-attendances?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-attendances?offset=0&limit=20"
}

GET /event-attendances

Retrieves all of the event attendances for an event that meet the specified parameters. Can be used to display event attendances for a consumer or to log who attended an event.

Parameters

Parameter In Type Required Default Description Accepted Values
eventId query string false N/A Filters by the ID of the event. If any event in the series has the ID that is specified for this query parameter, the series is retrieved. -
seriesId query string false N/A Filters by the ID of a series. -
slotId query string false N/A Filters by the ID of the event slot. -
consumerId query string false N/A Filters by 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. -

Response Statuses

Status Meaning Description Schema
200 OK Success. Attendances
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Delete an Event Attendance

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-1.healtheintent.com/consumer-engagement/v1/event-attendances/e9c16850-0082-47eb-b091-ae4db5c70ecb', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-attendances/e9c16850-0082-47eb-b091-ae4db5c70ecb \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /event-attendances/{attendanceId}

Deletes an event attendance, which indicates that the consumer did not attend the event.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Deleted. ConsumerEngagementPublicApi_Entities_V1_Events_Attendance
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Single Event Attendance

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-1.healtheintent.com/consumer-engagement/v1/event-attendances/e9c16850-0082-47eb-b091-ae4db5c70ecb', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-attendances/e9c16850-0082-47eb-b091-ae4db5c70ecb \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

GET /event-attendances/{attendanceId}

Retrieves a single event attendance by its ID. Used to retrieve information for a single event attendance.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success. ConsumerEngagementPublicApi_Entities_V1_Events_Attendance
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Create an Event Scope

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-1.healtheintent.com/consumer-engagement/v1/event-scopes', headers: headers, body: {"name":"2020 Incentivized Events Scope","kind":"Scope to group incentivized events in 2020.","consumerGroups":[{"id":"ea133b83-176c-4c7f-9f49-892521605164"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-scopes \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"2020 Incentivized Events Scope","kind":"Scope to group incentivized events in 2020.","consumerGroups":[{"id":"ea133b83-176c-4c7f-9f49-892521605164"}]}

POST /event-scopes

Creates a new event scope that can group events and event series. Events and event series can be included in event scopes to group the events and event series. To remove an event or event series from an event scope, the event or event series must be updated to remove the event scope reference.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created. ConsumerEngagementPublicApi_Entities_V1_Events_Scope
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a List of Event Scopes

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-1.healtheintent.com/consumer-engagement/v1/event-scopes', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "gtf0tg5e-7hnt-44re-6623-2789htb4b465",
      "name": "2020 Incentivized Events Scope",
      "kind": "Scope to group incentivized events in 2020.",
      "consumerGroups": [
        {
          "id": "ea133b83-176c-4c7f-9f49-892521605164"
        }
      ]
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-scopes?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-scopes?offset=0&limit=20"
}

GET /event-scopes

Retrieves all of the event scopes that can group events and event series.

Parameters

Parameter In Type Required Default Description Accepted Values
consumerGroupId query array[string] false N/A Filters by the ID of the consumer group. -
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. Scopes
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Delete an Event Scope

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-1.healtheintent.com/consumer-engagement/v1/event-scopes/gtf0tg5e-7hnt-44re-6623-2789htb4b465', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-scopes/gtf0tg5e-7hnt-44re-6623-2789htb4b465 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /event-scopes/{scopeId}

Deletes the single scope with the specified ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Deleted. ConsumerEngagementPublicApi_Entities_V1_Events_Scope
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Update an Event Scope

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-1.healtheintent.com/consumer-engagement/v1/event-scopes/gtf0tg5e-7hnt-44re-6623-2789htb4b465', headers: headers, body: {"name":"2020 Incentivized Events Scope","kind":"Scope to group incentivized events in 2020.","consumerGroups":[{"id":"ea133b83-176c-4c7f-9f49-892521605164"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-scopes/gtf0tg5e-7hnt-44re-6623-2789htb4b465 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"2020 Incentivized Events Scope","kind":"Scope to group incentivized events in 2020.","consumerGroups":[{"id":"ea133b83-176c-4c7f-9f49-892521605164"}]}

PUT /event-scopes/{scopeId}

Updates the information for an event scope.

Parameters

Parameter In Type Required Default Description Accepted Values
scopeId path string true N/A The ID of the scope. -
body body putEventScopes true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated. ConsumerEngagementPublicApi_Entities_V1_Events_Scope
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Single Event Scope

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-1.healtheintent.com/consumer-engagement/v1/event-scopes/gtf0tg5e-7hnt-44re-6623-2789htb4b465', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-scopes/gtf0tg5e-7hnt-44re-6623-2789htb4b465 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

GET /event-scopes/{scopeId}

Retrieves an event scope by its ID. This is used to retrieve information for a single event scope.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success. ConsumerEngagementPublicApi_Entities_V1_Events_Scope
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Create an Event Email Notification

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-1.healtheintent.com/consumer-engagement/v1/event-email-notifications', headers: headers, body: {"eventId":"94b44ea3-fb6b-4245-886b-caa8e156f125","locale":"en-US","emailSubject":"Take the First Step to Investing","emailBody":"<!DOCTYPE html>\\n<html lang=\\\"en\\\">\\n <head>\\n <meta charset=\\\"utf-8\\\" />\\n <p> Hi {{first_name}},</p>\\n <p> <html>Join Fidelity, our 401(k) record keeper, as they dive into investing. Learn key investing concepts, common investment types and how to choose your investment approach</html>.</p>\\n","sendNotificationOn":"2020-03-05"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-email-notifications \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"eventId":"94b44ea3-fb6b-4245-886b-caa8e156f125","locale":"en-US","emailSubject":"Take the First Step to Investing","emailBody":"<!DOCTYPE html>\\n<html lang=\\\"en\\\">\\n <head>\\n <meta charset=\\\"utf-8\\\" />\\n <p> Hi {{first_name}},</p>\\n <p> <html>Join Fidelity, our 401(k) record keeper, as they dive into investing. Learn key investing concepts, common investment types and how to choose your investment approach</html>.</p>\\n","sendNotificationOn":"2020-03-05"}

Example response

{
  "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "locale": "en-US",
  "eventId": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "emailSubject": "Things to do before ths start of event.",
  "emailBody": "<!DOCTYPE html>\\n<html lang=\\\"en\\\">\\n <head>\\n <meta charset=\\\"utf-8\\\" />\\n <p> Hi {{first_name}},</p>\\n <p> <html>Event begins in 3 days. Check out the things to complete before the start of this event</html>.</p>\\n",
  "sendNotificationOn": "2020-03-05",
  "notificationStatus": "NOT_SENT",
  "qualifiedConsumersCount": 2000,
  "createdAt": "2020-06-01T10:00:00.000Z",
  "updatedAt": "2020-06-07T10:00:00.000Z",
  "notificationProcessedAt": "2020-06-11T00:00:00.000Z"
}

POST /event-email-notifications

Creates an event email notification. Email notifications are sent to all consumers registered in the event. Placeholders can be used to automatically personalize the content of the email. To add a placeholder, include it inside braces, for example, {{first_name}}. The supported placeholders include first_name and last_name.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Events_EventEmailNotification
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a List of Event Email Notifications

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-1.healtheintent.com/consumer-engagement/v1/event-email-notifications', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-email-notifications \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "locale": "en-US",
      "eventId": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "emailSubject": "Things to do before ths start of event.",
      "emailBody": "<!DOCTYPE html>\\n<html lang=\\\"en\\\">\\n <head>\\n <meta charset=\\\"utf-8\\\" />\\n <p> Hi {{first_name}},</p>\\n <p> <html>Event begins in 3 days. Check out the things to complete before the start of this event</html>.</p>\\n",
      "sendNotificationOn": "2020-03-05",
      "notificationStatus": "NOT_SENT",
      "qualifiedConsumersCount": 2000,
      "createdAt": "2020-06-01T10:00:00.000Z",
      "updatedAt": "2020-06-07T10:00:00.000Z",
      "notificationProcessedAt": "2020-06-11T00:00:00.000Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-email-notifications?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-email-notifications?offset=0&limit=20"
}

GET /event-email-notifications

Retrieves a list of event email notifications.

Parameters

Parameter In Type Required Default Description Accepted Values
notificationStatus query array[string] false N/A Filters the retrieved event email notifications by status. SENT, IN_PROGRESS, NOT_SENT
eventId query array[string] false N/A Filters the retrieved event email notifications by event ID. -
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 EventEmailNotifications
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Delete an Event Email Notification

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-1.healtheintent.com/consumer-engagement/v1/event-email-notifications/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-email-notifications/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /event-email-notifications/{eventEmailNotificationId}

Deletes the event email notification with the specified ID. If the notification is already sent or is in progress, it cannot be deleted.

Parameters

Parameter In Type Required Default Description Accepted Values
eventEmailNotificationId path string true N/A The ID of an event email notification. -

Response Statuses

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

Update an Event Email Notification

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-1.healtheintent.com/consumer-engagement/v1/event-email-notifications/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers, body: {"eventId":"94b44ea3-fb6b-4245-886b-caa8e156f125","locale":"en-US","emailSubject":"Take the First Step to Investing","emailBody":"<!DOCTYPE html>\\n<html lang=\\\"en\\\">\\n <head>\\n <meta charset=\\\"utf-8\\\" />\\n <p> Hi {{first_name}},</p>\\n <p> <html>Join Fidelity, our 401(k) record keeper, as they dive into investing. Learn key investing concepts, common investment types and how to choose your investment approach</html>.</p>\\n","sendNotificationOn":"2020-03-05"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-email-notifications/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"eventId":"94b44ea3-fb6b-4245-886b-caa8e156f125","locale":"en-US","emailSubject":"Take the First Step to Investing","emailBody":"<!DOCTYPE html>\\n<html lang=\\\"en\\\">\\n <head>\\n <meta charset=\\\"utf-8\\\" />\\n <p> Hi {{first_name}},</p>\\n <p> <html>Join Fidelity, our 401(k) record keeper, as they dive into investing. Learn key investing concepts, common investment types and how to choose your investment approach</html>.</p>\\n","sendNotificationOn":"2020-03-05"}

PUT /event-email-notifications/{eventEmailNotificationId}

Updates the event email notification with the specified ID using the given data. If an event email notification is in progress or sent, it can no longer be updated.

Parameters

Parameter In Type Required Default Description Accepted Values
eventEmailNotificationId path string true N/A The ID of an event email notification. -
body body putEventEmailNotifications true N/A No description -

Response Statuses

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

Retrieve a Single Event Email Notification

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-1.healtheintent.com/consumer-engagement/v1/event-email-notifications/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/event-email-notifications/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "locale": "en-US",
  "eventId": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "emailSubject": "Things to do before ths start of event.",
  "emailBody": "<!DOCTYPE html>\\n<html lang=\\\"en\\\">\\n <head>\\n <meta charset=\\\"utf-8\\\" />\\n <p> Hi {{first_name}},</p>\\n <p> <html>Event begins in 3 days. Check out the things to complete before the start of this event</html>.</p>\\n",
  "sendNotificationOn": "2020-03-05",
  "notificationStatus": "NOT_SENT",
  "qualifiedConsumersCount": 2000,
  "createdAt": "2020-06-01T10:00:00.000Z",
  "updatedAt": "2020-06-07T10:00:00.000Z",
  "notificationProcessedAt": "2020-06-11T00:00:00.000Z"
}

GET /event-email-notifications/{eventEmailNotificationId}

Retrieves a single event email notification by ID.

Parameters

Parameter In Type Required Default Description Accepted Values
eventEmailNotificationId path string true N/A The ID of an event email notification. -

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Events_EventEmailNotification
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Learning Module

A learning module is an organized collection of educational content.

Create a Learning Module

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-1.healtheintent.com/consumer-engagement/v1/learning-modules', headers: headers, body: {"definitionId":"77a233a3-54d4-4ad3-9e63-53bb71762290","imageUrl":"https://heathwise.edu/1.jpg","title":[{"locale":"en-US","text":"Diabetes Prevention"}],"description":[{"locale":"en-US","text":"A 12-week course to help you establish healthy weight practices and habits."}],"keywords":[{"locale":"en-US","text":["Diabetes","prevention"]}],"categories":["0276ea55-a3cc-4b0a-88dc-284629d"],"catalogs":[{"id":"7eddc0ad-dc15-4746-9a5c-73f1ea680f83"}],"consumerGroups":[{"id":"0276ea55-a3cc-4b0a-88dc-284629d6"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-modules \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"definitionId":"77a233a3-54d4-4ad3-9e63-53bb71762290","imageUrl":"https://heathwise.edu/1.jpg","title":[{"locale":"en-US","text":"Diabetes Prevention"}],"description":[{"locale":"en-US","text":"A 12-week course to help you establish healthy weight practices and habits."}],"keywords":[{"locale":"en-US","text":["Diabetes","prevention"]}],"categories":["0276ea55-a3cc-4b0a-88dc-284629d"],"catalogs":[{"id":"7eddc0ad-dc15-4746-9a5c-73f1ea680f83"}],"consumerGroups":[{"id":"0276ea55-a3cc-4b0a-88dc-284629d6"}]}

Example response

{
  "id": "11e8902c9e2908c69718f13503066bee",
  "definitionId": "77a233a3-54d4-4ad3-9e63-53bb71762290",
  "title": [
    {
      "locale": "en-US",
      "text": "Diabetes Prevention"
    }
  ],
  "description": [
    {
      "locale": "en-US",
      "text": "Diabetes Prevention"
    }
  ],
  "status": "DRAFT",
  "type": "CUSTOM",
  "imageUrl": "https://heathwise.edu/1.jpg",
  "keywords": [
    {
      "locale": "en-US",
      "text": [
        "Diabetes",
        "prevention"
      ]
    }
  ],
  "categories": [
    "0276ea55-a3cc-4b0a-88dc-284629d"
  ],
  "catalogs": [
    {
      "id": "7eddc0ad-dc15-4746-9a5c-73f1ea680f83"
    }
  ],
  "consumerGroups": [
    {
      "id": "0276ea55-a3cc-4b0a-88dc-284629d6"
    }
  ],
  "createdAt": "2018-12-15T12:23:12Z",
  "updatedAt": "2018-12-15T12:23:12Z"
}

POST /learning-modules

Creates a learning module.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created The learning module was created. ConsumerEngagementPublicApi_Entities_V1_LearningModules_Module
400 Bad Request Bad Request. The learning module 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 title.
- duplicateLocale The locale for the provided titles and descriptions must be unique.
- missingTitle Title is required. Specify a title for the locale and description to continue.
- catgoryNotFound The category was not found.
Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a List of Learning Modules

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-1.healtheintent.com/consumer-engagement/v1/learning-modules', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "11e8902c9e2908c69718f13503066bee",
      "title": [
        {
          "locale": "en-US",
          "text": "Diabetes Prevention"
        }
      ],
      "description": [
        {
          "locale": "en-US",
          "text": "A 12-week course to help you establish healthy weight practices and habits."
        }
      ],
      "status": "PUBLISHED",
      "type": "CUSTOM",
      "imageUrl": "https://heathwise.edu/1.jpg",
      "keywords": [
        {
          "locale": "en-US",
          "text": [
            "Diabetes",
            "prevention"
          ]
        }
      ],
      "categories": [
        "0276ea55-a3cc-4b0a-88dc-284629d"
      ],
      "catalogs": [
        {
          "id": "7eddc0ad-dc15-4746-9a5c-73f1ea680f83"
        }
      ],
      "consumerGroups": [
        {
          "id": "0276ea55-a3cc-4b0a-88dc-284629d6"
        }
      ],
      "createdAt": "2018-12-15T12:23:12Z",
      "updatedAt": "2018-12-15T12:23:12Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-modules?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-modules?offset=0&limit=20"
}

GET /learning-modules

Retrieves a list of learning modules.

Parameters

Parameter In Type Required Default Description Accepted Values
ids query array[string] false N/A Filters modules by module IDs. -
categoryIds query array[string] false N/A Filters modules by category IDs. -
keywords query array[string] false N/A Filters modules by keywords. -
searchTerms query string false N/A Filters the retrieved modules to those that contain specific text. Partial matching is supported. -
status query array[string] false N/A Filters modules by status. DRAFT, PUBLISHED, RETIRED
type query string false N/A Filters modules by type. STANDARD, CUSTOM
catalogId query array[string] false N/A Filters modules by catalog ID. -
consumerGroupId query array[string] false N/A Filters modules by consumer group ID. -
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. -
locale query string false en-US Filters modules by locale. -
orderBy query string false updatedAt A comma-separated list of fields by which to sort. updatedAt, -updatedAt, createdAt, -createdAt, status, title, -title

Response Statuses

Status Meaning Description Schema
200 OK OK TranslatedModules
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Delete a Learning Module

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-1.healtheintent.com/consumer-engagement/v1/learning-modules/11e8902c9e2908c69718f13503066bee', headers: headers)

print JSON.pretty_generate(result)


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

DELETE /learning-modules/{moduleId}

Deletes a single learning module by ID.

Parameters

Parameter In Type Required Default Description Accepted Values
moduleId path string true N/A The module ID. -

Response Statuses

Status Meaning Description Schema
204 No Content The module was deleted. None
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Update a Learning Module

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-1.healtheintent.com/consumer-engagement/v1/learning-modules/11e8902c9e2908c69718f13503066bee', headers: headers, body: {"imageUrl":"https://heathwise.edu/1.jpg","status":"PUBLISHED","title":[{"locale":"en-US","text":"Diabetes Prevention"}],"description":[{"locale":"en-US","text":"A 12-week course to help you establish healthy weight practices and habits."}],"keywords":[{"locale":"en-US","text":["Diabetes","prevention"]}],"categories":["0276ea55-a3cc-4b0a-88dc-284629d"],"catalogs":[{"id":"7eddc0ad-dc15-4746-9a5c-73f1ea680f83"}],"consumerGroups":[{"id":"0276ea55-a3cc-4b0a-88dc-284629d6"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PATCH https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-modules/11e8902c9e2908c69718f13503066bee \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"imageUrl":"https://heathwise.edu/1.jpg","status":"PUBLISHED","title":[{"locale":"en-US","text":"Diabetes Prevention"}],"description":[{"locale":"en-US","text":"A 12-week course to help you establish healthy weight practices and habits."}],"keywords":[{"locale":"en-US","text":["Diabetes","prevention"]}],"categories":["0276ea55-a3cc-4b0a-88dc-284629d"],"catalogs":[{"id":"7eddc0ad-dc15-4746-9a5c-73f1ea680f83"}],"consumerGroups":[{"id":"0276ea55-a3cc-4b0a-88dc-284629d6"}]}

PATCH /learning-modules/{moduleId}

Updates a learning module.

Parameters

Parameter In Type Required Default Description Accepted Values
moduleId path string true N/A The module ID. -
body body patchLearningModules true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content The module was updated. None
400 Bad Request Bad Request. The education content 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 title if it is used in the body.
- duplicateLocale The locales for the titles and descriptions must be unique.
- categoryNotFound The category was not found.
Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error
409 Conflict Conflict Error

Retrieve a Single Module

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-1.healtheintent.com/consumer-engagement/v1/learning-modules/11e8902c9e2908c69718f13503066bee', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "id": "11e8902c9e2908c69718f13503066bee",
  "definitionId": "77a233a3-54d4-4ad3-9e63-53bb71762290",
  "title": [
    {
      "locale": "en-US",
      "text": "Diabetes Prevention"
    }
  ],
  "description": [
    {
      "locale": "en-US",
      "text": "Diabetes Prevention"
    }
  ],
  "status": "DRAFT",
  "type": "CUSTOM",
  "imageUrl": "https://heathwise.edu/1.jpg",
  "keywords": [
    {
      "locale": "en-US",
      "text": [
        "Diabetes",
        "prevention"
      ]
    }
  ],
  "categories": [
    "0276ea55-a3cc-4b0a-88dc-284629d"
  ],
  "catalogs": [
    {
      "id": "7eddc0ad-dc15-4746-9a5c-73f1ea680f83"
    }
  ],
  "consumerGroups": [
    {
      "id": "0276ea55-a3cc-4b0a-88dc-284629d6"
    }
  ],
  "createdAt": "2018-12-15T12:23:12Z",
  "updatedAt": "2018-12-15T12:23:12Z"
}

GET /learning-modules/{moduleId}

Retrieves a single module by ID.

Parameters

Parameter In Type Required Default Description Accepted Values
moduleId path string true N/A The module ID. -

Response Statuses

Status Meaning Description Schema
200 OK OK ConsumerEngagementPublicApi_Entities_V1_LearningModules_Module
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Copy a Learning Module

Example Request:


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

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

result = HTTParty.post('https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-modules/{moduleId}/clone', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-modules/{moduleId}/clone \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "11e8902c9e2908c69718f13503066bee",
  "definitionId": "77a233a3-54d4-4ad3-9e63-53bb71762290",
  "title": [
    {
      "locale": "en-US",
      "text": "Diabetes Prevention"
    }
  ],
  "description": [
    {
      "locale": "en-US",
      "text": "Diabetes Prevention"
    }
  ],
  "status": "DRAFT",
  "type": "CUSTOM",
  "imageUrl": "https://heathwise.edu/1.jpg",
  "keywords": [
    {
      "locale": "en-US",
      "text": [
        "Diabetes",
        "prevention"
      ]
    }
  ],
  "categories": [
    "0276ea55-a3cc-4b0a-88dc-284629d"
  ],
  "catalogs": [
    {
      "id": "7eddc0ad-dc15-4746-9a5c-73f1ea680f83"
    }
  ],
  "consumerGroups": [
    {
      "id": "0276ea55-a3cc-4b0a-88dc-284629d6"
    }
  ],
  "createdAt": "2018-12-15T12:23:12Z",
  "updatedAt": "2018-12-15T12:23:12Z"
}

POST /learning-modules/{moduleId}/clone

Copies a learning module with a specified ID to create a new learning module and its associated tasks.

Parameters

Parameter In Type Required Default Description Accepted Values
moduleId path string true N/A The module ID. -

Response Statuses

Status Meaning Description Schema
201 Created The learning module was cloned. ConsumerEngagementPublicApi_Entities_V1_LearningModules_Module
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Create a Task

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-1.healtheintent.com/consumer-engagement/v1/learning-modules/11e8902c9e2908c69718f13503066bee/tasks', headers: headers, body: {"title":[{"locale":"en-US","text":"Diabetes Prevention"}],"description":[{"locale":"en-US","text":"A 12-week course to help you establish healthy weight practices and habits."}],"sourceReference":{"id":"d8454f2a-665c-49d4-87db-8c167feae10e","kind":"education#content"},"order":"4","weeksBeforeActive":1}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-modules/11e8902c9e2908c69718f13503066bee/tasks \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"title":[{"locale":"en-US","text":"Diabetes Prevention"}],"description":[{"locale":"en-US","text":"A 12-week course to help you establish healthy weight practices and habits."}],"sourceReference":{"id":"d8454f2a-665c-49d4-87db-8c167feae10e","kind":"education#content"},"order":"4","weeksBeforeActive":1}

Example response

{
  "id": "d4454f2a-665c-49d4-87db-8c167feae17d",
  "moduleReference": {
    "id": "11e8902c9e2908c69718f13503066bee"
  },
  "title": [
    {
      "locale": "en-US",
      "text": "Diabetes Prevention"
    }
  ],
  "description": [
    {
      "locale": "en-US",
      "text": "A 12-week course to help you establish healthy weight practices and habits."
    }
  ],
  "sourceReference": {
    "id": "d8454f2a-665c-49d4-87db-8c167feae10e",
    "kind": "education#content"
  },
  "order": "4",
  "weeksBeforeActive": 1,
  "createdAt": "2018-12-15T12:23:12Z",
  "updatedAt": "2018-12-15T12:23:12Z"
}

POST /learning-modules/{moduleId}/tasks

Creates a task in the learning module.

Parameters

Parameter In Type Required Default Description Accepted Values
moduleId path string true N/A The module ID. -
body body postLearningModulesModuleidTasks true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created The learning module task was created. ConsumerEngagementPublicApi_Entities_V1_LearningModules_Task
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a List of Tasks for a Learning Module

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-1.healtheintent.com/consumer-engagement/v1/learning-modules/11e8902c9e2908c69718f13503066bee/tasks', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "d4454f2a-665c-49d4-87db-8c167feae17d",
      "moduleReference": {
        "id": "11e8902c9e2908c69718f13503066bee"
      },
      "title": [
        {
          "locale": "en-US",
          "text": "Diabetes Prevention"
        }
      ],
      "description": [
        {
          "locale": "en-US",
          "text": "A 12-week course to help you establish healthy weight practices and habits."
        }
      ],
      "sourceReference": {
        "id": "d8454f2a-665c-49d4-87db-8c167feae10e",
        "kind": "education#content"
      },
      "order": "4",
      "weeksBeforeActive": 1,
      "createdAt": "2018-12-15T12:23:12Z",
      "updatedAt": "2018-12-15T12:23:12Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-modules/db5f4eec-0e29-40b4-b051-707ad8a30b1d/tasks?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-modules/db5f4eec-0e29-40b4-b051-707ad8a30b1d/tasks?offset=0&limit=20"
}

GET /learning-modules/{moduleId}/tasks

Retrieves a list of tasks for a learning module.

Parameters

Parameter In Type Required Default Description Accepted Values
moduleId path string true N/A The module ID. -
sourceReferenceId query string false N/A The source ID in an external system, for example, the education library. -
sourceReferenceKind query string false N/A The source type in an external system, for example, the education library. -
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. -
locale query string false en-US Filters modules by locale. -
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 Tasks
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Delete a Task

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-1.healtheintent.com/consumer-engagement/v1/learning-modules/11e8902c9e2908c69718f13503066bee/tasks/42f0931e-d05d-458d-a835-cf6bc4795158', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-modules/11e8902c9e2908c69718f13503066bee/tasks/42f0931e-d05d-458d-a835-cf6bc4795158 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /learning-modules/{moduleId}/tasks/{taskId}

Deletes a single task in a learning module.

Parameters

Parameter In Type Required Default Description Accepted Values
moduleId path string true N/A The module ID. -
taskId path string true N/A The ID of the module task. -

Response Statuses

Status Meaning Description Schema
204 No Content The task was deleted. None
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Update a Task

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-1.healtheintent.com/consumer-engagement/v1/learning-modules/11e8902c9e2908c69718f13503066bee/tasks/42f0931e-d05d-458d-a835-cf6bc4795158', headers: headers, body: {"title":[{"locale":"en-US","text":"Diabetes Prevention"}],"sourceReference":{"id":"d8454f2a-665c-49d4-87db-8c167feae10e","kind":"education#content"},"order":"4","weeksBeforeActive":1,"description":[{"locale":"en-US","text":"A 12-week course to help you establish healthy weight practices and habits."}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PATCH https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-modules/11e8902c9e2908c69718f13503066bee/tasks/42f0931e-d05d-458d-a835-cf6bc4795158 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"title":[{"locale":"en-US","text":"Diabetes Prevention"}],"sourceReference":{"id":"d8454f2a-665c-49d4-87db-8c167feae10e","kind":"education#content"},"order":"4","weeksBeforeActive":1,"description":[{"locale":"en-US","text":"A 12-week course to help you establish healthy weight practices and habits."}]}

PATCH /learning-modules/{moduleId}/tasks/{taskId}

Updates a single task in a learning module.

Parameters

Parameter In Type Required Default Description Accepted Values
moduleId path string true N/A The module ID. -
taskId path string true N/A The ID of the module task. -
body body patchLearningModulesModuleidTasks true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content The task was updated. None
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error
409 Conflict Conflict Error

Add a Consumer to a Module

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-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments', headers: headers, body: {"moduleReferenceId":"11e8902c9e2908c69718f13503066bee","consumerReferenceId":"9fb56347-07bd-4a48-a495-fc86ef804ba7"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"moduleReferenceId":"11e8902c9e2908c69718f13503066bee","consumerReferenceId":"9fb56347-07bd-4a48-a495-fc86ef804ba7"}

Example response

{
  "id": "6fcfc048-77ab-4f8b-831f-52dbb64b906b",
  "consumerReference": {
    "id": "9fb56347-07bd-4a48-a495-fc86ef804ba7"
  },
  "moduleReference": {
    "id": "11e8902c9e2908c69718f13503066bee"
  },
  "status": "notStarted",
  "createdAt": "2018-12-15T12:23:12Z",
  "updatedAt": "2018-12-15T12:23:12Z"
}

POST /learning-module-enrollments

Creates a wellness learning module enrollment, which enrolls the consumer in the module.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created The learning enrollment was created. ConsumerEngagementPublicApi_Entities_V1_LearningModules_Enrollment
400 Bad Request Bad Request. The learning module was not created due to issues with the request. The request should be reattempted. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- consumerAlreadyEnrolled The person is already enrolled in the learning module.
- invalidField A field is incorrect in some way, for example, the data type is incorrect.
- missingField Review and complete all required information to continue.
Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a List of Enrolled Wellness Learning Modules

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-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "6fcfc048-77ab-4f8b-831f-52dbb64b906b",
      "consumerReference": {
        "id": "9fb56347-07bd-4a48-a495-fc86ef804ba7"
      },
      "moduleReference": {
        "id": "11e8902c9e2908c69718f13503066bee"
      },
      "status": "notStarted",
      "createdAt": "2018-12-15T12:23:12Z",
      "updatedAt": "2018-12-15T12:23:12Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments?offset=0&limit=20"
}

GET /learning-module-enrollments

Retrieves a list of the modules in which a consumer is enrolled.

Parameters

Parameter In Type Required Default Description Accepted Values
consumerReferenceId query string false N/A Filters enrollments by consumer ID. -
moduleReferenceId query string false N/A Filters enrollments by learning module ID. -
status query array[string] false N/A Filters enrollments by status. notStarted, inProgress, completed, unenrolled
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 Enrollments
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Remove a Consumer from a Module

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-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments/66886ed6-cfde-427c-9384-bc0995dc3a7e', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments/66886ed6-cfde-427c-9384-bc0995dc3a7e \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /learning-module-enrollments/{enrollmentId}

Deletes a learning module enrollment, which unenrolls a consumer from a module.

Parameters

Parameter In Type Required Default Description Accepted Values
enrollmentId path string true N/A The enrollment ID. -

Response Statuses

Status Meaning Description Schema
204 No Content The enrollment was deleted. None
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Wellness Learning Module Enrollment

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-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments/66886ed6-cfde-427c-9384-bc0995dc3a7e', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments/66886ed6-cfde-427c-9384-bc0995dc3a7e \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "6fcfc048-77ab-4f8b-831f-52dbb64b906b",
  "consumerReference": {
    "id": "9fb56347-07bd-4a48-a495-fc86ef804ba7"
  },
  "moduleReference": {
    "id": "11e8902c9e2908c69718f13503066bee"
  },
  "status": "notStarted",
  "createdAt": "2018-12-15T12:23:12Z",
  "updatedAt": "2018-12-15T12:23:12Z"
}

GET /learning-module-enrollments/{enrollmentId}

Retrieves a single wellness learning module enrollment by ID.

Parameters

Parameter In Type Required Default Description Accepted Values
enrollmentId path string true N/A The enrollment ID. -

Response Statuses

Status Meaning Description Schema
200 OK OK ConsumerEngagementPublicApi_Entities_V1_LearningModules_Enrollment
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a List of Tasks

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-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments/66886ed6-cfde-427c-9384-bc0995dc3a7e/tasks', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments/66886ed6-cfde-427c-9384-bc0995dc3a7e/tasks \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "f35241f0-968d-46bb-8ee0-f59818892c61",
      "moduleTaskReference": {
        "id": "d4454f2a-665c-49d4-87db-8c167feae17d"
      },
      "status": "NOT_STARTED",
      "order": "4",
      "taskActivity": {
        "id": "21c2341c-a273-4103-92f0-028653384bea"
      },
      "createdAt": "2018-12-15T12:23:12Z",
      "updatedAt": "2018-12-15T12:23:12Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments/11e8902c9e2908c69718/tasks?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments/11e8902c9e2908c69718/tasks?offset=0&limit=20"
}

GET /learning-module-enrollments/{enrollmentId}/tasks

Retrieves a list of tasks for a specific module in which a consumer is enrolled.

Parameters

Parameter In Type Required Default Description Accepted Values
enrollmentId path string true N/A The enrollment ID. -
status query string false N/A Filters enrollments by status. NOT_STARTED, COMPLETED
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 order A comma-separated list of fields by which to sort. updatedAt, -updatedAt, order, -order, status

Response Statuses

Status Meaning Description Schema
200 OK OK EnrollmentTasks
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Update a Task Status

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-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments/66886ed6-cfde-427c-9384-bc0995dc3a7e/tasks/d96a3cd2-01c1-4abf-aa1b-9be4605bfaed', headers: headers, body: {"status":"completed","taskActivity":{"id":"21c2341c-a273-4103-92f0-028653384bea"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PATCH https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-enrollments/66886ed6-cfde-427c-9384-bc0995dc3a7e/tasks/d96a3cd2-01c1-4abf-aa1b-9be4605bfaed \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"status":"completed","taskActivity":{"id":"21c2341c-a273-4103-92f0-028653384bea"}}

PATCH /learning-module-enrollments/{enrollmentId}/tasks/{enrollmentTaskId}

Updates the status of a task in a learning module in which a consumer is enrolled.

Parameters

Parameter In Type Required Default Description Accepted Values
enrollmentId path string true N/A The enrollment ID. -
enrollmentTaskId path string true N/A The enrollment ID of the learning module task. -
body body patchLearningModuleEnrollmentsEnrollmentidTasks true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content No Content ConsumerEngagementPublicApi_Entities_V1_LearningModules_Enrollment
400 Bad Request Bad Request. The resource cannot be updated due to issues with the request. The request should be reattempted. The response includes error details with a reason field that can help identify the issue. The following reasons are possible, among others:
- statusEnrollmentIssue The learning module is already in the specified status.
- invalidField A field is incorrect in some way, for example, the data type is incorrect.
Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error
409 Conflict Conflict Error

Create 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-1.healtheintent.com/consumer-engagement/v1/learning-module-categories', headers: headers, body: {"title":[{"text":"Diabetes Prevention","locale":"en-US"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-categories \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"title":[{"text":"Diabetes Prevention","locale":"en-US"}]}

Example response

{
  "id": "11e8902c9e2908c69718f13503066bee",
  "title": [
    {
      "locale": "en-US",
      "text": "Diabetes Prevention"
    }
  ],
  "createdAt": "2018-12-15T12:23:12Z",
  "updatedAt": "2018-05-15T12:23:12Z"
}

POST /learning-module-categories

Creates a category.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created The category was created. ConsumerEngagementPublicApi_Entities_V1_LearningModules_LearningModuleCategory
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a List of Categories

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-1.healtheintent.com/consumer-engagement/v1/learning-module-categories', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-categories \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "11e8902c9e2908c69718f13503066bee",
      "title": [
        {
          "locale": "en-US",
          "text": "Diabetes Prevention"
        }
      ],
      "createdAt": "2018-12-15T12:23:12Z",
      "updatedAt": "2018-05-15T12:23:12Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-categories?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-categories?offset=0&limit=20"
}

GET /learning-module-categories

Retrieves a list of categories.

Parameters

Parameter In Type Required Default Description Accepted Values
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 LearningModuleCategories
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

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'
} 

result = HTTParty.patch('https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-categories/11e8902c9e2908c69718f13503066bee', headers: headers, body: {"title":[{"text":"Diabetes Prevention","locale":"en-US"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PATCH https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-categories/11e8902c9e2908c69718f13503066bee \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"title":[{"text":"Diabetes Prevention","locale":"en-US"}]}

PATCH /learning-module-categories/{categoryId}

Updates a category.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content The category was updated. None
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error
409 Conflict Conflict Error

Delete 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-1.healtheintent.com/consumer-engagement/v1/learning-module-categories/11e8902c9e2908c69718f13503066bee', headers: headers)

print JSON.pretty_generate(result)


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

DELETE /learning-module-categories/{categoryId}

Deletes a single category.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content The category was deleted. None
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Single 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-1.healtheintent.com/consumer-engagement/v1/learning-module-categories/11e8902c9e2908c69718f13503066bee', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "id": "11e8902c9e2908c69718f13503066bee",
  "title": [
    {
      "locale": "en-US",
      "text": "Diabetes Prevention"
    }
  ],
  "createdAt": "2018-12-15T12:23:12Z",
  "updatedAt": "2018-05-15T12:23:12Z"
}

GET /learning-module-categories/{categoryId}

Retrieves a single category by ID.

Parameters

Parameter In Type Required Default Description Accepted Values
categoryId path string true N/A The ID of the category. -
locale query string false en-US Filters modules by locale. -

Response Statuses

Status Meaning Description Schema
200 OK OK ConsumerEngagementPublicApi_Entities_V1_LearningModules_LearningModuleCategory
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Create a Learning Module Catalog

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-1.healtheintent.com/consumer-engagement/v1/learning-module-catalogs', headers: headers, body: {"name":"2019 Incentivized Learning Module Catalog","description":"Catalog to group incentivized learning modules in 2019."}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-catalogs \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"2019 Incentivized Learning Module Catalog","description":"Catalog to group incentivized learning modules in 2019."}

POST /learning-module-catalogs

Creates a new learning module catalog. Learning modules can be included in learning module catalogs to group the learning modules. To remove a learning module from a learning module catalog, the learning module must be updated to remove the learning module catalog reference.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created. ConsumerEngagementPublicApi_Entities_V1_LearningModules_LearningModuleCatalog
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a List of learning Module Catalogs

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-1.healtheintent.com/consumer-engagement/v1/learning-module-catalogs', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-catalogs \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "cef0be9e-9bec-4f5e-8004-0252cab4b991",
      "name": "2019 Incentivized Learning Module Catalog",
      "description": "Catalog to group incentivized learning modules in 2019."
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-catalogs?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-catalogs?offset=0&limit=20"
}

GET /learning-module-catalogs

Retrieves all of the learning module catalogs that can group learning modules.

Parameters

Parameter In Type Required Default Description Accepted Values
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. LearningModuleCatalogs
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Update a Learning Module Catalog

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-1.healtheintent.com/consumer-engagement/v1/learning-module-catalogs/66886ed6-cfde-427c-9384-bc0995dc3a7e', headers: headers, body: {"name":"2019 Incentivized Learning Module Catalog","description":"Catalog to group incentivized learning modules in 2019."}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-catalogs/66886ed6-cfde-427c-9384-bc0995dc3a7e \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"2019 Incentivized Learning Module Catalog","description":"Catalog to group incentivized learning modules in 2019."}

PUT /learning-module-catalogs/{catalogId}

Updates information for a learning module catalog that can be used to group learning modules.

Parameters

Parameter In Type Required Default Description Accepted Values
catalogId path string true N/A The ID of the catalog. -
body body putLearningModuleCatalogs true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated. ConsumerEngagementPublicApi_Entities_V1_LearningModules_LearningModuleCatalog
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Learning Module Catalog

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-1.healtheintent.com/consumer-engagement/v1/learning-module-catalogs/66886ed6-cfde-427c-9384-bc0995dc3a7e', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/learning-module-catalogs/66886ed6-cfde-427c-9384-bc0995dc3a7e \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

GET /learning-module-catalogs/{catalogId}

Retrieves a learning module catalog based on its ID. This is used to retrieve information for a single learning module catalog.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success. ConsumerEngagementPublicApi_Entities_V1_LearningModules_LearningModuleCatalog
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Challenges

Challenges are engagement programs that encourage consumers to meet a personal or team-based goal. Challenges can be designed for individual consumers or for groups of consumers to complete together. Wellness programs can use challenges to create social awareness of healthy activities, facilitate competitions, and increase participation in the program, ultimately leading to positive behavior change and improved health outcomes. Additionally, challenge outcomes can be used for challenge leaderboards to compare how a particular consumer performed compared to all the other consumers participating in the challenge.

Create a Challenge

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-1.healtheintent.com/consumer-engagement/v1/challenges', headers: headers, body: {"names":[{"text":"Walking Challenge","locale":"en-US"}],"descriptions":[{"text":"90-day challenge to get into shape by walking","locale":"en-US"}],"consumerGroups":[{"id":"0276ea55-a3cc-4b0a-88dc-284629d6"}],"imageURL":"https://cerner.com/download/101/bewell_profile.png","startsAt":"2019-08-13T12:23:12Z","endsAt":"2019-08-30T12:23:12Z","registrationStartsAt":"2019-08-06T12:23:12Z","registrationEndsAt":"2019-08-20T12:23:12Z","timeZone":"America/New_York","catalogs":[{"id":"076295f2-bded-11e9-bed5-2a2ae2dbcce4"}],"goals":[{"id":"0185e5f2-bded-11e9-bed5-2a2ae2dbcce4"}],"completionCriteria":[{"goal":{"id":"74b44ea3-fb6b-4245-886b-caa8e156f125"},"value":100000,"timesGoalMet":1,"interval":"CHALLENGE_DURATION"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenges \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"names":[{"text":"Walking Challenge","locale":"en-US"}],"descriptions":[{"text":"90-day challenge to get into shape by walking","locale":"en-US"}],"consumerGroups":[{"id":"0276ea55-a3cc-4b0a-88dc-284629d6"}],"imageURL":"https://cerner.com/download/101/bewell_profile.png","startsAt":"2019-08-13T12:23:12Z","endsAt":"2019-08-30T12:23:12Z","registrationStartsAt":"2019-08-06T12:23:12Z","registrationEndsAt":"2019-08-20T12:23:12Z","timeZone":"America/New_York","catalogs":[{"id":"076295f2-bded-11e9-bed5-2a2ae2dbcce4"}],"goals":[{"id":"0185e5f2-bded-11e9-bed5-2a2ae2dbcce4"}],"completionCriteria":[{"goal":{"id":"74b44ea3-fb6b-4245-886b-caa8e156f125"},"value":100000,"timesGoalMet":1,"interval":"CHALLENGE_DURATION"}]}

Example response

{
  "id": "74b44ea3-fb6b-4245-886b-caa8e156f125",
  "names": [
    {
      "locale": "en-US",
      "text": "Walking Challenge"
    }
  ],
  "descriptions": [
    {
      "locale": "en-US",
      "text": "90-day challenge to get into shape by walking"
    }
  ],
  "consumerGroups": [
    {
      "id": "0276ea55-a3cc-4b0a-88dc-284629d6"
    }
  ],
  "imageURL": "https://cerner.com/download/101/bewell_profile.png",
  "startsAt": "2019-08-13T12:23:12Z",
  "endsAt": "2019-08-30T12:23:12Z",
  "registrationStartsAt": "2019-08-06T12:23:12Z",
  "registrationEndsAt": "2019-08-20T12:23:12Z",
  "timeZone": "America/New_York",
  "catalogs": [
    {
      "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "names": [
        {
          "locale": "en-US",
          "text": "Kansas City Wellness Challenges"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "All challenges for the Kansas City location"
        }
      ]
    }
  ],
  "goals": [
    {
      "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "names": [
        {
          "locale": "en-US",
          "text": "Complete 150,000 steps in four weeks"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "Walk 5000 steps every day to meet your goal"
        }
      ],
      "type": "STEPS",
      "value": 100000,
      "unit": "STEPS",
      "frequency": "ONE_TIME",
      "isAffirmative": true,
      "coding": {
        "code": "10831000175105",
        "system": "2.16.840.1.113883.6.96",
        "display": "Steps"
      },
      "createdAt": "2020-06-01T10:00:00.000Z",
      "updatedAt": "2020-06-07T10:00:00.000Z"
    }
  ],
  "completionCriteria": [
    {
      "goal": {
        "id": "74b44ea3-fb6b-4245-886b-caa8e156f125"
      },
      "value": 100000,
      "timesGoalMet": 1,
      "interval": "CHALLENGE_DURATION"
    }
  ],
  "createdAt": "2020-06-01T10:00:00.000Z",
  "updatedAt": "2020-06-07T10:00:00.000Z"
}

POST /challenges

Creates a challenge using the specified parameters. Challenges are engagement programs used to encourage consumers to participate in behaviors specified by the challenge goal or goals. Challenges can be created on an individual or team level. Completion criteria can be used to define what a consumer must do to complete a challenge. For consumers to complete a challenge, they must meet all specified completion criteria.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Challenges_Challenge
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Retrieve a List of Challenges

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-1.healtheintent.com/consumer-engagement/v1/challenges', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "74b44ea3-fb6b-4245-886b-caa8e156f125",
      "names": [
        {
          "locale": "en-US",
          "text": "Walking Challenge"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "90-day challenge to get into shape by walking"
        }
      ],
      "consumerGroups": [
        {
          "id": "0276ea55-a3cc-4b0a-88dc-284629d6"
        }
      ],
      "imageURL": "https://cerner.com/download/101/bewell_profile.png",
      "startsAt": "2019-08-13T12:23:12Z",
      "endsAt": "2019-08-30T12:23:12Z",
      "registrationStartsAt": "2019-08-06T12:23:12Z",
      "registrationEndsAt": "2019-08-20T12:23:12Z",
      "timeZone": "America/New_York",
      "catalogs": [
        {
          "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
          "names": [
            {
              "locale": "en-US",
              "text": "Kansas City Wellness Challenges"
            }
          ],
          "descriptions": [
            {
              "locale": "en-US",
              "text": "All challenges for the Kansas City location"
            }
          ]
        }
      ],
      "goals": [
        {
          "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
          "names": [
            {
              "locale": "en-US",
              "text": "Complete 150,000 steps in four weeks"
            }
          ],
          "descriptions": [
            {
              "locale": "en-US",
              "text": "Walk 5000 steps every day to meet your goal"
            }
          ],
          "type": "STEPS",
          "value": 100000,
          "unit": "STEPS",
          "frequency": "ONE_TIME",
          "isAffirmative": true,
          "coding": {
            "code": "10831000175105",
            "system": "2.16.840.1.113883.6.96",
            "display": "Steps"
          },
          "createdAt": "2020-06-01T10:00:00.000Z",
          "updatedAt": "2020-06-07T10:00:00.000Z"
        }
      ],
      "completionCriteria": [
        {
          "goal": {
            "id": "74b44ea3-fb6b-4245-886b-caa8e156f125"
          },
          "value": 100000,
          "timesGoalMet": 1,
          "interval": "CHALLENGE_DURATION"
        }
      ],
      "createdAt": "2020-06-01T10:00:00.000Z",
      "updatedAt": "2020-06-07T10:00:00.000Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenges?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenges?offset=0&limit=20"
}

GET /challenges

Retrieves a list of challenges.

Parameters

Parameter In Type Required Default Description Accepted Values
catalogId query array[string] false N/A The ID or IDs of one or more catalogs by which to filter the challenges. -
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. -
consumerGroupId query array[string] false N/A Filters by the ID of the consumer group. -

Response Statuses

Status Meaning Description Schema
200 OK Success Challenges
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Delete a Challenge

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-1.healtheintent.com/consumer-engagement/v1/challenges/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenges/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /challenges/{challengeId}

Deletes a single challenge by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Success None
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Update a Challenge

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-1.healtheintent.com/consumer-engagement/v1/challenges/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers, body: {"names":[{"text":"Walking Challenge","locale":"en-US"}],"descriptions":[{"text":"90-day challenge to get into shape by walking","locale":"en-US"}],"consumerGroups":[{"id":"0276ea55-a3cc-4b0a-88dc-284629d6"}],"imageURL":"https://cerner.com/download/101/bewell_profile.png","startsAt":"2019-08-13T12:23:12Z","endsAt":"2019-08-30T12:23:12Z","registrationStartsAt":"2019-08-06T12:23:12Z","registrationEndsAt":"2019-08-20T12:23:12Z","timeZone":"America/New_York","catalogs":[{"id":"076295f2-bded-11e9-bed5-2a2ae2dbcce4"}],"goals":[{"id":"0185e5f2-bded-11e9-bed5-2a2ae2dbcce4"}],"completionCriteria":[{"goal":{"id":"74b44ea3-fb6b-4245-886b-caa8e156f125"},"value":100000,"timesGoalMet":1,"interval":"CHALLENGE_DURATION"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenges/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"names":[{"text":"Walking Challenge","locale":"en-US"}],"descriptions":[{"text":"90-day challenge to get into shape by walking","locale":"en-US"}],"consumerGroups":[{"id":"0276ea55-a3cc-4b0a-88dc-284629d6"}],"imageURL":"https://cerner.com/download/101/bewell_profile.png","startsAt":"2019-08-13T12:23:12Z","endsAt":"2019-08-30T12:23:12Z","registrationStartsAt":"2019-08-06T12:23:12Z","registrationEndsAt":"2019-08-20T12:23:12Z","timeZone":"America/New_York","catalogs":[{"id":"076295f2-bded-11e9-bed5-2a2ae2dbcce4"}],"goals":[{"id":"0185e5f2-bded-11e9-bed5-2a2ae2dbcce4"}],"completionCriteria":[{"goal":{"id":"74b44ea3-fb6b-4245-886b-caa8e156f125"},"value":100000,"timesGoalMet":1,"interval":"CHALLENGE_DURATION"}]}

PUT /challenges/{challengeId}

Updates a single challenge by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Success ConsumerEngagementPublicApi_Entities_V1_Challenges_Challenge
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Retrieve a Single Challenge

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-1.healtheintent.com/consumer-engagement/v1/challenges/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenges/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "74b44ea3-fb6b-4245-886b-caa8e156f125",
  "names": [
    {
      "locale": "en-US",
      "text": "Walking Challenge"
    }
  ],
  "descriptions": [
    {
      "locale": "en-US",
      "text": "90-day challenge to get into shape by walking"
    }
  ],
  "consumerGroups": [
    {
      "id": "0276ea55-a3cc-4b0a-88dc-284629d6"
    }
  ],
  "imageURL": "https://cerner.com/download/101/bewell_profile.png",
  "startsAt": "2019-08-13T12:23:12Z",
  "endsAt": "2019-08-30T12:23:12Z",
  "registrationStartsAt": "2019-08-06T12:23:12Z",
  "registrationEndsAt": "2019-08-20T12:23:12Z",
  "timeZone": "America/New_York",
  "catalogs": [
    {
      "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "names": [
        {
          "locale": "en-US",
          "text": "Kansas City Wellness Challenges"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "All challenges for the Kansas City location"
        }
      ]
    }
  ],
  "goals": [
    {
      "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "names": [
        {
          "locale": "en-US",
          "text": "Complete 150,000 steps in four weeks"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "Walk 5000 steps every day to meet your goal"
        }
      ],
      "type": "STEPS",
      "value": 100000,
      "unit": "STEPS",
      "frequency": "ONE_TIME",
      "isAffirmative": true,
      "coding": {
        "code": "10831000175105",
        "system": "2.16.840.1.113883.6.96",
        "display": "Steps"
      },
      "createdAt": "2020-06-01T10:00:00.000Z",
      "updatedAt": "2020-06-07T10:00:00.000Z"
    }
  ],
  "completionCriteria": [
    {
      "goal": {
        "id": "74b44ea3-fb6b-4245-886b-caa8e156f125"
      },
      "value": 100000,
      "timesGoalMet": 1,
      "interval": "CHALLENGE_DURATION"
    }
  ],
  "createdAt": "2020-06-01T10:00:00.000Z",
  "updatedAt": "2020-06-07T10:00:00.000Z"
}

GET /challenges/{challengeId}

Retrieves a single challenge by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Challenges_Challenge
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Create a Team Challenge

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-1.healtheintent.com/consumer-engagement/v1/team-challenges', headers: headers, body: {"names":[{"text":"Walking Challenge","locale":"en-US"}],"descriptions":[{"text":"90-day challenge to get into shape by walking","locale":"en-US"}],"consumerGroups":[{"id":"0276ea55-a3cc-4b0a-88dc-284629d6"}],"imageURL":"https://cerner.com/download/101/bewell_profile.png","startsAt":"2019-08-13T12:23:12Z","endsAt":"2019-08-30T12:23:12Z","registrationStartsAt":"2019-08-06T12:23:12Z","registrationEndsAt":"2019-08-20T12:23:12Z","canConsumerCreateTeam":true,"timeZone":"America/New_York","maxTeamRegistrations":50,"catalogs":[{"id":"076295f2-bded-11e9-bed5-2a2ae2dbcce4"}],"goals":[{"id":"0185e5f2-bded-11e9-bed5-2a2ae2dbcce4"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-challenges \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"names":[{"text":"Walking Challenge","locale":"en-US"}],"descriptions":[{"text":"90-day challenge to get into shape by walking","locale":"en-US"}],"consumerGroups":[{"id":"0276ea55-a3cc-4b0a-88dc-284629d6"}],"imageURL":"https://cerner.com/download/101/bewell_profile.png","startsAt":"2019-08-13T12:23:12Z","endsAt":"2019-08-30T12:23:12Z","registrationStartsAt":"2019-08-06T12:23:12Z","registrationEndsAt":"2019-08-20T12:23:12Z","canConsumerCreateTeam":true,"timeZone":"America/New_York","maxTeamRegistrations":50,"catalogs":[{"id":"076295f2-bded-11e9-bed5-2a2ae2dbcce4"}],"goals":[{"id":"0185e5f2-bded-11e9-bed5-2a2ae2dbcce4"}]}

Example response

{
  "id": "74b44ea3-fb6b-4245-886b-caa8e156f125",
  "names": [
    {
      "locale": "en-US",
      "text": "Walking Challenge"
    }
  ],
  "descriptions": [
    {
      "locale": "en-US",
      "text": "90-day challenge to get into shape by walking"
    }
  ],
  "consumerGroups": [
    {
      "id": "0276ea55-a3cc-4b0a-88dc-284629d6"
    }
  ],
  "imageURL": "https://cerner.com/download/101/bewell_profile.png",
  "startsAt": "2019-08-13T12:23:12Z",
  "endsAt": "2019-08-30T12:23:12Z",
  "registrationStartsAt": "2019-08-06T12:23:12Z",
  "registrationEndsAt": "2019-08-20T12:23:12Z",
  "canConsumerCreateTeam": true,
  "timeZone": "America/New_York",
  "maxTeamRegistrations": 50,
  "catalogs": [
    {
      "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "names": [
        {
          "locale": "en-US",
          "text": "Kansas City Wellness Challenges"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "All challenges for the Kansas City location"
        }
      ]
    }
  ],
  "goals": [
    {
      "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "names": [
        {
          "locale": "en-US",
          "text": "Complete 150,000 steps in four weeks"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "Walk 5000 steps every day to meet your goal"
        }
      ],
      "type": "STEPS",
      "value": 100000,
      "unit": "STEPS",
      "frequency": "ONE_TIME",
      "isAffirmative": true,
      "coding": {
        "code": "10831000175105",
        "system": "2.16.840.1.113883.6.96",
        "display": "Steps"
      },
      "createdAt": "2020-06-01T10:00:00.000Z",
      "updatedAt": "2020-06-07T10:00:00.000Z"
    }
  ],
  "createdAt": "2020-06-01T10:00:00.000Z",
  "updatedAt": "2020-06-07T10:00:00.000Z"
}

POST /team-challenges

Creates a team challenge using the specified parameters.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Challenges_TeamChallenge
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Retrieve a List of Team Challenges

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-1.healtheintent.com/consumer-engagement/v1/team-challenges', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "74b44ea3-fb6b-4245-886b-caa8e156f125",
      "names": [
        {
          "locale": "en-US",
          "text": "Walking Challenge"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "90-day challenge to get into shape by walking"
        }
      ],
      "consumerGroups": [
        {
          "id": "0276ea55-a3cc-4b0a-88dc-284629d6"
        }
      ],
      "imageURL": "https://cerner.com/download/101/bewell_profile.png",
      "startsAt": "2019-08-13T12:23:12Z",
      "endsAt": "2019-08-30T12:23:12Z",
      "registrationStartsAt": "2019-08-06T12:23:12Z",
      "registrationEndsAt": "2019-08-20T12:23:12Z",
      "canConsumerCreateTeam": true,
      "timeZone": "America/New_York",
      "maxTeamRegistrations": 50,
      "catalogs": [
        {
          "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
          "names": [
            {
              "locale": "en-US",
              "text": "Kansas City Wellness Challenges"
            }
          ],
          "descriptions": [
            {
              "locale": "en-US",
              "text": "All challenges for the Kansas City location"
            }
          ]
        }
      ],
      "goals": [
        {
          "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
          "names": [
            {
              "locale": "en-US",
              "text": "Complete 150,000 steps in four weeks"
            }
          ],
          "descriptions": [
            {
              "locale": "en-US",
              "text": "Walk 5000 steps every day to meet your goal"
            }
          ],
          "type": "STEPS",
          "value": 100000,
          "unit": "STEPS",
          "frequency": "ONE_TIME",
          "isAffirmative": true,
          "coding": {
            "code": "10831000175105",
            "system": "2.16.840.1.113883.6.96",
            "display": "Steps"
          },
          "createdAt": "2020-06-01T10:00:00.000Z",
          "updatedAt": "2020-06-07T10:00:00.000Z"
        }
      ],
      "createdAt": "2020-06-01T10:00:00.000Z",
      "updatedAt": "2020-06-07T10:00:00.000Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-challenges?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-challenges?offset=0&limit=20"
}

GET /team-challenges

Retrieves a list of team challenges.

Parameters

Parameter In Type Required Default Description Accepted Values
catalogId query array[string] false N/A The ID or IDs of one or more catalogs by which to filter the challenges. -
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. -
consumerGroupId query array[string] false N/A Filters by the ID of the consumer group. -

Response Statuses

Status Meaning Description Schema
200 OK Success TeamChallenges
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Delete a Team Challenge

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-1.healtheintent.com/consumer-engagement/v1/team-challenges/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-challenges/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /team-challenges/{teamChallengeId}

Deletes a single team challenge by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Success None
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Update a Team Challenge

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-1.healtheintent.com/consumer-engagement/v1/team-challenges/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers, body: {"names":[{"text":"Walking Challenge","locale":"en-US"}],"descriptions":[{"text":"90-day challenge to get into shape by walking","locale":"en-US"}],"consumerGroups":[{"id":"0276ea55-a3cc-4b0a-88dc-284629d6"}],"imageURL":"https://cerner.com/download/101/bewell_profile.png","startsAt":"2019-08-13T12:23:12Z","endsAt":"2019-08-30T12:23:12Z","registrationStartsAt":"2019-08-06T12:23:12Z","registrationEndsAt":"2019-08-20T12:23:12Z","canConsumerCreateTeam":true,"timeZone":"America/New_York","maxTeamRegistrations":50,"catalogs":[{"id":"076295f2-bded-11e9-bed5-2a2ae2dbcce4"}],"goals":[{"id":"0185e5f2-bded-11e9-bed5-2a2ae2dbcce4"}]}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-challenges/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"names":[{"text":"Walking Challenge","locale":"en-US"}],"descriptions":[{"text":"90-day challenge to get into shape by walking","locale":"en-US"}],"consumerGroups":[{"id":"0276ea55-a3cc-4b0a-88dc-284629d6"}],"imageURL":"https://cerner.com/download/101/bewell_profile.png","startsAt":"2019-08-13T12:23:12Z","endsAt":"2019-08-30T12:23:12Z","registrationStartsAt":"2019-08-06T12:23:12Z","registrationEndsAt":"2019-08-20T12:23:12Z","canConsumerCreateTeam":true,"timeZone":"America/New_York","maxTeamRegistrations":50,"catalogs":[{"id":"076295f2-bded-11e9-bed5-2a2ae2dbcce4"}],"goals":[{"id":"0185e5f2-bded-11e9-bed5-2a2ae2dbcce4"}]}

PUT /team-challenges/{teamChallengeId}

Updates a single team challenge by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Success ConsumerEngagementPublicApi_Entities_V1_Challenges_TeamChallenge
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Retrieve a Single Team Challenge

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-1.healtheintent.com/consumer-engagement/v1/team-challenges/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-challenges/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "74b44ea3-fb6b-4245-886b-caa8e156f125",
  "names": [
    {
      "locale": "en-US",
      "text": "Walking Challenge"
    }
  ],
  "descriptions": [
    {
      "locale": "en-US",
      "text": "90-day challenge to get into shape by walking"
    }
  ],
  "consumerGroups": [
    {
      "id": "0276ea55-a3cc-4b0a-88dc-284629d6"
    }
  ],
  "imageURL": "https://cerner.com/download/101/bewell_profile.png",
  "startsAt": "2019-08-13T12:23:12Z",
  "endsAt": "2019-08-30T12:23:12Z",
  "registrationStartsAt": "2019-08-06T12:23:12Z",
  "registrationEndsAt": "2019-08-20T12:23:12Z",
  "canConsumerCreateTeam": true,
  "timeZone": "America/New_York",
  "maxTeamRegistrations": 50,
  "catalogs": [
    {
      "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "names": [
        {
          "locale": "en-US",
          "text": "Kansas City Wellness Challenges"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "All challenges for the Kansas City location"
        }
      ]
    }
  ],
  "goals": [
    {
      "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "names": [
        {
          "locale": "en-US",
          "text": "Complete 150,000 steps in four weeks"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "Walk 5000 steps every day to meet your goal"
        }
      ],
      "type": "STEPS",
      "value": 100000,
      "unit": "STEPS",
      "frequency": "ONE_TIME",
      "isAffirmative": true,
      "coding": {
        "code": "10831000175105",
        "system": "2.16.840.1.113883.6.96",
        "display": "Steps"
      },
      "createdAt": "2020-06-01T10:00:00.000Z",
      "updatedAt": "2020-06-07T10:00:00.000Z"
    }
  ],
  "createdAt": "2020-06-01T10:00:00.000Z",
  "updatedAt": "2020-06-07T10:00:00.000Z"
}

GET /team-challenges/{teamChallengeId}

Retrieves a single team challenge by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Challenges_TeamChallenge
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Create a Team 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-1.healtheintent.com/consumer-engagement/v1/team-definitions', headers: headers, body: {"teamChallengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","name":"Fitness Squad","description":"Join the Fitness Squad and stay motivated to compete with other teams and win this challenge.","imageUrl":"https://cerner.com/download/101/bewell_profile.png","createdBy":{"id":"f078eb81-1a74-4418-87e2-40a6ddab490c","kind":"CONSUMER"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-definitions \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"teamChallengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","name":"Fitness Squad","description":"Join the Fitness Squad and stay motivated to compete with other teams and win this challenge.","imageUrl":"https://cerner.com/download/101/bewell_profile.png","createdBy":{"id":"f078eb81-1a74-4418-87e2-40a6ddab490c","kind":"CONSUMER"}}

Example response

{
  "id": "74b44ea3-fb6b-4245-886b-caa8e156f125",
  "teamChallengeId": "b95218d0-470f-11ea-b77f-2e728ce88125",
  "name": "Fitness Squad",
  "description": "Join the Fitness Squad and stay motivated to compete with other teams and win this challenge.",
  "imageURL": "https://cerner.com/download/101/bewell_profile.png",
  "availableRegistrations": 5,
  "createdBy": {
    "id": "f078eb81-1a74-4418-87e2-40a6ddab490c",
    "kind": "CONSUMER"
  },
  "createdAt": "2020-06-01T10:00:00.000Z",
  "updatedAt": "2020-06-07T10:00:00.000Z"
}

POST /team-definitions

Creates a team definition using the specified parameters. A team can be created by either consumers participating in the challenge or an administrator.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Challenges_TeamDefinition
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Retrieve a List of Team 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-1.healtheintent.com/consumer-engagement/v1/team-definitions', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "74b44ea3-fb6b-4245-886b-caa8e156f125",
      "teamChallengeId": "b95218d0-470f-11ea-b77f-2e728ce88125",
      "name": "Fitness Squad",
      "description": "Join the Fitness Squad and stay motivated to compete with other teams and win this challenge.",
      "imageURL": "https://cerner.com/download/101/bewell_profile.png",
      "availableRegistrations": 5,
      "createdBy": {
        "id": "f078eb81-1a74-4418-87e2-40a6ddab490c",
        "kind": "CONSUMER"
      },
      "createdAt": "2020-06-01T10:00:00.000Z",
      "updatedAt": "2020-06-07T10:00:00.000Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-definitions?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-definitions?offset=0&limit=20"
}

GET /team-definitions

Retrieves a list of team definitions.

Parameters

Parameter In Type Required Default Description Accepted Values
teamChallengeId query array[string] false N/A The ID or IDs of one or more team challenges by which to filter the team registrations. -
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 TeamDefinitions
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Delete a Team 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-1.healtheintent.com/consumer-engagement/v1/team-definitions/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-definitions/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /team-definitions/{teamDefinitionId}

Deletes a single team definition by ID. This operation also deletes team challenge outcomes, team outcomes, team availabilities, and team registrations for the team. Deleting a team definition when the team challenge is in progress affects the team challenge outcome because the team’s contribution is removed from the outcome.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Success None
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Update a Team 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-1.healtheintent.com/consumer-engagement/v1/team-definitions/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers, body: {"teamChallengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","name":"Fitness Squad","description":"Join the Fitness Squad and stay motivated to compete with other teams and win this challenge.","imageUrl":"https://cerner.com/download/101/bewell_profile.png","createdBy":{"id":"f078eb81-1a74-4418-87e2-40a6ddab490c","kind":"CONSUMER"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-definitions/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"teamChallengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","name":"Fitness Squad","description":"Join the Fitness Squad and stay motivated to compete with other teams and win this challenge.","imageUrl":"https://cerner.com/download/101/bewell_profile.png","createdBy":{"id":"f078eb81-1a74-4418-87e2-40a6ddab490c","kind":"CONSUMER"}}

PUT /team-definitions/{teamDefinitionId}

Update a single team definition by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Success ConsumerEngagementPublicApi_Entities_V1_Challenges_TeamDefinition
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Retrieve a Single Team 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-1.healtheintent.com/consumer-engagement/v1/team-definitions/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-definitions/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "74b44ea3-fb6b-4245-886b-caa8e156f125",
  "teamChallengeId": "b95218d0-470f-11ea-b77f-2e728ce88125",
  "name": "Fitness Squad",
  "description": "Join the Fitness Squad and stay motivated to compete with other teams and win this challenge.",
  "imageURL": "https://cerner.com/download/101/bewell_profile.png",
  "availableRegistrations": 5,
  "createdBy": {
    "id": "f078eb81-1a74-4418-87e2-40a6ddab490c",
    "kind": "CONSUMER"
  },
  "createdAt": "2020-06-01T10:00:00.000Z",
  "updatedAt": "2020-06-07T10:00:00.000Z"
}

GET /team-definitions/{teamDefinitionId}

Retrieves a single team definition by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Challenges_TeamDefinition
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Create a Team Registration

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-1.healtheintent.com/consumer-engagement/v1/team-registrations', headers: headers, body: {"teamChallengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","teamId":"6c235b5a-470f-11ea-b77f-2e728ce88125","consumerId":"b491d16e-470f-11ea-b77f-2e728ce88125"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-registrations \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"teamChallengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","teamId":"6c235b5a-470f-11ea-b77f-2e728ce88125","consumerId":"b491d16e-470f-11ea-b77f-2e728ce88125"}

Example response

{
  "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "teamChallengeId": "7159c778-470d-11ea-b77f-2e728ce88125",
  "teamId": "8034293c-470d-11ea-b77f-2e728ce88125",
  "consumerId": "86b87178-470d-11ea-b77f-2e728ce88125",
  "createdAt": "2020-06-01T10:00:00.000Z",
  "updatedAt": "2020-06-07T10:00:00.000Z"
}

POST /team-registrations

Creates a team registration using the specified parameters. Consumers can register to be in a team only if the team has registrations available and registration is still open for the team challenge.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Challenges_TeamRegistration
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Retrieve a List of Team Registrations

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-1.healtheintent.com/consumer-engagement/v1/team-registrations', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "teamChallengeId": "7159c778-470d-11ea-b77f-2e728ce88125",
      "teamId": "8034293c-470d-11ea-b77f-2e728ce88125",
      "consumerId": "86b87178-470d-11ea-b77f-2e728ce88125",
      "createdAt": "2020-06-01T10:00:00.000Z",
      "updatedAt": "2020-06-07T10:00:00.000Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-registrations?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-registrations?offset=0&limit=20"
}

GET /team-registrations

Retrieves a list of team registrations.

Parameters

Parameter In Type Required Default Description Accepted Values
consumerId query array[string] false N/A The ID or IDs of one or more consumers whose team registrations are to be retrieved. -
teamChallengeId query array[string] false N/A The ID or IDs of one or more team challenges by which to filter the team registrations. -
teamId query array[string] false N/A The ID of the team. -
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 TeamRegistrations
401 Unauthorized Unauthorized Error

Delete a Team Registration

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-1.healtheintent.com/consumer-engagement/v1/team-registrations/11e8902c9e2908c69718f13503066bee', headers: headers)

print JSON.pretty_generate(result)


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

DELETE /team-registrations/{teamRegistrationId}

Deletes a single team registration for a consumer by ID. Deleting a registration while the challenge is in progress removes the consumer’s contribution and changes the team’s total.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Success None
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Retrieve a Single Team Registration

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-1.healtheintent.com/consumer-engagement/v1/team-registrations/11e8902c9e2908c69718f13503066bee', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "teamChallengeId": "7159c778-470d-11ea-b77f-2e728ce88125",
  "teamId": "8034293c-470d-11ea-b77f-2e728ce88125",
  "consumerId": "86b87178-470d-11ea-b77f-2e728ce88125",
  "createdAt": "2020-06-01T10:00:00.000Z",
  "updatedAt": "2020-06-07T10:00:00.000Z"
}

GET /team-registrations/{teamRegistrationId}

Retrieves a single team registration by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Challenges_TeamRegistration
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Create a Challenge Goal

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-1.healtheintent.com/consumer-engagement/v1/challenge-goals', headers: headers, body: {"names":[{"text":"Complete 150,000 steps in four weeks","locale":"en-US"}],"descriptions":[{"text":"Walk 5000 steps every day to meet your goal","locale":"en-US"}],"type":"STEPS","value":100000,"unit":"STEPS","frequency":"ONE_TIME","isAffirmative":true,"coding":{"code":"10831000175105","system":"2.16.840.1.113883.6.96","display":"Steps"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-goals \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"names":[{"text":"Complete 150,000 steps in four weeks","locale":"en-US"}],"descriptions":[{"text":"Walk 5000 steps every day to meet your goal","locale":"en-US"}],"type":"STEPS","value":100000,"unit":"STEPS","frequency":"ONE_TIME","isAffirmative":true,"coding":{"code":"10831000175105","system":"2.16.840.1.113883.6.96","display":"Steps"}}

Example response

{
  "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "names": [
    {
      "locale": "en-US",
      "text": "Complete 150,000 steps in four weeks"
    }
  ],
  "descriptions": [
    {
      "locale": "en-US",
      "text": "Walk 5000 steps every day to meet your goal"
    }
  ],
  "type": "STEPS",
  "value": 100000,
  "unit": "STEPS",
  "frequency": "ONE_TIME",
  "isAffirmative": true,
  "coding": {
    "code": "10831000175105",
    "system": "2.16.840.1.113883.6.96",
    "display": "Steps"
  },
  "createdAt": "2020-06-01T10:00:00.000Z",
  "updatedAt": "2020-06-07T10:00:00.000Z"
}

POST /challenge-goals

Creates a challenge goal using the specified parameters. A goal linked to an individual challenge is complete when the consumer reaches the value of the goal within the specified frequency. A goal can have a daily, weekly, or one time frequency. Goals with a one time frequency must be completed within the start and end dates of the challenge. Goals with a null value and unit are tracked by consumers affirming they completed the goal. A goal linked to a team-based challenge is complete when the team total reaches the value of the goal within the duration of the team challenge.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Challenges_Goal
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Retrieve a List of Challenge Goals

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-1.healtheintent.com/consumer-engagement/v1/challenge-goals', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "names": [
        {
          "locale": "en-US",
          "text": "Complete 150,000 steps in four weeks"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "Walk 5000 steps every day to meet your goal"
        }
      ],
      "type": "STEPS",
      "value": 100000,
      "unit": "STEPS",
      "frequency": "ONE_TIME",
      "isAffirmative": true,
      "coding": {
        "code": "10831000175105",
        "system": "2.16.840.1.113883.6.96",
        "display": "Steps"
      },
      "createdAt": "2020-06-01T10:00:00.000Z",
      "updatedAt": "2020-06-07T10:00:00.000Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-goals?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-goals?offset=0&limit=20"
}

GET /challenge-goals

Retrieves a list of challenge goals.

Parameters

Parameter In Type Required Default Description Accepted Values
type query array[string] false N/A One or more challenge goal types by which to filter results. -
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 Goals
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Delete a Challenge Goal

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-1.healtheintent.com/consumer-engagement/v1/challenge-goals/873ed54e-d4e5-44ed-a2ca-0dac7f858646', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-goals/873ed54e-d4e5-44ed-a2ca-0dac7f858646 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /challenge-goals/{goalId}

Deletes a single challenge goal by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Success None
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Update a Challenge Goal

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-1.healtheintent.com/consumer-engagement/v1/challenge-goals/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers, body: {"names":[{"text":"Complete 150,000 steps in four weeks","locale":"en-US"}],"descriptions":[{"text":"Walk 5000 steps every day to meet your goal","locale":"en-US"}],"type":"STEPS","value":100000,"unit":"STEPS","frequency":"ONE_TIME","isAffirmative":true,"coding":{"code":"10831000175105","system":"2.16.840.1.113883.6.96","display":"Steps"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-goals/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"names":[{"text":"Complete 150,000 steps in four weeks","locale":"en-US"}],"descriptions":[{"text":"Walk 5000 steps every day to meet your goal","locale":"en-US"}],"type":"STEPS","value":100000,"unit":"STEPS","frequency":"ONE_TIME","isAffirmative":true,"coding":{"code":"10831000175105","system":"2.16.840.1.113883.6.96","display":"Steps"}}

PUT /challenge-goals/{goalId}

Updates a challenge goal by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Success ConsumerEngagementPublicApi_Entities_V1_Challenges_Goal
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Retrieve a Single Challenge Goal

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-1.healtheintent.com/consumer-engagement/v1/challenge-goals/873ed54e-d4e5-44ed-a2ca-0dac7f858646', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-goals/873ed54e-d4e5-44ed-a2ca-0dac7f858646 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "names": [
    {
      "locale": "en-US",
      "text": "Complete 150,000 steps in four weeks"
    }
  ],
  "descriptions": [
    {
      "locale": "en-US",
      "text": "Walk 5000 steps every day to meet your goal"
    }
  ],
  "type": "STEPS",
  "value": 100000,
  "unit": "STEPS",
  "frequency": "ONE_TIME",
  "isAffirmative": true,
  "coding": {
    "code": "10831000175105",
    "system": "2.16.840.1.113883.6.96",
    "display": "Steps"
  },
  "createdAt": "2020-06-01T10:00:00.000Z",
  "updatedAt": "2020-06-07T10:00:00.000Z"
}

GET /challenge-goals/{goalId}

Retrieves a single challenge goal by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Challenges_Goal
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Create a Challenge Catalog

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-1.healtheintent.com/consumer-engagement/v1/challenge-catalogs', headers: headers)

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-catalogs \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json'

Example response

{
  "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "names": [
    {
      "locale": "en-US",
      "text": "Kansas City Wellness Challenges"
    }
  ],
  "descriptions": [
    {
      "locale": "en-US",
      "text": "All challenges for the Kansas City location"
    }
  ]
}

POST /challenge-catalogs

Creates a challenge catalog using the specified parameters. A catalog provides a way to group and organize challenges together.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Challenges_Catalog
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Retrieve a List of Challenge Catalogs

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-1.healtheintent.com/consumer-engagement/v1/challenge-catalogs', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "names": [
        {
          "locale": "en-US",
          "text": "Kansas City Wellness Challenges"
        }
      ],
      "descriptions": [
        {
          "locale": "en-US",
          "text": "All challenges for the Kansas City location"
        }
      ]
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-catalogs?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-catalogs?offset=0&limit=20"
}

GET /challenge-catalogs

Retrieves a list of challenge catalogs.

Parameters

Parameter In Type Required Default Description Accepted Values
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 Catalogs
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Updates a Challenge Catalog

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-1.healtheintent.com/consumer-engagement/v1/challenge-catalogs/66886ed6-cfde-427c-9384-bc0995dc3a7e', headers: headers)

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-catalogs/66886ed6-cfde-427c-9384-bc0995dc3a7e \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json'

PUT /challenge-catalogs/{catalogId}

Updates a specific challenge catalog using the provided parameters.

Parameters

Parameter In Type Required Default Description Accepted Values
catalogId path string true N/A The ID of the challenge catalog. -
body body putChallengeCatalogs true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Updated ConsumerEngagementPublicApi_Entities_V1_Challenges_Catalog
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Delete a Challenge Catalog

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-1.healtheintent.com/consumer-engagement/v1/challenge-catalogs/66886ed6-cfde-427c-9384-bc0995dc3a7e', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-catalogs/66886ed6-cfde-427c-9384-bc0995dc3a7e \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /challenge-catalogs/{catalogId}

Deletes a single challenge catalog by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Success None
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Retrieve a Single Challenge Catalog

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-1.healtheintent.com/consumer-engagement/v1/challenge-catalogs/66886ed6-cfde-427c-9384-bc0995dc3a7e', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-catalogs/66886ed6-cfde-427c-9384-bc0995dc3a7e \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "names": [
    {
      "locale": "en-US",
      "text": "Kansas City Wellness Challenges"
    }
  ],
  "descriptions": [
    {
      "locale": "en-US",
      "text": "All challenges for the Kansas City location"
    }
  ]
}

GET /challenge-catalogs/{catalogId}

Retrieves a single challenge catalog by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Challenges_Catalog
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Create a Challenge Registration

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-1.healtheintent.com/consumer-engagement/v1/challenge-registrations', headers: headers, body: {"challengeId":"94b44ea3-fb6b-4245-886b-caa8e156f125","consumerId":"94b44ea3-fb6b-4245-886b-caa8e156f125","status":"ACTIVE"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-registrations \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"challengeId":"94b44ea3-fb6b-4245-886b-caa8e156f125","consumerId":"94b44ea3-fb6b-4245-886b-caa8e156f125","status":"ACTIVE"}

Example response

{
  "id": "90d80434-470d-11ea-b77f-2e728ce88125",
  "challengeId": "977022b8-470d-11ea-b77f-2e728ce88125",
  "consumerId": "a045032c-470d-11ea-b77f-2e728ce88125",
  "status": "ACTIVE",
  "createdAt": "2020-06-01T10:00:00.000Z",
  "updatedAt": "2020-06-07T10:00:00.000Z"
}

POST /challenge-registrations

Creates a challenge registration using the specified parameters. If you created a team challenge, use the team-registrations resource to register consumers in a team.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Challenges_ChallengeRegistration
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Retrieve a List of Challenge Registrations

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-1.healtheintent.com/consumer-engagement/v1/challenge-registrations', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "90d80434-470d-11ea-b77f-2e728ce88125",
      "challengeId": "977022b8-470d-11ea-b77f-2e728ce88125",
      "consumerId": "a045032c-470d-11ea-b77f-2e728ce88125",
      "status": "ACTIVE",
      "createdAt": "2020-06-01T10:00:00.000Z",
      "updatedAt": "2020-06-07T10:00:00.000Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/registrations?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/registrations?offset=0&limit=20"
}

GET /challenge-registrations

Retrieves a list of challenge registrations.

Parameters

Parameter In Type Required Default Description Accepted Values
consumerId query array[string] false N/A The ID or IDs of one or more consumers whose challenge registrations are to be retrieved. -
challengeId query array[string] false N/A The ID or IDs of one or more challenges by which to filter the challenge registrations. -
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 ChallengeRegistrations
401 Unauthorized Unauthorized Error

Delete a Challenge Registration

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-1.healtheintent.com/consumer-engagement/v1/challenge-registrations/11e8902c9e2908c69718f13503066bee', headers: headers)

print JSON.pretty_generate(result)


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

DELETE /challenge-registrations/{registrationId}

Deletes a single challenge registration of a consumer by ID. Deleting a registration while the challenge is in progress also removes the challenge outcome for that consumer.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Success None
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Retrieve a Single Challenge Registration

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-1.healtheintent.com/consumer-engagement/v1/challenge-registrations/11e8902c9e2908c69718f13503066bee', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "id": "90d80434-470d-11ea-b77f-2e728ce88125",
  "challengeId": "977022b8-470d-11ea-b77f-2e728ce88125",
  "consumerId": "a045032c-470d-11ea-b77f-2e728ce88125",
  "status": "ACTIVE",
  "createdAt": "2020-06-01T10:00:00.000Z",
  "updatedAt": "2020-06-07T10:00:00.000Z"
}

GET /challenge-registrations/{registrationId}

Retrieves a single challenge registration by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Challenges_ChallengeRegistration
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Create a Challenge Outcome

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-1.healtheintent.com/consumer-engagement/v1/challenge-outcomes', headers: headers, body: {"challengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","consumerId":"b491d16e-470f-11ea-b77f-2e728ce88125","total":10000}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-outcomes \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"challengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","consumerId":"b491d16e-470f-11ea-b77f-2e728ce88125","total":10000}

Example response

{
  "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "challengeId": "977022b8-470d-11ea-b77f-2e728ce88125",
  "consumerId": "86b87178-470d-11ea-b77f-2e728ce88125",
  "total": 10000,
  "rank": 5,
  "status": "COMPLETE",
  "unit": "STEPS",
  "updatedAt": "2018-12-15T12:23:12Z"
}

POST /challenge-outcomes

Creates an outcome for the consumer in the challenge using the specified data. The total is used to calculate the rank of a consumer compared to totals from other consumers in the challenge.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Challenges_ChallengeOutcome
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
409 Conflict Conflict Error

Retrieve a List of Challenge Outcomes

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-1.healtheintent.com/consumer-engagement/v1/challenge-outcomes', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "challengeId": "977022b8-470d-11ea-b77f-2e728ce88125",
      "consumerId": "86b87178-470d-11ea-b77f-2e728ce88125",
      "total": 10000,
      "rank": 5,
      "status": "COMPLETE",
      "unit": "STEPS",
      "updatedAt": "2018-12-15T12:23:12Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-outcomes?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-outcomes?offset=0&limit=20"
}

GET /challenge-outcomes

Retrieves a list of challenge outcomes. Outcomes by default are sorted by rank. Outcomes can be used for challenge leaderboards to compare how a particular consumer performed compared to all the other consumers participating in the challenge.

Parameters

Parameter In Type Required Default Description Accepted Values
consumerId query string false N/A Filters the challenge outcomes by consumer ID. -
challengeId query string false N/A Filters the challenge outcomes by challenge ID. -
status query string false N/A Filters the challenge outcomes by the completion status of a consumer for the challenge. The status is based on whether the challenge goal is met. Possible status values are COMPLETE or INCOMPLETE. -
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 ChallengeOutcomes
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Delete a Challenge Outcome

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-1.healtheintent.com/consumer-engagement/v1/challenge-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /challenge-outcomes/{challengeOutcomeId}

Deletes a single challenge outcome by ID. Deleting a challenge outcome does not immediately update the overall rankings.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Success None
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Update a Challenge Outcome

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-1.healtheintent.com/consumer-engagement/v1/challenge-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers, body: {"challengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","consumerId":"b491d16e-470f-11ea-b77f-2e728ce88125","total":10000}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"challengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","consumerId":"b491d16e-470f-11ea-b77f-2e728ce88125","total":10000}

PUT /challenge-outcomes/{challengeOutcomeId}

Updates a single challenge outcome by ID using the specified data. Updating a challenge outcome does not immediately update the overall rankings.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Success ConsumerEngagementPublicApi_Entities_V1_Challenges_ChallengeOutcome
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Retrieve a Single Challenge Outcome

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-1.healtheintent.com/consumer-engagement/v1/challenge-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/challenge-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "challengeId": "977022b8-470d-11ea-b77f-2e728ce88125",
  "consumerId": "86b87178-470d-11ea-b77f-2e728ce88125",
  "total": 10000,
  "rank": 5,
  "status": "COMPLETE",
  "unit": "STEPS",
  "updatedAt": "2018-12-15T12:23:12Z"
}

GET /challenge-outcomes/{challengeOutcomeId}

Retrieves a single challenge outcome by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Challenges_ChallengeOutcome
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Create a Team Outcome

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-1.healtheintent.com/consumer-engagement/v1/team-outcomes', headers: headers, body: {"teamChallengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","teamId":"be528s3e-470f-11ea-b77f-2e728ce88125","total":10000,"consumerId":"b491d16e-470f-11ea-b77f-2e728ce88125","status":"COMPLETE","unit":"STEPS"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-outcomes \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"teamChallengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","teamId":"be528s3e-470f-11ea-b77f-2e728ce88125","total":10000,"consumerId":"b491d16e-470f-11ea-b77f-2e728ce88125","status":"COMPLETE","unit":"STEPS"}

Example response

{
  "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "teamChallengeId": "977022b8-470d-11ea-b77f-2e728ce88125",
  "teamId": "8034293c-470d-11ea-b77f-2e728ce88125",
  "consumerId": "86b87178-470d-11ea-b77f-2e728ce88125",
  "total": 10000
}

POST /team-outcomes

Creates an outcome for the consumer in a team challenge using the specified data. The total is used to calculate the rank of a consumer compared to totals from the other consumers in the team.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Challenges_TeamOutcomeCreateResponse
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Retrieve a List of Team Outcomes

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-1.healtheintent.com/consumer-engagement/v1/team-outcomes', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "teamChallengeId": "977022b8-470d-11ea-b77f-2e728ce88125",
      "teamId": "8034293c-470d-11ea-b77f-2e728ce88125",
      "consumerId": "86b87178-470d-11ea-b77f-2e728ce88125",
      "total": 10000,
      "rank": 5,
      "status": "COMPLETE",
      "unit": "STEPS",
      "updatedAt": "2018-12-15T12:23:12Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-outcomes?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-outcomes?offset=0&limit=20"
}

GET /team-outcomes

Retrieves a list of team outcomes. Outcomes by default are sorted by rank. Outcomes can be used for team leaderboards to compare how a particular consumer performed compared to all the other consumers of the team participating in the challenge.

Parameters

Parameter In Type Required Default Description Accepted Values
consumerId query array[string] false N/A Filters the team outcomes by consumer ID. -
teamChallengeId query array[string] false N/A Filters the team outcomes by team challenge ID. -
teamId query array[string] false N/A Filters the team outcomes by team ID. -
status query array[string] false N/A Filters the team outcomes by the completion status of a consumer for the challenge. The status is based on whether the challenge goal is met. Possible status values are COMPLETE or INCOMPLETE. -
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 TeamOutcomes
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Delete a Team Outcome

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-1.healtheintent.com/consumer-engagement/v1/team-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /team-outcomes/{teamOutcomeId}

Deletes a single team outcome by ID. Deleting a team outcome does not immediately update the overall rankings.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content Success None
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Update a Team Outcome

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-1.healtheintent.com/consumer-engagement/v1/team-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers, body: {"teamChallengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","teamId":"be528s3e-470f-11ea-b77f-2e728ce88125","total":10000,"consumerId":"b491d16e-470f-11ea-b77f-2e728ce88125","status":"COMPLETE","unit":"STEPS"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"teamChallengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","teamId":"be528s3e-470f-11ea-b77f-2e728ce88125","total":10000,"consumerId":"b491d16e-470f-11ea-b77f-2e728ce88125","status":"COMPLETE","unit":"STEPS"}

PUT /team-outcomes/{teamOutcomeId}

Updates a single team outcome by ID using the specified data. Updating a team outcome does not immediately update the overall rankings and status.

Parameters

Parameter In Type Required Default Description Accepted Values
teamOutcomeId path string true N/A The ID of the team outcome. -
body body putTeamOutcomes true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Success ConsumerEngagementPublicApi_Entities_V1_Challenges_TeamOutcome
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Retrieve a Single Team Outcome

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-1.healtheintent.com/consumer-engagement/v1/team-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "teamChallengeId": "977022b8-470d-11ea-b77f-2e728ce88125",
  "teamId": "8034293c-470d-11ea-b77f-2e728ce88125",
  "consumerId": "86b87178-470d-11ea-b77f-2e728ce88125",
  "total": 10000,
  "rank": 5,
  "status": "COMPLETE",
  "unit": "STEPS",
  "updatedAt": "2018-12-15T12:23:12Z"
}

GET /team-outcomes/{teamOutcomeId}

Retrieves a single team outcome by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Challenges_TeamOutcome
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Create a Team Challenge Outcome

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-1.healtheintent.com/consumer-engagement/v1/team-challenge-outcomes', headers: headers, body: {"teamChallengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","teamId":"be528s3e-470f-11ea-b77f-2e728ce88125","total":10000,"status":"COMPLETE","unit":"STEPS","average":"5000.50"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-challenge-outcomes \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"teamChallengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","teamId":"be528s3e-470f-11ea-b77f-2e728ce88125","total":10000,"status":"COMPLETE","unit":"STEPS","average":"5000.50"}

Example response

{
  "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "teamChallengeId": "977022b8-470d-11ea-b77f-2e728ce88125",
  "teamId": "8034293c-470d-11ea-b77f-2e728ce88125",
  "total": 10000
}

POST /team-challenge-outcomes

Creates an outcome for the team in a team challenge using the specified data. The total is used to calculate the rank of a team compared to totals from other teams in a team challenge.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Challenges_TeamChallengeOutcomeCreateResponse
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Retrieve a List of Team Challenge Outcomes

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-1.healtheintent.com/consumer-engagement/v1/team-challenge-outcomes', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-challenge-outcomes \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
      "teamChallengeId": "977022b8-470d-11ea-b77f-2e728ce88125",
      "teamId": "8034293c-470d-11ea-b77f-2e728ce88125",
      "total": 10000,
      "average": 5000.5,
      "rank": 5,
      "status": "COMPLETE",
      "unit": "STEPS",
      "updatedAt": "2018-12-15T12:23:12Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-challenge-outcomes?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-challenge-outcomes?offset=0&limit=20"
}

GET /team-challenge-outcomes

Retrieves a list of team challenge outcomes. Outcomes by default are sorted by rank. Outcomes can be used for team challenge leaderboards to compare how a particular team performed compared to all the other teams participating in the team challenge.

Parameters

Parameter In Type Required Default Description Accepted Values
teamChallengeId query array[string] false N/A Filters the team challenge outcomes by team challenge ID. -
teamId query array[string] false N/A Filters the team challenge outcomes by team ID. -
status query array[string] false N/A Filters the team challenge outcomes by the completion status of a team for the challenge. The status is based on whether the team met the challenge goal. Possible status values are COMPLETE or INCOMPLETE. -
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 TeamChallengeOutcomes
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error

Delete a Team Challenge Outcome

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-1.healtheintent.com/consumer-engagement/v1/team-challenge-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-challenge-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /team-challenge-outcomes/{teamChallengeOutcomeId}

Deletes a single team challenge outcome by ID. Deleting a team challenge outcome does not immediately update the overall rankings.

Parameters

Parameter In Type Required Default Description Accepted Values
teamChallengeOutcomeId path string true N/A The ID of the team challenge outcome. -

Response Statuses

Status Meaning Description Schema
204 No Content Success None
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Update a Team Challenge Outcome

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-1.healtheintent.com/consumer-engagement/v1/team-challenge-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers, body: {"teamChallengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","teamId":"be528s3e-470f-11ea-b77f-2e728ce88125","total":10000,"status":"COMPLETE","unit":"STEPS","average":"5000.50"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-challenge-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"teamChallengeId":"b95218d0-470f-11ea-b77f-2e728ce88125","teamId":"be528s3e-470f-11ea-b77f-2e728ce88125","total":10000,"status":"COMPLETE","unit":"STEPS","average":"5000.50"}

PUT /team-challenge-outcomes/{teamChallengeOutcomeId}

Updates a single team challenge outcome by ID using the specified data. Updating a team challenge outcome does not immediately update the overall rankings.

Parameters

Parameter In Type Required Default Description Accepted Values
teamChallengeOutcomeId path string true N/A The ID of the team challenge outcome. -
body body putTeamChallengeOutcomes true N/A No description -

Response Statuses

Status Meaning Description Schema
204 No Content Success ConsumerEngagementPublicApi_Entities_V1_Challenges_TeamChallengeOutcome
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Retrieve a Single Team Challenge Outcome

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-1.healtheintent.com/consumer-engagement/v1/team-challenge-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/team-challenge-outcomes/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "94b44ea3-fb6b-4245-886b-caa8e156f125",
  "teamChallengeId": "977022b8-470d-11ea-b77f-2e728ce88125",
  "teamId": "8034293c-470d-11ea-b77f-2e728ce88125",
  "total": 10000,
  "average": 5000.5,
  "rank": 5,
  "status": "COMPLETE",
  "unit": "STEPS",
  "updatedAt": "2018-12-15T12:23:12Z"
}

GET /team-challenge-outcomes/{teamChallengeOutcomeId}

Retrieves a single team challenge outcome by ID

Parameters

Parameter In Type Required Default Description Accepted Values
teamChallengeOutcomeId path string true N/A The ID of the team challenge outcome. -

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Challenges_TeamChallengeOutcome
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
404 Not Found Not Found Error

Create a Goal Observation

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-1.healtheintent.com/consumer-engagement/v1/goal-observations', headers: headers, body: {"consumer":{"id":"94b44ea3-fb6b-4245-886b-caa8e156f125"},"goal":{"id":"5e7f792f-9817-441f-857a-d8c88420711b"},"value":2,"unit":"CUPS","performedAt":"2019-08-20T12:23:12Z","timeZone":"America/New_York"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/goal-observations \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"consumer":{"id":"94b44ea3-fb6b-4245-886b-caa8e156f125"},"goal":{"id":"5e7f792f-9817-441f-857a-d8c88420711b"},"value":2,"unit":"CUPS","performedAt":"2019-08-20T12:23:12Z","timeZone":"America/New_York"}

Example response

{
  "id": "74b44ea3-fb6b-4245-886b-caa8e156f125",
  "consumer": {
    "id": "2281caf2-4757-11ea-b77f-2e728ce88125"
  },
  "goal": {
    "id": "8dc5e868-6250-4c4f-aeb6-6401029cda9d"
  },
  "value": 2,
  "unit": "CUPS",
  "performedAt": "2019-08-20T12:23:12Z",
  "timeZone": "America/New_York",
  "createdAt": "2019-09-15T11:19:11Z",
  "updatedAt": "2020-01-01T12:12:12Z"
}

POST /goal-observations

Creates a goal observation using the specified parameters. A goal observation is tied to a consumer and a goal. Goal observations are used in the challenges product to allow consumers to track their progress in a challenge. Observations for goals with a null value and unit also have a null value and unit. In those scenarios, the observation affirms the consumer completed the goal on the specified date.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Challenges_GoalObservation
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a list of Goal Observations

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-1.healtheintent.com/consumer-engagement/v1/goal-observations', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "74b44ea3-fb6b-4245-886b-caa8e156f125",
      "consumer": {
        "id": "2281caf2-4757-11ea-b77f-2e728ce88125"
      },
      "goal": {
        "id": "8dc5e868-6250-4c4f-aeb6-6401029cda9d"
      },
      "value": 2,
      "unit": "CUPS",
      "performedAt": "2019-08-20T12:23:12Z",
      "timeZone": "America/New_York",
      "createdAt": "2019-09-15T11:19:11Z",
      "updatedAt": "2020-01-01T12:12:12Z"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/goal-observations?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/goal-observations?offset=0&limit=20"
}

GET /goal-observations

Retrieves a list of goal observations.

Parameters

Parameter In Type Required Default Description Accepted Values
consumerId query array[string] false N/A One or more consumer IDs for which to get observations. -
goalId query array[string] false N/A One or more goal IDs for which to get observations. -
startsAt query string false N/A The starting date and time by which to filter observations. -
endsAt query string false N/A The ending date and time by which to filter observations. -
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 GoalObservations
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Delete a Goal Observation

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-1.healtheintent.com/consumer-engagement/v1/goal-observations/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X DELETE https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/goal-observations/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /goal-observations/{goalObservationId}

Deletes a single goal observation by ID.

Parameters

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

Response Statuses

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

Update a Goal Observation

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-1.healtheintent.com/consumer-engagement/v1/goal-observations/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers, body: {"goal":{"id":"5e7f792f-9817-441f-857a-d8c88420711b"},"value":2,"unit":"CUPS","performedAt":"2019-08-20T12:23:12Z","timeZone":"America/New_York"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/goal-observations/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"goal":{"id":"5e7f792f-9817-441f-857a-d8c88420711b"},"value":2,"unit":"CUPS","performedAt":"2019-08-20T12:23:12Z","timeZone":"America/New_York"}

PUT /goal-observations/{goalObservationId}

Updates a goal observation by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
204 No Content No Content ConsumerEngagementPublicApi_Entities_V1_Challenges_GoalObservation
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a single Goal Observation

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-1.healtheintent.com/consumer-engagement/v1/goal-observations/1a857d33-5b74-4c76-9a60-a008ea652cc6', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/goal-observations/1a857d33-5b74-4c76-9a60-a008ea652cc6 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "74b44ea3-fb6b-4245-886b-caa8e156f125",
  "consumer": {
    "id": "2281caf2-4757-11ea-b77f-2e728ce88125"
  },
  "goal": {
    "id": "8dc5e868-6250-4c4f-aeb6-6401029cda9d"
  },
  "value": 2,
  "unit": "CUPS",
  "performedAt": "2019-08-20T12:23:12Z",
  "timeZone": "America/New_York",
  "createdAt": "2019-09-15T11:19:11Z",
  "updatedAt": "2020-01-01T12:12:12Z"
}

GET /goal-observations/{goalObservationId}

Retrieves a single goal observation by ID.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Challenges_GoalObservation
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a List of Aggregated Goal Observations

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-1.healtheintent.com/consumer-engagement/v1/aggregated-goal-observations',
  query: {
  'goalId' => 'string',
'consumerId' => 'array[string]'
}, headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/aggregated-goal-observations?goalId=type,string&consumerId=type,array,items,%5Bobject%20Object%5D \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "items": [
    {
      "consumer": {
        "id": "2281caf2-4757-11ea-b77f-2e728ce88125"
      },
      "goal": {
        "id": "8dc5e868-6250-4c4f-aeb6-6401029cda9d"
      },
      "value": 2,
      "unit": "CUPS",
      "frequency": "DAILY",
      "frequencyStartsAt": "2019-08-20",
      "timeZone": "America/New_York"
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/aggregated-goal-observations?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/aggregated-goal-observations?offset=0&limit=20"
}

GET /aggregated-goal-observations

Retrieves a list of aggregated goal observations. Aggregated observations are combined observations for a challenge over a specified frequency and are used to track a consumer’s progress in a challenge. Observations can be aggregated on a daily or weekly basis. If the goal passed does not have a value, a bad request occurs.

Parameters

Parameter In Type Required Default Description Accepted Values
goalId query string true N/A The goal ID to by which to filter observations. -
consumerId query array[string] true N/A One or more consumer IDs for which to get observations. -
startsAt query string false N/A The start date by which to filter observations. -
endsAt query string false N/A The end date by which to filter observations. -
frequency query string false N/A The frequency on which to aggregate observations. This value can be DAILY or WEEKLY. -
timeZone query string false N/A The time zone used to configure the date and time on which to aggregate observations. -
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 AggregatedGoalObservations
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Questionnaires

Questionnaires are structured sets of questions and instructions presented to collect answers from HealtheIntent consumers. The Questionnaire endpoints enable the creation and presentation of Questionnaires and their answers. Questionnaires can be used to collect data for analysis or to customize the behavior of .HealtheIntent wellness campaigns.

Retrieve a List of Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "items": [
    {
      "id": "e61dd2fa-702d-11e9-a923-1681be663d3e",
      "questionnaireId": "ace20324-a0b9-11e8-98d0-529269fb1459",
      "name": "Cerner Demo Questions Before You Start 2021",
      "type": "CAMPAIGN",
      "locale": "en-US",
      "description": "\\\"Cerner Demo Questions Before You Start 2021\\\" gathers general information from the consumer when they complete a `REGISTRATION WORKFLOW`.",
      "code": {
        "system": "urn:ietf:rfc:3986",
        "code": "2-16-840-1-113883-6-1",
        "display": "something that's not a Personal Health Assessment"
      }
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions?offset=0&limit=20"
}

GET /questionnaire-definitions

Retrieves a list of all the available Questionnaire definitions. A Questionnaire Definition stores metadata for a Questionnaire. Questionnaire Sections, Questionnaire Subsections, and Questionnaire Questions are all scoped to a Questionnaire Definition. The Questionnaire Definition may be changed at anytime but it will not affect a Published Questionnaire. The Questionnaire Definition does not represent a complete Questionnaire.

Parameters

Parameter In Type Required Default Description Accepted Values
questionnaireId query string false N/A Filters by the ID of a questionnaire. -
type query array[string] false N/A Filters by questionnaire types. -
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 QuestionnaireDefinitions
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Create a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions', headers: headers, body: {"name":"Cerner Demo Questions Before You Start 2021","questionnaireId":"ace20324-a0b9-11e8-98d0-529269fb1459","type":"CAMPAIGN","locale":"en-US","description":"\\\"Cerner Demo Questions Before You Start 2021\\\" gathers general information from the consumer when they complete a `REGISTRATION WORKFLOW`.","code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"something that's not a Personal Health Assessment"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Cerner Demo Questions Before You Start 2021","questionnaireId":"ace20324-a0b9-11e8-98d0-529269fb1459","type":"CAMPAIGN","locale":"en-US","description":"\\\"Cerner Demo Questions Before You Start 2021\\\" gathers general information from the consumer when they complete a `REGISTRATION WORKFLOW`.","code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"something that's not a Personal Health Assessment"}}

Example response

{
  "id": "e61dd2fa-702d-11e9-a923-1681be663d3e",
  "questionnaireId": "ace20324-a0b9-11e8-98d0-529269fb1459",
  "name": "Cerner Demo Questions Before You Start 2021",
  "type": "CAMPAIGN",
  "locale": "en-US",
  "description": "\\\"Cerner Demo Questions Before You Start 2021\\\" gathers general information from the consumer when they complete a `REGISTRATION WORKFLOW`.",
  "code": {
    "system": "urn:ietf:rfc:3986",
    "code": "2-16-840-1-113883-6-1",
    "display": "something that's not a Personal Health Assessment"
  }
}

POST /questionnaire-definitions

Creates a new Questionnaire definition. A Questionnaire Definition stores metadata for a Questionnaire. Questionnaire Sections, Questionnaire Subsections, and Questionnaire Questions are all scoped to a Questionnaire Definition. The Questionnaire Definition may be changed at anytime but it will not affect a Published Questionnaire. The Questionnaire Definition does not represent a complete Questionnaire.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Questionnaires_QuestionnaireDefinition
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Delete a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /questionnaire-definitions/{questionnaireDefinitionId}

Deletes a Questionnaire definition. A Questionnaire Definition stores metadata for a Questionnaire. Questionnaire Sections, Questionnaire Subsections, and Questionnaire Questions are all scoped to a Questionnaire Definition. The Questionnaire Definition may be changed at anytime but it will not affect a Published Questionnaire. The Questionnaire Definition does not represent a complete Questionnaire.

Parameters

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

Response Statuses

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

Update a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e', headers: headers, body: {"name":"Cerner Demo Questions Before You Start 2021","questionnaireId":"ace20324-a0b9-11e8-98d0-529269fb1459","type":"CAMPAIGN","locale":"en-US","description":"\\\"Cerner Demo Questions Before You Start 2021\\\" gathers general information from the consumer when they complete a `REGISTRATION WORKFLOW`.","code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"something that's not a Personal Health Assessment"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"name":"Cerner Demo Questions Before You Start 2021","questionnaireId":"ace20324-a0b9-11e8-98d0-529269fb1459","type":"CAMPAIGN","locale":"en-US","description":"\\\"Cerner Demo Questions Before You Start 2021\\\" gathers general information from the consumer when they complete a `REGISTRATION WORKFLOW`.","code":{"system":"urn:ietf:rfc:3986","code":"2-16-840-1-113883-6-1","display":"something that's not a Personal Health Assessment"}}

PUT /questionnaire-definitions/{questionnaireDefinitionId}

Updates a Questionnaire definition. A Questionnaire Definition stores metadata for a Questionnaire. Questionnaire Sections, Questionnaire Subsections, and Questionnaire Questions are all scoped to a Questionnaire Definition. The Questionnaire Definition may be changed at anytime but it will not affect a Published Questionnaire. The Questionnaire Definition does not represent a complete Questionnaire.

Parameters

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

Response Statuses

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

Retrieve a Single Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

Example response

{
  "id": "e61dd2fa-702d-11e9-a923-1681be663d3e",
  "questionnaireId": "ace20324-a0b9-11e8-98d0-529269fb1459",
  "name": "Cerner Demo Questions Before You Start 2021",
  "type": "CAMPAIGN",
  "locale": "en-US",
  "description": "\\\"Cerner Demo Questions Before You Start 2021\\\" gathers general information from the consumer when they complete a `REGISTRATION WORKFLOW`.",
  "code": {
    "system": "urn:ietf:rfc:3986",
    "code": "2-16-840-1-113883-6-1",
    "display": "something that's not a Personal Health Assessment"
  }
}

GET /questionnaire-definitions/{questionnaireDefinitionId}

Retrieves a single Questionnaire definition. A Questionnaire Definition stores metadata for a Questionnaire. Questionnaire Sections, Questionnaire Subsections, and Questionnaire Questions are all scoped to a Questionnaire Definition. The Questionnaire Definition may be changed at anytime but it will not affect a Published Questionnaire. The Questionnaire Definition does not represent a complete Questionnaire.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Questionnaires_QuestionnaireDefinition
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a List of Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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": "something that's not a Personal Health Assessment"
      }
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/questionnaire/v1/questionnaire-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/sections?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/questionnaire/v1/questionnaire-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/sections?offset=0&limit=20"
}

GET /questionnaire-definitions/{questionnaireDefinitionId}/sections

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

Parameters

Parameter In Type Required Default Description Accepted Values
questionnaireDefinitionId path string true N/A The ID of the Questionnaire 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 QuestionnaireSections
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Create a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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":"something that's not a Personal Health Assessment"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-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":"something that's not a 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": "something that's not a Personal Health Assessment"
  }
}

POST /questionnaire-definitions/{questionnaireDefinitionId}/sections

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

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Questionnaires_QuestionnaireSection
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.
Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Delete a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/sections/9a7be7c8-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /questionnaire-definitions/{questionnaireDefinitionId}/sections/{sectionId}

Deletes a Questionnaire section for a Questionnaire definition.

Parameters

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

Response Statuses

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

Update a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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":"something that's not a Personal Health Assessment"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-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":"something that's not a Personal Health Assessment"}}

PUT /questionnaire-definitions/{questionnaireDefinitionId}/sections/{sectionId}

Updates a Questionnaire section for a Questionnaire definition.

Parameters

Parameter In Type Required Default Description Accepted Values
questionnaireDefinitionId path string true N/A The ID of the Questionnaire definition. -
sectionId path string true N/A The ID of the Questionnaire section. -
body body putQuestionnaireDefinitionsQuestionnairedefinitionidSections 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.
Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Single Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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": "something that's not a Personal Health Assessment"
  }
}

GET /questionnaire-definitions/{questionnaireDefinitionId}/sections/{sectionId}

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

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Questionnaires_QuestionnaireSection
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a List of Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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": "something that's not a Personal Health Assessment"
      },
      "section": {
        "id": "12345678-120b-4c1e-81e4-3d3ae9c7580e"
      }
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/subsections?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/subsections?offset=0&limit=20"
}

GET /questionnaire-definitions/{questionnaireDefinitionId}/subsections

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

Parameters

Parameter In Type Required Default Description Accepted Values
questionnaireDefinitionId path string true N/A The ID of the Questionnaire 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 QuestionnaireSubsections
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Create a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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":"2-16-840-1-113883-6-1","system":"urn:ietf:rfc:3986","display":"something that's not a 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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":"2-16-840-1-113883-6-1","system":"urn:ietf:rfc:3986","display":"something that's not a 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": "something that's not a Personal Health Assessment"
  },
  "section": {
    "id": "12345678-120b-4c1e-81e4-3d3ae9c7580e"
  }
}

POST /questionnaire-definitions/{questionnaireDefinitionId}/subsections

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

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Questionnaires_QuestionnaireSubsection
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 Questionnaire section specified for the subsection does not exist.
- PositionNotUnique A section already exists for the specified position.
Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Delete a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/subsections/ace20324-a0b9-11e8-98d0-529269fb1459 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /questionnaire-definitions/{questionnaireDefinitionId}/subsections/{subsectionId}

Deletes a Questionnaire subsection for a Questionnaire definition.

Parameters

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

Response Statuses

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

Update a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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":"2-16-840-1-113883-6-1","system":"urn:ietf:rfc:3986","display":"something that's not a 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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":"2-16-840-1-113883-6-1","system":"urn:ietf:rfc:3986","display":"something that's not a Personal Health Assessment","section":{"id":"12345678-120b-4c1e-81e4-3d3ae9c7580e"}}

PUT /questionnaire-definitions/{questionnaireDefinitionId}/subsections/{subsectionId}

Updates a Questionnaire subsection for a Questionnaire definition.

Parameters

Parameter In Type Required Default Description Accepted Values
questionnaireDefinitionId path string true N/A The ID of the Questionnaire definition. -
subsectionId path string true N/A The ID of the questionnaire subsection. -
body body putQuestionnaireDefinitionsQuestionnairedefinitionidSubsections 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 Questionnaire section specified for the subsection does not exist.
- PositionNotUnique A section already exists for the specified position.
Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Single Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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": "something that's not a Personal Health Assessment"
  },
  "section": {
    "id": "12345678-120b-4c1e-81e4-3d3ae9c7580e"
  }
}

GET /questionnaire-definitions/{questionnaireDefinitionId}/subsections/{subsectionId}

Retrieves a single Questionnaire subsection for a Questionnaire definition.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Questionnaires_QuestionnaireSubsection
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a List of Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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": "something that's not a 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/questions?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/questions?offset=0&limit=20"
}

GET /questionnaire-definitions/{questionnaireDefinitionId}/questions

Retrieves a list of all of the available questions.

Parameters

Parameter In Type Required Default Description Accepted Values
questionnaireDefinitionId path string true N/A The ID of the Questionnaire 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 QuestionnaireQuestions
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Create a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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":"something that's not a 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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":"something that's not a 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": "something that's not a 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 /questionnaire-definitions/{questionnaireDefinitionId}/questions

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

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Questionnaires_QuestionnaireQuestion
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 Questionnaire section specified for the question does not exist.
- SubsectionNotFound The Questionnaire 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.
Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Delete a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions/e61dd2fa-702d-11e9-a923-1681be663d3e/questions/ace20324-a0b9-11e8-98d0-529269fb1459 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /questionnaire-definitions/{questionnaireDefinitionId}/questions/{questionId}

Deletes a Questionnaire question.

Parameters

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

Response Statuses

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

Update a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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":"something that's not a 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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":"something that's not a 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 /questionnaire-definitions/{questionnaireDefinitionId}/questions/{questionId}

Updates a Questionnaire question.

Parameters

Parameter In Type Required Default Description Accepted Values
questionnaireDefinitionId path string true N/A The ID of the Questionnaire definition. -
questionId path string true N/A The ID of the question. -
body body putQuestionnaireDefinitionsQuestionnairedefinitionidQuestions 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 Questionnaire section specified for the question does not exist.
- SubsectionNotFound The Questionnaire 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.
Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Single Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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": "something that's not a 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 /questionnaire-definitions/{questionnaireDefinitionId}/questions/{questionId}

Retrieves a single Questionnaire question.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Questionnaires_QuestionnaireQuestion
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Clone Existing Published Questionnaire

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-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions/83193b19-60d1-4918-a23f-5e46e0ef4e02/clone', headers: headers, body: {"sections":["ace20324-a0b9-11e8-98d0-529269fb1459"],"type":"STANDARD","questionnaireId":"0459f2ec-06e2-43c1-881e-9aeb3a50c1cd","name":"Cerner Demo Questionnaire 2020"}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-definitions/83193b19-60d1-4918-a23f-5e46e0ef4e02/clone \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"sections":["ace20324-a0b9-11e8-98d0-529269fb1459"],"type":"STANDARD","questionnaireId":"0459f2ec-06e2-43c1-881e-9aeb3a50c1cd","name":"Cerner Demo Questionnaire 2020"}

Example response

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

POST /questionnaire-definitions/{questionnaireDefinitionId}/clone

Clone existing questionnaire resources based on the Questionnaire definition ID and the list of section IDs. The following resources will be cloned: questionnaire-definition, sections, subsections, and questions. NOTE: Only the sections, subsections, and questions associated with the provided section IDs will be cloned.

Parameters

Parameter In Type Required Default Description Accepted Values
questionnaireDefinitionId path string true N/A The ID of the Questionnaire definition to clone. -
body body postQuestionnaireDefinitionsQuestionnairedefinitionidClone true N/A No description -

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Questionnaires_QuestionnaireClone
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a List of Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-response-definitions', headers: headers)

print JSON.pretty_generate(result)


# You can also use wget
curl -X GET https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-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",
      "publishedQuestionnaire": {
        "id": "6091627d-b20b-4c1e-81e4-3d3ae9c7580e",
        "name": "Cerner Demo Questionnaire 2019"
      },
      "consumer": {
        "id": "08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"
      },
      "completedQuestionnaireResponses": [
        {
          "id": "cf98baee-c461-11e9-aa8c-2a2ae2dbcce4",
          "authoredAt": "2018-07-16T19:20:00+01:00"
        }
      ]
    }
  ],
  "totalResults": 1,
  "firstLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-response-definitions?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-response-definitions?offset=0&limit=20"
}

GET /questionnaire-response-definitions

Retrieves a list of all the available Questionnaire Response Definitions.

Parameters

Parameter In Type Required Default Description Accepted Values
publishedQuestionnaireId query string false N/A Filters by the ID of a published questionnaire. -
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. QuestionnaireResponseDefinitions
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Create a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-response-definitions', headers: headers, body: {"authoredAt":"2018-07-16T19:20:00+01:00","consumer":{"id":"08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"},"publishedQuestionnaire":{"id":"6091627d-b20b-4c1e-81e4-3d3ae9c7580e","name":"Cerner Demo Questionnaire 2019"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X POST https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-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"},"publishedQuestionnaire":{"id":"6091627d-b20b-4c1e-81e4-3d3ae9c7580e","name":"Cerner Demo Questionnaire 2019"}}

Example response

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

POST /questionnaire-response-definitions

Creates a new Questionnaire response definition. A Questionnaire Response Definition stores metadata for a Questionnaire Response. Questionnaire Response Sections, Questionnaire Response Subsections, and Questionnaire Answers are all scoped to a Questionnaire Response Definition. The Questionnaire Response Definition may be changed at anytime but it will not affect a Completed Questionnaire Response. The Questionnaire Response Definition does not represent a complete Questionnaire Response.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Questionnaires_QuestionnaireResponseDefinition
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:
- QuestionnaireDefinitionNotFound The Questionnaire definition specified for the response does not exist.
Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Delete a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /questionnaire-response-definitions/{questionnaireResponseDefinitionId}

Deletes a Questionnaire response definition.

Parameters

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

Response Statuses

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

Update a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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"},"publishedQuestionnaire":{"id":"6091627d-b20b-4c1e-81e4-3d3ae9c7580e","name":"Cerner Demo Questionnaire 2019"}}.to_json )

print JSON.pretty_generate(result)




# You can also use wget
curl -X PUT https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-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"},"publishedQuestionnaire":{"id":"6091627d-b20b-4c1e-81e4-3d3ae9c7580e","name":"Cerner Demo Questionnaire 2019"}}

PUT /questionnaire-response-definitions/{questionnaireResponseDefinitionId}

Updates a Questionnaire response definition.

Parameters

Parameter In Type Required Default Description Accepted Values
questionnaireResponseDefinitionId path string true N/A The ID of the questionniare response definition. -
body body putQuestionnaireResponseDefinitions 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:
- QuestionnaireDefinitionNotFound The Questionnaire definition specified for the response does not exist.
Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Single Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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",
  "publishedQuestionnaire": {
    "id": "6091627d-b20b-4c1e-81e4-3d3ae9c7580e",
    "name": "Cerner Demo Questionnaire 2019"
  },
  "consumer": {
    "id": "08f464c0-4ce1-4cec-8e3c-9107ea17a1d7"
  },
  "completedQuestionnaireResponses": [
    {
      "id": "cf98baee-c461-11e9-aa8c-2a2ae2dbcce4",
      "authoredAt": "2018-07-16T19:20:00+01:00"
    }
  ]
}

GET /questionnaire-response-definitions/{questionnaireResponseDefinitionId}

Retrieves a single Questionnaire response definition.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Questionnaires_QuestionnaireResponseDefinition
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a List of Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-sections?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-sections?offset=0&limit=20"
}

GET /questionnaire-response-definitions/{questionnaireResponseDefinitionId}/response-sections

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

Parameters

Parameter In Type Required Default Description Accepted Values
questionnaireResponseDefinitionId path string true N/A The ID of the questionniare 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 QuestionnaireResponseSections
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Create a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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

{
  "questionnaireResponseSections": [
    {
      "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 /questionnaire-response-definitions/{questionnaireResponseDefinitionId}/response-sections

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

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Questionnaires_QuestionnaireResponseSectionGroup
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:
- QuestionnaireSectionNotFound The Questionnaire section specified for the response section does not exist.
- QuestionnaireQuestionNotFound The Questionnaire 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.
Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Delete a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-sections/9a7bdd28-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /questionnaire-response-definitions/{questionnaireResponseDefinitionId}/response-sections/{responseSectionId}

Deletes a Questionnaire response section for a Questionnaire response.

Parameters

Parameter In Type Required Default Description Accepted Values
questionnaireResponseDefinitionId 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 Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Update a Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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 /questionnaire-response-definitions/{questionnaireResponseDefinitionId}/response-sections/{responseSectionId}

Updates a Questionnaire response section for a Questionnaire response.

Parameters

Parameter In Type Required Default Description Accepted Values
questionnaireResponseDefinitionId path string true N/A The ID of the questionniare response definition. -
responseSectionId path string true N/A The ID of the Questionnaire response section. -
body body putQuestionnaireResponseDefinitionsQuestionnaireresponsedefinitionidResponseSections 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:
- QuestionnaireSectionNotFound The Questionnaire section specified for the response section does not exist.
- QuestionnaireQuestionNotFound The Questionnaire 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.
Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a Single Questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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 /questionnaire-response-definitions/{questionnaireResponseDefinitionId}/response-sections/{responseSectionId}

Retrieves a single Questionnaire response section for a Questionnaire response.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Questionnaires_QuestionnaireResponseSection
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a List of questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-subsections?offset=0&limit=20",
  "lastLink": "https://cernerdemo.api.us-1.healtheintent.com/consumer-engagement/v1/questionnaire-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-subsections?offset=0&limit=20"
}

GET /questionnaire-response-definitions/{questionnaireResponseDefinitionId}/response-subsections

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

Parameters

Parameter In Type Required Default Description Accepted Values
questionnaireResponseDefinitionId path string true N/A The ID of the questionniare 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. QuestionnaireResponseSubsections
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Create a questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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 /questionnaire-response-definitions/{questionnaireResponseDefinitionId}/response-subsections

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

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Questionnaires_QuestionnaireResponseSubsection
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:
- questionnaireSubsectionNotFound The questionnaire subsection specified for the response subsection does not exist.
- questionnaireQuestionNotFound The questionnaire 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.
Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Delete a questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-response-definitions/e3e44e50-5c65-11e9-8647-d663bd873d93/response-subsections/9a7bdd28-5c65-11e9-8647-d663bd873d93 \
-H 'Authorization: {auth_header}' \
-H 'Accept: application/json'

DELETE /questionnaire-response-definitions/{questionnaireResponseDefinitionId}/response-subsections/{responseSubsectionId}

Deletes a questionnaire response subsection for a questionnaire response.

Parameters

Parameter In Type Required Default Description Accepted Values
questionnaireResponseDefinitionId 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 Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Update a questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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 /questionnaire-response-definitions/{questionnaireResponseDefinitionId}/response-subsections/{responseSubsectionId}

Updates a questionnaire response subsection for a questionnaire response.

Parameters

Parameter In Type Required Default Description Accepted Values
questionnaireResponseDefinitionId path string true N/A The ID of the questionniare response definition. -
responseSubsectionId path string true N/A The ID of the Questionnaire response subsection. -
body body putQuestionnaireResponseDefinitionsQuestionnaireresponsedefinitionidResponseSubsections true N/A No description -

Response Statuses

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

Retrieve a Single questionnaire 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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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-1.healtheintent.com/consumer-engagement/v1/questionnaire-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 /questionnaire-response-definitions/{questionnaireResponseDefinitionId}/response-subsections/{responseSubsectionId}

Retrieves a single questionnaire response subsection for a questionnaire response.

Parameters

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

Response Statuses

Status Meaning Description Schema
200 OK Success ConsumerEngagementPublicApi_Entities_V1_Questionnaires_QuestionnaireResponseSubsection
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error
404 Not Found Not Found Error

Retrieve a List of Published Questionnaires

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-1.healtheintent.com/consumer-engagement/v1/published-questionnaires', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
  "name": "Cerner Demo Questionnaire 2021",
  "createdAt": "2021-02-09T17:11:24.000Z"
}

GET /published-questionnaires

Retrieves a list of all the available published questionnaires. A Published Questionnaire combines a Questionnaire Definition, Questionnaire Sections, Questionnaire Subsections, and Questionnaire Questions into a single resource. The Published Questionnaire is an immutable representation of a complete Questionnaire. The Published Questionnaire should be the resource that is referenced by external Services.

Parameters

Parameter In Type Required Default Description Accepted Values
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 Success PublishedQuestionnaireLists
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Create a Published Questionnaire

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-1.healtheintent.com/consumer-engagement/v1/published-questionnaires', headers: headers, body: {"questionnaireDefinition":{"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-1.healtheintent.com/consumer-engagement/v1/published-questionnaires \
-H 'Authorization: {auth_header}' \
-H 'Content-Type: application/json' \ \
-H 'Accept: application/json' \
-d {"questionnaireDefinition":{"id":"e61dd2fa-702d-11e9-a923-1681be663d3e"}}

Example response

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

POST /published-questionnaires

Creates a new published questionnaire. A Published Questionnaire combines a Questionnaire Definition, Questionnaire Sections, Questionnaire Subsections, and Questionnaire Questions into a single resource. The Published Questionnaire is an immutable representation of a complete Questionnaire. The Published Questionnaire should be the resource that is referenced by external Services.

Parameters

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

Response Statuses

Status Meaning Description Schema
201 Created Created ConsumerEngagementPublicApi_Entities_V1_Questionnaires_PublishedQuestionnaire
400 Bad Request Bad Request Error
401 Unauthorized Unauthorized Error
403 Forbidden Forbidden Error

Retrieve a Single Published Questionnaire

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-1.healtheintent.com/consumer-engagement/v1/published-questionnaires/69c7f20d-a568-4bfd-ae0b-4475e0e2dd7f', headers: headers)

print JSON.pretty_generate(result)


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

Example response

{
  "id": "ace20324-a0b9-11e8-98d0-529269fb1459",
  "questionnaireDefinition": {
    "id": "e61dd2fa-702d-11e9-a923-1681be663d3e",
    "questionnaireId": "ace20324-a0b9-11e8-98d0-529269fb1459",
    "name": "Cerner Demo Questions Before You Start 2021",
    "type": "CAMPAIGN",
    "locale": "en-US",
    "description": "\\\"Cerner Demo Questions Before You Start 2021\\\" gathers general information from the consumer when they complete a `REGISTRATION WORKFLOW`.",
    "code": {
      "system": "urn:ietf:rfc:3986",