Remove xAI web search capability (#5255) With web search on, the API now returns 410 Gone.

e834d3724b3dd1901cb603cc2f2b557efe282c3f

equal-l2 <eng.equall2@gmail.com>

Signed
2 files changed, +1 -12Showing whitespace changes
public/index.html+1 -1
@@ -1982,7 +1982,7 @@
1982 </span>1982 </span>
1983 </div>1983 </div>
1984 </div>1984 </div>
1985 <div class="range-block" data-source="makersuite,vertexai,aimlapi,openrouter,claude,xai,electronhub,chutes,nanogpt">1985 <div class="range-block" data-source="makersuite,vertexai,aimlapi,openrouter,claude,electronhub,chutes,nanogpt">
1986 <label for="openai_enable_web_search" class="checkbox_label flexWrap widthFreeExpand">1986 <label for="openai_enable_web_search" class="checkbox_label flexWrap widthFreeExpand">
1987 <input id="openai_enable_web_search" type="checkbox" />1987 <input id="openai_enable_web_search" type="checkbox" />
1988 <span data-i18n="Enable web search">Enable web search</span>1988 <span data-i18n="Enable web search">Enable web search</span>
src/endpoints/backends/chat-completions.js+0 -11
@@ -1154,17 +1154,6 @@ async function sendXaiRequest(request, response) {
1154 bodyParams['reasoning_effort'] = request.body.reasoning_effort === 'high' ? 'high' : 'low';1154 bodyParams['reasoning_effort'] = request.body.reasoning_effort === 'high' ? 'high' : 'low';
1155 }1155 }
11561156
1157 if (request.body.enable_web_search) {
1158 bodyParams['search_parameters'] = {
1159 mode: 'on',
1160 sources: [
1161 { type: 'web', safe_search: false },
1162 { type: 'news', safe_search: false },
1163 { type: 'x' },
1164 ],
1165 };
1166 }
1167
1168 if (request.body.json_schema) {1157 if (request.body.json_schema) {
1169 bodyParams['response_format'] = {1158 bodyParams['response_format'] = {
1170 type: 'json_schema',1159 type: 'json_schema',