v1

latestOpenAPI 3.0.0Creative Commons Attribution 3.02026-07-1376177324.7 KB
projects

Creates a FHIR resource. Implements the FHIR standard create interaction (DSTU2, STU3, R4, R5), which creates a new resource with a server-assigned resource ID. Also supports the FHIR standard conditional create interaction (DSTU2, STU3, R4, R5), specified by supplying an If-None-Exist header containing a FHIR search query, limited to searching by resource identifier. If no resources match this search query, the server processes the create operation as normal. When using conditional create, the search term for identifier should be in the pattern identifier=system|value or identifier=value - similar to the search method on resources with a specific identifier. 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 resource as it was created on the server, including the server-assigned resource ID and 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. For samples that show how to call create, see Creating a FHIR resource.

post/v1/{+parent}/fhir/{+type}

Path parameters

parentstring required

Required. The name of the FHIR store this resource belongs to.

typestring required

Required. The FHIR resource type to create, such as Patient or Observation. For a complete list, see the FHIR Resource Index (DSTU2, STU3, R4, R5). Must match the resource type in the provided content.

Request body

extensionsobject[]

Application specific response metadata. Must be set in the first response for streaming APIs.

datastring byte

The HTTP request/response body as raw binary.

contentTypestring

The HTTP Content-Type header value specifying the content type of the body.

Response

Successful response