{"_id":"@2tagin/expo-sdk","_rev":"24-7d54c506a6577dad71375270567d6962","name":"@2tagin/expo-sdk","dist-tags":{"latest":"1.1.3"},"versions":{"1.0.5":{"name":"@2tagin/expo-sdk","version":"1.0.5","keywords":["react-native","sdk","analytics","utm","2tagin"],"author":{"name":"SRCU"},"license":"MIT","_id":"@2tagin/expo-sdk@1.0.5","maintainers":[{"name":"2tagin","email":"2tagin.app@gmail.com"}],"dist":{"shasum":"e6c4a8a8bb6cd848b97adeaba7dc727f3cd3dbc4","tarball":"https://registry.npmjs.org/@2tagin/expo-sdk/-/expo-sdk-1.0.5.tgz","fileCount":6,"integrity":"sha512-04Txv1MNwGlrJfLou9cUdAHDPoChmAf7O04TAgtijPF/VsF9oLy+6BB9gd1JxDn2HCQMnAISiN9Dwr9kHfKS0w==","signatures":[{"sig":"MEUCIEEMayHtGvWfCjpbsYXLDCVAR1PqsipBKH89G6MSy+rKAiEAl+eRPYbUNfAqa/PKNXMkXospmo4THozX1/h8AapMMzw=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":13167},"main":"src/index.js","types":"index.d.ts","engines":{"npm":">=7","node":">=14"},"gitHead":"a846e8bcfdb9c71ee8947854dd4542e64d648d91","scripts":{"test":"echo \"No tests yet\" && exit 0","prepare":"echo 'Ready to publish'"},"_npmUser":{"name":"2tagin","email":"2tagin.app@gmail.com"},"deprecated":"Version no longer supported","_npmVersion":"10.9.2","description":"React Native SDK for tracking events via 2tag.in","directories":{},"_nodeVersion":"20.18.0","dependencies":{"jwt-decode":"^4.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"prettier":"^3.0.0"},"peerDependencies":{"expo-jwt":"*","expo-linking":"*","react-native":">=0.63.0","expo-application":"*","@react-native-community/netinfo":">=9.5.0","@react-native-async-storage/async-storage":">=1.17.11"},"_npmOperationalInternal":{"tmp":"tmp/expo-sdk_1.0.5_1748348051659_0.9839344454577503","host":"s3://npm-registry-packages-npm-production"}},"1.0.6":{"name":"@2tagin/expo-sdk","version":"1.0.6","keywords":["react-native","sdk","analytics","utm","2tagin"],"author":{"name":"SRCU"},"license":"MIT","_id":"@2tagin/expo-sdk@1.0.6","maintainers":[{"name":"2tagin","email":"2tagin.app@gmail.com"}],"dist":{"shasum":"8324735a7163769bd500d0b620abd02d9cbed55d","tarball":"https://registry.npmjs.org/@2tagin/expo-sdk/-/expo-sdk-1.0.6.tgz","fileCount":6,"integrity":"sha512-6XRGuGQdUVSkqp88mUzTNBMwjvFjxWjvZH6HfwXzMSLZsgpGToaFchd7bK+TU4FP5DzZti6hxoAJLL+Q2Y562Q==","signatures":[{"sig":"MEYCIQCoZ2kdfV2xka78InlCItzrjWr6ggWFfmS8e/TE/FA1fgIhAOvhy33bqVhLOq1Dy4C/6J80w9OqXyJmAYw9mI2ltGy7","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":13085},"main":"src/index.js","types":"index.d.ts","engines":{"npm":">=7","node":">=14"},"gitHead":"41a954123564c1b6952e6ee1d27ce3af20cdcba7","scripts":{"test":"echo \"No tests yet\" && exit 0","prepare":"echo 'Ready to publish'"},"_npmUser":{"name":"2tagin","email":"2tagin.app@gmail.com"},"deprecated":"This version is outdated. Please upgrade to 1.1.0","_npmVersion":"11.4.2","description":"React Native SDK for tracking events via 2tag.in","directories":{},"_nodeVersion":"20.18.1","dependencies":{"jwt-decode":"^4.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"prettier":"^3.0.0"},"peerDependencies":{"expo-jwt":"*","expo-linking":"*","react-native":">=0.63.0","expo-application":"*","@react-native-community/netinfo":">=9.5.0","@react-native-async-storage/async-storage":">=1.17.11"},"_npmOperationalInternal":{"tmp":"tmp/expo-sdk_1.0.6_1752185952685_0.2735691379298162","host":"s3://npm-registry-packages-npm-production"}},"1.1.0":{"name":"@2tagin/expo-sdk","version":"1.1.0","keywords":["react-native","expo","sdk","analytics","attribution","utm","2tagin"],"author":{"name":"SRCU"},"license":"MIT","_id":"@2tagin/expo-sdk@1.1.0","maintainers":[{"name":"2tagin","email":"2tagin.app@gmail.com"}],"dist":{"shasum":"e7957ab172d06830b5d11fdb8f8e10bf1f82f4c6","tarball":"https://registry.npmjs.org/@2tagin/expo-sdk/-/expo-sdk-1.1.0.tgz","fileCount":5,"integrity":"sha512-qXTh77gcaSN6Id0+7UuzwVmVW9V2BDtk07NulLsP0u1NCs9TxHus4iuKTDwwUi1uRC5hpzDX78no36ruXCrsVA==","signatures":[{"sig":"MEYCIQD1ucH/CdSMHRZB3fRCgDlcYlNptGB/WTcwnjxfbnqtiAIhALPbrlqdZlvc7yj570NcF/0Ctk0nd6G5QxEPbz7/g61g","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":85982},"main":"dist/index.js","types":"index.d.ts","engines":{"npm":">=7","node":">=14"},"gitHead":"be688fe2fe078a13427cb79e29f59107cecf4c9f","scripts":{"test":"echo \"No tests yet\" && exit 0","build":"node scripts/build.mjs","prepare":"npm run build"},"_npmUser":{"name":"2tagin","email":"2tagin.app@gmail.com"},"deprecated":"This version is outdated. Please upgrade to 1.1.1","_npmVersion":"11.4.2","description":"React Native SDK for tracking attribution and event analytics via 2tag.in","directories":{},"_nodeVersion":"20.18.1","dependencies":{"expo-jwt":"^1.8.2","jwt-decode":"^4.0.0","expo-crypto":"^14.1.5","expo-device":"^7.1.4","expo-linking":"^7.1.7","react-native":"^0.80.2","expo-cellular":"^7.1.5","expo-application":"^6.1.5","expo-file-system":"^18.1.11","expo-localization":"^16.1.6","expo-secure-store":"^14.2.3","expo-tracking-transparency":"^5.2.4","@react-native-community/netinfo":"^11.4.1","@react-native-async-storage/async-storage":"^2.2.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"esbuild":"^0.25.8","prettier":"^3.0.0","javascript-obfuscator":"^4.1.1"},"_npmOperationalInternal":{"tmp":"tmp/expo-sdk_1.1.0_1754280202678_0.626960021874873","host":"s3://npm-registry-packages-npm-production"}},"1.1.3":{"name":"@2tagin/expo-sdk","version":"1.1.3","description":"React Native SDK for tracking attribution and event analytics via 2tag.in","main":"dist/index.js","types":"index.d.ts","publishConfig":{"access":"public"},"keywords":["react-native","expo","sdk","analytics","attribution","utm","2tagin"],"author":{"name":"SRCU"},"license":"MIT","dependencies":{"@react-native-async-storage/async-storage":"^2.2.0","@react-native-community/netinfo":"^11.4.1","expo-application":"^6.1.5","expo-cellular":"^7.1.5","expo-crypto":"^14.1.5","expo-device":"^7.1.4","expo-file-system":"^18.1.11","expo-jwt":"^1.8.2","expo-linking":"^7.1.7","expo-localization":"^16.1.6","expo-secure-store":"^14.2.3","expo-tracking-transparency":"^5.2.4","jwt-decode":"^4.0.0","react-native":"^0.80.2"},"devDependencies":{"esbuild":"^0.25.8","javascript-obfuscator":"^4.1.1","prettier":"^3.0.0"},"scripts":{"build":"node scripts/build.mjs","prepare":"npm run build","test":"echo \"No tests yet\" && exit 0"},"engines":{"node":">=14","npm":">=7"},"_id":"@2tagin/expo-sdk@1.1.3","gitHead":"be688fe2fe078a13427cb79e29f59107cecf4c9f","_nodeVersion":"20.18.1","_npmVersion":"11.4.2","dist":{"integrity":"sha512-zgy/ruroCltgfV2YIEYI89YD2CTZMFZbLLRjfix0vteTd5ma55B7a/pi29LczTjk9OphcD1Jov1OrhFgJsEv7Q==","shasum":"0a5d6bb57da54f035b3b751bab38afad074427cf","tarball":"https://registry.npmjs.org/@2tagin/expo-sdk/-/expo-sdk-1.1.3.tgz","fileCount":5,"unpackedSize":85517,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIGUqLPiT0h1Icvo8EV5p2yE4+rXl6mof09V7ltJz3l3AAiBUB1omkcz99STI+mIMSfjmWNfb1sCH+lcJQWaoMIGbWQ=="}]},"_npmUser":{"name":"2tagin","email":"2tagin.app@gmail.com"},"directories":{},"maintainers":[{"name":"2tagin","email":"2tagin.app@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/expo-sdk_1.1.3_1754719336524_0.7812430396624639"},"_hasShrinkwrap":false}},"time":{"created":"2025-05-26T02:50:12.399Z","modified":"2025-08-09T06:02:16.894Z","1.0.0":"2025-05-26T02:22:58.416Z","1.0.1":"2025-05-26T02:30:31.000Z","1.0.2":"2025-05-26T02:37:27.039Z","1.0.3":"2025-05-26T02:50:12.685Z","1.0.4":"2025-05-26T09:19:45.749Z","1.0.5":"2025-05-27T12:14:11.838Z","1.0.6":"2025-07-10T22:19:12.866Z","1.1.0":"2025-08-04T04:03:22.851Z","1.1.1":"2025-08-06T06:14:31.581Z","1.1.2":"2025-08-07T13:32:53.464Z","1.1.3":"2025-08-09T06:02:16.685Z"},"author":{"name":"SRCU"},"license":"MIT","keywords":["react-native","expo","sdk","analytics","attribution","utm","2tagin"],"description":"React Native SDK for tracking attribution and event analytics via 2tag.in","maintainers":[{"name":"2tagin","email":"2tagin.app@gmail.com"}],"readme":"# 2tag.in React Native SDK\n\nA secure, production-ready attribution and analytics SDK for React Native (Expo-compatible), supporting deep links, install referrer attribution, and event deduplication for both Android and iOS.\n\n## Features\n\n- Attribution via deep link and Play Store referrer (iOS & Android)\n- Event queuing and retry with exponential backoff\n- Visit and action events tracking with deduplication\n- Secure JWT signing using client secret\n- Device and network info collection (optional)\n- ATT / GAID / IDFA support\n- Mutex-based concurrency safety\n- Offline queue flush on reconnection\n\n## Installation\n\n```bash\nnpm install 2tagin-sdk\n# or\nyarn add 2tagin-sdk\n```\n\n## Peer Dependencies\nEnsure the following peer dependencies are installed:\n\n- `@react-native-async-storage/async-storage`\n- `@react-native-community/netinfo`\n- `expo-application`\n- `expo-device`\n- `expo-crypto`\n- `expo-secure-store`\n- `expo-localization`\n- `expo-file-system`\n- `expo-tracking-transparency`\n- `expo-jwt`\n- `jwt-decode`\n\n## Initialization\n\n```ts\nimport { initialize2Tagin } from '2tagin-sdk';\n\nconst result = await initialize2Tagin({\n  debug: __DEV__,\n  clientId: '<your-client-id>',\n  clientSecret: '<your-client-secret>',\n  trackingEnabled: true\n});\n\nif (result.success) {\n  console.log('Attribution:', result.attributionType);\n}\n```\n\n## Sending Action\n\n```ts\nimport { sendAction } from '2tagin-sdk';\n\nawait sendAction('purchase', { revenue: 200, currency: 'INR' });\n```\n\n## API\n\n### `initialize2Tagin(options)`\nInitializes the SDK, sets up sessions and listeners.\n\n### `sendAction(act, details)`\nSends the defined action for the current session.\n\n### `getAttribution()`\nReturns current valid session if available.\n\n### `getQueueLength()`\nReturns number of pending events in queue.\n\n### `optOut()`\nDisable tracking entirely.\n\n### `reset()`\nClears all stored SDK state and listeners.\n\n### `clear2TaginEventQueue()`\nForce-clear the pending event queue.\n\n### `setSendDeviceInfo(enabled)`\nEnables/disables extended device info capture.\n\n### `cleanup()`\nFlush queue and remove all listeners (e.g., on app exit).\n\n## Notes\n- This SDK handles deduplication, retry, secure signing, and attribution automatically.\n- Use `clientSecret` securely — do not expose if using in public builds without obfuscation.\n- Designed to be compatible with Meta CAPI and Google Ads via server-side postbacks.\n\n## License\nMIT © 2tag.in","readmeFilename":"README.md"}