class_docstr: Interact with Amazon Chime Webhooks to create notifications.
  
  .. warning:: This hook is only designed to work with web hooks and not chat bots.
  
  :param chime_conn_id: :ref:`Amazon Chime Connection ID <howto/connection:chime>`
      with Endpoint as `https://hooks.chime.aws` and the webhook token
      in the form of ``{webhook.id}?token{webhook.token}``
class_docstr_tok: ["Interact","with","Amazon","Chime","Webhooks","to","create","notifications",".","..","warning",":",":","This","hook","is","only","designed","to","work","with","web","hooks","and","not","chat","bots",".",":","param","chime_conn_id",":",":","ref",":","`","Amazon","Chime","Connection","ID","<","howto\/connection",":","chime",">","`","with","Endpoint","as","`","https",":","\/\/hooks.chime.aws","`","and","the","webhook","token","in","the","form","of","``","{","webhook.id","}","?","token","{","webhook.token","}","``"]
docstr: Build payload for Chime and ensures messages do not exceed max length allowed.
  
  :param message: The message you want to send to your Chime room. (max 4096 characters)
docstr_tok: ["Build","payload","for","Chime","and","ensures","messages","do","not","exceed","max","length","allowed",".",":","param","message",":","The","message","you","want","to","send","to","your","Chime","room",".","(","max","4096","characters",")"]
code: def _build_chime_payload(self, message: str) -> str:
      """
      Build payload for Chime and ensures messages do not exceed max length allowed.
  
      :param message: The message you want to send to your Chime room. (max 4096 characters)
      """
      payload: dict[str, Any] = {}
      # We need to make sure that the message does not exceed the max length for Chime
      if len(message) > 4096:
          raise AirflowException(
              "Chime message must be 4096 characters or less."
          )
  
      payload["Content"] = message
      return json.dumps(payload)
  
file_path: airflow/airflow/providers/amazon/aws/hooks/chime.py
imports: from __future__ import annotations
  import json
  import re
  from functools import cached_property
  from typing import Any
  from airflow.exceptions import AirflowException
  from airflow.providers.http.hooks.http import HttpHook
label_desc: Use image node_id 4 for calling the ChimeWebhookHook obj's underlying member method code with example usage: obj._build_chime_payload(message) and returns: json