Guest Referral

Create a patient referral in a Salesforce org from an OOTB guest web form.

When you send a request to create a patient referral, the API creates records in multiple objects, such as PersonAccount, ClinicalServiceRequest, and ClinicalServiceRequestDetail to store the patient referral information.

Resource 

1/connect/health/referral-management/guest-referrals

Resource Example 

Replace {yourInstance} with the My Domain name of your Salesforce org.

1https://{yourInstance}.salesforce.com/services/data/v68.0/connect/health/referral-management/guest-referrals

Available Version 

60.0

HTTP Methods 

POST

JSON example 

Here’s an example request to create a patient referral from the OOTB web form filled by a guest user.

1{
2   "captchaToken":{
3      "type":"ReCaptcha",
4      "token":"09APYnBZUChiG3s985dvsz9eHvoAMIoa6lB0qeDvL-pZjNvZ3Qg9HgZVRo4rAxebgl_7H1ZqavwGwecshDuL0K1K9rfv0eI_dn7pqyGA",
5      "siteKeyDeveloperName":"GoogleSiteKey"
6   },
7   "patient":{
8      "fields":{
9         "FirstName":"Charles",
10         "LastName":"Green",
11         "Phone":"8012345678"
12      }
13   },
14   "referralDetails":[
15      {
16         "detailType":"Insurance",
17         "detailRecordType":"Member Plan",
18         "fields":{
19            "Name":"Aetna PPO",
20            "MemberNumber":"2345678"
21         }
22      },
23      {
24         "detailType":"Based On",
25         "detailRecordType":"Health Condition",
26         "fields":{
27            "Condition Status":"Condition",
28            "Diagnostic Status":"Status"
29         }
30      }
31   ],
32   "referralNotes":"This is an urgent request",
33   "referral":{
34      "fields":{
35         "PatientInstruction":"Need Appointment ASAP.",
36         "Priority":"Urgent"
37      }
38   }
39}

Here’s an example request to create a patient referral with the provided performers and requesters in the OOTB guest web form.

1{
2   "captchaToken": {
3        "type": "ReCaptcha",
4        "token": "09APYnBZUChiG3s985dvsz9eHvoAMIoa6lB0qeDvL-pZjNvZ3Qg9HgZVRo4rAxebgl_7H1ZqavwGwecshDuL0K1K9rfv0eI_dn7pqyGA",
5        "siteKeyDeveloperName": "GoogleSiteKey"
6    },
7  "patient": {
8    "fields": {
9      "FirstName": "Joe",
10      "LastName": "Clark",
11      "Phone": "801XXXXX89"
12    }
13  },
14  "referralDetails": [
15    {
16      "detailType": "Insurance",
17      "detailRecordType": "Member Plan",
18      "fields": {
19        "Name": "Aetna PPO",
20        "MemberNumber": "2345678"
21      }
22    },
23    {
24      "detailType": "Insurance",
25      "detailRecordType": "Member Plan",
26      "detailRecordId": "0SqRM0000004F2z0AE"
27    },
28    {
29      "detailType": "Body Site",
30      "detailRecordType": "Health Condition",
31      "detailCodeId": "0hsRM000000043aYAA"
32    },
33    {
34      "detailType": "Reason Reference",
35      "detailRecordId": "0j4RM0000004MunYAE"
36    }
37  ],
38  "requester": {
39    "id": "0cmRM0000004nAgYAI"
40  },
41  "performers": [
42    {
43      "id": "0cmRM0000000l2JYAQ"
44    },
45    {
46      "id": "0cmRM0000000tnoYAA"
47    }
48  ],
49  "referralNotes": "This is an urgent request",
50  "referral": {
51    "fields": {
52      "Priority": "Routine",
53      "Status": "Draft",
54      "Type": "Plan"
55    }
56  }
57}

Properties 

NameTypeDescriptionRequired or OptionalAvailable Version
captchaTokenCaptcha Token InputGoogle captcha verification token.
Because the referral information comes from a web form, this API expects a captcha token for security reasons. The guest referral API calls the Google API to verify the provided captcha.
A Google captcha token is valid only for 2 minutes.
Required60.0
patientRecord Fields Input[]Account details of the patient being referred.Required60.0
performerRecord Fields Input[]List of healthcare providers who perform the service.
You can provide a maximum of 5 provider IDs in a request.
Optional60.0
referralRecord Fields Input[]Referral information.Required60.0
referralDetailsReferral Detail Input[]Patient details, such as, insurance, and health condition.Optional60.0
referralNotesStringReferral notes.Optional60.0
requesterRecord Fields Input[]Information about the provider requesting the service. A requester can be an Account, Asset, Healthcare Provider, or a CareRegisteredDevice object.
If the requester is new, provide information to create an account.
Optional60.0

Response Body for POST 

Guest Referral Output