README.rst 1006 Bytes
Newer Older
jens.kleineheismann's avatar
jens.kleineheismann committed
1
2
3
4
5
6
7
ABOUT
=====
This package provide a python binding to the KIT Gruppenverwaltung REST API.


INSTALLATION
============
8
9
``$ python setup.py develop``

jens.kleineheismann's avatar
jens.kleineheismann committed
10
or
11
12
13

``$ pip install -e .``

jens.kleineheismann's avatar
jens.kleineheismann committed
14
15
16
17
18
or any other method, you use to install your python packages.


USAGE
=====
19
::
jens.kleineheismann's avatar
jens.kleineheismann committed
20

21
 from kitgvapi import basicConfig, Oe, Group, User
jens.kleineheismann's avatar
jens.kleineheismann committed
22

23
 basicConfig('myusername', 'mypassword')
jens.kleineheismann's avatar
jens.kleineheismann committed
24

25
26
27
 iism = Oe('IISM')
 for g in iism.get_groups():
     print g.name
28
 iism.create_group('IISM-EM-newgroup', 'Neue Gruppe')
jens.kleineheismann's avatar
jens.kleineheismann committed
29

30
31
32
33
 staff = Group('IISM-EM-OU-Staff')
 for u in staff.get_users(effective=True):
     print "%s %s (%s)" % (u.firstname, u.lastname, u.samaccount)
 for g in staff.get_groups():
34
     print "%s (%s)" % (g.name, g.description)
35
36
37

 me = User('zy8373')
 others = me.oe.get_users()
jens.kleineheismann's avatar
jens.kleineheismann committed
38

39
40
41
42
Note:
-----
basicConfig() is not thread safe and is subject to change.

jens.kleineheismann's avatar
jens.kleineheismann committed
43
44
45
46

LICENCE
=======
Author: Jens Kleineheismann <kleineheismann@kit.edu>
47

jens.kleineheismann's avatar
jens.kleineheismann committed
48
49
Permission to use, copy, modify, and/or distribute this software
for any purpose with or without fee is hereby granted.