---
title: OpenAI: GPT 5.2 Pro API | Text Generation | ModelsLab
description: Flagship LLM with 400K token context, 128K output, multimodal text/image support, and xhigh reasoning for enterprise coding, math SOTA, and.
url: https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/openai/openai-gpt-5.2-pro/api.md
canonical: https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/openai/openai-gpt-5.2-pro/api.md
type: product
component: Playground/LLM/Index
generated_at: 2026-05-13T10:33:26.577858Z
---

OpenAI: GPT-5.2 Pro
---

 [LLMs.txt](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/openai-gpt-5.2-pro/llms.txt) [.md](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/openai/openai-gpt-5.2-pro.md)

openai-gpt-5.2-pro openai Closed Source Model $94.500000 / call

OpenAI: GPT-5.2 Pro
---

Choose a prompt below to get started or type your own message

 Explain quantum computing in simple terms

 Write a Python function to sort a list

 Create a marketing email for a SaaS product

 Compare REST vs GraphQL APIs

Send

### OpenAI: GPT-5.2 Pro

openai openai-gpt-5.2-pro

Copy model ID

PricingInput $21.00 / 1M tokens

Output $168.00 / 1M tokens

API EndpointsOpenAI Compatible

`https://modelslab.com/api/v7/llm/chat/completions`Endpoint

Anthropic Compatible

`https://modelslab.com/api/v7/llm/v1/messages`Messages

`https://modelslab.com/api/v7/llm/v1/messages/count_tokens`Count Tokens

`https://modelslab.com/api/v7/llm/v1/models`Models

Use with Claude Code

cURL Example

ParametersSystem MessageYou are a helpful AI assistant specialized in providing accurate and detailed responses.

Temperature0.7

Max Tokens1000

Top P0.9

Frequency Penalty0

Presence Penalty0

Model Info

Support

Related Models
---

Discover similar models you might be interested in

 [View all LLM Models](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models?feature=llmaster)

[CC](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/cohere-command-a)[Open Router](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router)

 [Cohere: Command A

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/cohere-command-a)

[MK](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/moonshotai-kimi-latest)[Open Router](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router)

 [MoonshotAI Kimi Latest

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/moonshotai-kimi-latest)

