redacto_consent_sdk
Flutter SDK for Redacto consent management.
Installation
flutter pub add redacto_consent_sdk
RedactoNoticeConsent
showModalBottomSheet(
context: context,
isDismissible: false,
builder: (_) => RedactoNoticeConsent(
noticeId: noticeUuid,
accessToken: accessToken,
refreshToken: refreshToken,
blockUI: true,
onAccept: () {},
onDecline: () {},
onError: (error) {},
),
);
Main properties
noticeId(required): notice UUIDaccessToken(required): JWT access tokenrefreshToken(required): refresh token for parity with mobile SDKsbaseUrl: override API base URL (defaults tohttps://api.redacto.io/consent)validateAgainst:ValidateAgainst.allorValidateAgainst.requiredincludeFullyConsentedData: include already-consented data in payloadonAccept/onDecline: user action callbacksonError: API or rendering error callback
RedactoNoticeConsentInline
Inline consent component for embedding consent state into existing screens.
RedactoNoticeConsentInline(
noticeId: noticeUuid,
accessToken: accessToken,
onAccept: () {},
onValidationChange: (isValid) {},
)
Development
cd packages/consent-sdk-flutter
flutter pub get
dart analyze
flutter test