This blog post explains one reason why expected fields may be absent when attempting to limit fields returned for entries in the Contentstack SaaS headless CMS.
By default, when you retrieve an entry, the CMS returns all its fields, potentially excluding some system metadata such as workflow state unless explicitly requested. You can use the Contentstack only operator to specify the fields returned, reducing HTTP payloads to increase performance and efficiency.
The only operator translates to an API query string parameter named only[BASE][].
I had assumed that if I wanted to retrieve multiple fields, I would use a comma-separated list of field names. Apparently, this causes Contentstack to look for a single field with an name containing all of those strings and commas, which does not exist.
Rather than using a single comma-separated value, add one instances of the only[BASE][] query string parameter for each field. The Contentstack SDKs likely do this automatically, but I prefer to construct the URLs and HTTP requests, call the HTTPS APIs directly, and process the JSON response myself.
A request for a URL with the following query string parameter would not return the expected fields title and pagedata.
only[BASE][]=title,pagedata
A request for a URL with the following query string parameters returns those fields if they exist.
only[BASE][]=title&only[BASE][]=pagedata