sample api app

This commit is contained in:
baccenfutter 2013-10-20 20:42:13 +02:00
parent 0d49874df1
commit 9eca98c1d4
6 changed files with 54 additions and 17 deletions

22
cbapi_ldap/views.py Normal file
View file

@ -0,0 +1,22 @@
from jsonrpc import jsonrpc_method
TODO = [
'',
]
@jsonrpc_method("ping", authenticated=True)
def ping(request, username, password):
"""Ping - Echo Request
:returns str: echo_response
"""
echo_response = "PONG"
return echo_response
@jsonrpc_method("todo")
def todo(request):
"""Todo - List ToDo Items
:returns list: todolist
"""
return TODO