Messaging Health Status

The Health Messaging Status feature allows you to monitor the status of the WhatsApp Business Account (WABA) and phone number within the Cloud API messaging system.

By making the request to the /health_status endpoint, you can receive the operational condition of the messaging service.

API Reference

The health_status endpoint returns the status of both the phone number and WABA account in the same response.

Health Status

GET https://waba-v2.360dialog.io/health_status

Request Example:

curl --location 'https://waba-v2.360dialog.io/health_status' --header 'D360-API-KEY: {{API_Key}}' --header 'Content-Type: application/json'

Headers

Name
Type
Description

D360-API-KEY*

string

See Callback Response below.

Response Payload

 {
   "health_status": {
    "can_send_message": "<OVERALL_MESSAGING_STATUS>",
    "entities": [
      {
        "entity_type": "PHONE_NUMBER",
        "id": "<BUSINESS_PHONE_NUMBER_ID>",
        "can_send_message": "<BUSINESS_PHONE_NUMBER_MESSAGING_STATUS>",
        "can_receive_call_sip": "<BUSINESS_PHONE_NUMBER_SIP_STATUS>"
      },
      {
        "entity_type": "WABA",
        "id": "<WABA_ID>",
        "can_send_message": "<WABA_MESSAGING_STATUS>"
      },
      {
        "entity_type": "BUSINESS",
        "id": "<BUSINESS_ID>",
        "can_send_message": "<BUSINESS_MESSAGING_STATUS>"
      },
      {
        "entity_type": "APP",
        "id": "<APP_ID>",
        "can_send_message": "<APP_MESSAGING_STATUS>",
        "can_receive_call_sip": "<BUSINESS_PHONE_NUMBER_SIP_STATUS>"
      }
    ]
  },
  "id": "<NODE_ID>"
}

Messaging Health Status Details

When you attempt to send a message, it involves several parts (nodes or entities), such as a WhatsApp Business Account (WABA), a business phone number, and sometimes a message template. Each node has a "health status" assigned to the can_send_message property to show if it can send messages:

  • AVAILABLE: Indicates that the node meets all messaging requirements.

  • LIMITED: Indicates that the node meets messaging requirements, but has some limitations. If a given node has this value, additional info will be included.

  • BLOCKED: Indicates that the node does not meet one or more messaging requirements. If a given node has this value, the errors property will be included which describes the error and a possible solution.

Overall Status

The overall health status property can_send_message will be set as follows:

  • If one or more nodes is blocked, it will be set to BLOCKED.

  • If no nodes are blocked, but one or more nodes is limited, it will be set to LIMITED.

  • If all nodes are available, it will be set to AVAILABLE.

Example Response:

{
  "health_status": {
    "can_send_message": "AVAILABLE",
    "entities": [
      {
        "entity_type": "PHONE_NUMBER",
        "id": "106540352242922",
        "can_send_message": "AVAILABLE"
      },
      {
        "entity_type": "WABA",
        "id": "102290129340398",
        "can_send_message": "AVAILABLE"
      },
      {
        "entity_type": "BUSINESS",
        "id": "506914307656634",
        "can_send_message": "AVAILABLE"
      },
      {
        "entity_type": "APP",
        "id": "634974688087057",
        "can_send_message": "AVAILABLE"
      }
    ]
  },
  "id": "106540352242922" 
}

Additional Info Property

If a given node's can_send_message property is set to LIMITED, the additional_info property will be included, which provides additional context for the limitation.

Example Limited Response

This is an example response to a request on a business phone number that can be used to send messages, but has a limit on the number it can send because its display name has not been approved.

{
  "health_status": {
    "can_send_message": "LIMITED",
    "entities": [
      {
        "entity_type": "PHONE_NUMBER",
        "id": "106540352242922",
        "can_send_message": "LIMITED",
        "additional_info": [
          "Your display name has not been approved yet. Your message limit will increase after the display name is approved."
        ]
      },
      {
        "entity_type": "WABA",
        "id": "102290129340398",
        "can_send_message": "AVAILABLE"
      },
      {
        "entity_type": "BUSINESS",
        "id": "506914307656634",
        "can_send_message": "AVAILABLE"
      },
      {
        "entity_type": "APP",
        "id": "634974688087057",
        "can_send_message": "AVAILABLE"
      }
    ]
  },
  "id": "105154286024403"
}

Errors Property

If a given node's can_send_message property is set to BLOCKED, the errors property will be included, which describes the reason for the status and a possible solution.

Example Blocked Response

This is an example response to a request on a template that can't be sent in a template message because it is still in a pending state.

{
  "health_status": {
    "can_send_message": "BLOCKED",
    "entities": [
      {
        "entity_type": "MESSAGE_TEMPLATE",
        "id": "2632273056924580",
        "can_send_message": "BLOCKED",
        "errors": [
          {
            "error_code": 141002,
            "error_description": "Message templates can only be sent out if they are approved.",
            "possible_solution": "Edit or appeal the message template review decision."
          }
        ]
      },
      {
        "entity_type": "WABA",
        "id": "102290129340398",
        "can_send_message": "AVAILABLE"
      },
      {
        "entity_type": "BUSINESS",
        "id": "506914307656634",
        "can_send_message": "AVAILABLE"
      },
      {
        "entity_type": "APP",
        "id": "634974688087057",
        "can_send_message": "AVAILABLE"
      }
    ]
  },
  "id": "2632273056924580"
}

Last updated

Was this helpful?