fixed python samples
honor http response code
Merge pull request #11 from lzoubek/samples

Fixed rest-api python samples to correctly work with latest Rest api