No PNG renditions/thumbnails for PSD, AI, PDF files

The Creative Cloud Libraries doesn’t return any PNG renditions or thumbnails of uploaded PSD, AI or PDF files.

Based on Adobe’s specification for renditions and representations, these file types should have a static png rendition.

https://developer.adobe.com/creative-cloud-libraries/docs/integrate/guides/working-with-elements/accessing-file-formats/

Here is an example of the renditions of an Illustrator file.

{
    "id": "34af5ff6-1e1f-453d-94e9-4dbab71c7ba4",
    "type": "application/illustrator",
    "relationship": "primary",
    "path": "34af5ff6-1e1f-453d-94e9-4dbab71c7ba4.ai",
    "is_full_size": false,
    "is_external_link": false,
    "content_length": 228785,
    "storage_href": "https://cc-api-storage.adobe.io/id/urn:aaid:sc:EU:c18243fb-e0f8-46bd-a910-912ac271d30a?component_id=34af5ff6-1e1f-453d-94e9-4dbab71c7ba4",
    "name": "Illustrator-Test-Adobe-CC-Hootsuite_75807eb6-2dc9-43be-b96f-865ab1275cd2.ai",
    "version": "0",
    "md5": "p0ZyHdS+MBc5deUV+C2DMQ==",
    "_links": {
        "http://ns.adobe.com/melville/rel/primary": {
            "href": "https://cc-api-storage.adobe.io/id/urn:aaid:sc:EU:c18243fb-e0f8-46bd-a910-912ac271d30a?component_id=34af5ff6-1e1f-453d-94e9-4dbab71c7ba4",
            "rel": "http://ns.adobe.com/melville/rel/primary",
            "type": "application/illustrator",
            "templated": false
        },
        "http://ns.adobe.com/melville/rel/rendition": {
            "href": "https://cc-api-storage.adobe.io/id/urn:aaid:sc:EU:c18243fb-e0f8-46bd-a910-912ac271d30a/:rendition?component_id=34af5ff6-1e1f-453d-94e9-4dbab71c7ba4&size={size}",
            "rel": "http://ns.adobe.com/melville/rel/rendition",
            "type": "application/illustrator",
            "templated": true
        }
    },
    "etag": "\"a746721dd4be30173975e515f82d8331\"",
    "is_preferred_thumbnail": false,
    "is_component": true,
    "state": "unmodified",
    "library#sha256": "20f23a2709a7a37f6ac744934092824d21491320835c36152c2d81a99efcdf4b"
}

For example, if you request the Thumbnail (Size: 200) rendition with size 400 from an AI file, you will get a PDF with the same file size! => Adjusting the size via templating (for CC files) does not work.

Thumbnail URL:
https://cc-api-storage.adobe.io/id/urn:aaid:sc:EU:c18243fb-e0f8-46bd-a910-912ac271d30a/:rendition?component_id=34af5ff6-1e1f-453d-94e9-4dbab71c7ba4&size=200

Template URL:
https://cc-api-storage.adobe.io/id/urn:aaid:sc:EU:c18243fb-e0f8-46bd-a910-912ac271d30a/:rendition?component_id=34af5ff6-1e1f-453d-94e9-4dbab71c7ba4&size={ size}

Difference between Thumbnail and Template URL, the Thumbnail URL already has a size of 200 defined.

We use the selector “representations” to load the data from a library to display a list of assets.

Here is an example URL: https://cc-libraries.adobe.io/api/v1/libraries/urn%3Aaaid%3Asc%3AEU%3Ac18243fb-e0f8-46bd-a910-912ac271d30a/elements?start=0&limit=20&selector=representations

Currently, this does not allow us to display thumbnails of CC files, for example, use the PNG representation to display.

This issue appeared after the changes in mid December and is still unsolved.

Hi, thanks for your question.

I am not able to reproduce the issue you’re seeing. Using that template (but with an AI file in a library in my account), I can populate the {size} attribute with either ‘200’ or ‘400’ and I get back a suitably sized (size in pixels & bytes) PNG in response.

If you’d like to share the library with me so I can maybe reproduce your specific issue, please feel free to share with roche@adobe.com. I’ll be glad to help.

Thanks again.

@roche I’ve send Ingo and you a detailed email with all the information including urls and the responses.

Thank you for sharing the library. With the permissions granted to me via the invitation/acceptance, I was able to inspect the library contents.

I’m assuming you’re using the elements API with the selector=representations argument you cite:

