Skip to main content
1-Visitor
May 21, 2019
Solved

Unable get data from third party web service

  • May 21, 2019
  • 1 reply
  • 1236 views

Hi,

    I'm trying to get data from weather web API.

var params = {
//proxyScheme: undefined /* STRING */,
//headers: undefined /* JSON */,
ignoreSSLErrors: true/* BOOLEAN */,
//useNTLM: undefined /* BOOLEAN */,
//workstation: undefined /* STRING */,
//useProxy: undefined /* BOOLEAN */,
//withCookies: undefined /* BOOLEAN */,
//proxyHost: undefined /* STRING */,
url: "https://api.openweathermap.org/data/2.5/weather?lat=16.4974&lon=80.6458&appid=appid", /* STRING */
//timeout: undefined /* NUMBER */,
//proxyPort: undefined /* INTEGER */,
password: "password" /* STRING */,
//domain: undefined /* STRING */,
username: "username" /* STRING */
};

// result: JSON
var myJson = Resources["ContentLoaderFunctions"].GetJSON(params);
result = myJson;
//me.Outside_Temperature= myJson.main.temp-273.15;
//me.Outside_Humidity = myJson.main.humidity;

It is giving output as below

[message: Execution error in service script [OutSideTemp] :: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target]

 

Best answer by Surekha

Hi @effpt3 ,

    Please Make sure of internet connectivity.

Regards,

Surekha N.

1 reply

Surekha1-VisitorAnswer
1-Visitor
May 21, 2019

Hi @effpt3 ,

    Please Make sure of internet connectivity.

Regards,

Surekha N.