Contentful logo

Contentful Community

This is not valid JSON

Hello, I have content model wite one filed as a json object.
When I write array inside this filed I get This is not valid JSON.

what is the problem? my app needs to map this array but I get nothing as a response because of this error.

Thanks.

Hi, Did this ever get resolved? I am having the same issue.

Error publishing “single economy”: Validation failed. Please check the individual fields for errors.

Hi, JSON arrays should be written inside square brackets, for example:

[
{“firstName”:“John”, “lastName”:“Doe”},
{“firstName”:“Anna”, “lastName”:“Smith”},
{“firstName”:“Peter”, “lastName”:“Jones”}
]