Provider agent hands a prior-auth Case to a payer agent
Two HIPAA-covered orgs exchange a provably-minimized prior-auth handoff, with PHI scope encoded in the receipt.
01Scenario
A provider's Case for a prior-authorization request is escalated by an Agentforce agent. The payer org — a separate Salesforce instance, separate HIPAA covered entity — needs to receive a verifiable record of the handoff including the minimized PHI scope.
case.escalation.handoff mints a receipt where the payload references only the minimum necessary fields (CPT code set, diagnosis category, member identifier hash). The full PHI never leaves the provider; only the signed assertion about what was sent crosses orgs.
On the payer side, the Hive A2A Inbox LWC renders the receipt chain on the matching Case. The compliance team can subpoena the receipt JSONL and verify it offline without either org's Salesforce.
02Handles
03APEX
Case c = [SELECT Id, AccountId, Status, Priority, ContactId
FROM Case WHERE Id = :caseId];
// Minimize PHI surface — receipt encodes references only
Map<String, Object> payload = new Map<String, Object>{
'case_id' => c.Id,
'cpt_set_hash' => HiveHash.sha256(cptCodesJson),
'dx_category' => 'orthopedic.shoulder.arthroscopy',
'member_id_hash' => HiveHash.sha256(memberMRN + orgSalt),
'urgency' => 'standard',
'requested_los_days' => 2,
'preauth_window_hr' => 72
};
Id receiptId = HiveReceiptMinter.mint(
c.Id,
'case.escalation.handoff',
'did:hive:0xPayerOrgAgent',
'salesforce:case:' + c.Id,
payload
);
// receipt.Jurisdiction__c = 'US-HIPAA'
// receipt.Direction__c = 'OUTBOUND' on provider side
// counterpart write on payer side = 'INBOUND' (paired by Action_Ref__c)
04Flow XML
<Flow xmlns="http://soap.sforce.com/2006/04/metadata">
<processType>AutoLaunchedFlow</processType>
<start>
<connector><targetReference>mint_handoff</targetReference></connector>
<object>Case</object>
<recordTriggerType>UpdatedAndConditionMet</recordTriggerType>
<filters>
<field>Status</field><operator>EqualTo</operator>
<value><stringValue>Escalated</stringValue></value>
</filters>
<triggerType>RecordAfterSave</triggerType>
</start>
<actionCalls>
<name>mint_handoff</name>
<label>Mint HIPAA-shape handoff receipt</label>
<actionName>HiveReceiptMinter</actionName>
<actionType>apex</actionType>
</actionCalls>
<status>Active</status>
</Flow>
05The receipt that lands in Hive_Receipt__c
{
"agent_id": "did:hive:0xProviderAgent",
"counterparty_did": "did:hive:0xPayerOrgAgent",
"action_type": "case.escalation.handoff",
"scope": "salesforce:case:5001a00000HJK",
"action_ref": "sha256(...)",
"payload_hash": "sha256:2e88...c0f3",
"signature": "ed25519:c4b7...8821",
"timestamp_ms": 1716333900000,
"jurisdiction": "US-HIPAA",
"direction": "OUTBOUND",
"verification_status": "VERIFIED"
}
06Verification
Compliance subpoena flow — verify without either org's Salesforce
# Receipt JSONL is exported from Hive_Receipt__c by Compliance.
# Anyone with the public key can verify it.
curl -sS https://hivemorph.onrender.com/v1/verify \
-H 'content-type: application/json' \
--data-binary @case_handoff_receipt.json
# expected:
# {"verified":true,"jurisdiction":"US-HIPAA","payload_hash_matches":true}
07Economics
| Per-handoff fee | $0.50 (Standard rail) |
| Free tier | 100 handoffs/month free |
| Monthly cap | $499 |
| Typical mid-size payer | ~600 escalation handoffs/mo → $499/mo (capped) |
| HIPAA shape | Receipt payload is hashes + categories, not PHI |
| BAA required | Hive operates as a covered-entity processor under signed BAA |
08Compliance and audit shape
- Receipt body contains zero PHI — hashed member identifier, CPT-set hash, diagnosis category only.
- Hive offers a Business Associate Agreement (BAA) to all healthcare customers.
- Receipt JSONL is exportable for compliance review with no Salesforce login.
- Action_Ref__c pairs INBOUND/OUTBOUND receipts across both orgs for end-to-end audit.
09Trust anchors
Every claim on this page is verifiable against these public constants. No login. No NDA.
| Rail | STANDARD — $0.50/receipt, Hive-billed |
| Hive Ed25519 pubkey | fd9d10abe60de7510c61ef649c8da598a519468dd2a2b827106d76487a899444 |
| Canonicalization | RFC 8785 JCS over the JSON receipt body |
| Signature algorithm | Ed25519 (RFC 8032) |
| Backend root | https://hivemorph.onrender.com |
| Verify any receipt | thehiveryiq.com/verify |
| MIT starter | thehiveryiq.com/salesforce/install |
| Billing | $0.50/receipt, 100/mo free, $499/mo cap. Square invoice or monthly ACH — buyer picks. |
| Pricing | thehiveryiq.com/pricing |