Skip to content

No way to get request_id for a tool call to cancel it #230

Closed

Description

@ihrpr

Describe the bug
When trying to cancel a tool by sending a cancel notification, there is no way to know request_id.

It would be useful to set a request id during the tool call.

To Reproduce
Try cancelling a tool call

Expected behavior
Have a reques_id known to cancel it

Activity

  1. davemssavage commented on May 10, 2025

    @davemssavage

    As an alternative to having to expose the request id outside of the client session #628 uses the cancel scope that the session is running in to trigger cancelation, this feels more natural to me and hides the internal protocol details inside the client, I'm not sure request_id has any usage outside of cancelation, if there are other use cases then other approaches may be more appropriate.

  2. added
    enhancement
    on Oct 7, 2025
  3. added
    ready for work
    P2
    and removed on Oct 7, 2025
  4. added
    needs decision
    and removed
    ready for work
    on Apr 17, 2026
  5. maxisbey commented on Aug 10, 2026

    @maxisbey
    Contributor

    This landed as part of v2, which is now released (via #2838) — closing. Feel free to reopen if there's something still outstanding.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2enhancementneeds decision

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions