AdobeDocs/photoshop-api-docs

Getting URL of rendition to download?

Closed this issue · 4 comments

Expected Behaviour

Actual Behaviour

Reproduce Scenario (including but not limited to)

I would like to download a rendition created with the API, but it isn't clear how I would do that.
I would like to download a rendition of a layer with the API but it isn't clear how to do that either.

Steps to Reproduce

Platform and Version

Sample Code that illustrates the problem

Logs taken while reproducing problem

@mscherotter For downloading a rendition, I assume you have invoked the renditionCreate API (https://github.com/AdobeDocs/photoshop-api-docs#renditioncreate-generating-new-renditions). You will poll for the status of the asynchronous job. When it is completed, the rendition or renditions will be at the href value in the "renditions" array of "outputs" (https://github.com/AdobeDocs/photoshop-api-docs#example-2-poll-for-status-and-results-2).

If you are using "adobe" storage, the href will contain the path to the rendition, e.g., "files/my-rendition.jpeg", which you would be able to see at https://assets.adobe.com/files in your browser.

If you are using "external" storage, the href will contain the url you provided in the renditionCreate API request.

To obtain the renditions of each layer, you would use the documentManifest API. You would provide the "options" object to request thumbnails and to specify the image type. For example
{ "inputs": [ { "storage": "adobe", "href": "files/Sunflower.psd" } ], "options": { "thumbnails": { "type": "image/jpeg" } } }

In the job status you will receive a url to the rendition for each layer in the "thumbnail" value.

@mscherotter Wanted to follow up on the thread and see if you've had any success. Also wanted to clarify Nabeel's last response. Using the documentManifest api you can request small thumbnail size previews of all the renderable layers. We have an upcoming feature on our backlog to implement creating a rendition of a one or more individual layers with various allowable options (type, size, etc).

Closing issue as resolved