Comments (2)
public class Main { public static void main(String[] args) { OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder() .url("https://api.pawan.krd/chat/gpt?text=hello") .build(); try { Response response = client.newCall(request).execute(); String responseBody = response.body().string(); System.out.println(responseBody); } catch (Exception e) { e.printStackTrace(); } } }
Responce:
<html> <head><title>502 Bad Gateway</title><script src="/cdn-cgi/apps/head/dYMkwc06fJ_hgAqAMinzib-CLyo.js"></script></head> <body> <center><h1>502 Bad Gateway</h1></center> <hr><center>openresty</center> <script>(function(){var js = "window['__CF$cv$params']={r:'79b820001f4836dd',m:'I9LtAGxe2vQftngWibqkAOSaJkWdl9.GKH.HkDRaync-1676737592-0-ARvKa/MkfLXgDd/u5qccaUo9pLoTb0rH1ejUHlAI3Ftc+5kjDtQzjyyBLx1sBMXDhBueFWEQ+13PXuhNCclRQg01q/7sZ/IHMMAmq28u17Opb+5RNWt59VZo7qva9x3iQWjxbG+nni9Oc4oWIeuYCs0=',s:[0x790cdb083e,0x124aa35753],u:'/cdn-cgi/challenge-platform/h/g'};var now=Date.now()/1000,offset=14400,ts=''+(Math.floor(now)-Math.floor(now%offset)),_cpo=document.createElement('script');_cpo.nonce='',_cpo.src='/cdn-cgi/challenge-platform/h/g/scripts/alpha/invisible.js?ts='+ts,document.getElementsByTagName('head')[0].appendChild(_cpo);";var _0xh = document.createElement('iframe');_0xh.height = 1;_0xh.width = 1;_0xh.style.position = 'absolute';_0xh.style.top = 0;_0xh.style.left = 0;_0xh.style.border = 'none';_0xh.style.visibility = 'hidden';document.body.appendChild(_0xh);function handler() {var _0xi = _0xh.contentDocument || _0xh.contentWindow.document;if (_0xi) {var _0xj = _0xi.createElement('script');_0xj.nonce = '';_0xj.innerHTML = js;_0xi.getElementsByTagName('head')[0].appendChild(_0xj);}}if (document.readyState !== 'loading') {handler();} else if (window.addEventListener) {document.addEventListener('DOMContentLoaded', handler);} else {var prev = document.onreadystatechange || function () {};document.onreadystatechange = function (e) {prev(e);if (document.readyState !== 'loading') {document.onreadystatechange = prev;handler();}};}})();</script></body> </html>
Oh... I catched the same error when I tried C# example :(
I cannot fix this issue:
from chatgpt.
We updated the API endpoint check readme for docs
from chatgpt.
Related Issues (20)
- i get an error saying my country might not be supported despite it working two days ago HOT 9
- problem when requesting data
- problem HOT 1
- Error while getting new session HOT 4
- Question: HOT 2
- the ai sends empty respones HOT 1
- 他不能回我信息
- The requested endpoint (GET /v1/chat/completions) was not found HOT 18
- Run the API in LAN
- why return openai.InternalServerError: Error code: 503? HOT 2
- gpt 4o support HOT 1
- An error occurred. please try again. Additionally, ensure that your request complies with OpenAI's policy HOT 6
- api returns None HOT 6
- Error: messages is required! and must be an array of objects with content and role properties HOT 2
- System.Net.Http.HttpRequestException: 'Response status code does not indicate success: 401 (Unauthorized).'
- README should include note about access to hosted API being limited to Patreon supporters HOT 1
- Gives an error: type invalid_request_error HOT 12
- BetterGPT Error: ERR_EMPTY_RESPONSE
- Question: How does this work? As ChatGPT API key is not free, are you using the ChatGPT web interface at the backend? HOT 3
- docker: Error response from daemon: manifest for pawanosman/chatgpt:latestd not found: manifest unknown: manifest unknown. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from chatgpt.