Retrieves a message by its ID. An acting admin without the required policy still receives the message, with the link removed from every attachment.
Security
apiKeyAuth and practiceGroupId
- Mock serverhttps://developer.herohealth.net/_mock/apis/public-api/openapi/v1/messages/{id}
- Staginghttps://api.staging.htech.app/v1/messages/{id}
- Productionhttps://api.herohealth.net/v1/messages/{id}
curl -i -X GET \
'https://developer.herohealth.net/_mock/apis/public-api/openapi/v1/messages/{id}' \
-H 'x-api-key: YOUR_API_KEY_HERE' \
-H 'x-practice-group-id: YOUR_API_KEY_HERE'Ok
Why the message failed, set only when status is retry or fatal. Use unknown when no specific reason is available.
Enum:"insufficient_credits""invalid_number""number_not_recognised""missing_contact_number""declined_by_network""provider_configuration_error""invalid_sender_name""invalid_message_content""invalid_send_time""send_failed"
Response
{ "id": "string", "patient": { "id": "string", "title": "Baron", "first_name": "string", "last_name": "string" }, "write_to_record": { "write_to_record_at": "2019-08-24T14:15:22Z", "status": "string", "failure_reason": "string", "snomed_code": "string" }, "short_link": { "id": "string", "type": "string", "name": "string", "status": "string" }, "campaign": { "id": "string", "name": "string" }, "created_at": "2019-08-24T14:15:22Z", "sent_at": "2019-08-24T14:15:22Z", "scheduled_at": "2019-08-24T14:15:22Z", "status": "delivered", "sent_by_admin": { "id": "string", "first_name": "string", "last_name": "string" }, "recipient_contact_detail": "string", "message_type": "string", "message": "string", "attachments": [ { … } ], "fallback_attempts": [ { … } ], "status_code": "insufficient_credits" }