Repository navigation
Closed as not planned
Description
Question
im trying to use opencode go API with copilot through oai-compatible-copilot heres error & config:
full error log:
Sorry, your request failed. Please try again.
Copilot Request id: 687d33f4-3958-42c9-aa3e-43a42f301418
Reason: Anthropic API error: [403] Forbidden <!doctype html>
<!--[if lt IE 7]> <html class="no-js ie6 oldie" lang="en-US"> <![endif]--> <!--[if IE 7]> <html class="no-js ie7 oldie" lang="en-US"> <![endif]--> <!--[if IE 8]> <html class="no-js ie8 oldie" lang="en-US"> <![endif]--> <!--[if gt IE 8]><!--> <html class="no-js" lang="en-US"> <!--<![endif]--> <head> <title>Access denied | opencode.ai used Cloudflare to restrict access | opencode.ai | Cloudflare</title> <meta charset="UTF-8" /> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <meta http-equiv="X-UA-Compatible" content="IE=Edge" /> <meta name="robots" content="noindex, nofollow" /> <meta name="viewport" content="width=device-width,initial-scale=1" /> <link rel="stylesheet" id="cf_styles-css" href="/cdn-cgi/styles/main.css" /> <script> (function(){if(document.addEventListener&&window.XMLHttpRequest&&JSON&&JSON.stringify){var e=function(a){var c=document.getElementById("error-feedback-survey"),d=document.getElementById("error-feedback-success"),b=new XMLHttpRequest;a={event:"feedback clicked",properties:{errorCode: 1010 },helpful:a,version: 1 };b.open("POST","https://sparrow.cloudflare.com/api/v1/event");b.setRequestHeader("Content-Type","application/json");b.setRequestHeader("Sparrow-Source-Key","c771f0e4b54944bebf4261d44bd79a1e"); b.send(JSON.stringify(a));c.classList.add("feedback-hidden");d.classList.remove("feedback-hidden")};document.addEventListener("DOMContentLoaded",function(){var a=document.getElementById("error-feedback"),c=document.getElementById("feedback-button-yes"),d=document.getElementById("feedback-button-no");"classList"in a&&(a.classList.remove("feedback-hidden"),c.addEventListener("click",function(){e(!0)}),d.addEventListener("click",function(){e(!1)}))})}})(); </script> <script defer src="https://performance.radar.cloudflare.com/beacon.js" ></script> </head> <body> <div id="cf-wrapper"> <div class="cf-alert cf-alert-error cf-cookie-error hidden" id="cookie-alert" data-translate="enable_cookies" > Please enable cookies. </div> <div id="cf-error-details" class="p-0"> <header class="mx-auto pt-10 lg:pt-6 lg:px-8 w-240 lg:w-full mb-15 antialiased" > <h1 class="inline-block md:block mr-2 md:mb-2 font-light text-60 md:text-3xl text-black-dark leading-tight" > <span data-translate="error">Error</span> <span>1010</span> </h1> <span class="inline-block md:block heading-ray-id font-mono text-15 lg:text-sm lg:leading-relaxed" >Ray ID: 9f1c74bde9f76c24 •</span > <span class="inline-block md:block heading-ray-id font-mono text-15 lg:text-sm lg:leading-relaxed" >2026-04-25 09:52:38 UTC</span > <h2 class="text-gray-600 leading-1.3 text-3xl lg:text-2xl font-light" > Access denied </h2> </header>
<section class="w-240 lg:w-full mx-auto mb-8 lg:px-8">
<div id="what-happened-section" class="w-1/2 md:w-full">
<h2
class="text-3xl leading-tight font-normal mb-4 text-black-dark antialiased"
data-translate="what_happened"
>
What happened?
</h2>
<p>The owner of this website (opencode.ai) has banned your access based on your browser's signature (9f1c74bde9f76c24-ua63).</p>
<p>
Please see
<a
rel="noopener noreferrer"
href="https://developers.cloudflare.com/support/troubleshooting/http-status-codes/cloudflare-1xxx-errors/error-1010/"
target="_blank"
>https://developers.cloudflare.com/support/troubleshooting/http-status-codes/cloudflare-1xxx-errors/error-1010/</a
>
for more details.
</p>
</div>
</section>
<div class="feedback-hidden py-8 text-center" id="error-feedback">
<div id="error-feedback-survey" class="footer-line-wrapper">
Was this page helpful?
<button
class="border border-solid bg-white cf-button cursor-pointer ml-4 px-4 py-2 rounded"
id="feedback-button-yes"
type="button"
>
Yes
</button>
<button
class="border border-solid bg-white cf-button cursor-pointer ml-4 px-4 py-2 rounded"
id="feedback-button-no"
type="button"
>
No
</button>
</div>
<div class="feedback-success feedback-hidden" id="error-feedback-success">
Thank you for your feedback!
</div>
</div> <div class="cf-error-footer cf-wrapper w-240 lg:w-full py-10 sm:py-4 sm:px-8 mx-auto text-center sm:text-left border-solid border-0 border-t border-gray-300"> <p class="text-13"> <span class="cf-footer-item sm:block sm:mb-1">Cloudflare Ray ID: <strong class="font-semibold">9f1c74bde9f76c24</strong></span> <span class="cf-footer-separator sm:hidden">•</span> <span id="cf-footer-item-ip" class="cf-footer-item hidden sm:block sm:mb-1"> Your IP: <button type="button" id="cf-footer-ip-reveal" class="cf-footer-ip-reveal-btn">Click to reveal</button> <span class="hidden" id="cf-footer-ip">157.254.20.35</span> <span class="cf-footer-separator sm:hidden">•</span> </span> <span class="cf-footer-item sm:block sm:mb-1"><span>Performance & security by</span> <a rel="noopener noreferrer" href="https://www.cloudflare.com/5xx-error-landing" id="brand_link" target="_blank">Cloudflare</a></span>
</p>
<script>(function(){function d(){var b=a.getElementById("cf-footer-item-ip"),c=a.getElementById("cf-footer-ip-reveal");b&&"classList"in b&&(b.classList.remove("hidden"),c.addEventListener("click",function(){c.classList.add("hidden");a.getElementById("cf-footer-ip").classList.remove("hidden")}))}var a=document;document.addEventListener&&a.addEventListener("DOMContentLoaded",d)})();</script>
</div><!-- /.error-footer --> </div> <!-- /#cf-error-details --> </div> <!-- /#cf-wrapper -->
<script>
window._cf_translation = {};
</script>
</body>
</html> URL: https://opencode.ai/zen/go/v1/messages: Error: Anthropic API error: [403] Forbidden <!doctype html> <!--[if lt IE 7]> <html class="no-js ie6 oldie" lang="en-US"> <![endif]--> <!--[if IE 7]> <html class="no-js ie7 oldie" lang="en-US"> <![endif]--> <!--[if IE 8]> <html class="no-js ie8 oldie" lang="en-US"> <![endif]--> <!--[if gt IE 8]><!--> <html class="no-js" lang="en-US"> <!--<![endif]--> <head> <title>Access denied | opencode.ai used Cloudflare to restrict access | opencode.ai | Cloudflare</title> <meta charset="UTF-8" /> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <meta http-equiv="X-UA-Compatible" content="IE=Edge" /> <meta name="robots" content="noindex, nofollow" /> <meta name="viewport" content="width=device-width,initial-scale=1" /> <link rel="stylesheet" id="cf_styles-css" href="/cdn-cgi/styles/main.css" /> <script> (function(){if(document.addEventListener&&window.XMLHttpRequest&&JSON&&JSON.stringify){var e=function(a){var c=document.getElementById("error-feedback-survey"),d=document.getElementById("error-feedback-success"),b=new XMLHttpRequest;a={event:"feedback clicked",properties:{errorCode: 1010 },helpful:a,version: 1 };b.open("POST","https://sparrow.cloudflare.com/api/v1/event");b.setRequestHeader("Content-Type","application/json");b.setRequestHeader("Sparrow-Source-Key","c771f0e4b54944bebf4261d44bd79a1e"); b.send(JSON.stringify(a));c.classList.add("feedback-hidden");d.classList.remove("feedback-hidden")};document.addEventListener("DOMContentLoaded",function(){var a=document.getElementById("error-feedback"),c=document.getElementById("feedback-button-yes"),d=document.getElementById("feedback-button-no");"classList"in a&&(a.classList.remove("feedback-hidden"),c.addEventListener("click",function(){e(!0)}),d.addEventListener("click",function(){e(!1)}))})}})(); </script> <script defer src="https://performance.radar.cloudflare.com/beacon.js" ></script> </head> <body> <div id="cf-wrapper"> <div class="cf-alert cf-alert-error cf-cookie-error hidden" id="cookie-alert" data-translate="enable_cookies" > Please enable cookies. </div> <div id="cf-error-details" class="p-0"> <header class="mx-auto pt-10 lg:pt-6 lg:px-8 w-240 lg:w-full mb-15 antialiased" > <h1 class="inline-block md:block mr-2 md:mb-2 font-light text-60 md:text-3xl text-black-dark leading-tight" > <span data-translate="error">Error</span> <span>1010</span> </h1> <span class="inline-block md:block heading-ray-id font-mono text-15 lg:text-sm lg:leading-relaxed" >Ray ID: 9f1c74bde9f76c24 •</span > <span class="inline-block md:block heading-ray-id font-mono text-15 lg:text-sm lg:leading-relaxed" >2026-04-25 09:52:38 UTC</span > <h2 class="text-gray-600 leading-1.3 text-3xl lg:text-2xl font-light" > Access denied </h2> </header>
<section class="w-240 lg:w-full mx-auto mb-8 lg:px-8">
<div id="what-happened-section" class="w-1/2 md:w-full">
<h2
class="text-3xl leading-tight font-normal mb-4 text-black-dark antialiased"
data-translate="what_happened"
>
What happened?
</h2>
<p>The owner of this website (opencode.ai) has banned your access based on your browser's signature (9f1c74bde9f76c24-ua63).</p>
<p>
Please see
<a
rel="noopener noreferrer"
href="https://developers.cloudflare.com/support/troubleshooting/http-status-codes/cloudflare-1xxx-errors/error-1010/"
target="_blank"
>https://developers.cloudflare.com/support/troubleshooting/http-status-codes/cloudflare-1xxx-errors/error-1010/</a
>
for more details.
</p>
</div>
</section>
<div class="feedback-hidden py-8 text-center" id="error-feedback">
<div id="error-feedback-survey" class="footer-line-wrapper">
Was this page helpful?
<button
class="border border-solid bg-white cf-button cursor-pointer ml-4 px-4 py-2 rounded"
id="feedback-button-yes"
type="button"
>
Yes
</button>
<button
class="border border-solid bg-white cf-button cursor-pointer ml-4 px-4 py-2 rounded"
id="feedback-button-no"
type="button"
>
No
</button>
</div>
<div class="feedback-success feedback-hidden" id="error-feedback-success">
Thank you for your feedback!
</div>
</div> <div class="cf-error-footer cf-wrapper w-240 lg:w-full py-10 sm:py-4 sm:px-8 mx-auto text-center sm:text-left border-solid border-0 border-t border-gray-300"> <p class="text-13"> <span class="cf-footer-item sm:block sm:mb-1">Cloudflare Ray ID: <strong class="font-semibold">9f1c74bde9f76c24</strong></span> <span class="cf-footer-separator sm:hidden">•</span> <span id="cf-footer-item-ip" class="cf-footer-item hidden sm:block sm:mb-1"> Your IP: <button type="button" id="cf-footer-ip-reveal" class="cf-footer-ip-reveal-btn">Click to reveal</button> <span class="hidden" id="cf-footer-ip">157.254.20.35</span> <span class="cf-footer-separator sm:hidden">•</span> </span> <span class="cf-footer-item sm:block sm:mb-1"><span>Performance & security by</span> <a rel="noopener noreferrer" href="https://www.cloudflare.com/5xx-error-landing" id="brand_link" target="_blank">Cloudflare</a></span>
</p>
<script>(function(){function d(){var b=a.getElementById("cf-footer-item-ip"),c=a.getElementById("cf-footer-ip-reveal");b&&"classList"in b&&(b.classList.remove("hidden"),c.addEventListener("click",function(){c.classList.add("hidden");a.getElementById("cf-footer-ip").classList.remove("hidden")}))}var a=document;document.addEventListener&&a.addEventListener("DOMContentLoaded",d)})();</script>
</div><!-- /.error-footer --> </div> <!-- /#cf-error-details --> </div> <!-- /#cf-wrapper -->
<script>
window._cf_translation = {};
</script>
</body>
</html> URL: https://opencode.ai/zen/go/v1/messages at c:\Users\LEGION\.vscode\extensions\johnny-zhao.oai-compatible-copilot-0.3.6\out\provider.js:252:31 at process.processTicksAndRejections (node:internal/process/task_queues:103:5) at async executeWithRetry (c:\Users\LEGION\.vscode\extensions\johnny-zhao.oai-compatible-copilot-0.3.6\out\utils.js:302:20) at async HuggingFaceChatModelProvider.provideLanguageModelChatResponse (c:\Users\LEGION\.vscode\extensions\johnny-zhao.oai-compatible-copilot-0.3.6\out\provider.js:243:34)
Reacted by Marcos Nunes
Metadata
Metadata
Assignees
Labels
No labels
Activity
marcosnunesmbs commentedon Apr 28, 2026
Same issue here. I am using the Alibaba Coding Plan API on OAI very well, but the error happen on Opencode GO. I can also use OpenCode Go via the API in QWEN Code without any problems; it's very good, by the way.
pedrazadixon commentedon May 4, 2026
same problem here
Athameral commentedon Jun 20, 2026
See these lines.
OAI-Compatibleextension uses a customUser-Agentheader, which may not be recognized by cloudflare. A temporarily workaround is changinguain theCustom Headergui config like the following:{ "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36" }That would work (at least for me). Or seriously, why not just use native
Custom Endpointfeature in VSCode now? That just works out of the box XDrekram1-node commentedon Jun 23, 2026
Automated: closing question issues.
GitHub Issues are for bug reports and feature requests only — questions / support are no longer tracked here.
If this is a bug or feature request, please open a new issue with the appropriate template.