When using the REST API and exposing the custom fields I do see the 'toolset-meta' added to the results but not all the fields are populated. For instance, for the first 5 custom posts the field in question is populated with data. All other posts with these fields are reporting back empty with I look at the API response. So it's only capturing some of the data. I checked in WordPress and indeed the data has been entered.
The field in question is a text field and I have about 120 posts. I have set to expose all fields using,
add_filter('toolset_rest_run_exposure_filters', '__return_true');
Thanks for your help.
I made a discovery. The data will appear if I click the post button on each of the posts, even though the post is published. Possibly a bug with the plugin?
Hello,
I assume we are talking about the "Publish" button when you edit a post.
If it is, what post status are those posts using before you publish? "draft" or "Pending"?
The wordpress REST API won't display non published post by default, you will need to make sure your REST API can be exposed in your REST API, for example:
https://developer.wordpress.org/rest-api/reference/posts/
A named status for the object.
Context: view, edit
One of: publish, future, draft, pending, private