[![Mixtral-8x7B Instruct v0.1](https://images.stablediffusionapi.com/?Image=https://assets.modelslab.ai/generations/67dabe3d-a00a-4cc4-a158-136c8f189137.png)](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai/mistralai-Mixtral-8x7B-Instruct-v0.1)[Together AI](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai)

 [Mixtral-8x7B Instruct v0.1

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai/mistralai-Mixtral-8x7B-Instruct-v0.1)

[QP](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai/Qwen-Qwen3.6-Plus)[Together AI](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai)

 [Qwen3.6 Plus

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai/Qwen-Qwen3.6-Plus)

[ML](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai/meta-llama-Llama-3.1-405B-Instruct)[Together AI](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai)

 [Meta Llama 3.1 405B Instruct

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai/meta-llama-Llama-3.1-405B-Instruct)

[GG](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/google-gemma-3-12b-it)[Open Router](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router)

 [Google: Gemma 3 12B

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/google-gemma-3-12b-it)

[XM](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/xiaomi-mimo-v2-flash)[Open Router](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router)

 [Xiaomi: MiMo-V2-Flash

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/xiaomi-mimo-v2-flash)

[L3](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai/meta-llama-Llama-3.3-70B-Instruct-FP8-Lora)[Together AI](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai)

 [Llama 3.3 70B Instruct FP8 Lora

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai/meta-llama-Llama-3.3-70B-Instruct-FP8-Lora)

[![Gemini 3 Pro Preview](https://images.stablediffusionapi.com/?Image=https://assets.modelslab.ai/generations/1846e76f-9d5c-4a35-a43a-82db45b7bb8b.png)](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/google/gemini-3-pro-preview)[Google](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/google)

 [Gemini 3 Pro Preview

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/google/gemini-3-pro-preview)

[G4](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai/google-gemma-4-26B-A4B-it)[Together AI](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai)

 [Gemma 4 26B A4b It

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai/google-gemma-4-26B-A4B-it)

[NN](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/nvidia-nemotron-3-nano-30b-a3b-free)[Open Router](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router)

 [NVIDIA: Nemotron 3 Nano 30B A3B (free)

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/nvidia-nemotron-3-nano-30b-a3b-free)

[DR](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai/deepseek-ai-DeepSeek-R1-Distill-Qwen-1.5B)[Together AI](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai)

 [DeepSeek R1 Distill Qwen 1.5B

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/together_ai/deepseek-ai-DeepSeek-R1-Distill-Qwen-1.5B)

[QQ](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/qwen-qwen3-max-thinking)[Open Router](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router)

 [Qwen: Qwen3 Max Thinking

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/qwen-qwen3-max-thinking)

[OG](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/openai-gpt-5-pro)[Open Router](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router)

 [OpenAI: GPT-5 Pro

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/openai-gpt-5-pro)

[OG](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/openai-gpt-chat-latest)[Open Router](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router)

 [OpenAI: GPT Chat Latest

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/openai-gpt-chat-latest)

[DD](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/deepseek-deepseek-v3.2)[Open Router](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router)

 [DeepSeek: DeepSeek V3.2

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/deepseek-deepseek-v3.2)

[MP](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/mistralai-pixtral-large-2411)[Open Router](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router)

 [Mistral: Pixtral Large 2411

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/mistralai-pixtral-large-2411)

[AC](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/anthropic-claude-opus-4.6)[Open Router](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router)

 [Anthropic: Claude Opus 4.6

Closed Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/anthropic-claude-opus-4.6)

About OpenAI: GPT-5.2 Pro
---

GPT-5.2 Pro is OpenAI’s most advanced model, offering major improvements in agentic coding and long context performance over GPT-5 Pro. It is optimized for complex tasks that require step-by-step reasoning,...

### Technical Specifications

Model IDopenai-gpt-5.2-proCategoryLLM ModelsTaskText GenerationPrice$94.500000 per million tokensAddedFebruary 20, 2026

### Key Features

- Chat completion and multi-turn conversation API
- Streaming response with token-by-token output
- Function calling and tool use support
- System prompts and role-based messaging
- JSON mode and structured output

### Quick Start

Integrate OpenAI: GPT-5.2 Pro into your application with a single API call. Get your API key from the [pricing page](https://modelslab-frontend-v2-927501783998.us-east4.run.app/pricing) to get started.

PythonJavaScriptcURLPHP

```
<code>import requests
import json

url = "https://modelslab.com/api/v7/llm/chat/completions"

headers = {
    "Content-Type": "application/json"
}

data = {
        "model_id": "openai-gpt-5.2-pro",
        "messages": [
            {
                "role": "user",
                "content": "Hello!"
            }
        ],
        "max_tokens": 1000,
        "key": "YOUR_API_KEY"
    }

try:
    response = requests.post(url, headers=headers, json=data)
    response.raise_for_status()  # Raises an HTTPError for bad responses (4XX or 5XX)
    result = response.json()
    print("API Response:")
    print(json.dumps(result, indent=2))
except requests.exceptions.HTTPError as http_err:
    print(f"HTTP error occurred: {http_err} - {response.text}")
except Exception as err:
    print(f"Other error occurred: {err}")</code>
```

View the [full API documentation](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/openai/openai-gpt-5.2-pro/api) for SDKs, code examples in Python, JavaScript, and more.

### Pricing

OpenAI: GPT-5.2 Pro API costs $94.500000 per million tokens. Pay only for what you use with no minimum commitments. [View pricing plans](https://modelslab-frontend-v2-927501783998.us-east4.run.app/pricing)

### Use Cases

- AI chatbots and virtual assistants
- Code generation and developer tools
- Content writing and copywriting automation
- Data analysis, summarization, and extraction

[Learn more about OpenAI: GPT-5.2 Pro](https://modelslab-frontend-v2-927501783998.us-east4.run.app/openai-gpt-52-pro) [Browse LLM Models](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models?feature=llmaster) [More from Openai](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router) [View Pricing](https://modelslab-frontend-v2-927501783998.us-east4.run.app/pricing)

OpenAI: GPT-5.2 Pro FAQ
---

### What is OpenAI: GPT-5.2 Pro?

GPT-5.2 Pro is OpenAI’s most advanced model, offering major improvements in agentic coding and long context performance over GPT-5 Pro. It is optimized for complex tasks that require step-by-step reasoning,...

### How do I use the OpenAI: GPT-5.2 Pro API?

You can integrate OpenAI: GPT-5.2 Pro into your application with a single API call. Sign up on ModelsLab to get your API key, then use the model ID "openai-gpt-5.2-pro" in your API requests. We provide SDKs for Python, JavaScript, and cURL examples in the API documentation.

### How much does OpenAI: GPT-5.2 Pro cost?

OpenAI: GPT-5.2 Pro costs $94.500000 per million tokens. ModelsLab uses pay-per-use pricing with no minimum commitments. A free tier is available to get started.

### What is the OpenAI: GPT-5.2 Pro model ID?

The model ID for OpenAI: GPT-5.2 Pro is "openai-gpt-5.2-pro". Use this ID in your API requests to specify this model.

### Does OpenAI: GPT-5.2 Pro have a free tier?

Yes, ModelsLab offers a free tier that lets you try OpenAI: GPT-5.2 Pro and other AI models. Sign up to get free API credits and start building immediately.

---

*This markdown version is optimized for AI agents and LLMs.*

**Links:**
- [Website](https://modelslab.com)
- [API Documentation](https://docs.modelslab.com)
- [Blog](https://modelslab.com/blog)

---
*Generated by ModelsLab - 2026-05-13*