Practitioner Create


Practitioner creation API definition


In order to create a Practitioner it is required to send a Practitioner Resource.


Method Endpoint URI Parameters Request Headers Request Body Response Body Security
POST https://[host]/partners/fhir/stu3/api/[Resource] Resource: Practitioner
org_id : Organization OID

x-origin-request-id: Request unique id, generated by EMR middleware

client_id : Public identifier for organizations generated by Roche DC

client_secret : Client related secret known only to the EMR and Roche DC

Content-Type: Default value application/json
Practitioner Resource - Please check Request Definition Please check Response Definition Mutual TLS Authentication (mTLS)

Complete FHIR API Specification here

Request Definition


  • Please find Practitioner Resource Schema Overview here
  • Please find Sample Practitioner here
  • Please find Practitioner Example cURL Request here
  • Please find FHIR STU3 Schema here

Response Definition


Success response: On successful creation of Practitioner through API will return HTTP 200 Status Code and Roche internal ID is returned for Practitioner ID in the body of response.

  • Please find Example Response here

Error response: Please check error codes in validation section below.


Uniqueness

In RDCP the practitioner is uniquely identified by the email.
Note: if a practitioner is created with the same email an “duplicate” error will be thrown.


Data Validation


Validation Error code
A required element is missing. required
A structural issue in the content such as wrong namespace, or unable to parse the content completely, or invalid json syntax structure
An internal timeout has occurred. timeout
An unexpected internal error has occurred. exception
Content invalid against the specification or a profile. invalid
Provided content is too long (typically, this is a denial of service protection type of error). too-long
An attempt was made to create a duplicate record. duplicate

Please find Error handling details here


Response Time


The average and the worst case scenario response time for the practitioner creation API are:

Response Time (ms)
Average 1391.93
Worst case scenario 9203

Sample Practitioner

Scenario: A practitioner creation request is sent with the following details:

  • Other details like name, telecome etc as mentioned in the sample below.

Note : under telecom 'email' is mandatory and other values (phone, fax, pager, url, sms, other) are optional.

Command 'json' could not render: Project was not found for bundle-practitioner-create.json.

Example Request


Example cURL Request:


curl -L -X POST 'https://api-services-demo.rochedcplatform-sandbox.com/partners/fhir/stu3/api/Practitioner' -H 'client_id: {CLIENT_ID}' -H 'client_secret: {CLIENT_SECRET}' -H 'org_id: {ORG_ID}' -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'x-request-id: 12345678' --data-raw '{
    "id": "abdca832-a616-454b-b5c7-f1ed1fb45d4e",
    "resourceType": "Practitioner",
    "meta": {
        "profile":  [
            "http://roche.com/fhir/rdc/StructureDefinition/practitioner-v2"
        ]
    },
    "identifier":  [
        {
            "system": "urn:oid:2.16.724.4.305",
            "value": "999999991A"
        }
    ],
    "active": "true",
    "name":  [
        {
            "family": "Pérez Fuster",
            "given":  [
                "Manolo"
            ]
        }
    ],
    "telecom":  [
        {
            "system": "email",
            "value": "bla@bla.com"
        },
        {
            "system": "phone",
            "value": "555-12345"
        }
    ],
    "gender": "male",
    "birthDate": "1975-06-16"
}'

Example Response

{ "identifier": [ { "system": "urn:oid:2.16.724.4.305", "value": "92999929A" } ], "gender": "male", "meta": { "profile": [ "http://roche.com/fhir/rdc/StructureDefinition/practitioner-v2" ] }, "name": [ { "given": [ "Charles" ], "family": "Perez Fuster" } ], "active": "true", "telecom": [ { "system": "email", "value": "2222@testes2.com" } ], "id": "92999929A", "birthDate": "1975-06-16", "resourceType": "Practitioner" }