class

OpenAI::RealtimeClientEventResponseCancel

Inherits JSON::Serializable < Reference < Object

Send this event to cancel an in-progress response. The server will respond with a response.done event with a status of response.status=cancelled. If there is no response to cancel, the server will respond with an error. It's safe to call response.cancel even if no response is in progress, an error will be returned the session will remain unaffected.

Constructors

new(event_id : String | Nil = nil, type_value : Hash(String, JSON::Any) = Hash(String, JSON::Any).new, response_id : String | Nil = nil)
Source
new(*, __pull_for_json_serializable pull : JSON::PullParser)
Source

Instance methods

event_id

Optional client-generated ID used to identify this event.

Source
event_id=(event_id : String | Nil)

Optional client-generated ID used to identify this event.

Source
response_id

A specific response ID to cancel - if not provided, will cancel an in-progress response in the default conversation.

Source
response_id=(response_id : String | Nil)

A specific response ID to cancel - if not provided, will cancel an in-progress response in the default conversation.

Source
type_value

The event type, must be response.cancel.

Source
type_value=(type_value : Hash(String, JSON::Any))

The event type, must be response.cancel.

Source