OpenAI

GPT-4o (2024-08-06)

gpt-4o-2024-08-06Available

GPT-4o (2024-08-06). Text generation model.

Context
128K tokens
vs. official price
15% cheaper

Pricing (USD per 1M tokens)

How prices are calculated
Prices (USD per 1M tokens)
ItemOfficialBasicPremium
Input$2.50≈ ¥397$2.125≈ ¥340$1.875≈ ¥300
Output$10.00≈ ¥1,586$8.50≈ ¥1,360$7.50≈ ¥1,200
Cache read$1.25≈ ¥198$1.0625≈ ¥170$0.9375≈ ¥150

Cost per task vs. models at a similar price

Compare them

How to call

POST/v1/chat/completions

import os
from openai import OpenAI

client = OpenAI(
    base_url="https://token.echohub.io/v1",
    api_key=os.environ["ECHO_API_KEY"],
)

res = client.chat.completions.create(
    model="gpt-4o-2024-08-06",
    messages=[{"role": "user", "content": "Hello"}],
)
print(res.choices[0].message.content)
its developer docs