Responses Overview | OpenAI API Reference
function setupNavLinksInitial(){
let mode = localStorage.getItem(“stl-nav-links-mode”);
// initial guess
if(mode === null){
mode = window.innerWidth @font-face{font-family:Geist-5f5286da3bd2e78c;src:url(”/_astro/fonts/5216c2de3e224a57.woff2?dpl=dpl_DWJkNzhqCeJeVymvKDP8zhvM4zDW”) format(“woff2”);font-display:swap;unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;font-weight:100 900;font-style:normal;font-feature-settings:‘ss01’ on, ‘ss03’ on, ‘ss04’ on, ‘ss06’ on, ‘ss08’ on;}@font-face{font-family:Geist-5f5286da3bd2e78c;src:url(”/_astro/fonts/3091e8e2f7d84674.woff2?dpl=dpl_DWJkNzhqCeJeVymvKDP8zhvM4zDW”) format(“woff2”);font-display:swap;unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;font-weight:100 900;font-style:italic;font-feature-settings:‘ss01’ on, ‘ss03’ on, ‘ss04’ on, ‘ss06’ on, ‘ss08’ on;}@font-face{font-family:“Geist-5f5286da3bd2e78c fallback: Arial”;src:local(“Arial”);font-display:swap;font-weight:100 900;font-style:normal;size-adjust:104.7553%;ascent-override:95.9379%;descent-override:28.1609%;line-gap-override:0%;}@font-face{font-family:“Geist-5f5286da3bd2e78c fallback: Arial”;src:local(“Arial”);font-display:swap;font-weight:100 900;font-style:italic;size-adjust:104.7553%;ascent-override:95.9379%;descent-override:28.1609%;line-gap-override:0%;}:root{—stl-typography-font:Geist-5f5286da3bd2e78c,“Geist-5f5286da3bd2e78c fallback: Arial”,sans-serif;} @font-face{font-family:“Geist Mono-1014d9fb64fdb22f”;src:url(”/_astro/fonts/dd9b54ad83e16be2.woff2?dpl=dpl_DWJkNzhqCeJeVymvKDP8zhvM4zDW”) format(“woff2”);font-display:swap;unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;font-weight:100 900;font-style:normal;}@font-face{font-family:“Geist Mono-1014d9fb64fdb22f”;src:url(”/_astro/fonts/b4b874112890710d.woff2?dpl=dpl_DWJkNzhqCeJeVymvKDP8zhvM4zDW”) format(“woff2”);font-display:swap;unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;font-weight:100 900;font-style:italic;}@font-face{font-family:“Geist Mono-1014d9fb64fdb22f fallback: Arial”;src:local(“Arial”);font-display:swap;font-weight:100 900;font-style:normal;size-adjust:134.5893%;ascent-override:74.6716%;descent-override:21.9185%;line-gap-override:0%;}@font-face{font-family:“Geist Mono-1014d9fb64fdb22f fallback: Arial”;src:local(“Arial”);font-display:swap;font-weight:100 900;font-style:italic;size-adjust:134.5893%;ascent-override:74.6716%;descent-override:21.9185%;line-gap-override:0%;}:root{—stl-typography-font-mono:“Geist Mono-1014d9fb64fdb22f”,“Geist Mono-1014d9fb64fdb22f fallback: Arial”,sans-serif;}
window.didInitThemePickers = window.didInitThemePickers ?? false;
// Only run once.
if (!window.didInitThemePickers) {
window.didInitThemePickers = true;
// The stored theme will be either ‘auto’, ‘light’, ‘dark’ or null.
const storedTheme = typeof localStorage !== ‘undefined’ && localStorage.getItem(‘starlight-theme’);
// This theme is either ‘light’ or ‘dark’. It’s used for setting the data-theme attribute.
const theme =
!storedTheme || storedTheme === ‘auto’
? window.matchMedia(‘(prefers-color-scheme: light)‘).matches
? ‘light’
: ‘dark’
: storedTheme;
document.documentElement.dataset.theme = theme === ‘light’ ? ‘light’ : ‘dark’;
const themeSelects = document.querySelectorAll(‘[data-theme-select]’);
const selectedThemeValue = storedTheme || ‘auto’;
themeSelects.forEach((select) ⇒ {
const tmpl = select.querySelector([data-value="${selectedThemeValue}"] template);
const selectedSlot = select.querySelector(‘[data-part=“trigger-selected”]’);
selectedSlot.innerHTML = ”;
if (tmpl) {
selectedSlot.appendChild(tmpl.content.cloneNode(true));
return;
});
.stl-content-breadcrumbs{display:none!important;height:0!important;margin:0!important;padding:0!important}
.language-blocks:where(.astro-5wla7qih){display:flex;flex-wrap:wrap;gap:1rem;margin-top:2rem}.language-blocks:where(.astro-5wla7qih)>:where(.astro-5wla7qih){width:0;flex:1 1 350px}.api-overview:where(.astro-5wla7qih) .stldocs-resource-content:where(.astro-5wla7qih){padding:0!important}
@layer base{.syntax-highlighter{background:transparent;color:var(—color-text);overflow-x:auto}.syntax-highlighter>code{border:none;box-shadow:none;font-family:var(—monospace)}.syntax-highlighter>code>code{padding-right:16px;border:none;box-shadow:none;float:left;font-family:var(—monospace);line-height:20px}.syntax-highlighter .react-syntax-highlighter-line-number{color:var(—color-text-disabled);line-height:20px;opacity:.5;text-align:right;-webkit-user-select:none;-moz-user-select:none;user-select:none}.syntax-highlighter [data-highlighted-row=true]{display:block;width:150%;margin-left:-25%;background-color:var(—pill-success-bg)}.syntax-highlighter [data-highlighted-row-subtle=true]{background-color:rgba(var(—sh-fg),.08)}.hljs-comment{color:rgba(var(—sh-fg),.5)}.hljs-meta{color:rgba(var(—sh-fg),.6)}.hljs-built_in,.hljs-class .hljs-title{color:var(—syntax1)}.hljs-doctag,.hljs-keyword,.hljs-formula,.hljs-literal{color:var(—syntax2)}.hljs-string,.hljs-regexp,.hljs-addition,.hljs-attribute,.hljs-meta-string{color:var(—syntax3)}.hljs-attr,.hljs-variable,.hljs-template-variable,.hljs-type,.hljs-selector-class,.hljs-selector-attr,.hljs-selector-pseudo,.hljs-number{color:var(—syntax4)}.hljs-symbol,.hljs-bullet,.hljs-link,.hljs-selector-id,.hljs-title{color:var(—syntax5)}}
@layer base{.icon-item{cursor:pointer;border-radius:8px;align-items:flex-start;text-decoration:none;transition:opacity .15s;display:flex}.icon-item:hover .pointer{opacity:1;transform:translate(0)}.icon-item:hover .icon-item-icon{background:var(—card-gradient-hover);color:var(—color-text-emphasis)}.icon-item-icon{box-sizing:border-box;border:1px solid var(—color-background-primary-soft);background:var(—card-gradient-hover);width:48px;height:48px;color:var(—color-text);border-radius:8px;flex-shrink:0;justify-content:center;align-items:center;font-size:24px;line-height:0;transition:background .2s;display:flex}:where(html.dark,html[data-theme=dark]) .icon-item-icon{background:linear-gradient(90deg,#56586980,#56586999,#565869b3)}:where(html.dark,html[data-theme=dark]) .icon-item:hover .icon-item-icon{background:linear-gradient(90deg,#56586999,#565869b3,#565869cc)}.icon-item-right{padding-left:16px}.icon-item-title{color:var(—color-text-emphasis);align-items:center;font-weight:500;transition:color .15s;display:flex}.pointer{opacity:0;justify-content:center;transition:opacity .15s ease-in-out,transform .15s ease-in-out;display:flex;transform:translate(-4px)}.icon-item-tag{background-color:var(—color-background-primary-soft);color:var(—gray-700);font-size:12px;font-weight:var(—font-weight-bold);letter-spacing:var(—font-tracking-wide);border-radius:8px;margin-left:8px;padding:2px 6px;line-height:16px;display:inline-block;transform:translateY(-2px)}.icon-item-tag.icon-item-tag-green{background-color:var(—green-100);color:var(—green-700)}.icon-item-desc{color:var(—color-text-secondary);text-overflow:ellipsis;white-space:normal;margin-bottom:15px;overflow:hidden}.icon-item *{text-decoration:none}}
@layer components{._Arrow_t2o77_1{—arrow-size: 6px;position:absolute;width:0;height:0}._Arrow_t2o77_1[data-side=top]{bottom:0;left:50%;border-top:var(—arrow-size) solid var(—gray-700);border-right:var(—arrow-size) solid transparent;border-left:var(—arrow-size) solid transparent;margin-right:-8px;transform:translate(-50%) translateY(100%)}._Arrow_t2o77_1[data-side=bottom]{top:0;left:50%;border-right:var(—arrow-size) solid transparent;border-bottom:var(—arrow-size) solid var(—gray-700);border-left:var(—arrow-size) solid transparent;margin-left:-8px;transform:translate(-50%) translateY(-100%)}._Arrow_t2o77_1[data-side=left]{top:50%;right:0;border-top:var(—arrow-size) solid transparent;border-bottom:var(—arrow-size) solid transparent;border-left:var(—arrow-size) solid var(—gray-700);margin-right:-8px;transform:translate(100%) translateY(-50%)}._Arrow_t2o77_1[data-side=right]{top:50%;left:0;border-top:var(—arrow-size) solid transparent;border-right:var(—arrow-size) solid var(—gray-700);border-bottom:var(—arrow-size) solid transparent;margin-left:-8px;transform:translate(-100%) translateY(-50%)}}
apps-sdk-changelog li:target button[data-anchor-id]{opacity:1}
@layer components{._ModelsTitle_163e7_1{font-size:30px;font-weight:var(—font-weight-semibold);letter-spacing:var(—font-tracking-tight);line-height:1.3}}@layer components{._ImageContainer_z2xlm_1{position:relative;display:inline-block;width:100%}._ImageContainer_z2xlm_1 ._Image_z2xlm_1{position:absolute;top:0;left:0;width:100%;height:auto;opacity:0;transition:opacity .3s ease}._ImageContainer_z2xlm_1 ._Image_z2xlm_1[data-loaded]{opacity:1}}
@layer components.base{._root_w8837_2{position:relative;display:flex;flex-direction:column;margin:20px 0;border:.5px solid var(—color-border-primary-surface);border-radius:8px;background:var(—code-snippet-bg)}._root_w8837_2+._root_w8837_2{margin-top:1em}._flush_w8837_16{width:100%;border:0;background:transparent;background-color:transparent;color:var(—color-text-emphasis);line-height:20px}._flush_w8837_16 code>code{padding-right:20px!important}._flush_w8837_16 .syntax-highlighter{background:transparent;font-size:13px;letter-spacing:var(—font-tracking-wide)}._flush_w8837_16 ._header_w8837_34{position:relative;z-index:1;justify-content:space-between;padding-left:8px;border-bottom:none;background:transparent}._flush_w8837_16 ._header_w8837_34 ._title_w8837_42{display:none}._flush_w8837_16 ._header_w8837_34 .code-sample-select-val{font-size:12px;letter-spacing:var(—font-tracking-wide)}._flush_w8837_16 ._header_w8837_34 .code-sample-select-wrap{margin-bottom:4px;margin-left:12px;font-size:12px;letter-spacing:var(—font-tracking-wide)}._flush_w8837_16 ._body_w8837_59{background:transparent}._flush_w8837_16 ._body_w8837_59 ._pre_w8837_62{padding-top:0}._root_w8837_2 .python-upgrade-banner{display:flex;padding:2px;background:var(—card-gradient);color:#fff;font-size:.8em;font-weight:var(—font-weight-bold);text-align:center}._root_w8837_2 .python-upgrade-banner svg{margin-top:6px;margin-right:8px;margin-left:8px}._root_w8837_2 .python-upgrade-banner path{stroke:#fff}._header_w8837_34{overflow:auto;display:flex;align-items:center;gap:4px;flex-shrink:0;padding:4px 8px 4px 14px;border-bottom:.5px solid var(—color-border-primary-surface);border-top-left-radius:8px;border-top-right-radius:8px}._title_w8837_42{overflow:hidden;flex:1 1 auto;margin-right:12px;color:var(—color-text);font-family:var(—monospace);font-size:12px;font-weight:var(—font-weight-normal);letter-spacing:var(—font-tracking-wide);text-overflow:ellipsis;white-space:nowrap}._sep_w8837_113{flex:0 0 auto;min-width:1px;height:22px;padding-left:8px;border-left:1px solid var(—color-background-primary-soft);margin-left:8px}._body_w8837_59{position:relative;flex-grow:1;flex-shrink:0}._body_w8837_59 ._pre_w8837_62{height:100%;min-height:44px;padding:12px 16px;border-radius:8px;margin:0;font-size:14px;line-height:20px;white-space:pre;background:var(—code-snippet-bg)}._body_w8837_59._bodyWithHeader_w8837_139 ._pre_w8837_62{border-top-left-radius:0;border-top-right-radius:0}._copyFloat_w8837_151{position:absolute;top:6px;right:6px}._oneliner_w8837_156 ._copyFloat_w8837_151{top:50%;transform:translateY(-50%)}._copyButton_w8837_162{height:1.75rem;padding:0 .5rem;border-radius:.375rem}}
.blog-prose-content :where(h2):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:var(—font-heading-xl-size);font-weight:var(—font-heading-xl-weight);letter-spacing:var(—font-heading-xl-tracking);line-height:var(—font-heading-xl-line-height)}.blog-prose-content :where(h3):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:var(—font-heading-lg-size);font-weight:var(—font-heading-lg-weight);letter-spacing:var(—font-heading-lg-tracking);line-height:var(—font-heading-lg-line-height)}
.request-builder-container form{display:grid;grid-template-columns:max-content max-content max-content 1fr;font-family:var(—stl-typography-font);font-size:var(—stl-typography-text-body-sm);color:var(—stl-color-foreground)}.request-builder-container form>*{padding-inline-start:12px;padding-inline-end:8px}.request-builder-container form>h4{grid-column:1 / -1;text-transform:capitalize;font-size:var(—stl-typography-scale-sm);margin-top:0;margin-bottom:.25em;color:var(—stl-color-foreground-muted);padding-top:.75rem}.request-builder-container form>h4:not(:first-child){border-top:1px solid var(—stl-color-border)}.request-builder-container form .request-builder-param{grid-column:1 / -1;display:grid;grid-template-columns:subgrid;align-items:center;-moz-column-gap:.5rem;column-gap:.5rem;padding-block:.35rem}.request-builder-container form .request-builder-param .request-builder-param-info-button{color:var(—stl-color-foreground-muted);margin-inline:-4px;padding:0}.request-builder-container form .request-builder-param .request-builder-param-label{font-family:var(—stl-typography-font-mono)}.request-builder-container form .request-builder-param .request-builder-param-colon{font-family:var(—stl-typography-font-mono);color:var(—stl-color-foreground-muted)}.request-builder-container form .request-builder-param .request-builder-param-value input{margin:6px 8px;font-size:inherit}.request-builder-container form .request-builder-param:has(+h4),.request-builder-container form .request-builder-param:last-child{padding-bottom:.75rem}.request-builder-footer .stl-ui-button—ghost .stl-ui-button__icon{color:var(—stl-color-foreground);opacity:var(—stl-opacity-level-040)}
.workflow-steps:where(.astro-4drqtmie)>ol{counter-reset:workflow-step;list-style:none;padding-left:0;margin:1.5rem 0}.workflow-steps:where(.astro-4drqtmie)>ol>li{counter-increment:workflow-step;position:relative;padding-left:2.75rem;margin:0}.workflow-steps:where(.astro-4drqtmie)>ol>li:not(:last-child){padding-bottom:.75rem}.workflow-steps:where(.astro-4drqtmie)>ol>li:before{content:counter(workflow-step);position:absolute;left:0;top:0;height:27px;min-width:27px;padding:0 6px;display:inline-flex;align-items:center;justify-content:center;border-radius:9999px;background:var(—color-gray-100);color:var(—color-gray-700);font-size:12px;font-weight:600;line-height:1;font-variant-numeric:tabular-nums;box-sizing:border-box}.workflow-steps—headings:where(.astro-4drqtmie)>ol>li>p:first-of-type{font-weight:600}
.prompt-scroll:where(.astro-blfj6jyd){—prompt-scroll-gutter-x: 14px;—prompt-scroll-gutter-y: 16px;padding:0 calc(4.5rem + var(—prompt-scroll-gutter-x)) 0 1.5rem;scrollbar-gutter:stable;scrollbar-width:thin;scrollbar-color:rgb(15 23 42 / 28%) transparent}.prompt-scroll-frame:where(.astro-blfj6jyd){position:relative;background:inherit}.prompt-scroll__content:where(.astro-blfj6jyd){margin-right:calc(-1 * var(—prompt-scroll-gutter-x))}.prompt-scroll-frame:where(.astro-blfj6jyd):before,.prompt-scroll-frame:where(.astro-blfj6jyd):after{content:"";position:absolute;right:0;width:calc(1.5rem + var(—prompt-scroll-gutter-x) + 8px);height:var(—prompt-scroll-gutter-y);background:inherit;pointer-events:none;z-index:1}.prompt-scroll-frame:where(.astro-blfj6jyd):before{top:0}.prompt-scroll-frame:where(.astro-blfj6jyd):after{bottom:0}.prompt-actions:where(.astro-blfj6jyd){z-index:2}.prompt-scroll:where(.astro-blfj6jyd)::-webkit-scrollbar{width:8px;height:8px}.prompt-scroll:where(.astro-blfj6jyd)::-webkit-scrollbar-track{background:transparent;margin-block:var(—prompt-scroll-gutter-y)}.prompt-scroll:where(.astro-blfj6jyd)::-webkit-scrollbar-thumb{background-color:#0f172a47;border:2px solid transparent;border-radius:9999px;background-clip:padding-box}html.dark .prompt-scroll:where(.astro-blfj6jyd),[data-theme=dark] .prompt-scroll:where(.astro-blfj6jyd){scrollbar-color:rgb(255 255 255 / 28%) transparent}html.dark .prompt-scroll:where(.astro-blfj6jyd)::-webkit-scrollbar-thumb,[data-theme=dark] .prompt-scroll:where(.astro-blfj6jyd)::-webkit-scrollbar-thumb{background-color:#ffffff47}
[data-feed-field-layout=cards] table.feed-field-table-responsive{display:none!important}[data-feed-field-layout=cards] .feed-field-card-list{display:block!important;margin-top:.75rem}[data-feed-field-layout=table] .feed-field-card-list,[data-feed-field-layout=table] .feed-field-section-controls{display:none!important}.feed-field-section-controls{margin-top:.25rem;margin-bottom:.45rem;display:flex;flex-wrap:wrap;gap:.4rem}.feed-field-section-control-btn{display:inline-flex;align-items:center;border:1px solid var(—color-border-default);border-radius:.375rem;padding:.25rem .5rem;font-size:.7rem;font-weight:600;color:var(—color-text-secondary);background:transparent;transition:background .12s ease,color .12s ease}.feed-field-section-control-btn:hover{background:var(—color-surface);color:var(—color-text-primary)}.feed-field-card{margin-bottom:.875rem;border:1px solid var(—color-border-default, d1d5db);border-radius:.75rem;background:var(—color-surface);padding:.75rem .875rem}.feed-field-card-header{display:flex;align-items:flex-start;justify-content:space-between;gap:.75rem;margin-bottom:.25rem}.feed-field-card-attribute{min-width:0}.feed-field-card-attribute-label{color:#2563eb;font-size:.72rem;font-weight:700;letter-spacing:.01em;text-transform:uppercase;margin-bottom:.125rem}.feed-field-card-attribute-value{color:var(—color-text-primary);font-weight:650;line-height:1.35;word-break:break-word}.feed-field-card-requirement-badge{display:inline-flex;align-items:center;border-radius:9999px;padding:.2rem .55rem;font-size:.7rem;font-weight:700;letter-spacing:.01em;white-space:nowrap}.feed-field-card-requirement-badge.is-required{background:#fee2e2;color:#b91c1c}.feed-field-card-requirement-badge.is-conditional{background:#fef9c3;color:#a16207}.feed-field-card-requirement-badge.is-recommended{background:#dbeafe;color:#1d4ed8}.feed-field-card-requirement-badge.is-optional,.feed-field-card-requirement-badge.is-neutral{background:#f3f4f6;color:#6b7280}.feed-field-card-toggle{width:-moz-fit-content;width:fit-content;margin-left:auto;margin-right:auto;display:flex;justify-content:center;align-items:center;gap:.35rem;margin-top:.375rem;border:0;background:transparent;padding:.22rem .38rem;min-height:2rem;cursor:pointer;border-radius:.375rem;transition:background-color .12s ease}.feed-field-card-toggle:hover{background:#f3f4f6}.feed-field-card-toggle-icon{display:inline-block;width:16px;height:10px;color:var(—color-text-secondary);transform:rotate(0);transition:transform .16s ease}.feed-field-card-toggle-text{color:var(—color-text-secondary);font-size:.72rem;font-weight:600;line-height:1}.feed-field-card-toggle[aria-expanded=true] .feed-field-card-toggle-icon{transform:rotate(180deg)}.feed-field-card-row{display:grid;grid-template-columns:minmax(110px,24%) 1fr;gap:.4rem;padding:.3rem 0;border-bottom:1px solid color-mix(in srgb,var(—color-border-default) 60%,transparent)}.feed-field-card-row:last-child{border-bottom:0}.feed-field-card-key{color:var(—color-text-secondary);font-size:.72rem;font-weight:700;letter-spacing:.01em;text-transform:uppercase;word-break:break-word}.feed-field-card-value{color:var(—color-text-primary);font-size:.875rem;line-height:1.5;word-break:break-word}.feed-field-card-value code{font-size:.82rem}
.cursor-blink:where(.astro-76h4scq2){display:inline-block;min-width:.65ch;padding:0 .05ch;animation:cli-cursor-blink 1.4s steps(2,start) infinite}:where(.astro-76h4scq2)[data-cli-terminal-preview] pre:where(.astro-76h4scq2){-ms-overflow-style:none;scrollbar-width:none}:where(.astro-76h4scq2)[data-cli-terminal-preview] pre:where(.astro-76h4scq2)::-webkit-scrollbar{display:none}@keyframes cli-cursor-blink{0%,45%{background:#fff;color:var(—cli-cursor-text)}55%,to{background:transparent;color:inherit}}:where(.astro-76h4scq2)[data-cli-terminal-preview]{—cli-bg: 0f172ae6;—cli-border: #47556980;—cli-ring: #00000066;—cli-header-bg: 020617b3;—cli-text-strong: e2e8f0;—cli-text: cbd5e1;—cli-text-muted: 94a3b8;—cli-accent: 38bdf8;—cli-panel-bg: 0f172a66;—cli-dot-red: ff5f56;—cli-dot-yellow: ffbd2e;—cli-dot-green: 27c93f;—cli-cursor-text: #374151}
@layer components{._SectionContent_1tiej_1>*{border-top:1px solid var(—color-background-primary-soft)}}
dt:where(.astro-jofih75k) .cursor-help{text-decoration:none}
Skip to content Home
API Docs
Guides and concepts for the OpenAI API
API reference
Endpoints, parameters, and responses
Codex Docs
Guides, concepts, and product docs for Codex
Use cases
Example workflows and tasks teams hand to Codex
ChatGPT Apps SDK
Build apps to extend ChatGPT
Commerce
Build commerce flows in ChatGPT
Resources Showcase
Demo apps to get inspired
Blog
Learnings and experiences from developers
Cookbook
Notebook examples for building with OpenAI models
Learn
Docs, videos, and demo apps for building with OpenAI
Community
Programs, meetups, and support for builders
Start searching API Dashboard
Search the API docs
astro-island,astro-slot,astro-static-slot{display:contents} (()⇒{var e=async t⇒{await(await t())()};(self.Astro||(self.Astro={})).load=e;window.dispatchEvent(new Event(“astro:load”));})(); (()⇒{var A=Object.defineProperty;var g=(i,o,a)⇒o in i?A(i,o,{enumerable:!0,configurable:!0,writable:!0,value:a}):i[o]=a;var d=(i,o,a)⇒g(i,typeof o!=“symbol”?o+"":o,a);{let i={0:t⇒m(t),1:t⇒a(t),2:t⇒new RegExp(t),3:t⇒new Date(t),4:t⇒new Map(a(t)),5:t⇒new Set(a(t)),6:t⇒BigInt(t),7:t⇒new URL(t),8:t⇒new Uint8Array(t),9:t⇒new Uint16Array(t),10:t⇒new Uint32Array(t),11:t⇒Number.POSITIVE_INFINITY*t},o=t⇒{let[l,e]=t;return l in i?il:void 0},a=t⇒t.map(o),m=t⇒typeof t!=“object”||t===null?t:Object.fromEntries(Object.entries(t).map(([l,e])⇒[l,o(e)]));class y extends HTMLElement{constructor(){super(…arguments);d(this,“Component”);d(this,“hydrator”);d(this,“hydrate”,async()⇒{var b;if(!this.hydrator||!this.isConnected)return;let e=(b=this.parentElement)==null?void 0:b.closest(“astro-island[ssr]”);if(e){e.addEventListener(“astro:hydrate”,this.hydrate,{once:!0});return}let c=this.querySelectorAll(“astro-slot”),n={},h=this.querySelectorAll(“template[data-astro-template]”);for(let r of h){let s=r.closest(this.tagName);s!=null&&s.isSameNode(this)&&(n[r.getAttribute(“data-astro-template”)||“default”]=r.innerHTML,r.remove())}for(let r of c){let s=r.closest(this.tagName);s!=null&&s.isSameNode(this)&&(n[r.getAttribute(“name”)||“default”]=r.innerHTML)}let p;try{p=this.hasAttribute(“props”)?m(JSON.parse(this.getAttribute(“props”))):{}}catch(r){let s=this.getAttribute(“component-url”)||” “,v=this.getAttribute(“component-export”);throw v&&(s+= (export ${v})),console.error([hydrate] Error parsing props for component ${s},this.getAttribute(“props”),r),r}let u;await this.hydrator(this)(this.Component,p,n,{client:this.getAttribute(“client”)}),this.removeAttribute(“ssr”),this.dispatchEvent(new CustomEvent(“astro:hydrate”))});d(this,“unmount”,()⇒{this.isConnected||this.dispatchEvent(new CustomEvent(“astro:unmount”))})}disconnectedCallback(){document.removeEventListener(“astro:after-swap”,this.unmount),document.addEventListener(“astro:after-swap”,this.unmount,{once:!0})}connectedCallback(){if(!this.hasAttribute(“await-children”)||document.readyState="interactive"||document.readyState=“complete”)this.childrenConnectedCallback();else{let e=()⇒{document.removeEventListener(“DOMContentLoaded”,e),c.disconnect(),this.childrenConnectedCallback()},c=new MutationObserver(()⇒{var n;((n=this.lastChild)null?void 0:n.nodeType)=Node.COMMENT_NODE&&this.lastChild.nodeValue===“astro:end”&&(this.lastChild.remove(),e())});c.observe(this,{childList:!0}),document.addEventListener(“DOMContentLoaded”,e)}}async childrenConnectedCallback(){let e=this.getAttribute(“before-hydration-url”);e&&await import(e),this.start()}async start(){let e=JSON.parse(this.getAttribute(“opts”)),c=this.getAttribute(“client”);if(Astro[c]===void 0){window.addEventListener(astro:${c},()⇒this.start(),{once:!0});return}try{await Astro[c](async()⇒{let n=this.getAttribute(“renderer-url”),[h,{default:p}]=await Promise.all([import(this.getAttribute(“component-url”)),n?import(n):()⇒()⇒{}]),u=this.getAttribute(“component-export”)||“default”;if(!u.includes(”.“))this.Component=h[u];else{this.Component=h;for(let f of u.split(”.“))this.Component=this.Component[f]}return this.hydrator=p,this.hydrate},e,this)}catch(n){console.error([astro-island] Error hydrating ${this.getAttribute("component-url")},n)}}attributeChangedCallback(){this.hydrate()}}d(y,“observedAttributes”,[“props”]),customElements.get(“astro-island”)||customElements.define(“astro-island”,y)}})(); Search docs
Suggested
responses create reasoning_effort realtime prompt caching
Primary navigation API API Reference Codex ChatGPT Resources
Search docs
Get started
Overview
Quickstart
Models
Pricing
Libraries
Latest: GPT-5.4
Prompt guidance
Core concepts
Text generation
Code generation
Images and vision
Audio and speech
Structured output
Function calling
Responses API
Using tools
Agents SDK
Agent definitions
Models and providers
Running agents
Sandbox agents
Orchestration
Guardrails
Results and state
Integrations and observability
Evaluate agent workflows
Voice agents
Agent Builder Overview
Node reference
Safety in building agents
ChatKit Overview
Customize
Widgets
Actions
Advanced integrations
Tools
Web search
MCP and Connectors
Skills
Shell
Computer use
File search and retrieval File search
Retrieval
Tool search
More tools Apply Patch
Local shell
Image generation
Code interpreter
Run and scale
Conversation state
Background mode
Streaming
WebSocket mode
Webhooks
File inputs
Context management Compaction
Counting tokens
Prompt caching
Prompting Overview
Prompt engineering
Citation formatting
Reasoning Reasoning models
Reasoning best practices
Evaluation
Getting started
Working with evals
Prompt optimizer
External models
Best practices
Realtime API
Connect WebRTC
WebSocket
SIP
Usage Using realtime models
Managing conversations
MCP servers
Webhooks and server-side controls
Managing costs
Realtime transcription
Model optimization
Optimization cycle
Fine-tuning Supervised fine-tuning
Vision fine-tuning
Direct preference optimization
Reinforcement fine-tuning
RFT use cases
Graders
Specialized models
Video generation
Text to speech
Speech to text
Deep research
Embeddings
Moderation
Going live
Production best practices
Latency optimization Overview
Predicted Outputs
Priority processing
Cost optimization Overview
Batch
Flex processing
Accuracy optimization
Safety Safety best practices
Safety checks
Cybersecurity checks
Under 18 API Guidance
Legacy APIs
Assistants API Migration guide
Deep dive
Resources
Terms and policies
Changelog
Your data
Permissions
Rate limits
Deprecations
MCP for deep research
Developer mode
ChatGPT Actions Introduction
Actions library
Authentication
Production
Data retrieval
Sending files
Docs Use cases
Getting Started
Explore use cases
Concepts Prompting
Customization
Memories
Sandboxing
Subagents
Workflows
Cyber Safety
Using Codex
App Overview
Features
Settings
Review
Automations
Worktrees
Local Environments
In-app browser
Computer Use
Commands
Windows
Troubleshooting
IDE Extension Overview
IDE Commands
Slash commands
CLI Overview
Command Line Options
Web Overview
Environments
Internet Access
Integrations GitHub
Slack
Linear
Codex Security Overview
Setup
Improving the threat model
FAQ
Configuration
Config File Config Basics
Advanced Config
Config Reference
Sample Config
Speed
Rules
Hooks
AGENTS.md
MCP
Plugins Overview
Build plugins
Administration
Agent approvals & security
Remote connections
Enterprise Admin Setup
Governance
Managed configuration
Automation
Non-interactive Mode
Codex SDK
App Server
MCP Server
GitHub Action
Videos
Blog Using skills to accelerate OSS maintenance
Building frontend UIs with Codex and Figma
View all
Cookbooks Codex Prompting Guide
Modernizing your Codebase with Codex
Building AI Teams
Releases
Feature Maturity
Open Source
Home
Apps SDK Commerce
Core Concepts
MCP Apps in ChatGPT
UX principles
UI guidelines
Plan
Research use cases
Define tools
Design components
Build
Set up your server
Build your ChatGPT UI
Authenticate users
Manage state
Monetize your app
Examples
Deploy
Deploy your app
Connect from ChatGPT
Test your integration
Submit your app
Guides
Optimize Metadata
Security & Privacy
App submission guidelines