SIGN IN SIGN UP

feat(api): Add shell call streaming events and new service/image types (#3635)

## Summary

Introduce first-class streaming event types for shell tool calls and add
typed service-tier and image-detail aliases used across Responses and
beta APIs. Also add optional image metadata fields for partial image
events, an optional metadata field on ChatCompletion, and a new
audit-log event value.

## Changes

- Add streaming event models for shell call commands and output (command
added, command delta, command done, output content delta, output content
done) and corresponding WebSocket/server variants for both stable and
beta Responses event unions.
- Introduce ImageDetail and BetaImageDetail type aliases
("low"|"high"|"auto"|"original") and replace inline literal detail
annotations in Response/BetaResponse input and screenshot types to use
these aliases.
- Introduce ServiceTier and BetaServiceTier type aliases
(Optional["auto"|"default"|"flex"|"scale"|"priority"|"fast"|"ultrafast"])
and update service_tier parameters/fields across Response, BetaResponse,
Responses client/server event types, and request parameter types to use
these aliases.
- Add new optional fields to image partial events (background,
output_format, quality, size) on image-generation partial-image event
models.
- Add an optional metadata field to ChatCompletion model to allow
attaching 16 key-value pairs to chat completion objects.
- Add a new audit log event value
"tenant.ads_account.onboarding.redemption" to audit log enums and
response types.
- Expose the new event and type symbols through the public
Responses/beta/responses type exports so they appear in the SDK surface
area.

Co-authored-by: apcha-oai <228803254+apcha-oai@users.noreply.github.com>
A
Alex Chang committed
ff14a33c1b21c36b9e43a0150a3818ee3aa3712a
Parent: 10ee3f0
Committed by GitHub <noreply@github.com> on 8/17/2026, 3:42:09 PM