コンテンツにジャンプ

Getting Started

GitHub

CapgoのAIアシストセットアップを使用してプラグインをインストールできます。AIツールにCapgoスキルを追加するには、以下のコマンドを実行してください。

ターミナル画面
npx skills add https://github.com/Cap-go/capgo-skills --skill capacitor-plugins

次に、以下のプロンプトを使用してください。

Use the `capacitor-plugins` skill from `Cap-go/capgo-skills` to install the `@capgo/capacitor-install-referrer` plugin in my project.

Manualセットアップを使用する場合は、以下のコマンドを実行してプラグインをインストールし、以下のプラットフォーム固有の指示に従ってください。

ターミナル画面
bun add @capgo/capacitor-install-referrer
bunx cap sync
import { InstallReferrer } from '@capgo/capacitor-install-referrer';
const result = await InstallReferrer.getReferrer();
if (result.platform === 'android') {
console.log('Install referrer:', result.referrer);
console.log('Click timestamp:', result.clickTimestampSeconds);
console.log('Install timestamp:', result.installBeginTimestampSeconds);
}
if (result.platform === 'ios') {
console.log('AdServices token:', result.attributionToken);
}

iOS で Apple の Attribution エンドポイントを取得する

セクション「iOS で Apple の Attribution エンドポイントを取得する」

Apple の Attribution エンドポイントを呼び出すには、native code に Apple のエンドポイントを渡します。 fetchAppleAttribution.

const result = await InstallReferrer.getReferrer({
fetchAppleAttribution: true,
appleAttributionRetryCount: 3,
appleAttributionRetryDelayMs: 5000,
});
// result.appleAttribution is the parsed Apple attribution response.
// See the iOS attribution page for the Apple-provided payload fields.
console.log(result.appleAttribution);

Apple は、Attribution データが有効なトークンに対して準備中の場合に、Attribution データを返します。 404 有効なトークンに対して Attribution データが準備中の場合、native プラグインは、再試行のオプションを設定して、再試行する頻度を制御します。詳細は iOS 属性 プラットフォームの詳細については。

GetReferrer() Capacitor からアプリを移行している場合は利用できます。 cap-play-install-referrer.

const result = await InstallReferrer.GetReferrer();

New code should use getReferrer().

Capacitor からアプリを移行している場合は利用できます。

Capacitor からアプリを移行している場合は利用できます。

Capacitor からアプリを移行している場合は利用できます。 Capacitor からアプリを移行している場合は利用できます。 Capacitor からアプリを移行している場合は利用できます。 使用@capgo/capacitor-install-referrer 使用@capgo/capacitor-install-referrer Capgo プラグイン ディレクトリ Capgo プラグイン フロー Capacitor プラグイン(Capgo) for the implementation detail in Capacitor Plugins by Capgo, プラグインの追加または更新 Ionic Enterprise プラグインの代替 編集 前へ