Template Status Update

Template Status Update#

class pywa.types.templates.TemplateStatusUpdate#

Represents status change of a template.

Triggers:

- A template is approved.
- A template is rejected.
- A template is disabled.
Variables:
  • id โ€“ ID of Whatsapp Business Accounts this update belongs to.

  • timestamp โ€“ Timestamp of the update (in UTC).

  • new_status (TemplateStatus) โ€“ The new status of the template.

  • template_id โ€“ The ID of the template.

  • template_name โ€“ The name of the template.

  • template_language โ€“ The language of the template.

  • category (TemplateCategory | None) โ€“ The category of the template.

  • reason (TemplateRejectionReason | None) โ€“ The reason the template was rejected (if status is REJECTED).

  • disable_date (datetime.datetime | None) โ€“ The date the template was disabled (if status is DISABLED).

  • title (str | None) โ€“ Title of template pause or unpause event.

  • description (str | None) โ€“ String describing why the template was locked or unlocked.

  • shared_data โ€“ Shared data between handlers.

class pywa.types.templates.TemplateRejectionReason#

The reason the template was rejected.

โ€˜Rejection statusโ€™ on developers.facebook.com

Variables:
  • PROMOTIONAL โ€“ Indicates template contains content that violates our policies.

  • ABUSIVE_CONTENT โ€“ Indicates template contains content that violates our policies.

  • INCORRECT_CATEGORY โ€“ Indicates the templateโ€™s content doesnโ€™t match the category designated at the time of template creation.

  • INVALID_FORMAT โ€“ Indicates template has an invalid format.

  • SCAM โ€“ Indicates template contains content that violates our policies.

  • TAG_CONTENT_MISMATCH โ€“ Indicates the templateโ€™s content doesnโ€™t match the category designated at the time of template creation.

  • NONE โ€“ Indicates template was paused.