How OpenAI prompt caching actually cuts your token bill
OpenAI prompt caching takes 90% off repeated tokens, but only for prefixes over 1,024 tokens and only when the static part of your prompt comes first. Here is a Python example plus the ordering mistake that kills cache hits.