Skip to content

fix(ccr0316): correct $send-message return type and document preconditions#292

Merged
jhntrifork merged 2 commits into
release_2026.3from
ccr0316-send-message-operation-return-type
Jun 16, 2026
Merged

fix(ccr0316): correct $send-message return type and document preconditions#292
jhntrifork merged 2 commits into
release_2026.3from
ccr0316-send-message-operation-return-type

Conversation

@jhntrifork

Copy link
Copy Markdown
Contributor

Summary

Follow-up to the original CCR0316 IG work (commit e407e68d) and downstream fut-patient PR #3334.

The return parameter on Appointment-send-message was declared as type: Reference with targetProfile: ehealth-message. The operation actually returns the created Communication resource embedded in a Parameters response — both per CCR0316 §6 (OUT return ... type Communication) and per the fut-patient implementation (SendMessageOperationHandlerParameters with result.getParameterFirstRep().getResource() returning a Communication). A strict consumer or code generator that trusts the OperationDefinition would expect a Reference and break.

This PR corrects the contract and fills out the documentation that was previously sparse.

Changes

  • Return parameter: typeCommunication, drop targetProfile, rewrite documentation to point at the ehealth-message profile and document the completed/stopped status semantics.
  • New comment field listing the preconditions that yield HTTP 400 Bad Request — appointment profile (video/group-video) and status (booked/pending), participant status (accepted/tentative/needs-action), RelatedPerson active/period/telecom:video-appointment-reminder-sms — and a note on the persist-on-failure audit behaviour.
  • Cross-links in description to the ehealth-relatedperson, ehealth-appointment and ehealth-message profile pages.
  • Changelog entry for release_2026.3 updated to reflect the corrected return type and the documented preconditions.

Downstream impact

No code changes required in fut-patient — the implementation already matches the corrected contract. Consumers that hand-rolled their own client from the previous (Reference-typed) OperationDefinition will need to update once they pick up this release.

…tions

The `return` parameter on Appointment-send-message was declared as
`type: Reference` with `targetProfile: ehealth-message`, but the operation
actually returns the created Communication resource embedded in the
Parameters response (per CCR0316 §6 and the fut-patient implementation).
A strict consumer or code generator following the OperationDefinition
would expect a Reference and break.

- Return parameter: `type` → `Communication`, drop `targetProfile`,
  expand `documentation` to mention the ehealth-message profile and the
  completed/stopped status semantics.
- Add an `comment` field listing the preconditions that yield HTTP 400
  (appointment profile/status, participant status, RelatedPerson
  active/period/telecom-purpose) and explain the persisted-on-failure
  audit behaviour.
- Cross-link the description to ehealth-relatedperson, ehealth-appointment
  and ehealth-message profile pages.
- Update the release_2026.3 changelog entry accordingly.
@jhntrifork jhntrifork requested review from ohetrifork and removed request for ohetrifork June 8, 2026 07:54
Comment thread input/resources/OperationDefinition-Appointment-send-message.json Outdated
…files

The description linked to the generic ehealth-appointment profile, but
the operation only applies to video appointments. Point it at
ehealth-videoappointment and ehealth-group-videoappointment to match the
precondition already documented in comment.
@jhntrifork jhntrifork merged commit 874fd2f into release_2026.3 Jun 16, 2026
@jhntrifork jhntrifork deleted the ccr0316-send-message-operation-return-type branch June 16, 2026 09:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants