Skip to main content

A simple API to check the cpu and memory usage of an instance

Project description

Resource Checker API

This is a simple application that checks the resource usage of your server via API

Requires

  • python = ">=3.13"

Installation

pip3 install resource-api-monitor

You can also download the .whl package and install from there.

Usage

Run:

monitor-server

Then just curl to endpoint:8000/cpu or endpoint:8000/memory.

API Reference

Endpoint Method Description
/memory GET Returns RAM usage and swap statistics.
/cpu GET Returns average CPU usage (0.3s duration between samples).

Example CPU Output

{ "total_cpu_usage": 0.15, "usage_per_cpu": [0.12, 0.18, 0.14, 0.16] }

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

resource_api_monitor-0.0.1-cp314-cp314-manylinux2010_x86_64.manylinux_2_12_x86_64.manylinux_2_28_x86_64.whl (44.0 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.12+ x86-64manylinux: glibc 2.28+ x86-64

resource_api_monitor-0.0.1-cp313-cp313-manylinux2010_x86_64.manylinux_2_12_x86_64.manylinux_2_28_x86_64.whl (44.0 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.12+ x86-64manylinux: glibc 2.28+ x86-64

File details

Details for the file resource_api_monitor-0.0.1-cp314-cp314-manylinux2010_x86_64.manylinux_2_12_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for resource_api_monitor-0.0.1-cp314-cp314-manylinux2010_x86_64.manylinux_2_12_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 dd70e1fc9e46f16f7d83ed5d313c2d7087517528df12fbdd5603ecf0e5509e23
MD5 78282103889fdc7d5cd171a98281537b
BLAKE2b-256 12477668c237c106982e1f34c43b9ede37d8206d66323eee4e9aa2e00eae5a4a

See more details on using hashes here.

File details

Details for the file resource_api_monitor-0.0.1-cp313-cp313-manylinux2010_x86_64.manylinux_2_12_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for resource_api_monitor-0.0.1-cp313-cp313-manylinux2010_x86_64.manylinux_2_12_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 4ebc337a807600b31aa2f984022d9ec3a02c2485ecf1065478bb11837c8c67ce
MD5 bcb8667be9d0f7a1d18a5ec8d31a5827
BLAKE2b-256 347e34b35fb3156657a8a177a0c5dfccfdbf200577be238bec9a77c87f3fc25a

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