GoogleApi.HealthCare.V1beta1.Api.Projects.healthcare_projects_locations_datasets_fhir_stores_fhir_conditional_update
healthcare_projects_locations_datasets_fhir_stores_fhir_conditional_update
, go back to GoogleApi.HealthCare.V1beta1.Api.Projects module for more information.
healthcare_projects_locations_datasets_fhir_stores_fhir_conditional_update(connection, projects_id, locations_id, datasets_id, fhir_stores_id, fhir_id, optional_params \\ [], opts \\ [])
View SourceSpecs
healthcare_projects_locations_datasets_fhir_stores_fhir_conditional_update( Tesla.Env.client(), String.t(), String.t(), String.t(), String.t(), String.t(), keyword(), keyword() ) :: {:ok, GoogleApi.HealthCare.V1beta1.Model.HttpBody.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()}
If a resource is found based on the search criteria specified in the query parameters, updates the entire contents of that resource. Implements the FHIR standard conditional update interaction (DSTU2, STU3, R4). Search terms are provided as query parameters following the same pattern as the search method. If the search criteria identify more than one match, the request returns a 412 Precondition Failed
error. If the search criteria identify zero matches, and the supplied resource body contains an id
, and the FHIR store has enable_update_create set, creates the resource with the client-specified ID. It is strongly advised not to include or encode any sensitive data such as patient identifiers in client-specified resource IDs. Those IDs are part of the FHIR resource path recorded in Cloud Audit Logs and Pub/Sub notifications. Those IDs can also be contained in reference fields within other resources. If the search criteria identify zero matches, and the supplied resource body does not contain an id
, the resource is created with a server-assigned ID as per the create method. The request body must contain a JSON-encoded FHIR resource, and the request headers must contain Content-Type: application/fhir+json
. On success, the response body contains a JSON-encoded representation of the updated resource, including the server-assigned version ID. Errors generated by the FHIR store contain a JSON-encoded OperationOutcome
resource describing the reason for the error. If the request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead. This method requires thehealthcare.fhirStores.searchResources
and healthcare.fhirResources.update
permissions on the parent FHIR store. For samples that show how to call conditionalUpdate
, see Conditionally updating a FHIR resource.
Parameters
-
connection
(type:GoogleApi.HealthCare.V1beta1.Connection.t
) - Connection to server -
projects_id
(type:String.t
) - Part ofparent
. The name of the FHIR store this resource belongs to. -
locations_id
(type:String.t
) - Part ofparent
. See documentation ofprojectsId
. -
datasets_id
(type:String.t
) - Part ofparent
. See documentation ofprojectsId
. -
fhir_stores_id
(type:String.t
) - Part ofparent
. See documentation ofprojectsId
. -
fhir_id
(type:String.t
) - Part oftype
. The FHIR resource type to update, such as Patient or Observation. For a complete list, see the FHIR Resource Index (DSTU2, STU3, R4). Must match the resource type in the provided content. -
optional_params
(type:keyword()
) - Optional parameters-
:"$.xgafv"
(type:String.t
) - V1 error format. -
:access_token
(type:String.t
) - OAuth access token. -
:alt
(type:String.t
) - Data format for response. -
:callback
(type:String.t
) - JSONP -
:fields
(type:String.t
) - Selector specifying which fields to include in a partial response. -
:key
(type:String.t
) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. -
:oauth_token
(type:String.t
) - OAuth 2.0 token for the current user. -
:prettyPrint
(type:boolean()
) - Returns response with indentations and line breaks. -
:quotaUser
(type:String.t
) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. -
:uploadType
(type:String.t
) - Legacy upload protocol for media (e.g. "media", "multipart"). -
:upload_protocol
(type:String.t
) - Upload protocol for media (e.g. "raw", "multipart"). -
:body
(type:GoogleApi.HealthCare.V1beta1.Model.HttpBody.t
) -
-
-
opts
(type:keyword()
) - Call options
Returns
-
{:ok, %GoogleApi.HealthCare.V1beta1.Model.HttpBody{}}
on success -
{:error, info}
on failure