While building a WhatsApp Flow, you might run into this error:

INVALID_ENUM_VALUE

Value should be one of: [data_exchange, navigate].

This is a static validation error, and it usually means that you've used a valid property—but with a value that’s not allowed. In simple terms: You used the right key, but gave it the wrong value.

Let’s break it down and fix it with a real example.

Example of the Problem

Here’s a snippet that causes the INVALID_ENUM_VALUE error:

{
  "screens": [
    {
      "id": "FIRST_SCREEN",
      "layout": {
        "children": [
          {
            "type": "EmbeddedLink",
            "text": "link",
            "on-click-action": {
              "name": "complete",
              "payload": {}
            }
          }
        ]
      }
    }
  ]
}

So what’s wrong?

The on-click-action.name is set to "complete"—but for an EmbeddedLink, that’s not one of the allowed values.

The Fix

According to the WhatsApp Flow schema, EmbeddedLink supports only specific values for on-click-action.name, like:

[data_exchange, navigate]

So, to fix the error, update the name value to one of the allowed options:

{
  "screens": [
    {
      "id": "FIRST_SCREEN",
      "layout": {
        "children": [
          {
            "type": "EmbeddedLink",
            "text": "link",
            "on-click-action": {
              "name": "navigate",
              "payload": {
                "screen_id": "SECOND_SCREEN"
              }
            }
          }
        ]
      }
    }
  ]
}

Now it’s valid! We’re using an allowed value (navigate) for this component type.

Why This Happens

Different components in WhatsApp Flows have different rules for what actions they can trigger. For example:

  • Button might support actions like data_exchange or complete.

  • Footer can trigger complete.

  • EmbeddedLink supports only navigate or data_exchange.

If you assign an unsupported action to a component, you’ll get this INVALID_ENUM_VALUE error.

Quick Reference: Allowed Values (Examples)

Component

Allowed on-click-action.name values

Button

data_exchange, navigate, complete

Footer

complete only

EmbeddedLink

navigate, data_exchange

Always check the documentation or component-specific schema when in doubt.

Tip: Try using the official Flow Builder UI for a few screens before editing JSON directly. It helps you understand which components accept which values—without having to memorize the entire schema.

For more troubleshooting insights related to WhatsApp Business API, check out heltar.com/blogs.