@capgo/capacitor-rudderstack
Overview
Section titled “Overview”Initialize the RudderStack native SDK once, then identify, track, and screen from your shared TypeScript layer. The plugin forwards events to iOS and Android native pipelines with flushing, advertising ID hooks, and anonymous ID control for privacy conscious rollouts.
Typical fits: product analytics, funnel tracking, experiment assignment, and customer data platform routing without maintaining separate native RudderStack integrations.
Platform support
Section titled “Platform support”| Platform | Support | Notes |
|---|---|---|
| iOS | Yes | Native RudderStack iOS SDK |
| Android | Yes | Native RudderStack Android SDK |
| Web | See repo | Use RudderStack web SDK alongside Capacitor web builds |
Core Capabilities
Section titled “Core Capabilities”initialize- Initializes the RudderStack client.identify- Sends an identify call for the provided user id.group- Sends a group call for the provided group id.track- Sends a track call for the provided event name.
Public API
Section titled “Public API”| Method | Description |
|---|---|
initialize | Initializes the RudderStack client. |
identify | Sends an identify call for the provided user id. |
group | Sends a group call for the provided group id. |
track | Sends a track call for the provided event name. |
screen | Sends a screen call for the provided screen name. |
alias | Aliases the current user to a new identifier. |
reset | Resets the current RudderStack identity state. |
flush | Flushes queued events immediately. |
putDeviceToken | Sets the push token that RudderStack forwards to supported destinations. |
setAdvertisingId | See the source definitions for current behavior. |
putAdvertisingId | Sets a custom advertising id value. |
setAnonymousId | See the source definitions for current behavior. |
putAnonymousId | Sets a custom anonymous id value. |
optOut | Toggles RudderStack tracking opt-out. |
getPluginVersion | Returns the plugin version marker from the native implementation. |
Source Of Truth
Section titled “Source Of Truth”This reference is synced from src/definitions.ts in capacitor-rudderstack.
Keep going from @capgo/capacitor-rudderstack
Section titled “Keep going from @capgo/capacitor-rudderstack”If you are using @capgo/capacitor-rudderstack to plan native plugin work, connect it with Using @capgo/capacitor-rudderstack for the native capability in Using @capgo/capacitor-rudderstack, Capgo Plugin Directory for the product workflow in Capgo Plugin Directory, Capacitor Plugins by Capgo for the implementation detail in Capacitor Plugins by Capgo, Adding or Updating Plugins for the implementation detail in Adding or Updating Plugins, and Ionic Enterprise Plugin Alternatives for the product workflow in Ionic Enterprise Plugin Alternatives.