跪拜 Guibai
← All articles
Claude · GPT · DeepSeek

Microsoft's MAI Code 2 Halves Input Price to $0.50/M Tokens; DeepSeek Kills 18-Day-Old Web Search Fee — How to Reroute Your API Bills

By 一缕82年的清风 ·
Read original on juejin.cn ↗ Google Translate ↗ Alt translation

Token pricing and per-call fees directly decide whether agentic workflows are cheap enough to run continuously. Western developers running automated retrieval or large refactors can save hundreds of dollars per month by re-routing to the newly discounted MAI Code 2 and by using DeepSeek's now-free built-in web search, as long as they respect the billing boundaries.

Summary

Microsoft shipped MAI Code 2 at Ignite 2026 with a 1.05 million-token context and a promotional price of $0.50 per million input tokens (output at $2.50), half the normal rate until May 17, 2027. The sparse MoE model with native vision encoding runs in GitHub Copilot and Microsoft Foundry, and its Flash variant gives near-instant completions. Blind tests on a 30,000-line backend showed roughly equivalent performance to GPT-6.2 Sol and Gemini 4 Neon for refactoring and unit-test work, at a fraction of the cost.

DeepSeek reversed course on its web search fee after only 18 days. The 5 yuan per 1,000 successful requests charge, introduced November 1, is now gone for any search automatically triggered by the model — including the official web search tool and the Anthropic/Responses API web_search. Standalone Search/Fetch API calls still cost money, and fetched content still counts as input tokens, so tool parameters should cap results at 3 to avoid ballooning context.

A practical routing strategy splits daily work: 80% to discounted MAI Code 2, real-time lookups to DeepSeek's built-in web search, and less than 10% of hard concurrency/architecture tasks to premium models. The author's monthly spend dropped from $200–350 to under $40, with a 12-line Python routing config that switches on scene: search vs. coding.

Takeaways
— Microsoft's MAI Code 2 is priced at $0.50 per million input tokens and $2.50 per million output tokens until May 17, 2027, after which prices revert to $1 and $5.
— MAI Code 2 has a total context of 1.05 million tokens (922k input, 128k output) and offers low to max reasoning levels.
— DeepSeek officially canceled the per-use web search fee effective November 18, 2025 at 12:00 Beijing time; the fee was 5 yuan per 1,000 successful requests and only existed for 18 days.
— The exemption applies only to searches automatically triggered by the model during dialogue calls; standalone Search/Fetch API calls still incur the 5 yuan per 1,000 requests fee.
— Fetched web content is billed as input tokens, so limiting results to 3 or fewer per call prevents large context bills.
— A three-tier routing split (80% MAI Code 2, real-time search via DeepSeek's web_search, <10% premium models) reduced a monthly bill from $200–350 to under $40 for roughly 40M input and 5M output tokens per month.
— The example routing configuration uses OpenAI-compatible endpoints: DeepSeek for search scenes, Microsoft Foundry's MAI URL for coding scenes.
Conclusions

DeepSeek's 18-day fee reversal suggests that charging for built-in web search was a pricing experiment, and the backlash from automated users (whose bills ballooned despite low token costs) forced a quick rollback.

The half-price window for MAI Code 2 is effectively a long-term (18-month) price war, not a short-term promo, and it pressures other providers to match the $0.50 input rate.

With context windows now over a million tokens, the input token price has become the dominant cost lever for repository-scale refactors, making model choice more about input cost than raw output quality.

Capping web search results at 3 is a subtle but critical optimization: the real cost in retrieval workflows isn't the per-call fee anymore, but the token bloat from long pages.

Concepts & terms
Sparse MoE (Mixture of Experts)
A model architecture that activates only a subset of its expert networks per token, reducing inference cost while retaining large model capacity. MAI Code 2 uses sparse MoE to balance quality and price.
web_search tool
A function built into an LLM API that lets the model automatically search the web during a conversation. The results are injected into the context and the caller pays only for tokens, not per search.
Source: juejin.cn ↗ Google Translate ↗ Backup ↗