Skip to main content

Trektik Analytics Server SDK for Python

Project description

trektik

Trektik Analytics Server SDK for Python.

Install

pip install trektik

Usage

from trektik import Trektik, TrektikConfig

trektik = Trektik(TrektikConfig(api_key="pk_..."))

trektik.track("user_123", "page_view", {"page": "/home"})
trektik.identify("user_123", {"name": "Alex", "plan": "pro"})
trektik.track_revenue("user_123", 49.99, {"currency": "USD"})

# Feature flags
trektik.set_project_id(1)
value = trektik.get_flag("user_123", "new-checkout")

# Async
await trektik.track_async("user_123", "page_view")
await trektik.flush_async()

# Shutdown
trektik.shutdown()

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

trektik-0.1.0.tar.gz (7.8 kB view details)

Uploaded Source

Built Distribution

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

trektik-0.1.0-py3-none-any.whl (5.0 kB view details)

Uploaded Python 3

File details

Details for the file trektik-0.1.0.tar.gz.

File metadata

  • Download URL: trektik-0.1.0.tar.gz
  • Upload date:
  • Size: 7.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for trektik-0.1.0.tar.gz
Algorithm Hash digest
SHA256 4b901ff4898abededb61d1909dc99e89c9dc3d0fe54731c45af7570fef63401e
MD5 daea1a6c57799b5af9fd2009f04cf564
BLAKE2b-256 dbf975d89b23f0edbd544218e1904072f735dc5d06b8b448862de61279518d8f

See more details on using hashes here.

File details

Details for the file trektik-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: trektik-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 5.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for trektik-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 265b42b517e86038cfeddb4fe8e222e370209c3a27c5d645e50b63bd10659d0c
MD5 b77ee5b0bb034be755abb5a2685b073e
BLAKE2b-256 91cfbba350eb8903f3b94ff17938cf307369124f49b87c75484b51550b4b3e18

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