/api/v1/libraries/urn:aaid:sc:EU:ea67597d-e917-42b8-816f-26853c592526/elements/1b9ab5bf-22f2-42d5-b0fd-adedf124b17f?selector=representations

In this response, as you mention, there are links provided for the pre-formatted thumbnail and the template for the rendition. Here is the rendition template link I am receiving from the API:

https://cc-api-storage.adobe.io/id/urn%3Aaaid%3Asc%3AEU%3Aea67597d-e917-42b8-816f-26853c592526/:rendition?component_id=10505182-ef08-41ec-b31a-75880f3532e8{&size}

The syntax of the {&size} template parameter is defined in the IETF standard for URI templating, see RFC 6570 - URI Template for details. It is the client’s responsibility to provide the value by populating the template per the standard.

Below, for context, is the complete response I’m receiving for /api/v1/libraries/urn:aaid:sc:EU:ea67597d-e917-42b8-816f-26853c592526/elements/1b9ab5bf-22f2-42d5-b0fd-adedf124b17f?selector=representations

{
    "id": "1b9ab5bf-22f2-42d5-b0fd-adedf124b17f",
    "name": "Illustrator-Test-Adobe-CC-Hootsuite",
    "storage_used": 228785,
    "created_date": 1618481446923,
    "modified_date": 1618503743784,
    "type": "application/vnd.adobe.element.image+dcx",
    "thumbnail": {
        "type": "href",
        "rendition": "https://cc-api-storage.adobe.io/id/urn%3Aaaid%3Asc%3AEU%3Aea67597d-e917-42b8-816f-26853c592526/:rendition?component_id=10505182-ef08-41ec-b31a-75880f3532e8&size=200"
    },
    "representations": [
        {
            "id": "10505182-ef08-41ec-b31a-75880f3532e8",
            "type": "application/illustrator",
            "relationship": "primary",
            "path": "34af5ff6-1e1f-453d-94e9-4dbab71c7ba4.ai",
            "is_full_size": false,
            "is_external_link": false,
            "content_length": 228785,
            "storage_href": "https://cc-api-storage.adobe.io/id/urn%3Aaaid%3Asc%3AEU%3Aea67597d-e917-42b8-816f-26853c592526?component_id=10505182-ef08-41ec-b31a-75880f3532e8",
            "name": "Illustrator-Test-Adobe-CC-Hootsuite_75807eb6-2dc9-43be-b96f-865ab1275cd2.ai",
            "version": "0",
            "md5": "p0ZyHdS+MBc5deUV+C2DMQ==",
            "_links": {
                "http://ns.adobe.com/melville/rel/primary": {
                    "href": "https://cc-api-storage.adobe.io/id/urn%3Aaaid%3Asc%3AEU%3Aea67597d-e917-42b8-816f-26853c592526?component_id=10505182-ef08-41ec-b31a-75880f3532e8",
                    "rel": "http://ns.adobe.com/melville/rel/primary",
                    "type": "application/illustrator",
                    "templated": false
                },
                "http://ns.adobe.com/melville/rel/rendition": {
                    "href": "https://cc-api-storage.adobe.io/id/urn%3Aaaid%3Asc%3AEU%3Aea67597d-e917-42b8-816f-26853c592526/:rendition?component_id=10505182-ef08-41ec-b31a-75880f3532e8{&size}",
                    "rel": "http://ns.adobe.com/melville/rel/rendition",
                    "type": "application/illustrator",
                    "templated": true
                }
            },
            "etag": "\"a746721dd4be30173975e515f82d8331\"",
            "is_preferred_thumbnail": false,
            "is_component": true,
            "state": "unmodified",
            "library#sha256": "20f23a2709a7a37f6ac744934092824d21491320835c36152c2d81a99efcdf4b"
        }
    ],
    "assetSubType": "element",
    "_fc": false,
    "parent_id": "urn:aaid:sc:EU:ea67597d-e917-42b8-816f-26853c592526",
    "manifest_etag": "\"9af191648b01990ccc2941d9275afec9\"",
    "storage:assignee": {
        "id": "7BE705334649CBBD992015A9@AdobeID",
        "type": "user"
    },
    "is_archived": false,
    "_links": {
        "http://ns.adobe.com/melville/rel/primary": {
            "href": "/api/v1/libraries/urn:aaid:sc:EU:ea67597d-e917-42b8-816f-26853c592526/elements/1b9ab5bf-22f2-42d5-b0fd-adedf124b17f",
            "rel": "http://ns.adobe.com/melville/rel/primary",
            "type": "application/json",
            "templated": false
        },
        "http://ns.adobe.com/melville/rel/path": {
            "href": "/api/v1/libraries/urn:aaid:sc:EU:ea67597d-e917-42b8-816f-26853c592526/elements/1b9ab5bf-22f2-42d5-b0fd-adedf124b17f",
            "rel": "http://ns.adobe.com/melville/rel/path",
            "type": "application/json",
            "templated": false
        },
        "http://ns.adobe.com/melville/rel/id": {
            "href": "/api/v1/libraries/urn:aaid:sc:EU:ea67597d-e917-42b8-816f-26853c592526/elements/1b9ab5bf-22f2-42d5-b0fd-adedf124b17f",
            "rel": "http://ns.adobe.com/melville/rel/id",
            "type": "application/json",
            "templated": false
        },
        "http://ns.adobe.com/melville/rel/describedBy": {
            "href": "/api/v1/libraries/urn:aaid:sc:EU:ea67597d-e917-42b8-816f-26853c592526/elements/1b9ab5bf-22f2-42d5-b0fd-adedf124b17f",
            "rel": "http://ns.adobe.com/melville/rel/describedBy",
            "type": "application/json",
            "templated": false
        },
        "http://ns.adobe.com/melville/rel/rendition": {
            "href": "https://cc-api-storage.adobe.io/id/urn%3Aaaid%3Asc%3AEU%3Aea67597d-e917-42b8-816f-26853c592526/:rendition?component_id=10505182-ef08-41ec-b31a-75880f3532e8&size=200",
            "rel": "http://ns.adobe.com/melville/rel/rendition",
            "templated": false
        },
        "http://ns.adobe.com/melville/rel/representations": {
            "href": "/api/v1/libraries/urn:aaid:sc:EU:ea67597d-e917-42b8-816f-26853c592526/elements/1b9ab5bf-22f2-42d5-b0fd-adedf124b17f?selector=representations",
            "rel": "http://ns.adobe.com/melville/rel/representations",
            "type": "application/json",
            "templated": false
        },
        "http://ns.adobe.com/melville/rel/archive": {
            "href": "/api/v1/libraries/urn:aaid:sc:EU:ea67597d-e917-42b8-816f-26853c592526/elements/1b9ab5bf-22f2-42d5-b0fd-adedf124b17f",
            "rel": "http://ns.adobe.com/melville/rel/archive",
            "type": "application/json",
            "templated": false
        }
    }
}

