| Time |
S |
Nick |
Message |
| 00:14 |
|
|
Guest28183 joined #rest |
| 01:46 |
|
|
Guest28183 joined #rest |
| 01:53 |
|
|
tr3onlin_ joined #rest |
| 01:56 |
|
|
_ollie joined #rest |
| 02:41 |
|
|
_ollie1 joined #rest |
| 02:53 |
|
|
_ollie joined #rest |
| 04:20 |
|
|
tr3online joined #rest |
| 04:27 |
|
|
darkpassenger joined #rest |
| 04:31 |
|
|
renegadeds joined #rest |
| 05:15 |
|
|
_ollie joined #rest |
| 06:05 |
|
|
_ollie joined #rest |
| 06:24 |
|
|
_ollie1 joined #rest |
| 06:26 |
|
|
tr3online joined #rest |
| 07:23 |
|
|
tr3online joined #rest |
| 07:36 |
|
|
talios joined #rest |
| 07:42 |
|
|
rosstuck joined #rest |
| 07:58 |
|
|
Left_Turn joined #rest |
| 08:03 |
|
|
graste joined #rest |
| 08:12 |
|
|
graste1 joined #rest |
| 09:02 |
|
|
martinfilliau joined #rest |
| 09:16 |
|
|
ph88 joined #rest |
| 09:20 |
|
|
Left_Turn joined #rest |
| 10:04 |
|
|
tr3online joined #rest |
| 10:12 |
|
|
rosstuck joined #rest |
| 11:52 |
|
|
rosstuck_ joined #rest |
| 11:55 |
|
|
shrink0r joined #rest |
| 12:18 |
|
|
shrink0r left #rest |
| 12:58 |
|
|
_ollie joined #rest |
| 13:05 |
|
|
charlex joined #rest |
| 14:28 |
|
|
pezra joined #rest |
| 14:39 |
|
|
rosstuck joined #rest |
| 14:51 |
|
|
z34 joined #rest |
| 16:00 |
|
|
proteusguy joined #rest |
| 16:25 |
|
|
tr3online joined #rest |
| 16:39 |
|
|
pezra joined #rest |
| 16:48 |
|
|
fumanchu joined #rest |
| 16:57 |
|
|
nkoza joined #rest |
| 17:54 |
|
|
htowngangsta joined #rest |
| 17:58 |
|
|
tr3online joined #rest |
| 18:37 |
|
|
charlex joined #rest |
| 19:06 |
|
|
graste joined #rest |
| 19:30 |
|
|
pezra joined #rest |
| 19:31 |
|
|
shrink0r joined #rest |
| 19:40 |
|
|
tr3online joined #rest |
| 19:51 |
|
|
Guest28183 joined #rest |
| 19:52 |
|
|
Zer000 joined #rest |
| 19:52 |
|
Zer000 |
I have an api for a fairly simple, nested todo list. /api/{id} is the url, POST'ing creates a new item under the list with id, DELETE to that url deletes the list and sub-items. I'm mentioning this because I don't know how to then implement a check/uncheck function to mark a list as done or not done. Should I make POST respond differently or create a new route for /api/{id}/change_status or something? |
| 19:59 |
|
|
systmkor joined #rest |
| 20:00 |
|
fumanchu |
you want to mark a list as done or an item as done? |
| 20:01 |
|
fumanchu |
I guess they're the same thing in your scheme |
| 20:01 |
|
|
shrink0r1 joined #rest |
| 20:05 |
|
Zer000 |
fumanchu, yes they are the same thing, a list is just another item of a bigger list |
| 20:06 |
|
fumanchu |
I wouldn't recommend change_status etc.; such things are almost always better handled by PATCH. |
| 20:06 |
|
fumanchu |
if only to invalidate any cached copies along the way |
| 20:08 |
|
Zer000 |
fumanchu, can you explain the invalidation of cached copies thing? |
| 20:08 |
|
Zer000 |
also TIL about PATCH |
| 20:08 |
|
Zer000 |
ill totally be using that |
| 20:09 |
|
fumanchu |
one of the cornerstones of how HTTP uses the REST architectural style is that it relies on caching for network efficiency, not on small tuned messages |
| 20:09 |
|
fumanchu |
methods that alter a resource invalidate cached copies of the representation of that resource |
| 20:09 |
|
fumanchu |
so if you POST to /api/{id}/change_status, someone could GET a stale version of /api/{id} |
| 20:10 |
|
fumanchu |
but if instead you PATCH /api/{id}, then any cacahced copies of it (at least along the path from the caller) will be invalidated |
| 20:10 |
|
fumanchu |
and therefore fresh on the next GET |
| 20:11 |
|
Zer000 |
fumanchu, oh ok. thank you |
| 20:25 |
|
|
systmkor joined #rest |
| 20:31 |
|
|
talios joined #rest |
| 20:41 |
|
|
tr3online joined #rest |
| 20:43 |
|
|
talios joined #rest |
| 20:50 |
|
|
talios joined #rest |
| 20:51 |
|
|
tr3online joined #rest |
| 20:54 |
|
|
talios joined #rest |
| 21:38 |
|
|
talios joined #rest |
| 22:10 |
|
|
ph88 joined #rest |
| 23:08 |
|
|
cigarshark joined #rest |
| 23:25 |
|
|
proteusguy joined #rest |
| 23:28 |
|
|
luomo1 joined #rest |