workplaces

The workplaces query is used to provide records of workplaces/HCOs that match input filters.

Schema

 

 

type Query {

    workplaces(

        first: Int=10,

        offset: Int=0,

        parent: String,

        individuals: [String!],

        workplaces: [String!],

        specialties: [String!],

        medTerms: [String!],

        professionalType: String,

        criteria: String,

        criteriaScope: WorkplaceCriteriaScope,

        criterias: [WorkplaceCriteria],

        sortScope: WorkplaceSortScope,

        sorts: [WorkplaceSortScope]

        locale: String,

        location: GeopointQuery,

        country: String,

        county: String

    ): WorkplacesResult

}

 

 

Field

Type

Description

first

Int

Optional for pagination. Specifies ...

10 (default)

... to limit the number of results to get for the first page. The same number to limit results can be specified again to limit results for each of the following pages.

If this limit exceeds the server's number, then number of results is determined by the server.

offset

Int

Optional for pagination. Specifies ...

0 (default)

... to not offset the first number of results for the first page. However, offset is required for a following page to skip <total number results already retrieved on previous pages> to the next number to get from remaining results. For example:

  "offset: Int = 0" and "first: Int = 10" gets first 10 results for page 1

  "offset: Int = 10" and "first: Int = 10" skips first 10 results to get next 10 results for page 2

  "offset: Int = 20" and "first: Int = 10" skips first 20 results to get next 10 results for page 3

parent

String

 

individuals

[String!]

Optional. Restrict the search to activities associated with a set of HCPs. Expected values are individual IDs.

Review the HCPs that come with your subscription.

workplaces

[String!]

Optional. Restrict the search to activities associated with a set of HCOs. Expected values are workplace IDs.

Review the HCOs that come with your subscription.

specialties

[String!]

Optional. Restrict the search to activities involving an HCP who is profiled with one of the specialties. Expected values are specialty or international specialty codes.

Review the specialties that come with your subscription.

medTerms

[String!]

Optional. Restrict the search to activities involving an HCP who is profiled with one of the medical terms. Expected values are medical term codes.

Review the medical terms that come with your subscription.

professionalType

String

Optional. Restrict the search to activities of HCPs having a specific professional type.

criteria

String

Optional. Specifies free text as criteria for the search. The internal criteria text usage is bound to the scope (in the criteriaScope field). For example:

criteria: "John doe"  

criteriaScope

WorkplaceCriteriaScope

Optional. Specifies the scope of the criteria free text. Value is one of the following:

  Name

  Specialties

  MedTerms

Default value is "WorkplaceCriteriaScopeName".

criterias

[WorkplaceCriteria]

Optional. Specifies free text (in the criteria field) and scope (in criteriaScope field) that gets applied to the query for the search. For example:

criterias: [{

  text:"John doe",

  scope:WorkplaceCriteriaScopeName

}]

 

sortScope

WorkplaceSortScope

Optional. Specifies the scope of result sorting. Value is one of the following:

  Distance

  Name

  Relevancy

sorts

[WorkplaceSortScope]

Optional. Specifies the list of sort scopes to apply to results. Sorts are applied in the same order as provided.

locale

String

Optional. Specifies the language in which translatable fields are translated.

If not specified, then the default locale "en" is used.

location

GeopointQuery

Optional. Restrict the search to activities around a specific geolocation.

country

String

Optional. Restrict the search to activities within a specific country.

county

CountyQuery

Optional. Restrict the search to activities within a specific county.

 

 

 

Response

IndividualsResult

A JSON response with an object of the WorkplacesResult type as a result, which is a list of one or more HCOs.

Fault

ActivityException

If a server error occurs or an incorrect input is specified.

Discussion

Criteria in this query is from a "search request" made by your app for a search on HCOs, such as a search inputted (with the help of autocomplete suggestions) on the prebuilt  Search block.

This query is sent to the Autocomplete endpoint of the Activity API.

Availability

HealthCare Locator SDK 1.2.15 and higher

GraphQL Activity API 2.0