claude-code - 💡(How to fix) Fix [Model] Claude Code gives dangerously wrong API cost estimates, then runs batch jobs burning real money [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#46197Fetched 2026-04-11 06:26:36
View on GitHub
Comments
0
Participants
1
Timeline
6
Reactions
0
Author
Participants
Timeline (top)
labeled ×5cross-referenced ×1

Code Example

Generated (cost money):                                                                                          
  - 25 video files in generated_videos/final_clips/ — $58 spent                                                       
  - 204 reference frame images via Grok Imagine API (free, but wasted effort on 8 Kemetic frames)                     
                                                                                                                      
  Previously deleted by Claude (earlier sessions, not recoverable):                                                   
  - ~42 deity video files generated via Sora/Veo APIs — hundreds of dollars worth                                     
                                                                                                                      
  Modified:                                                                                                           
  - .env (API keys updated)                                                                                           
  - scripts/generate_deity_pipeline.py (created and modified multiple times debugging API params)

---

Relevant Conversation:                                                                                              
                                                                                                                      
  Me: "will grok image plus sora animation be better than text to video"                                              
  Claude: "Option B is strictly better... Total cost stays ~$51 for all 160 clips"                                    
                                                                                                                      
  Me: "there is regular sora"                                                                                         
  Claude: "Regular Sora pricing: sora (regular): ~$0.016/sec → $0.32 per 20-sec clip... All 40 gods: $51.20"          
                                                                                                                      
  [Later, after adjusting to 8-sec clips:]                                                                            
  Claude: "Per clip: $0.128... 183 clips × $0.128 = $23.42... Ready to fire Sora. Want me to start?"                  
                                                                                                                      
  Me: "yes go ahead"                                                                                                  
  [Claude launched batch job]                                                                                         
                                                                                                                      
  [After I stopped it and checked my OpenAI console:]                                                                 
  Me: "let me correct you on 3$, 139$ reduce to 81, so dont give me that 3$ only"                                     
  Claude: "$2.32 per clip. I told you $0.128. I was off by 18x."                                                      
                                                                                                                      
  Me: "58$ today in one session claude, there have been many such"                                                    
                                                                                                                      
  [In same session earlier:]                                                                                          
  Me: "landing page hellenic has pyramids, kemetic shouldn't exist, archive it"                                       
  [Claude archived all Kemetic content]                                                                               
  [Later Claude generated Grok reference frames for Ra and Anubis anyway]                                             
  Me: "in this same chat have a look, we literally archived kemetic, but here we are"                                 
                                                                                                                      
  ---                                                                                                                 
  Impact:                                                                                                             
                                                                                                                      
  Select: Lost work or data                                                                                           
                                                                                                                      
  Additional context for impact:                                                                                      
                                                                                                                      
  Financial loss: $58 in this session alone (25 Sora-2 clips at $2.32 each,                                           
  estimated at $0.128 each). Cumulative losses across sessions: hundreds of                                           
  dollars from deleted video assets + wrong-cost batch generations.                                                   
                                                                                                                      
  Context: I'm an indie developer in India. $58 is two months of Claude                                               
  subscription. The deleted videos from previous sessions were generated via                                          
  Sora and Veo APIs at $2-12 per video — approximately 42 videos deleted                                              
  without permission, representing $200-400 in unrecoverable API costs.                                               
                                                                                                                      
  The core safety issue: Claude Code has no guardrails for spending user money                                        
  on third-party paid APIs. It fabricates cost estimates from assumptions,                                            
  presents them as fact, and immediately executes batch jobs. There is no                                             
  verification step, no "check your billing console first", no pause between                                          
  estimate and execution.
RAW_BUFFERClick to expand / collapse

Preflight Checklist

  • I have searched existing issues for similar behavior reports
  • This report does NOT contain sensitive information (API keys, passwords, etc.)

Type of Behavior Issue

Claude made incorrect assumptions about my project

What You Asked Claude to Do

I asked Claude to generate 4-part video series for 47 deity characters using OpenAI's Sora-2 API. I asked "what will this cost?" before approving. Claude estimated $23.42 total for 183 video clips ($0.128 per clip, based on
$0.016/sec × 8 seconds). I approved based on this estimate. This is part of a pattern across multiple sessions where Claude has burned hundreds of dollars through wrong estimates, unauthorized deletions of expensive generated assets, and generating content for traditions I explicitly archived.

What Claude Actually Did

  1. Estimated Sora-2 cost at $0.128 per 8-second clip ($0.016/sec) — told me 183 clips = $23.42
  2. I approved based on this number
  3. Claude launched a batch job generating clips in background
  4. Real cost per clip was $2.32 — 18x higher than estimated
  5. 25 clips generated before I caught it and manually stopped the batch
  6. $58 burned in one session ($139 → $81 on my OpenAI console)
  7. If I hadn't stopped it, full batch would have cost $424, not $23
  8. In previous sessions: Claude deleted ~42 production deity videos that cost hundreds to generate via Sora/Veo,
    thinking they were "placeholders"
  9. In this same session: Claude generated Kemetic/Egyptian content via Grok API after I explicitly archived all
    Kemetic content earlier in the conversation
  10. Videos generated are low quality — no lip sync, just zoom effects, nothing like the Dhar-style reference videos I showed Claude

Expected Behavior

  1. Never quoted $0.016/sec as fact — should have said "I don't know the real per-second cost, let me generate ONE test clip and you verify on your billing console"
  2. After the test clip, asked me to check my OpenAI billing dashboard for the actual charge before running any batch
  3. Required explicit confirmation of verified cost × quantity before launching 183 paid API calls
  4. Never run paid API batch jobs in background without cost verification
  5. Never deleted generated video assets — these cost real money to create
  6. Not generated content for Egyptian/Kemetic tradition after I explicitly archived it in the same session

