Once a Captricity user has granted your application access to their account, your application will be able to perform actions on behalf of the user by manipulating API resources using standard HTTP GETs, PUTs, POSTs, and DELETEs.
To succesfully make a request to a Captricity API resource, your request must include at least two HTTP headers: X_API_TOKEN and X_API_VERSION.
h = httplib.HTTP('https://shreddr.captricity.com')
h.putheader('User-Agent', 'Your Client Name V0.1')
h.putheader('X_API_TOKEN', 'Your Client Token')
errcode, errmsg, headers = h.getreply()
if errcode != 200:
raise IOError('Response from %s was %s' % (url, errcode))
result = json.loads(h.file.read())
The only available API version for the X_API_VERSION header is "0.1". The X_API_TOKEN is the API token you receive in the callback after the Captricity user authorizes your application.