aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFilipp Lepalaan <f@230.to>2013-04-01 17:30:18 +0300
committerFilipp Lepalaan <f@230.to>2013-04-01 17:30:18 +0300
commit8a6d514696107e0944310286edab18ccd064c312 (patch)
tree2392b5cc18aad37ac6b6585d4fd89a578f054da8
parenta23e941b28325af23146734e95f969f37d1051e1 (diff)
downloadpy-gsxws-8a6d514696107e0944310286edab18ccd064c312.tar.gz
py-gsxws-8a6d514696107e0944310286edab18ccd064c312.tar.bz2
py-gsxws-8a6d514696107e0944310286edab18ccd064c312.zip
Added Content(), fetch_image()
-rwxr-xr-xgsxws.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/gsxws.py b/gsxws.py
index 64a3c47..2a1c490 100755
--- a/gsxws.py
+++ b/gsxws.py
@@ -204,6 +204,16 @@ class GsxObject(object):
return rd
+class Content(GsxObject):
+ def fetch_image(self, url):
+ '''
+ The Fetch Image API allows users to get the image file from GSX,
+ for the content articles, using the image URL.
+ The image URLs will be obtained from the image html tags in the data from all content APIs.
+ '''
+ dt = self._make_type('ns3:fetchImageRequestType')
+ dt.imageRequest = {'imageUrl': url}
+ return self.submit('FetchImage', dt, 'contentResponse')
class CompTIA(object):
'''