# usage.threshold

HTML: https://www.app2email.com/docs/api/webhooks/usage.threshold · Index: https://www.app2email.com/docs/api/llms.txt

80% or 100% of the billing month's messages are used (once each per month).

Group: Account. Header `X-App2email-Event: usage.threshold`. Inside the envelope `{id, type, created, number, test?, data}` ([envelope, headers, signature](https://www.app2email.com/docs/api/webhooks.md)). Every webhook of the number gets every number event: filter by `type`.

## data

| Field | Type | Required | Notes |
| --- | --- | --- | --- |
| `data.threshold_percent` | integer | yes | one of: `80`, `100` |
| `data.whatsapp_messages` | object |  |  |
| `data.whatsapp_messages.used` | integer |  |  |
| `data.whatsapp_messages.limit` | integer |  |  |
| `data.whatsapp_messages.left` | integer |  |  |
| `data.plan_messages` | object |  |  |
| `data.plan_messages.whatsapp_sent` | integer |  |  |
| `data.plan_messages.emails_sent` | integer |  |  |
| `data.plan_messages.total_sent` | integer |  |  |
| `data.plan_messages.limit` | integer |  |  |
| `data.plan_messages.left` | integer |  |  |
| `data.plan` | string |  |  |
| `data.billing_period` | object |  |  |
| `data.billing_period.start` | string |  |  |
| `data.billing_period.end` | string |  |  |
| `data.timestamp` | string |  |  |

## Samples

### 80

```json
{
  "id": "evt_Xq3k9m2Lw8Rt5Yp1Zs01",
  "type": "usage.threshold",
  "created": "2026-11-06T01:00:00.000Z",
  "number": "4976659348270",
  "data": {
    "threshold_percent": 80,
    "whatsapp_messages": {
      "used": 750,
      "limit": 1000,
      "left": 200
    },
    "plan_messages": {
      "whatsapp_sent": 750,
      "emails_sent": 50,
      "total_sent": 800,
      "limit": 1000,
      "left": 200
    },
    "plan": "standard_1000",
    "billing_period": {
      "start": "2026-11-01T00:00:00.000Z",
      "end": "2026-12-01T00:00:00.000Z"
    },
    "timestamp": "2026-11-06T01:00:00.000Z"
  }
}
```

## Caused by

- [Send a WhatsApp message: template, or free-form reply](https://www.app2email.com/docs/api/messages/send-template-message.md): `POST /v1/{number}/messages`
- [Delete a contact record](https://www.app2email.com/docs/api/contacts/delete-contact.md): `DELETE /v1/{number}/contacts/{identity}`
- [Approve a held send: it is sent now](https://www.app2email.com/docs/api/approvals/approve-send.md): `POST /v1/{number}/approvals/{id}/approve`
- [Put a customer on the waitlist of a full day](https://www.app2email.com/docs/api/book-and-pay/add-to-booking-waitlist.md): `POST /v1/{number}/bookings/waitlist`
- [Book an appointment for a customer at a free slot](https://www.app2email.com/docs/api/book-and-pay/create-booking.md): `POST /v1/{number}/bookings`
- [Cancel an appointment](https://www.app2email.com/docs/api/book-and-pay/cancel-booking.md): `POST /v1/{number}/bookings/{id}/cancel`
- [Mark an appointment completed, a no-show, or back to confirmed](https://www.app2email.com/docs/api/book-and-pay/set-booking-status.md): `POST /v1/{number}/bookings/{id}/status`
- [Send a Flow to a contact (the booking form or another form)](https://www.app2email.com/docs/api/book-and-pay/send-flow.md): `POST /v1/{number}/flows/{key}/send`

Send it to your URL: https://www.app2email.com/docs/api/webhooks/tester?type=usage.threshold
