Skip to main content

Umami Analytics Client for Python

Project description

Umami Analytics Client for Python

Analytics client for privacy-preserving, open source Umami platform based on httpx and pydantic.

Partially implemented

Implemented endpoints:

  • POST /api/auth/login as login_async and login
  • POST /api/auth/verify as verify_token_async and verify_token
  • GET /api/websites as websites_async and websites
  • POST /api/send as new_event_async and new_event

See the API documentation for the remaining endpoints to be added (PRs welcome).

Installation

Just pip install umami-analytics

Usage

import umami

umami.set_url_base(analytics_server_url)
login = umami.login(user, password)

websites = umami.websites()

site = [w for w in websites if w.domain == site_domain][0]

event_resp = umami.new_event(
    website_id=site.id,
    event_name='Umami-Test',
    title='Umami-Test',
    hostname=site.domain,
    url='/users/actions',
    custom_data={'client': 'umami-tester-v1'},
    referrer='https://some_url')

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

umami_analytics-0.1.4.tar.gz (4.5 kB view details)

Uploaded Source

Built Distribution

umami_analytics-0.1.4-py3-none-any.whl (5.0 kB view details)

Uploaded Python 3

File details

Details for the file umami_analytics-0.1.4.tar.gz.

File metadata

  • Download URL: umami_analytics-0.1.4.tar.gz
  • Upload date:
  • Size: 4.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-httpx/0.26.0

File hashes

Hashes for umami_analytics-0.1.4.tar.gz
Algorithm Hash digest
SHA256 5b3e29a20d7a1fbab0037570adef28dec22221596afc74883f1a924bd9cecb07
MD5 9274a1031047e800fe75761473d51e3d
BLAKE2b-256 32ef21a84f6c455da105c3a5470097836f66bf3118e682de423f92da1ec7ecff

See more details on using hashes here.

File details

Details for the file umami_analytics-0.1.4-py3-none-any.whl.

File metadata

File hashes

Hashes for umami_analytics-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 92e232748dfa01aa7be258267ea09b95816b7831b5f1de0da20f94d5fb11c45c
MD5 0a78b715844ee2582de44d81d7ac5a82
BLAKE2b-256 03bbd5e191131129ef34efe901f986d0d5fa403ad1a86e96513dfd23a38be11a

See more details on using hashes here.

Supported by

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