Expand my Community achievements bar.

SOLVED

GraphQL content fragment response customize additional fields

Avatar

Level 5

By default , graph QL query for a content fragment and an ImageReference inside content fragment gives _author_url and _publish_url.

How can we either customize either the publish URL to give scene7 urls for images or add an additional field in there?

 

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hello @asn11 

 

Please have a look at following Adobe documentations:

https://experienceleague.adobe.com/docs/experience-manager-learn/getting-started-with-aem-headless/h...

https://experienceleague.adobe.com/docs/experience-manager-cloud-service/content/headless/graphql-ap... 

https://experienceleague.adobe.com/docs/experience-manager-core-components/using/developing/web-opti... 

 

GraphQL supports web-optimized URLs like:

{
  "data": {
    "adventureByPath": {
      "item": {
        "_path": "/content/dam/wknd-shared/en/adventures/bali-surf-camp/bali-surf-camp",
        "title": "Bali Surf Camp",
        "primaryImage": {
          "_dynamicUrl": "/adobe/dynamicmedia/deliver/dm-aid--a38886f7-4537-4791-aa20-3f6ef0ac3fcd/adobestock_175749320.jpg?preferwebp=true&width=1000&quality=80"
        }
      }
    }
  }
}

 

 

 


Aanchal Sikka

View solution in original post

1 Reply

Avatar

Correct answer by
Community Advisor

Hello @asn11 

 

Please have a look at following Adobe documentations:

https://experienceleague.adobe.com/docs/experience-manager-learn/getting-started-with-aem-headless/h...

https://experienceleague.adobe.com/docs/experience-manager-cloud-service/content/headless/graphql-ap... 

https://experienceleague.adobe.com/docs/experience-manager-core-components/using/developing/web-opti... 

 

GraphQL supports web-optimized URLs like:

{
  "data": {
    "adventureByPath": {
      "item": {
        "_path": "/content/dam/wknd-shared/en/adventures/bali-surf-camp/bali-surf-camp",
        "title": "Bali Surf Camp",
        "primaryImage": {
          "_dynamicUrl": "/adobe/dynamicmedia/deliver/dm-aid--a38886f7-4537-4791-aa20-3f6ef0ac3fcd/adobestock_175749320.jpg?preferwebp=true&width=1000&quality=80"
        }
      }
    }
  }
}

 

 

 


Aanchal Sikka