Aspose.Imaging Cloud

Aspose.Imaging Cloud Aspose.Imaging Cloud’s platform independent image manipulation API is a true REST API that can be used with any language: .NET, Java, PHP, Ruby, Rails, Python, jQuery and many more. You can use it with any platform — web, desktop, mobile, and cloud.

Aspose.Imaging Cloud lets you use a REST API to inspect, convert, and transform images in the cloud. It supports the most popular image formats such as PSD, PNG, GIF, BMP, TIFF, and JPEG, and conversion between them. Aspose.Imaging Cloud also provides a rich set of features for manipulating images on-the-fly with cloud based image transformations. You can resize, crop and/or rotate images various ways by simply creating a request that includes the correct transformation instructions. The most demanding imaging routines, for example TIFF concatenation and image conversion to fax compatible format, are available through efficient and reliable specialized resources. Learn More

What’s new in the latest release

This is a major revamp release for Aspose.Imaging Cloud SDK for Python. It covers all the Aspose.Imaging Cloud APIs. This SDK provides a complete solution to work with cloud images in Python using powerful Aspose.Imaging Cloud APIs, so you can manipulate & convert images in the cloud seamlessly.

Source Code Repository

Complete source code of this release of Aspose.Imaging Cloud SDK for Python is freely available on your favorite GitHub and Codeplex repositories.

Setup

Aspose.Imaging Cloud SDK for Python is also available as released package in the PyPI (Python Package Index). You can bypass source code repository and depend directly on the released package by installing from PyPI:

PyPI Aspose.Imaging Cloud SDK for Python Installation

 pip install asposeimagingcloud
OR
easy_install asposeimagingcloud 

Data

In order to manipulate any files, you first need to upload them to the Aspose cloud storage or 3rd party cloud storage using Aspose.Storage Cloud SDK for Python.

Quick SDK Tutorial

 import asposeimagingcloud
from asposeimagingcloud.ImagingApi import ImagingApi
from asposeimagingcloud.ImagingApi import ApiException

import asposestoragecloud 
from asposestoragecloud.StorageApi import StorageApi
from asposestoragecloud.StorageApi import ResponseMessage

apiKey = "XXXXX" #sepcify App Key
appSid = "XXXXX" #sepcify App SID
apiServer = "http://api.aspose.com/v1.1"
data_folder = "../../data/"

#Instantiate Aspose Storage API SDK
storage_apiClient = asposestoragecloud.ApiClient.ApiClient(apiKey, appSid, True)
storageApi = StorageApi(storage_apiClient)
#Instantiate Aspose Imaging API SDK
api_client = asposeimagingcloud.ApiClient.ApiClient(apiKey, appSid, True)
imagingApi = ImagingApi(api_client);

#set input file name
name =  "sample.bmp"
bitsPerPixel = 24
horizontalResolution = 300
verticalResolution = 300

try:
    #upload file to aspose cloud storage
    response = storageApi.PutCreate(name, data_folder + name)
    
    #invoke Aspose.Imaging Cloud SDK API to get BMP image with specific properties
    response = imagingApi.GetImageBmp(name, bitsPerPixel, horizontalResolution, verticalResolution)
    
    if response.Status == 'OK':
        #download image from API response
        outfilename = "c:/temp/" + name 
        with open(outfilename, 'wb') as f:
                    for chunk in response.InputStream:
                        f.write(chunk)
                                                            
except ApiException as ex:
            print "ApiException:"
            print "Code:" + str(ex.code)
            print "Message:" + ex.message 

Aspose.Imaging Cloud API Documentation

Aspose.Imaging Cloud Documentation is available to guide developers to get familiar with the specific resources and operations within the Aspose.Imaging Cloud REST API.

Aspose.Imaging Cloud SDK for Python Examples

Aspose.Imaging Cloud SDK for Python Examples are also available to guide developers to get familiar with SDK and its usage to invoke resources and operations using the Aspose.Imaging Cloud REST API. Please see the SDK examples of following categories.

Start a Free Trial Today

Start a free trial today – all you need is to sign up with the Aspose Cloud service. Once you have signed up, you are ready to try the powerful file processing features offered by Aspose Cloud.