Getting Started
설치 단계와 이 플러그인의 전체 마크다운 가이드를 포함한 설정 지시를 복사하세요.
Set up this Capacitor plugin in the project.
Use the package manager already used by the project.
Install these package(s): `@capgo/capacitor-rudderstack`
Run the required Capacitor sync/update step after installation.
Read this markdown guide for the full setup steps: https://raw.githubusercontent.com/Cap-go/website/refs/heads/main/apps/docs/src/content/docs/docs/plugins/rudderstack/getting-started.mdx
Use that guide for platform-specific steps, native file edits, permissions, config changes, imports, and usage setup.
If that guide references other docs pages, read them too.
설치
설치란bun add @capgo/capacitor-rudderstackbunx cap syncimport
import란import { nativePlugin } from '@capgo/capacitor-rudderstack';API 개요
API란initialize
__CAPGO_KEEP_2__Initializes the RudderStack client.
The method keeps the Cordova signature, so the second argument may be either a config object or a Rudder options object.
import { nativePlugin } from '@capgo/capacitor-rudderstack';
await nativePlugin.initialize('value');identify
identifySends an identify call for the provided user id.
import { nativePlugin } from '@capgo/capacitor-rudderstack';
await nativePlugin.identify('value');group
groupSends a group call for the provided group id.
import { nativePlugin } from '@capgo/capacitor-rudderstack';
await nativePlugin.group('value');track
trackSends a track call for the provided event name.
import { nativePlugin } from '@capgo/capacitor-rudderstack';
await nativePlugin.track('value');screen
스크린 섹션스크린 이름을 제공하여 스크린 콜을 보냅니다.
import { nativePlugin } from '@capgo/capacitor-rudderstack';
await nativePlugin.screen('value');alias
alias 섹션현재 사용자를 새로운 식별자로.alias합니다.
import { nativePlugin } from '@capgo/capacitor-rudderstack';
await nativePlugin.alias('value');reset
reset 섹션현재 RudderStack 식별자 상태를 초기화합니다.
import { nativePlugin } from '@capgo/capacitor-rudderstack';
await nativePlugin.reset();flush
flush 섹션임시 저장된 이벤트를 즉시 플러시합니다.
import { nativePlugin } from '@capgo/capacitor-rudderstack';
await nativePlugin.flush();putDeviceToken
__CAPGO_KEEP_0____CAPGO_KEEP_1__
import { nativePlugin } from '@capgo/capacitor-rudderstack';
await nativePlugin.putDeviceToken('value');setAdvertisingId
__CAPGO_KEEP_3____CAPGO_KEEP_4__
import { nativePlugin } from '@capgo/capacitor-rudderstack';
await nativePlugin.setAdvertisingId('value');putAdvertisingId
__CAPGO_KEEP_6____CAPGO_KEEP_7__
import { nativePlugin } from '@capgo/capacitor-rudderstack';
await nativePlugin.putAdvertisingId('value');setAnonymousId
__CAPGO_KEEP_9____CAPGO_KEEP_10__
import { nativePlugin } from '@capgo/capacitor-rudderstack';
await nativePlugin.setAnonymousId('value');putAnonymousId
Section titled “putAnonymousId”개인 식별자 값을 설정합니다.
import { nativePlugin } from '@capgo/capacitor-rudderstack';
await nativePlugin.putAnonymousId('value');optOut
Section titled “optOut”RudderStack 추적을 비활성화합니다.
import { nativePlugin } from '@capgo/capacitor-rudderstack';
await nativePlugin.optOut(true);Type Reference
Section titled “Type Reference”RudderConfiguration
Section titled “RudderConfiguration”RudderStack 네이티브 SDK의 지원되는 구성 키입니다.
export interface RudderConfiguration { /** * RudderStack data plane URL. */ dataPlaneUrl?: string;
/** * Number of events to batch before a flush. */ flushQueueSize?: number;
/** * Database row threshold that triggers pruning on Android and iOS. */ dbCountThreshold?: number;
/** * Server config refresh interval in hours. */ configRefreshInterval?: number;
/** * RudderStack log verbosity. */ logLevel?: RudderLogLevelValue;
/** * Sleep timeout / sleep count used by the native SDK. */ sleepTimeOut?: number;
/** * Android only. Lets the native SDK collect the advertising identifier automatically. */ autoCollectAdvertId?: boolean;
/** * Tracks `Application Installed`, `Application Updated`, and `Application Opened` automatically. */ trackLifecycleEvents?: boolean;
/** * RudderStack control plane URL. */ controlPlaneUrl?: string;
/** * Enables automatic screen tracking where supported by the native SDK. */ recordScreenViews?: boolean;
/** * Ignored in this Capacitor port. * * The Cordova SDK uses this field to bootstrap native destination factories from companion plugins. * Those extension packages are not implemented in this first Capacitor release. */ factories?: any[];}RudderOptions
Section titled “RudderOptions”RudderStack per-call 옵션.
export interface RudderOptions { /** * External identifiers forwarded with the event. */ externalIds?: Record<string, string>;
/** * Destination enablement flags keyed by integration name. */ integrations?: Record<string, boolean>;}RudderTraits
RudderTraits속성 identify Traits payload accepted by group.
export type RudderTraits = Record<string, any>;RudderProperties
복사RudderProperties track 속성 screen.
export type RudderProperties = Record<string, any>;PluginVersionResult
and복사
export interface PluginVersionResult { /** * Version identifier returned by the platform implementation. */ version: string;}RudderLogLevelValue
RudderLogLevelValue이동 편의를 위해 제공되는 RudderStack 로그 수준 값.
export type RudderLogLevelValue = 0 | 1 | 2 | 3 | 4 | 5;진실의 원천
진실의 원천이 플러그인의 src/definitions.ts. upstream에서 API이 변경될 때마다 다시 동기화 하세요.
Getting Started에서 계속하기
Getting Started에서 계속하기Capgo CLI를 사용하는 경우 Getting Started API 대시보드와 운영을 계획하고 연결하기 위해 Using @capgo/capacitor-rudderstack capgo의 원시 기능을 사용하는 경우 Using @capgo/capacitor-rudderstack API 개요 API의 구현 세부 사항에 대해 __CAPGO_KEEP_0__ 소개 __CAPGO_KEEP_0__의 구현 세부 사항에 대해 API 키 API의 구현 세부 사항에 대해 및 __CAPGO_KEEP_0__ 장치 __CAPGO_KEEP_0__의 구현 세부 사항에 대해