메인 콘텐츠로 건너뛰기

설치 참조자 Capacitor 플러그인

Capacitor에서 Google Play 설치 참조 데이터 및 Apple AdServices Attribution을 읽습니다.

설치

bun add @capgo/capacitor-install-referrer bunx cap sync
npm, pnpm 또는 yarn
  • npm install @capgo/capacitor-install-referrer
  • pnpm add @capgo/capacitor-install-referrer
  • yarn add @capgo/capacitor-install-referrer

설명서

Capacitor에서 Install Referrer를 사용하는 방법

장치에서 테스트

Capgo 앱을 다운로드한 후 QR code를 스캔하세요.

설치 참조 플러그인 미리보기 QR code

@capgo/capacitor-install-referrer 사용

@capgo/capacitor-install-referrer Capacitor 앱에서 설치 인식 신호를 읽습니다.

Android와 Apple AdServices 인앱 구매 신호를 iOS에서 사용할 수 있는 하나의 API에서 Google Play 설치 참조 데이터를 사용하세요.

설치

bun add @capgo/capacitor-install-referrer
bunx cap sync

이 플러그인이 노출하는 것

  • getReferrer Android 또는 iOS에서 설치 인식 세부 정보를 반환합니다.
  • GetReferrer deprecated compatibility alias로 이전하기 위한 마이그레이션을 위한 compatibility alias입니다. cap-play-install-referrer.
  • Android에서 Play referrer 문자열, 클릭 시간, 설치 시간 및 즉시 앱 플래그를 반환합니다.
  • iOS는 AdServices attribution 토큰을 반환하고 Apple의 attribution 페이로드를 선택적으로 가져올 수 있습니다.

예시 사용

import { InstallReferrer } from '@capgo/capacitor-install-referrer';

const result = await InstallReferrer.getReferrer();

if (result.platform === 'android') {
  console.log(result.referrer);
}

if (result.platform === 'ios') {
  console.log(result.attributionToken);
}

애플 Attribution 페이로드

const result = await InstallReferrer.getReferrer({
  fetchAppleAttribution: true,
  appleAttributionRetryCount: 3,
  appleAttributionRetryDelayMs: 5000,
});

console.log(result.appleAttribution);

플랫폼 설명

안드로이드는 Google Play Install Referrer 서비스를 사용하고 실제 리퍼러 데이터를 얻기 위해 Play Store 설치가 필요합니다. iOS는 Apple AdServices를 사용하는 이유는 Apple이 일반적인 앱 스토어 설치 리퍼러 동등체를 제공하지 않기 때문입니다.

전체 참조

capgo의 @capgo/capacitor-install-referrer를 사용하는 경우 계속 진행하세요.

__CAPGO_KEEP_0__의 @__CAPGO_KEEP_0__/__CAPGO_KEEP_1__-install-referrer를 사용하는 경우 capgo의 @capgo/capacitor-install-referrer를 사용하는 경우 native 플러그인 작업을 계획하기 위해, 그것을 연결하세요. @capgo/capacitor-install-referrer capgo/capacitor-install-referrer의 implementation detail에 대해 시작하기 Getting Started의 implementation detail에 대해 Capgo 플러그인 디렉토리 Capgo 플러그인 디렉토리의 product workflow에 대해 Capacitor Capgo 플러그인 Capacitor Plugins by Capgo의 implementation detail에 대해, 그리고 플러그인 추가 또는 업데이트 Adding or Updating Plugins의 implementation detail에 대해.

FAQ

설치 리퍼러 플러그인 FAQ

Capacitor 앱에서 Install Referrer 플러그인을 어떻게 설치할 수 있나요?

Run "bun" add @capgo/capacitor-install-referrer" (or "npm install @capgo/capacitor-install-referrer"), then run "bunx cap sync" so the iOS and Android projects pick up the native code. Import it from "@capgo/capacitor-install-referrer" in your app code.

@capgo/capacitor-install-referrer는 React, Vue 및 Angular와 함께 작동합니까?

Yes. Install Referrer is a Capacitor package, so it works with any web framework that runs inside Capacitor, including Ionic, React, Vue, Angular, Svelte and plain JavaScript.

Which Capacitor version does @capgo/capacitor-install-referrer support?

Capgo plugins follow Capacitor's major version: use the plugin major version that matches your Capacitor major version (for example plugin v8 with Capacitor 8). The compatibility table in the GitHub README lists the maintained versions.

@capgo/capacitor-install-referrer은 무료이고 오픈 소스인가?

Yes. The source code is public on GitHub at https://github.com/Cap-go/capacitor-install-referrer/ and the package is free to install from npm. Bug reports and pull requests are welcome.

애플리케이션 스토어 리뷰 없이 Install Referrer를 사용하는 code를 업데이트할 수 있나요?

Installing or upgrading the plugin changes native code, so it needs a new store build. After that, JavaScript, HTML and CSS changes that call the plugin can ship instantly with Capgo live updates.

설치 참조자 변경을 앱 검토 대기 없이 배포합니다.

플러그인을 스토어 빌드에 추가한 후 Capgo 라이브 업데이트 통해 사용자에게 몇 분 내에 자바스크립트, HTML 및 CSS 변경 사항을 푸시합니다.

Capgo