09/04/2025 - REST API Errors For Multiple Units

🐛 Bug Fix: Appropriate User Errors for Invalid Payloads

Previously when writing a contact with multiple units, validation would permit payloads that caused server (500) errors. Further changes were required to ensure validation also upheld business rules when multiple units were provided.

New changes allow developers to mark properties as `important`. Such properties that are invalid, or have any child property that is invalid will fail the request.

  1. Sending the same unit ID twice in one payload results in 422

  2. If any unit is invalid, request fails with 422

  3. Useful errors return to the user

  4. More test coverage around discard invalid data rule

👨‍💻 Lee

Last updated