Can't interact with DE via REST API

Can't interact with DE via REST API

Hello guys!
Would you be so kind as to help me with my problem?
I try to interact with Device Expert via API from python script. I sent a POST request to URL like this <Protocol- http or https >://<DeviceExpert-Server-Name>:port/api with following parameters: ACTION = "GET_DEVICE", API_KEY='xxx', IPADDRESS='X.X.X.X', but I have received an empty string. 
  1. import urllib, urllib2
  2. url = 'https://x.x.x.x/api'
  3. req = urllib2.Request(url)
  4. values =  {'API_KEY':'xxxxxxxxxxx', 'IPADDRESS':'x.x.x.x', 'ACTION':'GET_DEVICE'}
  5. data = urllib.urlencode(values)
  6. req.add_data(data)
  7. resp = urllib2.urlopen(req)
  8. resp.read() #empty string ''
I tried the same on php, but received an empty string again. Thanks in advance!

George.

                  New to ADSelfService Plus?