Skip to content

Add list_events on AgentSession and AsyncAgentSession#7

Merged
bhaveshpatel640 merged 1 commit into
mainfrom
AGE-1206-expose-list-events-on-agent-session
Jul 7, 2026
Merged

Add list_events on AgentSession and AsyncAgentSession#7
bhaveshpatel640 merged 1 commit into
mainfrom
AGE-1206-expose-list-events-on-agent-session

Conversation

@bhaveshpatel640

@bhaveshpatel640 bhaveshpatel640 commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Note

Low Risk
Additive SDK surface with pass-through to existing API; no auth or core logic changes.

Overview
Adds list_events to AgentSession and AsyncAgentSession, exposing paginated session-wide events (newest first) on the enriched session wrapper instead of only via the raw sessions client.

Both sync and async methods forward to agents.sessions.list_events with page_token, optional last_turn_id (initial window anchor; defaults to the session’s last turn), limit (default 100), and RequestOptions. Return types are SyncPager/AsyncPager of SessionEventItem. Class docstrings now mention list_events alongside the other convenience methods.

Reviewed by Cursor Bugbot for commit 1478418. Bugbot is set up for automated code reviews on this repo. Configure here.

Co-authored-by: Cursor <cursoragent@cursor.com>
@bhaveshpatel640 bhaveshpatel640 requested a review from chiragjn July 7, 2026 14:40
@bhaveshpatel640 bhaveshpatel640 merged commit 2ffae22 into main Jul 7, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants