Initial hack at the 3PN protocols metadata lookup API

This commit is contained in:
Paul "LeoNerd" Evans 2016-08-24 12:33:01 +01:00
parent 63c19e1df9
commit 9899824b85
3 changed files with 44 additions and 0 deletions

View file

@ -175,6 +175,14 @@ class ApplicationServicesHandler(object):
defer.returnValue(ret)
@defer.inlineCallbacks
def get_3pe_protocols(self):
services = yield self.store.get_app_services()
protocols = set()
for s in services:
protocols.update(s.protocols)
defer.returnValue(protocols)
@defer.inlineCallbacks
def _get_services_for_event(self, event):
"""Retrieve a list of application services interested in this event.