# Fixing "INVALID_SCREEN_DATA: Expected the property 'items' to be of type boolean or object" Error on WhatsApp API
Author: Prashant Jangid
Author URL: https://www.heltar.com/blogs/author/prashant-jangid
Published: 2025-05-20
Category: Troubleshoot
Category URL: https://www.heltar.com/blogs/category/troubleshoot
Tags: WhatsApp Flows Error
Tag URLs: WhatsApp Flows Error (https://www.heltar.com/blogs/tag/whatsapp-flows-error)
URL: https://www.heltar.com/blogs/fixing-invalidscreendata-expected-the-property-items-to-be-of-type-boolean-or-object-error-on-whatsapp-api-cmawls31v000dqcb4qrrtwpdp

If you've hit this validation error:

**INVALID\_SCREEN\_DATA: Expected the property 'items' to be of type boolean or object**

You're not alone. This happens when you mistakenly assign a string value to the items property in your JSON schema.

## Quick Fix

If you're setting the **items property** in an array schema, make sure it's an **object or boolean**, not a string. Here's the corrected version:

```
{
  "type": "array",
  "items": {
    "type": "string"
  },
  "__example__": ["example item"]
}
```

## The Problem

This is invalid:

```
{
  "type": "array",
  "items": "string",
  "__example__": []
}
```

Although "string" feels intuitive, items expects either:

- an object defining the schema for each item, or

- false if you want to disallow items (rarely used).


## The Solution

Wrap the type inside an object:

```
{
  "type": "array",
  "items": {
    "type": "string"
  },
  "__example__": ["example item"]
}
```

Now the schema explicitly tells the renderer: "Each item in this array is a string." That’s exactly what it needs to validate and display your screen correctly.

Whenever you define an array in your screen schema, always pair it with a clear and valid items object. It prevents breakage and saves debugging time down the line.

For more troubleshooting insights related to WhatsApp Business API, check out [heltar.com/blogs](https://www.heltar.com/blogs).


---
This blog is powered by Superblog. Visit https://superblog.ai to know more.
---

