NAV Navbar
Logo cerner
ruby shell

Consumer API

The Consumer API provides details about a consumer. The consumer data can come from multiple sources, each having an assigning_authority and alias_id combination that maps to the consumer’s ID. Once the consumer’s ID is known, a request can be made to get further consumer details.

Calling the Service

To get details about a consumer, you must make two separate calls: The first call is a search using the name ID alias that returns a list of high-level profile objects. The second call is a direct call to get details, passing in the ID that was returned from the first call.

Lookup Consumer by Alias

GET https://{client}.consumerportal.healtheintent.com/clients/{client_id}/consumers?assigning_authority={assigning_authority}&alias_id={alias_id}

The goal of the alias lookup is to retrieve the consumer ID. The returned response ID represents the consumer ID. Once this consumer ID is found, further details can be requested in the consumer fetch request below.

Example Request:

require 'httparty'

HTTParty.get(
  'https://{client}.consumerportal.healtheintent.com/clients/1c243940-7f30-46a7-94b9-965466a7fefd/consumers?alias_id=f33d3a68-ea5d-488f-94a6-6ff304f16427&assigning_authority=1234',
    headers: { 
      'Authorization' => 'auth_header',
      'Accept' => 'application/json'
    }
)
curl -X GET -H 'Authorization: <auth_header>' -H 'Accept: application/json' 'https://{client}.consumerportal.healtheintent.com/clients/1c243940-7f30-46a7-94b9-965466a7fefd/consumers?alias_id=f33d3a68-ea5d-488f-94a6-6ff304f16427&assigning_authority=1234'

Example Response:

{
  "id": "f33d3a68-ea5d-488f-94a6-6ff304f16427",
  "names": [],
  "addresses": [],
  "aliases": [],
  "links": [],
  "verification": null,
  "date_of_birth": "2017-09-12T13:18:23.537Z",
  "client_id": "1c243940-7f30-46a7-94b9-965466a7fefd",
  "phone_numbers": [],
  "email_addresses": [],
  "updated_date_time": "2017-09-12T13:18:23.537Z",
  "gender_free_text": null
}

Path Parameters

Field Description
client_id The ID of the client

Query Parameters

Field Description
alias_id The ID of the person’s alias
assigning_authority The ID of the assigning authority

Responses

Status Type Description
200 ConsumerResponse The consumer response structure
400 N/A Bad Request
401 N/A Unauthorized
403 N/A Forbidden
404 N/A Resource Not Found
500 N/A Internal Server Error

Get Consumer

Example Request:

require 'httparty'

HTTParty.get(
  'https://{client}.consumerportal.healtheintent.com/clients/1c243940-7f30-46a7-94b9-965466a7fefd/consumers/f33d3a68-ea5d-488f-94a6-6ff304f16427',
    headers: { 
      'Authorization' => 'auth_header',
      'Accept' => 'application/json'
    }
)
curl -X GET -H 'Authorization: <auth_header>' -H 'Accept: application/json' 'https://{client}.consumerportal.healtheintent.com/clients/1c243940-7f30-46a7-94b9-965466a7fefd/consumers/f33d3a68-ea5d-488f-94a6-6ff304f16427'

Example Response:

