Skip to main content

No project description provided

Project description

[CircleCI]



AMPLITUDE-PYTHON


Python API for Amplitude Analytics Logging - https://amplitude.com

This API is a simple (unofficial) wrapper for the Amplitude HTTP API


1. Install amplitude-python

Potential preparation before installing: create and activate virtualenv or conda environment

1.1 Install from pypi with conda or pip

pip install amplitude-python

1.2 Install from github

$ git clone https://github.com/atveit/amplitude-python.git
$ cd amplitude-python
$ python setup.py instal


2. Logging to Amplitude with amplitude-python

Recommend having a look at Amplitude HTTP API Documentation before start logging.

import amplitude

# initialize amplitude logger
amplitude_logger = amplitude.AmplitudeLogger(api_key = "SOME_API_KEY_STRING")

# example event
event_args = {"device_id":"somedeviceid", "event_type":"justtesting",
"event_properties":{"property1":"somevalue", "propertyN":"anothervalue"}
event = amplitude_logger.create_event(**event_args)

# send event to amplitude
amplitude_logger.log_event(event)


3. Test amplitude-python module

python setup.py test

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

amplitude-python-0.13.tar.gz (3.3 kB view details)

Uploaded Source

File details

Details for the file amplitude-python-0.13.tar.gz.

File metadata

File hashes

Hashes for amplitude-python-0.13.tar.gz
Algorithm Hash digest
SHA256 2e8b5259ce59fa3bc6893574cc6c1110a86d03be3892e78c0d1e003b73cac712
MD5 2c2fe8cd0329ebe046f058a5367c89ff
BLAKE2b-256 4b89ba458bac542db11f8a4314149c6f3dfb0ba40b0a4b5b3121244f7ccd9aef

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