When I look up my "Image Advanced" field data via REST API, I only get the image ID (as if "Image Advanced" was a regular "Image" field). Looks like this:
"image_url":["3344"]
I'm not getting the full "Image Advanced" image data (like image URL).
If the field is nested in a group, it will be serialized and saved in the database such as {"image_advanced":["1957","1956","1955"]}. For some special fields, only the ID will be saved and you need to use some helper functions to get the URL of the image by the ID. For more information, please follow this documentation https://docs.metabox.io/extensions/meta-box-group/#special-fields
Got it! Why is it set up this way? I need to make a ton of calls to the REST API to grab metabox data, including image URLs, so I can display the content elsewhere (not on wordpress). I want to avoid making all those extra calls to the REST API (to /wp-json/wp/v2/media/{id}) to fetch the full image URLs. Is there a way I can edit one of the metabox plugins to add the full url field to Image Advanced (whether it's nested in a group or not)? Or is there no way to make this work when Image Advanced is nested in a group?
It's the feature of Group field Database optimization of sub-fields for reduced bloat. If every field nested in Group has all property saved, it will increase the size of the database and slow down your site. That's why Group only saves necessary information of the sub-field.