minube/amplitude-php

Amplitude SDK for PHP - Use Amplitude in your PHP project

Installs: 54 572

Dependents: 0

Suggesters: 0

Security: 0

Stars: 14

Watchers: 6

Forks: 12

Open Issues: 1

pkg:composer/minube/amplitude-php

2.0 2018-11-13 11:29 UTC

This package is not auto-updated.

Last update: 2025-09-28 01:07:29 UTC


README

How to use it

$apiKey = 123456;
$amplitudeClient = new \Amplitude\AmplitudeClient($apiKey);

$amplitudeEvent = new \Amplitude\AmplitudeEvent();

// For user properties
$amplitudeEvent->set('city_id', 123)
    ->set('country_id', 34);
    
// For event properties
$amplitudeEvent->addToEventProperties('revenue', 12.34);

$response = $amplitudeClient->track($amplitudeEvent);