Skip to main content

Emmett-Prometheus

Emmett-Prometheus is an Emmett framework extension integrating prometheus client.

Emmett-Prometheus is compatible both with Emmett and Emmett55.

Installation

You can install Emmett-Prometheus using pip:

pip install emmett-prometheus

And add it to your Emmett application:

from emmett_prometheus import Prometheus

app.use_extension(Prometheus)

Configuration

Here is the complete list of parameters of the extension configuration:

param default description
auto_load True Automatically inject extension on routes and expose metrics
enable_http_metrics True Enable metrics collection on HTTP routes
enable_ws_metrics True Enable metrics collection on Websocket routes
enable_sys_metrics False Enable default Prometheus client system metrics collection
metrics_route_path /metrics Path for metrics route
metrics_route_hostname Hostname for metrics route

You also have some additional customisations available (here we show the defaults):

app.config.Prometheus.http_histogram_statuses = [200, 201]
app.config.Prometheus.http_histogram_exclude_methods = ["OPTIONS"]
app.config.Prometheus.http_histogram_buckets = [
    5, 35, 100, 200, 500, 1000, "INF"
]
app.config.Prometheus.exclude_routes = []
app.config.Prometheus.metrics_names={
    "http_counter": "emmett_request_count",
    "http_histogram": "emmett_request_latency",
    "ws_gauge": "emmett_websocket_gauge",
    "ws_recv_counter": "emmett_websocket_messages_recv_count",
    "ws_send_counter": "emmett_websocket_messages_send_count"
}

License

Emmett-prometheus is released under BSD license.

Metadata

Release files for emmett-prometheus 0.3.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for emmett-prometheus 0.3.1
File Size Uploaded
emmett_prometheus-0.3.1.tar.gz 4.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for emmett-prometheus 0.3.1
File Interpreter ABI Platform
emmett_prometheus-0.3.1-py3-none-any.whl Python 3 none any Details

Total release size: 10.0 kB

Release files / emmett_prometheus-0.3.1.tar.gz

Download URL emmett_prometheus-0.3.1.tar.gz
Size 4.6 kB
Tags Source
SHA-256 checksum
How to use checksums
6ff0aca545ed94b6f717c3109a4475148d7fb44e3b97c8f11116ea38259c2451
BLAKE2b-256 checksum
How to use checksums
b61069ca6e6d22671a05701673453b800a76d29395ccc1e6026b5e83a22660f7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 25, 2026.

Transparency log

Release files / emmett_prometheus-0.3.1-py3-none-any.whl

Download URL emmett_prometheus-0.3.1-py3-none-any.whl
Size 5.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5621f67e772044a1dd138d36a2ae386092d3d67dbc080587f382e3fd8ce984b5
BLAKE2b-256 checksum
How to use checksums
3a48156ce4da3366d8712899b34ecc3d88f588f699f1bffeae481935302e6e9f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 25, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.3.1 This release

2 release files

0.3.0

2 release files

0.2.0

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page