Registry / observability / gaarf-exporter

gaarf-exporter

JSON →
library1.2.1pypypi✓ verified 83d ago

A Prometheus exporter for Google Ads API metrics, providing real-time monitoring of advertising accounts. Current version 1.2.1, released on 2025-02-15. Active development with irregular releases.

pip install gaarf-exporter
INSTALL
IMPORT
SIG · GAARF-EXPORTER
G
gaarf-exporter
observabilitypythonv1.2.1
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

GaarfExporter
✓ from gaarf_exporter import GaarfExporter
✗ from gaarf_exporter import GaarfPrometheusExporter

Start a Prometheus exporter that scrapes Google Ads metrics on a schedule.

import os from gaarf_exporter import GaarfPrometheusExporter from prometheus_client import start_http_server # Set credentials via environment variables or Google ADC exporter = GaarfPrometheusExporter( credentials={ "developer_token": os.environ.get("DEVELOPER_TOKEN", ""), "client_id": os.environ.get("CLIENT_ID", ""), "client_secret": os.environ.get("CLIENT_SECRET", ""), "refresh_token": os.environ.get("REFRESH_TOKEN", "") }, customer_id="123-456-7890" ) start_http_server(8000) exporter.run() print("Serving metrics on :8000")
gaarf-exporter --version
Debug
Known issues
breakingIn version 1.2.0 the constructor signature changed: credential_file argument was removed; use credentials dict instead.
fix
Replace credential_file='path' with credentials={'developer_token': ..., ...}
affects: >=1.2.0
gotchaThe exporter does not handle Google Ads API quota limits; if you hit rate limits, the exporter may crash with gRPC errors.
fix
Implement custom backoff or use gaarf's built-in quota handling. Not configured by default.
affects: all
gotchaTimeouts are not configurable in the current release; long-running queries may block the exporter HTTP server.
fix
Workaround: set a global timeout via Google Ads API client configuration before initializing exporter.
affects: <=1.2.1
Upgrade
Version history
1.2.1latest on PyPI · released Aug 26, 2025
Audit
Dependencies
gaarfrequiredCore dependency for Google Ads query building
google-adsrequiredGoogle Ads API client library
prometheus-clientrequiredPrometheus metrics exposition
Agent activity
40 hits · last 30 days
node
32
OpenAI (training)
2
Resources
gaarf-exporter — pip install gaarf-exporter · libregistry