# gpt-4.1 — API, Pricing & Context Window

gpt-4.1 on Vivgrid: OpenAI's GPT-4.1 with a ~1M-token context window and image input, available through a single unified API.

`gpt-4.1` is OpenAI's refined GPT-4-generation model, notable for its very large **~1.05M-token context window** and strong instruction following. It remains a dependable choice for long-document workflows and established integrations.

Vivgrid serves `gpt-4.1` through its unified, OpenAI-compatible endpoint, so you can keep proven prompts running while routing through one API key and billing surface.

## Specifications

|     |     |
| --- | --- |
| **Provider** | OpenAI |
| **Model ID** | `gpt-4.1` |
| **Best for** | General-purpose |
| **Context window** | 1,047,576 tokens |
| **Modalities** | Text, Image |
| **Tool / function calling** | Yes |
| **Knowledge cutoff** | 2024-05 |
| **Acceleration** | 🌐 Global (Centralized) |

## Pricing

Pricing in USD per 1M tokens, matching the provider's rates.

| Input | Cached input | Output |
| --- | --- | --- |
| $2.00 | $0.50 | $8.00 |

## Quick start

Call `gpt-4.1` through Vivgrid's unified, OpenAI-compatible endpoint. Get an API key from the [Vivgrid Console](https://console.vivgrid.com/).

```
curl https://api.vivgrid.com/v1/chat/completions \
  -H "Authorization: Bearer $VIVGRID_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{\n    "model": "gpt-4.1",\n    "messages": [\
      { "role": "user", "content": "Say hello in English, Chinese and Spanish." }\
    ],\n    "stream": true\n  }'\
```

## Ideal use cases

- Long-document analysis and summarization
- Stable production integrations built on GPT-4.x
- Instruction-following and structured extraction
- Workloads needing a very large context at GPT-4 pricing

## Related models

- [gpt-4o](/content/docs/models/gpt-4o/index.html) — multimodal GPT-4-class model
- [gpt-5](/content/docs/models/gpt-5/index.html) — the next-generation upgrade
- [gpt-5-mini](/content/docs/models/gpt-5-mini/index.html) — cheaper modern alternative

[gpt-5-chat\
\
gpt-5-chat on Vivgrid: a conversation-tuned GPT-5 model with a 128K context window and image input, accessed through one unified API.](/content/docs/models/gpt-5-chat/index.html) [gpt-4o\
\
gpt-4o on Vivgrid: OpenAI's multimodal GPT-4o with a 128K context window and image input, accessible through one unified API key.](/content/docs/models/gpt-4o/index.html)
