// Dumps raw metadata for every model (all fields) + GET /v1/models/{id} for one model to see extra fields. import OpenAI from "openai"; const client = new OpenAI(); const all: any[] = []; for await (const m of client.models.list()) all.push(m); all.sort((a, b) => a.id.localeCompare(b.id)); const keys = new Set(); all.forEach(m => Object.keys(m).forEach(k => keys.add(k))); console.log("FIELDS:", [...keys].join(",")); console.log("WITH shutdown_date:", all.filter(m => m.shutdown_date).map(m => `${m.id}=${m.shutdown_date}`).join(" ")); const one = await client.models.retrieve("gpt-5.5"); console.log("RETRIEVE gpt-5.5:", JSON.stringify(one)); const two = await client.models.retrieve("gpt-6-astra"); console.log("RETRIEVE gpt-6-astra:", JSON.stringify(two)); // print any non-standard fields for (const m of all) { const extra = Object.fromEntries(Object.entries(m).filter(([k]) => !["id","object","created","owned_by"].includes(k))); if (Object.keys(extra).length) console.log(m.id, JSON.stringify(extra)); }