InvergeDocs
PHPAPI reference

Events

Events in the PHP SDK.

// access
$nexus->events()

Events

class
class Inverge\Nexus\Resource\Events

Product analytics — capture events, optionally correlated to a person/session.

View source

__construct

constructor
function __construct(Inverge\Nexus\NexusClient $client)

Parameters

Prop

Type

View source

capture()

method
function capture(string $name, array $properties = [], array $context = []): int

Capture a single event.

Parameters

Prop

Type

Returns int — number of events written

View source

batch()

method
function batch(array $events, array $context = []): int

Capture a batch of events sharing one identity/context. Each event: ['name' => string, 'properties' => array, 'timestamp' => string].

Parameters

Prop

Type

Returns int

View source

On this page