So far I could access information about selected files/images, their metadata and categories.
It works great! 👍👍👍
Now I'd like to get these selected files as actual images (thumbnails, cache images).
I need to process them (resize, combine, add text) and save them as JPG.
How do I get an image from v1/files?
v1/files/image
Many thanks for this valuable advice.
If only I had scrolled down a little further, I would certainly have noticed it.
::)
Ok, then I'll clarify my question: WHAT do I get when I call up an image?
Before you reply that it would be an ,,image", I mean the data format, the type in Python.
Tip: When you call endpoints in your browser (or via tools like PostMan) you can see the response from IMWS.
The endpoint returns the pixels of the image as a binary data stream with a mime type depending on the format used (JPG or PNG or the extension of the original file when the original file is requested).
v1/files/image/base64
returns a Base64-encoded image, but that's more for icons and small images.
The IMatchLib.js (or .ts) source library included in IMatch has a method ImageUrl() that can be used to fetch an image in a specific size and use it e.g. for a src= Attribute in HTML ot fetch it with Curl or Python or whatever. See source code for details. auth-token can be empty for local use.