Revision f74d2b69 snf-astakos-client/docs/index.rst
b/snf-astakos-client/docs/index.rst | ||
---|---|---|
34 | 34 |
from astakosclient import AstakosClient |
35 | 35 |
|
36 | 36 |
client = AstakosClient("https://accounts.example.com") |
37 |
user_info = client.authenticate("UQpYas7ElzWGD5yCcEXtjw==")
|
|
37 |
user_info = client.getUserInfo("UQpYas7ElzWGD5yCcEXtjw==")
|
|
38 | 38 |
print user_info['username'] |
39 | 39 |
|
40 | 40 |
Another example where we ask for the username of a user with UUID: |
... | ... | |
67 | 67 |
|
68 | 68 |
This class provides the following methods: |
69 | 69 |
|
70 |
**authenticate(**\ token, usage=False\ **)**
|
|
70 |
**getUserInfo(**\ token, usage=False\ **)**
|
|
71 | 71 |
Given a valid authentication token it returns a dict with the |
72 | 72 |
correspoinding user's info. If usage is set to True more |
73 | 73 |
information about user's resources will be returned. |
Also available in: Unified diff