Integration settings
Integration settings connect a facility to your HIS.
HIS means hospital information system. It is the system where the final report should be stored.
What you configure
| Setting | What it does |
|---|---|
| Webhook URL | Where Tiep sends saved reports. |
| Webhook secret | Shared secret used to sign the payload. |
| Payload type | The format sent to your HIS. |
Webhook URL
This must be an HTTPS endpoint controlled by your system.
Example:
https://his.example.com/tiep/webhooks/consultations
When a doctor saves a report, Tiep sends an HTTP POST request to that URL.
Webhook secret
The secret proves the request came from Tiep.
Tiep sends this header:
X-Signature-256: sha256=<digest>
Your HIS should calculate the same digest using the raw request body and the secret.
import hmac
from hashlib import sha256
def is_valid_signature(raw_body: bytes, header: str, secret: str) -> bool:
expected = "sha256=" + hmac.new(
secret.encode("utf-8"),
msg=raw_body,
digestmod=sha256,
).hexdigest()
return hmac.compare_digest(header, expected)
Payload type
Choose the payload type based on what your HIS wants.
| Payload type | Use it when |
|---|---|
SIMPLE | You want simple JSON that mirrors the form answers. |
CUSTOM | You want simple JSON with custom handling. |
HL7_V1_0 | You need the older HL7 payload used by legacy integrations. |
HL7_V2 | You want a FHIR-style bundle. |
Read payload format for examples.
Two integration styles
Tiep UI style
Use this when doctors open Tiep.
Direct API style
Use this when your product owns the UI.
The same facility can support both styles if your workflow needs it.