Hi Team,
I’m running a Pythod REST API example and it is returning me a corrupt and empty output file.
from aspose.cloud.common import * 
import json 
import os.path 
try: 
# sepcify App SID 
AsposeApp.app_sid=’***********’ 
AsposeApp.app_key=’ ***********’ 
#build URI 
str_uri = ‘http://api.aspose.com/v1.1/slides/Test_HK.pptx/slides?Position=4’ 
#sign URI 
signed_uri = Utils.sign(Utils(), str_uri) Utils.process_command(Utils(), signed_uri, ‘POST’, ‘’, ‘’) 
#build URI to download output file 
str_uri = ‘http://api.aspose.com/v1.1/storage/Test_HK.pptx’ 
#sign URI 
signed_uri = Utils.sign(Utils(), str_uri) 
response_stream = Utils.process_command(Utils(),signed_uri, ‘GET’)
Utils.save_file(Utils(),response_stream, ‘Presentation4.pptx’) 
print ‘Done’ 
except Exception, 
ex: 
print type(ex) 
# the exception instance 
print ex.args 
# arguments stored 
in .args 
finally: 
raw_input(“Press any Key”)
There is no error as the code runs but the power point is not what I am expecting. maybe I am using the wrong referencing for the storage?
This message was posted using Email2Forum by Imran Rafique