PHPAPI reference
In-app messages
In-app messages in the PHP SDK.
// access
$nexus->inApp()InApp
classclass Inverge\Nexus\Resource\InAppIn-app messages — OneSignal-style modals & banners shown inside your app. Messages are composed in the console; this resource fetches the ones a user is eligible to see (for server-driven / headless UIs) and records impressions and clicks. Triggers + frequency caps are applied by the client SDK.
View source__construct
constructorfunction __construct(Inverge\Nexus\NexusClient $client)Parameters
Prop
Type
active()
methodfunction active(array $options = []): arrayThe active in-app messages for the tenant (the SDK evaluates triggers + frequency locally).
Parameters
Prop
Type
Returns array<mixed> — list of messages
trackEvent()
methodfunction trackEvent(string $messageId, string $type, array $options = []): arrayRecord an in-app message event: impression, click, or dismiss.
Parameters
Prop
Type
Returns array<mixed>
impression()
methodfunction impression(string $messageId, array $options = []): arrayParameters
Prop
Type
Returns array<mixed>
click()
methodfunction click(string $messageId, string $buttonId, array $options = []): arrayParameters
Prop
Type
Returns array<mixed>
dismiss()
methodfunction dismiss(string $messageId, array $options = []): arrayParameters
Prop
Type
Returns array<mixed>
