mirror of
https://github.com/encounter/adk-python.git
synced 2026-07-09 18:19:28 -07:00
feat: Support return all sessions when user id is none
PiperOrigin-RevId: 819884236
This commit is contained in:
committed by
Copybara-Service
parent
b650181384
commit
a985cc38ec
@@ -83,9 +83,18 @@ class BaseSessionService(abc.ABC):
|
||||
|
||||
@abc.abstractmethod
|
||||
async def list_sessions(
|
||||
self, *, app_name: str, user_id: str
|
||||
self, *, app_name: str, user_id: Optional[str] = None
|
||||
) -> ListSessionsResponse:
|
||||
"""Lists all the sessions."""
|
||||
"""Lists all the sessions for a user.
|
||||
|
||||
Args:
|
||||
app_name: The name of the app.
|
||||
user_id: The ID of the user. If not provided, lists all sessions for all
|
||||
users.
|
||||
|
||||
Returns:
|
||||
A ListSessionsResponse containing the sessions.
|
||||
"""
|
||||
|
||||
@abc.abstractmethod
|
||||
async def delete_session(
|
||||
|
||||
Reference in New Issue
Block a user