Time |
S |
Nick |
Message |
00:07 |
|
|
quimrstorres joined #rest |
00:11 |
|
sfisque |
lmao. coworker linked this to me…. THIS is an awesome use of REST : http://www.foaas.com/ |
00:15 |
|
whartung |
good to see the hard problems of the world being solved first... |
00:20 |
|
rmwdeveloper |
in books, like for example REST in Practice, what do they mean by consumers? Other pieces of software? Real people behind keyboards and phones/tablets? |
00:21 |
|
rmwdeveloper |
whos actually consuming the api? |
00:21 |
|
rmwdeveloper |
or what |
00:21 |
|
whartung |
yes |
00:26 |
|
rmwdeveloper |
also, should all services strive to be level 3 services if time/money isnt a constraint, as opposed to 2 or lower |
00:31 |
|
|
quimrstorres joined #rest |
00:52 |
|
|
alxbl joined #rest |
01:21 |
|
|
quimrstorres joined #rest |
01:22 |
|
|
quimrstorres joined #rest |
01:26 |
|
|
alxbl joined #rest |
01:36 |
|
|
blahdeblah left #rest |
01:50 |
|
|
quimrstorres joined #rest |
02:23 |
|
|
quimrstorres joined #rest |
03:24 |
|
|
quimrstorres joined #rest |
03:52 |
|
|
fuzzyhorns joined #rest |
03:58 |
|
|
baweaver joined #rest |
04:20 |
|
|
fuzzyhorns joined #rest |
04:23 |
|
|
Coldblackice joined #rest |
04:25 |
|
|
quimrstorres joined #rest |
05:27 |
|
|
quimrstorres joined #rest |
06:28 |
|
|
baweaver joined #rest |
06:28 |
|
|
quimrstorres joined #rest |
07:29 |
|
|
quimrstorres joined #rest |
07:52 |
|
|
DrCode joined #rest |
08:29 |
|
|
quimrstorres joined #rest |
08:39 |
|
|
_ollie joined #rest |
09:10 |
|
|
_ollie joined #rest |
09:30 |
|
|
quimrstorres joined #rest |
10:23 |
|
|
Blackskyliner joined #rest |
10:26 |
|
|
_ollie joined #rest |
10:56 |
|
|
Coldblackice joined #rest |
11:01 |
|
|
Coldblackice joined #rest |
11:31 |
|
|
_ollie joined #rest |
12:05 |
|
|
quimrstorres joined #rest |
12:11 |
|
|
quimrstorres joined #rest |
12:15 |
|
|
quimrstorres joined #rest |
12:19 |
|
|
quimrstorres joined #rest |
12:19 |
|
|
huckleberry78 joined #rest |
12:51 |
|
|
huckleberry78 joined #rest |
13:25 |
|
|
quimrstorres joined #rest |
13:33 |
|
|
quimrstorres joined #rest |
13:49 |
|
|
quimrstorres joined #rest |
13:53 |
|
|
quimrstorres joined #rest |
13:59 |
|
|
quimrstorres joined #rest |
14:13 |
|
|
_ollie joined #rest |
14:59 |
|
|
quimrstorres joined #rest |
15:01 |
|
|
fuzzyhorns joined #rest |
15:01 |
|
|
huckleberry78 joined #rest |
16:35 |
|
|
rmwdeveloper joined #rest |
17:02 |
|
|
huckleberry78 joined #rest |
17:23 |
|
|
metasansana joined #rest |
18:38 |
|
|
fuzzyhorns joined #rest |
19:38 |
|
|
fuzzyhorns joined #rest |
19:51 |
|
|
fuzzyhorns joined #rest |
20:27 |
|
|
fuzzyhorns joined #rest |
20:45 |
|
|
fumanchu_ joined #rest |
21:04 |
|
|
huckleberry78 joined #rest |
21:09 |
|
|
Darkman802 joined #rest |
21:10 |
|
Darkman802 |
What would be the correct status code to return when a client wants to 'start' a server that is already in the 'started' state? 403 Forbidden? |
21:10 |
|
trygvis |
422, bad semantics |
21:13 |
|
Darkman802 |
trygvis: Thanks, that looks good. |
21:14 |
|
Darkman802 |
I guess django rest framework doesn't support that code.. |
21:14 |
|
fumanchu_ |
I'd return 200 OK unless there's a reason the client needs to know it was already started |
21:15 |
|
fumanchu_ |
moving from the current state to the same state shouldn't be an error |
21:16 |
|
Darkman802 |
My only thought on that were it might help in debugging. Like the user can't connect so they believe they need to start the server, so returning an error would tell them it's already on. |
21:19 |
|
fumanchu_ |
I would imagine there'd be a "next step" to take in a troubleshooting workflow if the server were already on, and the response can return a link to that or instructions for that next step |
21:19 |
|
fumanchu_ |
you know your own API better but 2xx feels better to me than 4xx |
21:19 |
|
fumanchu_ |
4xx would feel like "you can't proceed in your workflow any more" |
21:23 |
|
Darkman802 |
That makes sense. |
21:32 |
|
Darkman802 |
fumanchu_: Would it make sense to return a response body depending on the situation? 'server is on, user wants to stop' = empty body 'server is on, user wants to start' = json detail message saying it's already on |
21:32 |
|
|
fuzzyhorns joined #rest |
21:32 |
|
Darkman802 |
both with 200 status? |
21:56 |
|
trygvis |
it makes sense to show the current state of the resource |
22:40 |
|
Blackskyliner |
HEAD /server/xyz => 503 if the server is down, HEAD /server/xyz => 200 if the server is online - I guess would also be a suitable solution |
22:41 |
|
Blackskyliner |
The only "problem" one could have is because of the 5xx space which indicates not something on the accessed resource but ont the server delivering the request... mhm... but if I see the resource of /server/xyz as mapping to a physical existent server then it maybe not too wrong... |
22:59 |
|
|
fumanchu joined #rest |
23:05 |
|
|
huckleberry78 joined #rest |