Skip to content

feat(MSK-93): implement TCF Vendor and Debug APIs#86

Merged
pleberre merged 1 commit intodevelopfrom
msk-93-tcf-debug-apis
Feb 16, 2026
Merged

feat(MSK-93): implement TCF Vendor and Debug APIs#86
pleberre merged 1 commit intodevelopfrom
msk-93-tcf-debug-apis

Conversation

@pleberre
Copy link
Contributor

@pleberre pleberre commented Feb 16, 2026

MSK-93: TCF Vendor and Debug APIs Implementation

Closes https://linear.app/axeptio/issue/MSK-93

What's implemented

iOS TCF Vendor Consent APIs ✅

  • getVendorConsents() - Get all vendor consent data
  • getConsentedVendors() - Get list of consented vendors
  • getRefusedVendors() - Get list of refused vendors
  • isVendorConsented(vendorId) - Check specific vendor consent

Android Debug Information API ✅

  • getConsentDebugInfo(preferenceKey?) - Get comprehensive consent debug data

Features

  • ✅ Platform-specific APIs with proper error handling
  • ✅ TypeScript definitions with JSDoc comments
  • ✅ Comprehensive test coverage: 95.76% (↑ from 95.14%)
  • ✅ 8 new tests for platform-specific behavior (97 total tests)
  • ✅ Backward compatible (no breaking changes)

Test Results

Test Suites: 5 passed, 5 total
Tests:       1 skipped, 97 passed, 98 total
Coverage:    95.76% statements, 94.73% branches, 91.83% functions, 95.72% lines

Technical Details

  • iOS methods wrapped with try-catch for proper error handling
  • Android debug info supports flexible type conversion
  • Platform checks prevent calling iOS-only methods on Android and vice versa
  • All methods return Promises for async consistency

Documentation

  • JSDoc comments on all new methods
  • Platform annotations (@platform iOS/Android)
  • Clear error messages for unsupported platforms

Ready for review

Requires native SDK versions:

  • iOS SDK ≥ 2.1.4
  • Android SDK ≥ 2.1.2

Summary by cubic

Adds iOS TCF vendor consent APIs and an Android consent debug API to the React Native SDK to match native 2.1.x capabilities. Supports MSK-93 and keeps the API backward compatible.

  • New Features

    • iOS: getVendorConsents, getConsentedVendors, getRefusedVendors, isVendorConsented (promise-based with error handling).
    • Android: getConsentDebugInfo(preferenceKey?) returns a typed map for troubleshooting.
    • Platform guards reject unsupported calls; TypeScript definitions with JSDoc included.
    • Tests: +8 new platform-specific tests; coverage at 95.76%.
  • Migration

    • Requires native SDKs: iOS ≥ 2.1.4, Android ≥ 2.1.2.
    • No breaking changes; existing integrations continue to work.

Written for commit 45ea010. Summary will update on new commits.

iOS TCF Vendor Consent APIs:
- getVendorConsents() - Get all vendor consent data
- getConsentedVendors() - Get list of consented vendors
- getRefusedVendors() - Get list of refused vendors
- isVendorConsented(vendorId) - Check specific vendor consent

Android Debug Information API:
- getConsentDebugInfo(preferenceKey?) - Get comprehensive debug data

Features:
- Platform-specific APIs with proper error handling
- TypeScript definitions with JSDoc comments
- Comprehensive test coverage (95.76%)
- 8 new tests for platform-specific behavior

Breaking Changes: None (backward compatible additions)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@linear
Copy link

linear bot commented Feb 16, 2026

Copy link

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cubic analysis

No issues found across 4 files

Linked issue analysis

Linked issue: MSK-93: Upgrade React Native SDK to latest iOS and Android with new TCF & Debug APIs

Status Acceptance criteria Notes
Native SDK versions updated successfully (iOS ≥2.1.4, Android ≥2.1.2, RN 2.1.0) No Podfile/Gradle/lockfile changes in diffs
widgetType parameter handled (set to PRODUCTION in wrapper) No code in diffs showing widgetType defaulting to PRODUCTION
Add iOS getVendorConsents() bridge method Added getVendorConsents implementation in Swift
Add iOS getConsentedVendors() bridge method Added getConsentedVendors implementation in Swift
Add iOS getRefusedVendors() bridge method Added getRefusedVendors implementation in Swift
Add iOS isVendorConsented(vendorId) bridge method Added isVendorConsented implementation in Swift
Enhanced debug API with parsed vendor data / TCFVendorConsentParser (iOS) No TCFVendorConsentParser or parsed-vendor debug code added
Add Android getConsentDebugInfo(preferenceKey?) bridge method Added getConsentDebugInfo Kotlin bridge with type mapping
⚠️ Android debug API returns Map combining SharedPreferences + consent file data Wrapper converts native map to WritableMap, but underlying merge not shown
⚠️ Android debug API reads datastore/event_saved.pb protobuf files JS bridge calls native SDK; pb reading would be in native SDK (not shown)
⚠️ Add TypeScript interface definitions (interface AxeptioSDK) in src/index.tsx JS methods added, but explicit interface declaration not present in diff
Expose iOS TCF methods from JS wrapper (src/index.tsx) JS wrapper includes getVendorConsents/getConsentedVendors/etc with platform guards
Expose Android getConsentDebugInfo from JS wrapper getConsentDebugInfo method added with Platform check and native call
Platform checks prevent calling iOS-only methods on Android and vice versa Platform.OS checks present before calling native methods
Bridge methods have error handling and type conversion iOS uses do/catch reject; Android maps native types to WritableMap
Tests for iOS TCF vendor consent APIs Unit tests added exercising iOS TCF methods with platform mocks
Tests for Android consent debug info API Unit tests added for Android getConsentDebugInfo behavior
Verify type conversion and error handling in bridge methods via tests Tests assert native calls and platform rejection behavior
⚠️ Ensure backward compatibility with existing implementations PR claims backward compatibility but no explicit compatibility tests or migration notes
Test with both debug and release builds No CI/build config or tests for debug vs release shown
Tests passing with ≥95% coverage PR summary and test results state coverage 95.76%
Example app demonstrates new functionality No example app changes or demo code included in diffs
Documentation updated with new API usage No docs, README, or CHANGELOG updates in diffs
Release notes prepared for next version No release notes or changelog entry present in diffs

@pleberre pleberre merged commit 3e713f8 into develop Feb 16, 2026
4 checks passed
@pleberre pleberre deleted the msk-93-tcf-debug-apis branch February 16, 2026 16:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant