My question is similar to this thread, however, slightly different.
I'm working on a scheduling application where appointments can be explicitly started and ended (think check-in/check-out). Starting an appointment is partially an update to the appointment status (changing it from scheduled to in progress), but it also kicks off a number of other processes, such as email notifications.
For example, my start endpoint is accessed at the following URL:
In addition to the
id, I also pass
lon (the latitude/longitude of the check-in).
lon aren't actually fields in my
appointment table, rather I have a
checkinCoordinates field that is computed based on those params and inserted as a PostGIS-compliant format.
In the spirit of keeping all of my requests/responses JSON API-compliant, I am wondering the proper way to represent something like this given that the fields aren't part of the actual model?
My initial thought was something like this:
All that said, in general, I believe I'm a little confused on how to represent non-CRUD actions like this in JSON API. Any advice or suggestions would be greatly appreciated!