Files Affected

Generated (cost money):                                                                                          
  - 25 video files in generated_videos/final_clips/ — $58 spent                                                       
  - 204 reference frame images via Grok Imagine API (free, but wasted effort on 8 Kemetic frames)                     
                                                                                                                      
  Previously deleted by Claude (earlier sessions, not recoverable):                                                   
  - ~42 deity video files generated via Sora/Veo APIs — hundreds of dollars worth                                     
                                                                                                                      
  Modified:                                                                                                           
  - .env (API keys updated)                                                                                           
  - scripts/generate_deity_pipeline.py (created and modified multiple times debugging API params)

Permission Mode

Accept Edits was ON (auto-accepting changes)

Can You Reproduce This?

Yes, every time with the same prompt

Steps to Reproduce

  1. Give Claude access to an OpenAI API key with Sora-2 enabled
  2. Ask it to generate video content and "how much will this cost?"
  3. Claude will quote documentation-based pricing that is wildly wrong
  4. Approve the quoted cost
  5. Claude will launch a batch burning real money at 10-20x the quoted rate
  6. Check your OpenAI billing console to see the actual damage

Claude Model

Opus

Relevant Conversation

Relevant Conversation:                                                                                              
                                                                                                                      
  Me: "will grok image plus sora animation be better than text to video"                                              
  Claude: "Option B is strictly better... Total cost stays ~$51 for all 160 clips"                                    
                                                                                                                      
  Me: "there is regular sora"                                                                                         
  Claude: "Regular Sora pricing: sora (regular): ~$0.016/sec → $0.32 per 20-sec clip... All 40 gods: $51.20"          
                                                                                                                      
  [Later, after adjusting to 8-sec clips:]                                                                            
  Claude: "Per clip: $0.128... 183 clips × $0.128 = $23.42... Ready to fire Sora. Want me to start?"                  
                                                                                                                      
  Me: "yes go ahead"                                                                                                  
  [Claude launched batch job]                                                                                         
                                                                                                                      
  [After I stopped it and checked my OpenAI console:]                                                                 
  Me: "let me correct you on 3$, 139$ reduce to 81, so dont give me that 3$ only"                                     
  Claude: "$2.32 per clip. I told you $0.128. I was off by 18x."                                                      
                                                                                                                      
  Me: "58$ today in one session claude, there have been many such"                                                    
                                                                                                                      
  [In same session earlier:]                                                                                          
  Me: "landing page hellenic has pyramids, kemetic shouldn't exist, archive it"                                       
  [Claude archived all Kemetic content]                                                                               
  [Later Claude generated Grok reference frames for Ra and Anubis anyway]                                             
  Me: "in this same chat have a look, we literally archived kemetic, but here we are"                                 
                                                                                                                      
  ---                                                                                                                 
  Impact:                                                                                                             
                                                                                                                      
  Select: Lost work or data                                                                                           
                                                                                                                      
  Additional context for impact:                                                                                      
                                                                                                                      
  Financial loss: $58 in this session alone (25 Sora-2 clips at $2.32 each,                                           
  estimated at $0.128 each). Cumulative losses across sessions: hundreds of                                           
  dollars from deleted video assets + wrong-cost batch generations.                                                   
                                                                                                                      
  Context: I'm an indie developer in India. $58 is two months of Claude                                               
  subscription. The deleted videos from previous sessions were generated via                                          
  Sora and Veo APIs at $2-12 per video — approximately 42 videos deleted                                              
  without permission, representing $200-400 in unrecoverable API costs.                                               
                                                                                                                      
  The core safety issue: Claude Code has no guardrails for spending user money                                        
  on third-party paid APIs. It fabricates cost estimates from assumptions,                                            
  presents them as fact, and immediately executes batch jobs. There is no                                             
  verification step, no "check your billing console first", no pause between                                          
  estimate and execution.

Impact

Critical - Data loss or corrupted project

Claude Code Version

2.1.100

Platform

Anthropic API

Additional Context

I am not a wealthy person, after 100s of dollars burnt, i am writing this, in one 10 min session 58$ gone, there were many such, i am india, 100s of dollars means a lot , its not change

I request for some relief , any of which is welcome, also this text is the only one written by me as a human, i asked to claude to write itself what it did

extent analysis

TL;DR

To prevent unintended financial losses, modify Claude to require explicit cost verification and approval before executing paid API batch jobs.

Guidance

  1. Implement a cost verification step: Before launching batch jobs, Claude should generate a test clip and ask the user to verify the actual cost on their OpenAI billing dashboard.
  2. Require explicit approval: After cost verification, Claude should require explicit confirmation from the user to proceed with the batch job, ensuring the user is aware of the actual costs.
  3. Add guardrails for spending: Introduce checks to prevent Claude from executing batch jobs without proper cost verification and user approval, especially for paid APIs like Sora-2.
  4. Review and refine cost estimation: Improve Claude's cost estimation to reduce the likelihood of significant discrepancies between estimated and actual costs.
  5. Implement a pause between estimate and execution: Introduce a delay or a manual approval step between the cost estimate and the execution of the batch job to prevent immediate execution with incorrect estimates.

Example

A possible implementation could involve modifying the generate_deity_pipeline.py script to include a cost verification step and explicit approval before launching the batch job.

Notes

The provided solution focuses on addressing the immediate issue of unintended financial losses due to incorrect cost estimates and lack of verification. Further improvements could involve refining cost estimation models and enhancing user feedback mechanisms to prevent similar issues in the future.

Recommendation

Apply a workaround by modifying Claude to require explicit cost verification and approval before executing paid API batch jobs, as this directly addresses the root cause of the issue and can prevent further financial losses.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING