codex_daily_usages

Daily Codex usage metrics per user

id

Primary key
Unique identifier for the row.

date

date
The date for which the usage metrics are recorded (UTC).

user_id

Foreign key
Foreign key referencing the parent codex_users record.

source

string
Identifies which connection produced this row: 'enterprise' (Codex Enterprise API) or 'otel' (Codex OpenTelemetry).

is_active

boolean
Indicates if the user had any Codex activity (threads or turns) on this date.

total_threads

number
Total number of Codex threads started by the user on this date.

total_turns

number
Total number of Codex turns taken by the user on this date.

total_credits

number
Total Codex credits consumed by the user on this date.

total_estimated_cost_usd

number
OpenAI's estimated cost in USD for the user's Codex usage on this date. May be null for flat-rate usage.

total_uncached_text_input_tokens

number
Total uncached text input tokens consumed by the user on this date.

total_cached_text_input_tokens

number
Total cached text input tokens consumed by the user on this date.

total_text_output_tokens

number
Total text output tokens produced for the user on this date.

total_text_total_tokens

number
Total text tokens (input + output) for the user on this date.