Skip to main content

agent.cancelThread()

Cancels in-flight work on a thread. Notes:
  • Unavailable with readOnly: true (throws an error).

Signature

Example

See all agent methods or runtime basics.
Last modified on November 8, 2026