GPT-5.2-Codex Now Available in AI Gateway and Agent Runners

January 14, 2026

OpenAI’s GPT-5.2-Codex model is now available through Netlify’s AI Gateway and Agent Runners with zero configuration required.

Use the OpenAI SDK directly in your Netlify Functions without managing API keys or authentication. The AI Gateway handles everything automatically. Here’s an example using the GPT-5.2-Codex model:

import OpenAI from 'openai';
export default async () => {
const openai = new OpenAI();
const response = await openai.responses.create({
model: 'gpt-5.2-codex',
input: 'How does AI work?'
});
return new Response(JSON.stringify(response), {
headers: { 'Content-Type': 'application/json' }
});
};

GPT-5.2-Codex is available across Background Functions, Scheduled Functions, and Agent Runners. You get automatic access to Netlify’s caching, rate limiting, and authentication infrastructure.

Learn more in the AI Gateway documentation and Agent Runners documentation.