Skip to content

Introducing Appwrite Monitors: usage and endpoint alerts

Appwrite Monitors alert your team when project usage crosses a threshold or an endpoint check fails, with escalations, acknowledgements, and project events.

Your app is live, and now someone has to watch it. Bandwidth spikes overnight, an endpoint stops answering, or a certificate gets a few days from expiring, and too often the first person to notice is a user. Catching those moments early usually means a separate monitoring service, wired to your project by hand and blind to what Appwrite already measures.

Today we are launching Appwrite Monitors, alerts built into your Appwrite project. Set a threshold on a usage metric Appwrite already records, or check an HTTP, DNS, TCP, or SMTP endpoint on a schedule, and Appwrite opens an alert the moment something is off. Your team hears about it by email, in the Console, and on their phones, and the alert resolves on its own when things recover.

What Appwrite Monitors gives you

  • Usage monitors: Set a threshold on a metric such as outbound bandwidth, database reads, or executions, for the whole project or one resource.
  • Monitors from your charts: Drag a threshold onto a chart on the Usage page and create a monitor at that level.
  • Endpoint checks: Check an HTTP status or certificate, a DNS record, a TCP port, or a mail server every 30 seconds to every hour.
  • Alerts that resolve themselves: An alert opens when a monitor fires and closes when it recovers, with the reading that opened it.
  • Notifications with a severity: Notify your organization's owners and developers by email, in the Console, and with a push, at Info, Warning, Error, or Critical.
  • A notifications center: Acknowledge alerts and manage your pushes from the bell in the Console header.
  • Escalations: Notify people in steps until someone acknowledges the alert.
  • Project events: React to alerts with webhooks, Functions, or Realtime.

Watch any usage metric

A usage monitor compares one metric with a threshold. Choose the metric, then what it Applies to: the whole project, or a single database, bucket, function, or site. On Appwrite Cloud, a dedicated database can also be watched for CPU, memory, and connections.

Counters such as requests and outbound bandwidth are summed over a window you choose, from 5 minutes to 30 days, and compared at each check. Gauges such as storage used compare the latest reading. To help you pick a threshold, the Console fills one in from your recent usage and charts it against the last 24 hours, so you see how often the monitor would have fired before you create it.

Monitors are part of the API, so you can create them with a server SDK, from a setup script or alongside the rest of your project's configuration. This one opens an alert when the project sends more than 1 GB in an hour:

JavaScript
import { Client, Monitors, Query, MonitorSeverity } from 'node-appwrite';

const client = new Client()
    .setEndpoint('https://<REGION>.cloud.appwrite.io/v1')
    .setProject('<PROJECT_ID>')
    .setKey('<API_KEY>');

const monitors = new Monitors(client);

await monitors.createUsageMonitor({
    monitorId: 'outbound-bandwidth',
    name: 'Outbound bandwidth spike',
    rules: [Query.greaterThan('network.outbound', 1000000000)],
    window: 3600,
    notify: ['owner', 'developer'],
    severity: MonitorSeverity.Error
});

Thresholds use the metric's API unit, so bandwidth and storage are in bytes. Usage monitors work on Appwrite Cloud and on self-hosted Appwrite. On Appwrite Cloud, the Budget cap and Billing alerts on your organization's Billing page also work as monitors for additional usage charges.

Draw a monitor on a usage chart

You don't have to start from the form. The charts on your project's Usage page can create a monitor for the metric they plot. Hover over a chart and a + appears at its right edge. Click it, drag the red line to the level that should alert you, and click Create monitor.

The create form opens with the metric, the threshold, and a window that matches the chart's interval. A line on an hourly requests chart becomes a monitor for more than 1,300 requests in an hour. Monitors you already have show up as red lines on the same charts, so you can see how close today's traffic came to each one.

This works on every chart the Usage page draws, including realtime messages, documents, and video storage, and on the charts of a database's Monitor tab. Function and site pages get a Monitor menu too, with ready-made monitors for an execution spike, compute usage, deployment storage, and a site's uptime.

Check your endpoints from Appwrite Cloud

Not every problem shows up in usage. On paid Appwrite Cloud plans, endpoint checks connect to a target on a schedule and open an alert when the check fails:

  • HTTP sends a request with the method, headers, and body you choose, and expects a status code, any 2xx by default. For an HTTPS URL, it can also warn a set number of days before the certificate expires.
  • DNS resolves a domain's A, AAAA, CNAME, MX, TXT, or NS record, optionally through a resolver you choose, and can expect a specific answer.
  • TCP succeeds when a host accepts a connection on a port.
  • SMTP checks that a mail server accepts a session and completes the TLS handshake you configure. By default, the port decides: implicit TLS on 465 and STARTTLS on 587.

Checks run every 30 seconds to every hour, with a timeout from 5 seconds to 1 minute. Your plan sets the shortest interval you can choose. The Monitors list shows each check's latest result, latency, and time.

Alerts that open and close on their own

