Thread 3PU lookup through as far as the AS API object; which currently noöps it

This commit is contained in:
Paul "LeoNerd" Evans 2016-08-17 13:15:06 +01:00
parent e3e3fbc23a
commit fa87c981e1
3 changed files with 33 additions and 2 deletions

View file

@ -16,6 +16,8 @@
import logging
from twisted.internet import defer
from synapse.http.servlet import RestServlet
from ._base import client_v2_patterns
@ -28,10 +30,15 @@ class ThirdPartyUserServlet(RestServlet):
def __init__(self, hs):
super(ThirdPartyUserServlet, self).__init__()
pass
self.appservice_handler = hs.get_application_service_handler()
@defer.inlineCallbacks
def on_GET(self, request, protocol):
return (200, {"TODO":"TODO"})
fields = {} # TODO
results = yield self.appservice_handler.query_3pu(protocol, fields)
defer.returnValue((200, results))
def register_servlets(hs, http_server):