Skip to content

Lack of InputTokenDetails in ResponseTokenUsage in Responses API #388

Open
@Tinyakov

Description

@Tinyakov

Service

OpenAI

Describe the bug

The InputTokenDetails property is missing in OpenAI.Responses.ResponseTokenUsage class, even though it is documented in the API here:
https://platform.openai.com/docs/api-reference/responses/object (input_tokens_details).

Similar property is available in OpenAI.Chat.ChatTokenUsage.

Steps to reproduce

I’m migrating code from the Chat API to the Responses API and encountered the issue that the number of cached tokens cannot be retrieved due to the absence of InputTokenDetails.

Code snippets

OS

macOS

.NET version

9.0

Library version

2.2.0-beta.4

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions