Skip to content

Latest commit

 

History

History
140 lines (95 loc) · 3.89 KB

remote-image.md

File metadata and controls

140 lines (95 loc) · 3.89 KB

Remote Image

remote_image_controller = client.remote_image

Class Name

RemoteImageController

Methods

Download Remote Image

Downloads a remote image for an item.

def download_remote_image(self,
                         item_id,
                         mtype,
                         image_url=None)

Parameters

Parameter Type Tags Description
item_id uuid|string Template, Required Item Id.
mtype ImageTypeEnum Query, Required The image type.
image_url string Query, Optional The image url.

Response Type

void

Example Usage

item_id = '0000130e-0000-0000-0000-000000000000'
mtype = ImageTypeEnum.THUMB

result = remote_image_controller.download_remote_image(item_id, mtype)

Errors

HTTP Status Code Error Description Exception Class
401 Unauthorized APIException
403 Forbidden APIException
404 Remote image not found. ProblemDetailsException

Get Remote Image Providers

Gets available remote image providers for an item.

def get_remote_image_providers(self,
                              item_id)

Parameters

Parameter Type Tags Description
item_id uuid|string Template, Required Item Id.

Response Type

List of ImageProviderInfo

Example Usage

item_id = '0000130e-0000-0000-0000-000000000000'

result = remote_image_controller.get_remote_image_providers(item_id)

Errors

HTTP Status Code Error Description Exception Class
401 Unauthorized APIException
403 Forbidden APIException
404 Item not found. ProblemDetailsException

Get Remote Images

Gets available remote images for an item.

def get_remote_images(self,
                     item_id,
                     mtype=None,
                     start_index=None,
                     limit=None,
                     provider_name=None,
                     include_all_languages=False)

Parameters

Parameter Type Tags Description
item_id uuid|string Template, Required Item Id.
mtype ImageTypeEnum Query, Optional The image type.
start_index int Query, Optional Optional. The record index to start at. All items with a lower index will be dropped from the results.
limit int Query, Optional Optional. The maximum number of records to return.
provider_name string Query, Optional Optional. The image provider to use.
include_all_languages bool Query, Optional Optional. Include all languages.
Default: False

Response Type

RemoteImageResult

Example Usage

item_id = '0000130e-0000-0000-0000-000000000000'
include_all_languages = False

result = remote_image_controller.get_remote_images(item_id, None, None, None, None, include_all_languages)

Errors

HTTP Status Code Error Description Exception Class
401 Unauthorized APIException
403 Forbidden APIException
404 Item not found. ProblemDetailsException