appsprint-react-native 1.1.11 → 1.1.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -6
- package/android/libs/appsprint-sdk.aar +0 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -157,20 +157,21 @@ Once an install registers, attribution is cached on the native side. You can rea
|
|
|
157
157
|
```tsx
|
|
158
158
|
const attribution = await AppSprint.getAttribution();
|
|
159
159
|
const appsprintId = await AppSprint.getAppSprintId();
|
|
160
|
-
const params = await AppSprint.getAttributionParams();
|
|
161
160
|
```
|
|
162
161
|
|
|
163
162
|
`AttributionResult.source` is one of `apple_ads`, `tracking_link`, or `organic`.
|
|
164
163
|
|
|
165
|
-
###
|
|
164
|
+
### Link RevenueCat or Superwall
|
|
166
165
|
|
|
167
|
-
`getAttributionParams()`
|
|
166
|
+
For revenue webhooks, set only the `appsprintId` subscriber/user attribute. Do not forward the full `getAttributionParams()` map to RevenueCat; it contains attribution details such as `source` and `isAttributed` for diagnostics and custom integrations.
|
|
168
167
|
|
|
169
168
|
```tsx
|
|
170
169
|
import Purchases from "react-native-purchases";
|
|
171
170
|
|
|
172
|
-
const
|
|
173
|
-
|
|
171
|
+
const appsprintId = await AppSprint.getAppSprintId();
|
|
172
|
+
if (appsprintId) {
|
|
173
|
+
await Purchases.setAttributes({ appsprintId });
|
|
174
|
+
}
|
|
174
175
|
```
|
|
175
176
|
|
|
176
177
|
### Manual refresh
|
|
@@ -252,7 +253,7 @@ import { AppSprint } from "appsprint-react-native";
|
|
|
252
253
|
- `refreshAttribution()` fetches the latest attribution from the backend.
|
|
253
254
|
- `setCustomerUserId(userId)` updates the customer user ID.
|
|
254
255
|
- `getAttribution()` returns the cached attribution.
|
|
255
|
-
- `getAttributionParams()` returns
|
|
256
|
+
- `getAttributionParams()` returns a flat attribution/debug payload for custom integrations.
|
|
256
257
|
- `getAppSprintId()` returns the SDK install identifier.
|
|
257
258
|
- `enableAppleAdsAttribution()` re-enables Apple Ads at runtime on iOS; returns `false` on Android.
|
|
258
259
|
- `sendTestEvent()` posts a diagnostic event and resolves to `{ success, message }`.
|
|
Binary file
|