Hi,
I am trying to use the Batch import API [1] to import multiple new documents into Bloomreach Content.
I’ve created a Content type, with various fields. One of the fields in the content type is an “Image Link”.
How do I go about importing a (via batch import API) document with the Image Link field that references an image that is yet to exist (in the “gallery”)?
It doesn’t look like the Batch import API caters for upload of the yet-to-exist-in-the-gallery image at the same time as importing the document(s)?
Am I supposed to (somehow) import all the images into the “gallery” separately and just ensure that in the batch import NDJSON data the Image Link field’s “value” contains the gallery path, for example (import data field for single document):
...
{
"name": "image",
"value": [
"/content/gallery/001.jpeg"
]
},
...
…where “/content/gallery/001.jpeg” is the product of another (image) import?
There is an “images” endpoint documented [2], but this seems to only support a GET method, and also doesn’t seem too relevant to what I’m looking to do.
Currently, the only way I can see to achieve using batch import of new documents that need to reference yet-to-exist images, is to run the import then manually go through the imported documents, edit each individually and upload an image for the document Image Link field, via the UI.
If there’s 10 new documents/images that’s not too bad, but if it’s hundreds, then the time to edit each new document an add an image (or images, if multiple Image Link fields) isn’t really an option.
Have I missed some docs around how to go about this? Or, is what I’m trying to achieve not currently possible in Bloomreach Content?