please suggest me best way to learn REST API call with CLI

Unix SA d.joshi84 at gmail.com
Sun Sep 28 07:21:59 CEST 2014


Hello,

I am intermediate to python and i am familier with OOP, but sometime i lost
some where looking at OOP in class and objects .... :(

I am looking at https://github.com/pulp/pulp ..

basically it uses okaara to generate CLI and calls API.


so for example if i run "pulp-admin -u admin -p admin rpm repo list" it
produces list of all repositories ...

now i want to write similar thing .. but without producing all repository i
just want to list single repo and below is the API for that ..

http://pulp-dev-guide.readthedocs.org/en/pulp-2.2/integration/rest-api/repo/retrieval.html

Not sure what's the best way to write it ... i want to do in OO way.. i
know how to use requests/httplib module and generate data and produce
output .........

but i am not able to build URL ...

can someone help to suggest best way to learn and write it ?

Regards,
DJ
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20140928/654503c1/attachment.html>


More information about the Python-list mailing list