Step by step guide

This guide covers the different options available to you through Hero's Messaging API.

1. Retrieve your patient

In all cases, a patient context is required.

To generate your Hero patient ID, you will need to run our RegisterPatient call. This accepts NHS number and DOB inputs, runs a lookup against PDS then checks the underlying health record for your practice. If not found, Hero will attempt to register a temporary patient using the details retrieved from the Spine.

  • "dob": "1992-01-01",
  • "postcode": "string",
  • "forename": "string",
  • "surname": "string",
  • "nhs_number": "123 456 7891"

The Hero patient ID returned in the response can then be passed to the SendMessage call

2. Send message

In this example, you can send SMS content using Hero. Messages will be sent using the practice's configured SMS provider (e.g. Firetext).

  • "patient_id": "1",
  • "message_type": "sms",
  • "message_string": "Sample text message",
  • "recipient_contact_detail": "07788 123456",
  • "write_to_record": true,
  • "encrypted": false,
  • "snomed_code": "123456789",
  • "snomed_term": "string",
  • "auto_write_to_record": false,
  • "task_id": "string",
  • "attachment_uuid": "string"