Skip to main content
POST
Create Resource
Creates a new FHIR resource. The server assigns a unique ID and returns the created resource with metadata.

Endpoint

string
required
The FHIR resource type (e.g., Patient, Observation, Encounter)

Headers

string
required
Must be application/fhir+json or application/fhir+xml
string
Response format: application/fhir+json (default) or application/fhir+xml
string
Response style:
  • return=representation (default) - Return full resource
  • return=minimal - Return headers only
  • return=OperationOutcome - Return OperationOutcome
string
Conditional create. Search parameters to check for existing resource.Example: identifier=http://hospital.example/mrn|12345

Request Body

ID in Body: Any id field in the request body is ignored. The server always assigns IDs for POST requests. Use PUT if you need to specify the ID.

Response

201 Created

Resource created successfully. Returns the new resource with server-assigned metadata.
string
required
Server-assigned unique identifier (typically UUID)
string
required
Version number (starts at “1”)
string
required
ISO 8601 timestamp of creation

200 OK (Conditional Create - Existing Resource)

When using If-None-Exist and a matching resource already exists.

400 Bad Request

Validation failed or malformed request.

412 Precondition Failed

Conditional create found multiple matching resources (ambiguous).

422 Unprocessable Entity

Resource violates business rules or profile constraints.

Examples

See Also

Update Resource

Update with PUT (can create with custom ID)

Read Resource

Retrieve created resource

Batch Create

Create multiple resources in one request

Learn FHIR CRUD

Understand FHIR’s create operation

Authorizations

Authorization
string
header
required

Bearer token authentication

Path Parameters

resourceType
string
required

The FHIR resource type (e.g., Patient, Observation, Encounter)

Body

The FHIR resource to create

A FHIR resource. All resources have resourceType, id, and meta fields.

resourceType
string
required

The type of resource

id
string

Logical id of this artifact

meta
object

Metadata about a resource

Response

Resource already exists (conditional create)

A FHIR resource. All resources have resourceType, id, and meta fields.

resourceType
string
required

The type of resource

id
string

Logical id of this artifact

meta
object

Metadata about a resource