{
  "id": "f33d3a68-ea5d-488f-94a6-6ff304f16427",
  "names": [
    {
      "id": 630575,
      "family_name": "Smith",
      "middle_name": "C",
      "given_name": "John",
      "display_name": "John Smith",
      "primary": true,
      "title": "Mr.",
      "prefix": "Sir",
      "suffix": "Jr.",
      "verification": {
        "type": "home",
        "status": "FAILED",
        "system": "ext",
        "date_time": "2016-04-28T16:00:49Z"
      }
    }
  ],
  "addresses": [
    {
      "id": 71651,
      "type": "WORK",
      "formatted": "202 S. Main St, Kansas City, MO 64138",
      "street_address": "202 S Main",
      "locality": "Kansas City",
      "region": "Kansas City Metro",
      "postal_code": "64138",
      "country": "US",
      "primary": false
    }
  ],
  "aliases": [
    {
      "id": "1c243940-7f30-46a7-94b9-965466a7fefd:CONSUMER:assigning:test-06-principal",
      "alias_id": "test-06-principal",
      "alias_type": "USER",
      "assigning_authority": "assigning",
      "source_type": "external",
      "verification": {
        "type": "home",
        "status": "SUCCESS",
        "system": "ext",
        "date_time": "2016-04-28T16:00:49Z"
      }
    },
    {
      "id": "0e25f365-9ffc-4323-9846-1e000023511d:CONSUMER:assigning:test-06-consumer",
      "alias_id": "test-06-consumer",
      "alias_type": "USER",
      "assigning_authority": "assigning",
      "source_type": "NAME_ID_ALIAS",
      "verification": {
        "type": "home",
        "status": "FAILED",
        "system": "ext",
        "date_time": "2016-04-28T16:00:49Z"
      }
    }
  ],
  "links": [
    {
      "type": "UNKNOWN",
      "status": "PENDING",
      "target_system_name": "sys",
      "target_system_identifier": "id",
      "target_object_type": "object_taco",
      "target_id": "target_taco",
      "assurance_level": 3,
      "external_href": "https://www.google.com/"
    }
  ],
  "verification": {
    "type": "home",
    "status": "SUCCESS",
    "system": "ext",
    "date_time": "2016-04-28T16:00:49Z"
  },
  "date_of_birth": "2017-09-12T13:18:23.537Z",
  "client_id": "1c243940-7f30-46a7-94b9-965466a7fefd",
  "phone_numbers": [
    {
      "id": 219242,
      "type": "type",
      "value": "8165554433",
      "primary": "true",
      "verification": {
        "type": "home",
        "status": "FAILED",
        "system": "ext",
        "date_time": "2016-04-28T16:00:49Z"
      }
    }
  ],
  "email_addresses": [
    {
      "id": 5051,
      "primary": true,
      "type": "PRIMARY",
      "value": "test@example.com",
      "verification": {
        "type": "home",
        "status": "FAILED",
        "system": "ext",
        "date_time": "2016-04-28T16:00:49Z"
      }
    }
  ],
  "updated_date_time": "2017-09-12T13:18:23.537Z",
  "gender_free_text": "Other"
}

GET https://{client}.consumerportal.healtheintent.com/clients/{client_id}/consumers/{consumer_id}

After retrieving the consumer ID from the alias search response, you can request further consumer details.

Path Parameters

Field Description
client_id The ID of the client
consumer_id The ID of the consumer

Responses

Status Type Description
200 ConsumerResponse The consumer response structure
400 N/A Bad Request
401 N/A Unauthorized
403 N/A Forbidden
404 N/A Resource Not Found
500 N/A Internal Server Error

Consumer API Definitions

Address

Name Type Description
id integer The ID of the address
type string The type of address
formatted string The formatted address
locality string The locality of the address
region string The region of the address
country string The country in which the address resides
primary boolean The primary indicator of the address
verification Verification An object indicating if address information has been verified by an external system
postal_code string The postal code of the address
street_address string The street address

Alias

Name Type Description
id string The unique identifier for an alias with respect to client and assigning authority
verification Verification An object indicating if alias information has been verified by an external system
source_type string The source type of the alias
alias_type string The type of the alias
alias_id string The ID of the alias
assigning_authority string The assigning authority of the alias

ConsumerResponse

Name Type Description
id string The ID of the response
names array:Name The names of the person
addresses array:Address The addresses of the person
aliases array:Alias A list of aliases to external systems
links array:Link List of links to records in external systems
verification Verification An object indicating if person information has been verified by an external system
date_of_birth string The date of birth of the person in ISO 8601 format
client_id string The ID of the Cerner client
phone_numbers array:Phone The phone numbers of the person
email_addresses array:Email The email addresses of the person
gender_free_text string The free text description of the person’s gender
updated_date_time string The updated date and time of the person record in ISO 8601 format

Email

Name Type Description
id integer The ID of the email
type string The type of the email
value string The value of the email
primary boolean The primary indicator of the email
verification Verification An object indicating if email information has been verified by an external system
Name Type Description
status string The status of the external link
target_system_name string The target system name of the link
assurance_level integer The assurance level of the link
external_href string The external href of the link
target_id string The target ID of the link
target_object_type string The target object type of the link
target_system_identifier string The target system identifier of the link

Name

Name Type Description
id integer The ID of the name
primary boolean The primary name of the person
title string The title of the person
prefix string The prefix to the name
suffix string The suffix to the name
verification Verification An object indicating if name information has been verified by an external system
family_name string The family name of the person
middle_name string The middle name of the person
given_name string The given name of the person
display_name string The display name of the person

Phone

Name Type Description
id integer The ID of the phone number
type string The type of the phone number
value string The value of the phone number
primary boolean The primary indicator of the phone number
verification Verification An object indicating if phone information has been verified by an external system

Verification

Name Type Description
type string The type of verification
status string The status of the verification
system string The verifying system
date_time string The date and time of the verification in ISO 8601 format