greptilian logo

IRC log for #rest, 2015-02-25

https://trygvis.io/rest-wiki/

| Channels | #rest index | Today | | Search | Google Search | Plain-Text | plain, newest first | summary

All times shown according to UTC.

Time S Nick Message
00:28 azer_ joined #rest
01:20 fumanchu_ joined #rest
01:20 warehouse13 joined #rest
01:20 shrink0r_ joined #rest
01:20 jaawerth joined #rest
01:20 mezod joined #rest
01:20 saml joined #rest
01:20 locks joined #rest
01:20 bigbluehat joined #rest
01:20 lebster joined #rest
01:20 tmoore joined #rest
01:20 ramsey joined #rest
01:20 gluegadget joined #rest
01:20 rickharrison joined #rest
01:20 blahdeblah joined #rest
01:20 csgeek joined #rest
01:20 asdf` joined #rest
01:20 HighBit joined #rest
01:20 benaiah joined #rest
01:20 sulky joined #rest
01:20 mgomezch joined #rest
01:20 ekroon joined #rest
01:20 igitoor joined #rest
01:20 jgornick joined #rest
01:20 ChrisAnn joined #rest
01:20 gamache joined #rest
01:20 cythrawll joined #rest
01:20 zama joined #rest
01:20 StatelessCat joined #rest
01:20 daxim joined #rest
01:20 ironChicken joined #rest
01:20 dreamdust joined #rest
01:20 SupaHam joined #rest
01:20 riddle joined #rest
01:20 Guest18878 joined #rest
01:20 blindscreen_ joined #rest
01:20 `0660 joined #rest
01:20 alxbl joined #rest
01:20 pdurbin joined #rest
01:20 imanc_ joined #rest
01:20 asm89 joined #rest
01:20 Davey joined #rest
01:20 CentaurWarchief joined #rest
01:20 blongden joined #rest
01:23 shrink0r joined #rest
01:29 proteusguy joined #rest
01:39 riddle joined #rest
01:39 pdurbin joined #rest
01:39 asm89 joined #rest
01:39 CentaurWarchief joined #rest
01:39 blongden joined #rest
01:41 riddle joined #rest
01:41 pdurbin joined #rest
01:41 asm89 joined #rest
01:41 CentaurWarchief joined #rest
01:41 blongden joined #rest
01:52 riddle joined #rest
01:53 asm89- joined #rest
02:09 shrink0r_ joined #rest
03:52 shrink0r joined #rest
04:01 lemur joined #rest
04:07 SlippinJimmy joined #rest
04:08 SlippinJimmy I’m using JSON-HAL and if I do a “POST /users” to create a new user, should the “self” link be “/users”, and have a “my:user” link be “/users/123” ; or should the “self” link be “/users/123”?
04:38 locks SlippinJimmy: the response from a post is a new representation right
04:38 locks so the self link should point to that representation
04:38 SlippinJimmy ok, that’s what I figured, but I wasn’t sure
04:39 SlippinJimmy thanks.
04:41 huckleberry78 joined #rest
07:38 lemur joined #rest
07:58 proteusguy joined #rest
08:17 shrink0r joined #rest
08:21 fumanchu joined #rest
08:58 azer_ joined #rest
09:12 interop_madness joined #rest
09:24 graste joined #rest
09:32 shrink0r joined #rest
11:46 fumanchu_ joined #rest
11:54 huckleberry78 joined #rest
12:04 shrink0r joined #rest
12:15 proteusguy joined #rest
12:15 Left_Turn joined #rest
12:20 ironChick` joined #rest
13:04 mezod joined #rest
13:14 jcromartie joined #rest
13:21 azer_ joined #rest
13:28 shrink0r_ joined #rest
13:32 shrink0r joined #rest
13:54 Mxyzpltk joined #rest
14:15 ironChicken joined #rest
14:30 azer_ joined #rest
14:46 shrink0r_ joined #rest
14:59 warehouse13 joined #rest
15:05 jgornick joined #rest
15:18 ironChicken joined #rest
15:47 azer_ joined #rest
16:14 shrink0r joined #rest
16:19 pgicxplzs joined #rest
17:05 lemur joined #rest
17:19 rosstuck joined #rest
17:23 shrink0r_ joined #rest
17:29 Mxyzpltk joined #rest
17:38 lemur joined #rest
17:42 shrink0r joined #rest
17:52 azer_ joined #rest
18:12 azer_ joined #rest
18:38 proteusguy joined #rest
18:59 tr3online joined #rest
19:46 shrink0r joined #rest
19:50 azer_ joined #rest
20:24 adaro joined #rest
20:27 warehouse13 joined #rest
20:34 Jefffrey joined #rest
21:03 jcromartie joined #rest
21:22 grazfather joined #rest
21:23 grazfather hey guys, if i have an endpoint like users/<username> and that user doesn't exist, should it return 200 with an empty list, or another error code e.g. 404?
21:27 fumanchu_ depends on what you would return if there were such a user
21:30 fumanchu_ a list?
21:35 grazfather a list
21:36 grazfather i guess if it's supposed to return one then we'd use the 'find_one_or_404'
21:36 grazfather but what otherwise?
21:36 dreamdust grazfather: 200 with an empty list. 404 is the code for if a resource does not exist - but /users is a resource that exists: the collection of users. The collection may be empty.
21:37 grazfather makes sense. Thank you
21:37 dreamdust An resource that exists that represents an empty collection is not teh same thing as a resource that does not exist.
21:37 dreamdust Your welcome.
21:37 grazfather hat was my intuition
21:37 grazfather s/hat/that
21:53 fumanchu_ too bad that's completely wrong
21:55 fumanchu_ Uniform. Resource. Identifier. /users/<username> identifies a different resource than /users
21:56 fumanchu_ so if there is no resource identified by /users/<username> then 404
21:58 fumanchu_ you could have a system where /users/<username> is trying to say "return me a list of all users whose username == <username>", in which case there is such a resource, it just happens to be empty
22:21 whartung Right, Uniform Resource Identifier. It's only usable by military and police departments, because they need to manage Uniform resources.
22:21 * whartung runs and hides
22:32 fumanchu joined #rest
22:37 grazfather fumanchu: Yeah we are converting it only return a single user and 404 if it doesn't exist. Before it would return a list (with 1 or 0 elements) with the future feature to support wild cards
23:01 huckleberry78 joined #rest

| Channels | #rest index | Today | | Search | Google Search | Plain-Text | plain, newest first | summary

https://trygvis.io/rest-wiki/