Hi Ugur,
I think this code helps for you.
Function GetIP()
fResult = "";
ResponseFile = GetTempFileName("json");
Try
HTTP = New HTTPConnection("api.ipify.org",,,,,,New OpenSSLSecureConnection());
HTTP.Get("/?format=json", ResponseFile);
Except
pError = BriefErrorDescription(ErrorInfo());
fResult = pError;
Return fResult;
EndTry;
JSONReader = New JSONReader;
JSONReader.OpenFile(ResponseFile);
Data = ReadJSON(JSONReader);
JSONReader.Close();
fResult = Data.ip;
BeginDeletingFiles(, ResponseFile);
Return fResult;
EndFunction