INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: MCWS Playback/Volume replies OK when sent a bad request  (Read 741 times)

mattkhan

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 4231
MCWS Playback/Volume replies OK when sent a bad request
« on: December 23, 2017, 02:10:20 am »

Say zone id 10003 exists but 10004 doesn't

If you send

http://jrmc:52199/MCWS/v1/Playback/Volume?Level=0.45&Zone=10003

then you get

Code: [Select]
<Response Status="OK">
<Item Name="Level">0.45</Item>
<Item Name="Display">45% (-27.5 dB)</Item>
</Response>

but if you send

http://jrmc:52199/MCWS/v1/Playback/Volume?Level=0.45&Zone=10004

then you get

Code: [Select]
<Response Status="OK"/>

i.e. you can't use the response status to determine whether something useful happened

IMV this should 404 because the zone doesn't exist but returning some error status code is probably more consistent with the way mcws is designed.
Logged
Pages: [1]   Go Up