Skip to main content

Dead man's switch for AI agents. Miss a heartbeat, get an alert.

Project description

Agent Pulse

Dead man's switch for AI agents. Miss a heartbeat, get an alert.

PyPI License: MIT

The Problem

Your AI agent silently dies at 2am. OOM, uncaught exception, network drop. You find out 6 hours later when a customer complains. Healthchecks.io works for cron jobs — but it doesn't understand agent-specific failures like token budget exhaustion or decision trace anomalies.

The Solution

Agent Pulse monitors your agents with heartbeats. If a heartbeat is missed, you get a Telegram alert (email and webhook coming). One line of Python to integrate.

Quick Start

pip install agent-heartbeat
import agentpulse

# One line. Background thread pings automatically.
agentpulse.init(
    token="ap_your_token_here",
    agent_id="my-scraper",
    interval=300,  # ping every 5 min
)

# Your agent code runs normally...

Or use the client directly:

from agentpulse import Client

client = Client(token="ap_your_token_here")

# Register a new agent
agent = client.register("my-trading-bot", interval=300)

# Send heartbeats
client.ping(agent["agent_id"])

# Check status
status = client.status(agent["agent_id"])
print(status)  # {'status': 'alive', 'last_ping_at': '...'}

API

Endpoint Method Description
/api/v1/register POST Create owner account, get API token
/api/v1/agents POST Register a new agent
/api/v1/agents/{id}/ping POST Send heartbeat
/api/v1/agents/{id} GET Check agent status
/api/v1/agents GET List all agents
/api/v1/agents/{id} DELETE Remove agent
/api/v1/config/telegram POST Set Telegram alert channel
/api/v1/config/webhook POST Set webhook alert channel

Self-Hosting

pip install agent-heartbeat[server]
uvicorn server.main:app --host 0.0.0.0 --port 8000

Requires: Python 3.9+, SQLite (included). No external databases needed.

Pricing

Self-hosted is free and unlimited. A hosted service with managed alerting is planned for a future release.

Built by LuciferForge

Part of the AI agent safety ecosystem:

Contact: LuciferForge@proton.me

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

agent_heartbeat-0.1.2.tar.gz (5.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

agent_heartbeat-0.1.2-py3-none-any.whl (5.6 kB view details)

Uploaded Python 3

File details

Details for the file agent_heartbeat-0.1.2.tar.gz.

File metadata

  • Download URL: agent_heartbeat-0.1.2.tar.gz
  • Upload date:
  • Size: 5.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.2

File hashes

Hashes for agent_heartbeat-0.1.2.tar.gz
Algorithm Hash digest
SHA256 fdfa7b7d557eeed30276b7a42c821a2dba35af32a3fe81b53ec124341303b071
MD5 66fc505c5ee1355f761a8310b2425f37
BLAKE2b-256 4df2b2c5d4243e00cc402fb3de97e5e06f8f2033a23fc6084a86d97dabf048e3

See more details on using hashes here.

File details

Details for the file agent_heartbeat-0.1.2-py3-none-any.whl.

File metadata

File hashes

Hashes for agent_heartbeat-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 9864a9e465d8c64d869e7354640f4844b9aea622ef63d9161da87f2754e72bc4
MD5 554f542b020f3332a710c71268c64f28
BLAKE2b-256 b996266d882572b2492aebec2f7586707f8ff72a42d38463dc41da861978a1bd

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page