Skip to content

Commit

Permalink
Grouped routes for webhooks
Browse files Browse the repository at this point in the history
  • Loading branch information
wdbasson committed Feb 1, 2024
1 parent 0fa0d67 commit 0f482d9
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions app/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
trust_registry,
verifier,
webhooks,
websocket_endpoint
)
from app.routes.admin import tenants
from app.routes.wallet import credentials as wallet_credentials
Expand Down Expand Up @@ -73,12 +74,14 @@ async def lifespan(_: FastAPI):
logger.info("Calling WebsocketManager shutdown")
await WebsocketManager.disconnect_all()


trust_registry_routes = [trust_registry]
tenant_admin_routes = [
tenants,
webhook_routes = [
webhooks,
sse,
websocket_endpoint
]

trust_registry_routes = [trust_registry]
tenant_admin_routes = [ tenants] + webhook_routes
tenant_routes = [
connections,
definitions,
Expand All @@ -89,9 +92,7 @@ async def lifespan(_: FastAPI):
verifier,
wallet_credentials,
wallet_dids,
webhooks,
sse,
]
] + webhook_routes


def routes_for_role(role: str) -> list:
Expand Down

0 comments on commit 0f482d9

Please sign in to comment.