Dynamic Media Scene7 URL fields aren’t available in GraphQL responses in Experience Manager 6.5 LTS

In Adobe Experience Manager 6.5 LTS, the GraphQL ImageRef type doesn’t expose Dynamic Media Scene7 delivery URL fields such as _dynamicUrl or _dmS7Url. As a result, headless consumers receive the standard image reference fields but not a ready-to-use Scene7 URL. To fix this, read the Dynamic Media metadata, construct the Scene7 URL after the asset reaches PublishComplete, and expose the URL through your application layer or a custom Content Fragment field.

Description description

Environment

  • Adobe Experience Manager (AEM) 6.5 LTS (all versions and Service Packs)
  • Content Fragments delivered via the AEM GraphQL API
  • Dynamic Media (Scene7 mode) enabled for assets

Issue/Symptoms

When you query Content Fragments through the AEM GraphQL API, the ImageRef type exposes standard image reference fields but doesn’t expose a Dynamic Media Scene7 delivery URL.

  • The ImageRef type exposes fields such as _path, _authorUrl, _publishUrl, mimeType, width, and height.
  • The ImageRef type doesn’t expose _dynamicUrl or _dmS7Url.
  • Dynamic Media URL fields documented for AEM as a Cloud Service aren’t available in the AEM 6.5 LTS GraphQL schema described in this article.
  • Headless consumers don’t receive an optimized Scene7 image URL directly in the GraphQL response.
  • Assets must be published to Dynamic Media before you construct and use a delivery URL.

Cause

The AEM 6.5 LTS GraphQL schema doesn’t expose Dynamic Media Scene7 delivery URL fields on the ImageRef type. The required URL must therefore be constructed from the Dynamic Media metadata and exposed through custom application logic or a custom Content Fragment field.

Resolution resolution

To expose Dynamic Media Scene7 URLs to headless consumers, follow these steps:

  1. Confirm the GraphQL schema limitation by checking the ImageRef type in the AEM GraphQL schema. Don’t query _dynamicUrl or _dmS7Url as native fields in the AEM 6.5 LTS schema.

  2. Publish the assets to Dynamic Media Scene7 and verify that dam:scene7Domain, dam:scene7File, and dam:scene7FileStatus are populated.

  3. Confirm that dam:scene7FileStatus is PublishComplete before constructing or using the delivery URL.

  4. Construct the Scene7 delivery URL from the metadata.

    • For image assets, combine dam:scene7Domain, is/image/, and dam:scene7File.
    • For static assets such as PDF or video files, combine dam:scene7Domain, is/content/, and dam:scene7File.
    code language-none
    if (dam:scene7FileStatus == 'PublishComplete') {
      if (assetType == 'image') {
        url = dam:scene7Domain + 'is/image/' + dam:scene7File;
      } else {
        url = dam:scene7Domain + 'is/content/' + dam:scene7File;
      }
    }
    
  5. Expose the constructed URL to headless consumers through a backend or middleware service, a custom API, or an application-layer field. If your architecture supports frontend construction, provide the metadata fields to the frontend and construct the URL there.

  6. Optionally add a string field such as dmScene7Urlto the Content Fragment Model and populate it with a workflow or event listener.

    • Note: This is a custom implementation and isn’t a native Dynamic Media URL field in the AEM 6.5 LTS GraphQL ImageRef type.
  7. Query the Content Fragment through GraphQL and verify that the required metadata fields or the constructed URL are present and correct.

recommendation-more-help
experience-cloud-kcs-help-kbarticles