Improve documentation
authorMoritz Kiefer <moritz.kiefer@gmail.com>
Tue, 15 Jan 2013 20:03:53 +0000 (21:03 +0100)
committerMoritz Kiefer <moritz.kiefer@gmail.com>
Tue, 15 Jan 2013 20:03:53 +0000 (21:03 +0100)
diaspy/diaspy.py

index c9783c99d94b45227db1a9e2e6d42d6c2b3e8ad2..2ec0d103b7c61ebc975b7b7b0acc0171a0a1e152 100755 (executable)
@@ -25,7 +25,14 @@ class Client:
         self._session = requests.Session()
 
     def login(self, username, password):
-        """blablablalbla"""
+        """This function is used to connect to the pod and log in.
+        
+        :param username: The username used to log in.
+        :type username: str.
+        :param password: The password used to log in.
+        :type password: str.
+        
+        """
         self._username = username
         self._password = password
         r = self._session.get(self._pod + "/users/sign_in")
@@ -39,7 +46,14 @@ class Client:
         r = self._session.post(self._pod + "/users/sign_in", data=data)
 
     def post(self, text, aspect_id='public'):
-        """blablablalbla"""
+        """This function sends a post to an aspect
+        
+        :param text: Text to post.
+        :type text: str
+        :param aspect_id: Aspect id to send post to.
+        :type aspect_id: str.
+        
+        """
         r = self._session.get(self._pod + "/stream")
         token = self._token_regex.search(r.text).group(1)
         data = {'aspect_ids': aspect_id,