FAQs & Troubleshooting
Common questions and solutions for integrating Redacto CMP.
Frequently Asked Questions
General
Q: What is a consent user?
A consent user represents a data principal (an individual whose data you process) in Redacto CMP. Each consent user has a unique identifier (org_user_id) and can have associated email, phone, and metadata.
Q: What's the difference between org_user_id, email, and mobile identifiers?
org_user_id: Your system's unique identifier for the user (e.g., customer ID)email: User's email address, can be used for privacy center loginmobile: User's phone number, can be used for privacy center login
All three are stored and can be used to look up users, but org_user_id is the primary identifier.
Q: When are consent users created?
Consent users are created when:
- Consent is submitted through the SDK (the user is created automatically using the identifier in the token)
- You explicitly create them via the User Management API
Token generation does not create consent users - it only creates a JWT for authentication. This allows you to generate tokens for anonymous IDs or temporary identifiers without creating user records until consent is actually given.
Q: How long are JWT tokens valid?
- Access tokens: 60 minutes by default
- Refresh tokens: 1 day by default
Use the refresh token to obtain new tokens before expiration.
SDK
Q: Which component should I use - modal or inline?
| Use Case | Recommended Component |
|---|---|
| Initial consent on signup/login | RedactoNoticeConsent (modal) |
| Consent embedded in forms | RedactoNoticeConsentInline |
| Blocking consent requirement | RedactoNoticeConsent (modal) |
| Progressive consent collection | RedactoNoticeConsentInline |
Q: Can I show the inline component before having tokens?
Yes. RedactoNoticeConsentInline can display consent content using just org_uuid, workspace_uuid, and notice_uuid. Tokens are only required when submitting consent.
Q: How do I know if the user needs to give consent?
Use validateAgainst="all" or validateAgainst="required" in the modal component. The SDK will check the user's consent status and only show the modal if consent is needed.
Q: Can users re-submit consent?
Yes. To allow re-submission with the inline component, provide a new accessToken. The component tracks submissions per token to prevent duplicates.
User Linking
Q: When should I link users?
Link users when you identify that multiple consent records belong to the same person:
- After anonymous users register
- When merging accounts
- When consolidating multi-channel consent
Q: What happens to consent when users are linked?
The primary user retains all consent records from linked (alias) users. The alias users' consent history is associated with the primary user.
Q: Can I unlink users?
Currently, linking is a one-way operation. Contact support if you need to unlink users.
Common Issues
Component Not Rendering
Symptoms: The consent component doesn't appear on the page.
Solutions:
-
Check required props:
// Modal: requires noticeId, accessToken, refreshToken <RedactoNoticeConsent noticeId={NOTICE_UUID} // Required accessToken={token} // Required refreshToken={refreshToken} // Required onAccept={() => {}} // Required onDecline={() => {}} // Required /> // Inline: requires org_uuid, workspace_uuid, notice_uuid <RedactoNoticeConsentInline org_uuid={ORG_UUID} // Required workspace_uuid={WORKSPACE_UUID} // Required notice_uuid={NOTICE_UUID} // Required /> -
Verify tokens are valid:
// Check token expiration before rendering if (isTokenExpired(accessToken)) { await refreshTokens(); } -
Check browser console for errors:
- CORS errors: Ensure your domain is allowed
- 401 errors: Token may be invalid or expired
- 404 errors: Check UUIDs are correct
-
Verify UUIDs:
- Copy UUIDs directly from Redacto Console
- Ensure no extra whitespace
Consent Not Submitting
Symptoms: User clicks accept but consent isn't recorded.
Solutions:
-
For inline component, check all conditions:
// All must be true for auto-submit: // 1. accessToken is provided // 2. Content is loaded // 3. Required elements are checked <RedactoNoticeConsentInline accessToken={tokens.accessToken} // Must be set onValidationChange={(valid) => { console.log("Validation:", valid); // Must be true }} /> -
Handle 409 Conflict (already consented):
onError={(error) => { if (error.status === 409) { // User already consented, treat as success handleSuccess(); } }} -
Check network tab for failed requests
-
Verify token matches user:
- Token should be generated for the same user
Token Generation Failing
Symptoms: Backend returns errors when generating tokens.
Solutions:
-
Verify CMS API Key:
// Check key is set if (!process.env.CMS_API_KEY) { throw new Error("CMS API Key not configured"); } // Check header format headers: { "X-CMS-API-Key": process.env.CMS_API_KEY, // Exact header name } -
Provide at least one identifier:
// At least one required: { org_user_id: "user123", // OR email: "[email protected]", // OR mobile: "+1234567890" } -
Check UUIDs in URL:
/organisations/{org_uuid}/workspaces/{ws_uuid}/tokens/generate -
Verify API key has correct permissions
Validation Not Working
Symptoms: onValidationChange never fires or always returns false.
Solutions:
-
Ensure callback is provided:
<RedactoNoticeConsentInline onValidationChange={(isValid) => { setConsentValid(isValid); }} /> -
Check notice configuration:
- Verify required data elements are configured in the notice
- Ensure notice is published and active
-
Wait for content to load:
- Validation occurs after consent content is fetched
User Not Found After Creation
Symptoms: Can't retrieve a user immediately after creating them.
Solutions:
-
Use the correct endpoint:
GET /consent-users/by-org-user-id/{org_user_id} // Use current org_user_id -
Handle 409 on create:
- 409 means user exists, use the returned
existing_user
- 409 means user exists, use the returned
-
Check workspace scope:
- Users are scoped to workspace
- Ensure you're querying the correct workspace
Linking Fails
Symptoms: Link users API returns errors or unexpected results.
Solutions:
-
Check primary user exists:
- 404 means primary user not found
- Create the primary user first
-
Primary cannot be an alias:
- 422 means primary is already an alias
- Choose a different primary user
-
Handle conflicts:
const result = await linkUsers({...}); // Check conflicts if (result.conflicts.length > 0) { // These users are already linked to someone else console.log("Conflicts:", result.conflicts); }
Error Codes
| Status | Description | Solution |
|---|---|---|
| 400 | Bad Request | Check request body format and required fields |
| 401 | Unauthorized | Verify API key or token is valid |
| 404 | Not Found | Check UUIDs and ensure resource exists |
| 409 | Conflict | Resource already exists; use existing data |
| 422 | Unprocessable Entity | Validation failed; check field values |
| 500 | Server Error | Retry request; contact support if persistent |
Best Practices Checklist
Backend Setup
- CMS API Key stored in environment variables
- API Key never exposed to frontend
- Token generation endpoint implemented
- Token refresh endpoint implemented
- Rate limiting configured
- Error handling in place
Frontend Integration
- SDK installed and imported correctly
- UUIDs configured (org, workspace, notice)
- Token management implemented
- Error callbacks provided (
onError) - Success callbacks handle navigation/state
- Loading states shown to users
User Management
- Consent users created with explicit
org_user_id - Anonymous IDs linked after registration
- Multi-channel users consolidated
- Conflict handling implemented
Webhooks
- Endpoint uses HTTPS
- Idempotency implemented (check event_id)
- Errors logged for debugging
- Async processing for long operations
- Retry-friendly (returns 2xx on success)
Getting Help
If you're still experiencing issues:
- Check the browser console and network tab for detailed errors
- Review the API Reference for endpoint details
- Contact Redacto support with:
- Error messages
- Request/response details
- Organisation and workspace UUIDs
- Steps to reproduce
Next Steps
- Getting Started - Setup guide
- Frontend SDKs - SDK documentation
- Example Flows - Integration patterns
Updated 9 days ago