function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
DILIP KUMAR PASUMARTHY 6DILIP KUMAR PASUMARTHY 6 

internal server error status code:500

Hi All,
There is some problem i am facing during the call out to EUP. When i am trying to make a call out from sales force i am not getting back the response and it is throwing some error which says internal server error with status code as 500. When i made a call from external rest api tools like Postman and dft i got the response back. Below is the code i used to make the call out from developer console.

 // Instantiate a new http object
    Http h = new Http();

     // Instantiate a new HTTP request, specify the method (GET) as well as the endpoint

    HttpRequest req = new HttpRequest();
    req.setEndpoint(''http://eupgateway.yahonline.com:8500');
    req.setMethod('GET');
   req.setHeader('content-type', 'application/x-www-form-urlencoded; charset=UTF-8');

    // Send the request, and return a response
    HttpResponse res = h.send(req);
    system.debug('$$$$$$$$$$$$$ '+res.getbody());
 
Andy BoettcherAndy Boettcher
Do you have eupgateway.yahonline.com:8500 set as a Remote Site?
DILIP KUMAR PASUMARTHY 6DILIP KUMAR PASUMARTHY 6
Hi Andy,
I did that in Remote site settings.