An alert records one period during which a monitor's condition holds or its check keeps failing. Appwrite opens it as Firing and marks it Resolved when the monitor recovers. If the monitor fires again later, that's a new alert.

The Alerts tab lists firing and resolved alerts, each with when it started, the usage reading or check result that opened it, and when it recovered. Acknowledge a firing alert to show your team someone is handling it. The count on the tab only includes firing alerts nobody has acknowledged yet.

Decide who hears about it

Each monitor notifies the Owners or Developers of your organization, or both. Confirmed members in those roles get an email and a Console notification when the monitor fires and again when it resolves, and members with a registered device can also get a push. Appwrite Beep, our mobile app launching alongside Monitors, brings those pushes to your phone.

Two more settings keep alerts useful:

  • Severity marks each monitor as Info, Warning, Error, or Critical. Critical pushes can use higher urgency on supported devices.
  • Cooldown sets the minimum time between two firing notifications from the same monitor, so a flapping metric doesn't flood your inbox. Alerts are still recorded while the cooldown holds notifications back.

Follow alerts from the notifications center

Monitors ship with a new notifications center in the Console. Click the bell in the header to see alerts as they fire and resolve, from any page.

Each alert gets one notification, and Appwrite updates it as the alert changes. When a teammate acknowledges the alert, everyone's notification says Acknowledged. When it resolves, the notification gets a green check and comes back as unread. You see the latest state of each alert instead of one row for every change.

Right-click a notification to acknowledge a firing alert without leaving the page you're on, mark it as read, or mute pushes for its project. The clock in the header snoozes Appwrite Beep pushes for 30 minutes to 24 hours while you work on an incident. The gear holds your browser alert and push settings, which Beep uses too. The Updates tab lists the latest changelog entries and any ongoing Appwrite Cloud incident.

Escalate until someone acknowledges

For alerts that can't wait, an escalation notifies people in steps. Create one under your organization's Settings > Escalations: each step names the roles or members to notify and how long to wait before it. Then pick the escalation as a monitor's recipient.

Appwrite follows the steps while the alert is firing, and stops when someone acknowledges it or the monitor recovers. If someone undoes their acknowledgement while the alert is still firing, the escalation picks up from its next step.

React to alerts in your own code

Every alert on a project monitor is also a project event, with the alert as its payload:

EventWhen it fires
monitors.[monitorId].alerts.[alertId].createThe monitor starts firing and opens an alert.
monitors.[monitorId].alerts.[alertId].updateThe alert resolves, is acknowledged, or has its acknowledgement undone.

Send them to a webhook to post in your team's chat, trigger a function that pauses an expensive job, or subscribe with Realtime to show alerts in your own dashboard. The cooldown only holds back team notifications, so events fire on every change.

The other direction works too. With an API key that has the alerts.write scope, a chat command or an on-call integration can acknowledge an alert by calling alerts.update with acknowledged: true.

Get started with Appwrite Monitors

Appwrite Monitors is available today on Appwrite Cloud. Open Monitors under Observe in your project, click Create monitor, and start with outbound bandwidth, or drag a threshold onto a chart on the Usage page. The Console suggests a threshold from your own usage, and the monitor shows as Pending until its first check.

Appwrite Monitors checks your project usage or an endpoint on a schedule and opens an alert when a usage condition is met or an endpoint check fails. You choose who gets notified, and review when each alert fired and recovered under Observe > Monitors in your project. See the Monitors docs.

A usage monitor compares one metric with a threshold, for the whole project or a single resource. Metrics include requests, outbound bandwidth, monthly active users, and storage for a project, reads and writes for a database, executions for a function or site, and CPU, memory, or connections for a dedicated database on Appwrite Cloud. See Usage monitors.

Yes. Hover over a chart on your project's Usage page, click the + at its right edge, drag the threshold line, and click Create monitor. The create form opens with the chart's metric, your threshold, and a window that matches the chart's interval. See Create a monitor from a chart.

Endpoint checks test an HTTP response status or an HTTPS certificate nearing expiration, a DNS record, a TCP port, or an SMTP server and its TLS handshake, every 30 seconds to every hour. They're available on paid Appwrite Cloud plans. See Endpoint checks.

The organization roles you pick, Owners by default, get an email and a Console notification when the monitor fires and again when it resolves, and members with a registered device can also get a push. An escalation notifies people in steps until someone acknowledges the alert. See Alerts and notifications.

Usage monitors do. They read the usage stats that the _APP_USAGE_STATS variable turns on, which is enabled by default. Endpoint checks run from Appwrite Cloud on paid plans.

Yes. A monitor fires monitors.[monitorId].alerts.[alertId].create when it opens an alert, and an update event when the alert resolves or is acknowledged. Use them with webhooks, Functions, or Realtime, and acknowledge alerts from your own tools with an API key that has the alerts.write scope. See Use project events.

Read next

Introducing Appwrite Zero

Chirag Aggarwal

Appwrite Zero creates a real Appwrite Cloud project for a developer or coding agent upfront, skipping signup and card entry. Projects run for an hour, and claiming one keeps everything already built inside.

6 min read