Hi @roche,

Please check the response body and the header content-type for the thumbnail and rendition. From my understanding this should be a PNG file and not an Illustrator file (application/illustrator).

In the email which I send you, you have all the response bodies and screenshots for response headers.

It is great that Adobe has adapted a standard for template parameter now.

However the implementation of template parameter has change twice in the last 4 months.

Before December 2021: {;size}
In December 2021: {size}
In March 2022: {&size}

If we have to adapt the replacement logic in your app to adapt to the changes, then the change is breaking change from Adobe. => Therefore Adobe has to release a new version of the API. This is best practise.

{;size} => ;size=200
{size} => 200
{&size} => &size=200

Where have you specified the usage of the IETF standard for the template in the documentation?

In the documentation of the API, you still reference the old format “;size=200” before December 2021 and not mentioning any used standard.
https://developer.adobe.com/creative-cloud-libraries/docs/integrate/guides/working-with-elements/accessing-file-formats/#operation/getPublicLibraryElement

How should someone known how you have implemented it if you don’t document how it works. You have to look into the response and test it.

Nobody can guess what Adobe has intended. It is try and error.

@roche Don’t get me wrong!

If Adobe would documented that any variant of the IETF standard could be used in the template than a developer could have looked into the standard and implemented the logic for replacement accordingly.

From your perspective the changes aren’t breaking as you think that you used only a different variant of the IETF standard.

However with the limited information and this single samples provided by Adobe, nobody can guess that this based on the IETF standard. Based on what Adobe has documented it is a breaking change.

Hi @roche,

Any updates on the missing PNG renditions?

Thanks
Patrick

@patrickheinzelmann We are working on a fix. The links you cite will all resolve to PNG or JPG files, depending on the original asset mimetype, and are simply mislabeled. Our fix will remove the labeling when we cannot guarantee a specific mimetype for the linked asset. This applies exclusively when linking to images. Handling for color, color theme, and other “inline” rendition output will be clearly identified.

Hi @patrickheinzelmann @roche,

The fix for this has been deployed to our staging environment, and we are targeting a prod release sometime next week.

Thanks,
Paul

Hi @PaulF,

Thanks for the update.

Patrick