Question
Using Images with Document Generation API
Hi there,
I'm trying to dynamically insert images into a document in a repeating section. For some reason this isn't working for me at all and I was hoping I could get some help. I've tried using the image urls as well as base 64 encoding.
My document has the following:
{% repeating-section backup[number > 0] %}

{{name}}
{% end-section %}
With the alt text of the image:
{
"location-path": "path",
"image-props": {
"alt-text": "Backup Load"
}
}
And the json is as follows:
{
"paymentType": "cash",
"client": {
"name": "Jade",
"address": "Placeholder Address"
},
"recommendation": {
"label": "7.1 kWp Solar Panels + 7kWh Storage",
"outputkWhYearOne": "56,739",
"priceInclVATR": "250,000",
"firstYearSavings": "20,123"
},
"backup":[
{"name":"Electric Fence", "number": 1, "path": "https://media.umbraco.io/mangrove/iopbdhw4/electric_fence.svg"},
{"name":"LED Lights", "number": 0, "path": "https://media.umbraco.io/mangrove/r31jgjzg/led_lights.svg"}
]
}
