Skip to content

feat: support DDC (Device Data Collection) next action in payment flow #1494

@AbhishekChorotiya

Description

@AbhishekChorotiya

Description

The SDK needs to handle a new invoke_ddc next action type returned by the backend during payment confirmation. Device Data Collection (DDC) is required by certain connectors to perform device fingerprinting before redirecting the user for authentication (e.g., 3DS).

Requirements

  • When next_action.type is invoke_ddc, the SDK should:
    1. Read ddc_data (iframe_url, timeout_ms) from the payment confirmation response
    2. Inject a hidden iframe pointing to the DDC URL
    3. Listen for a postMessage from the iframe containing the next redirect action
    4. Redirect the user to the URL received, respecting redirect_mode
    5. Fail gracefully on timeout or missing data with proper cleanup

Acceptance Criteria

  • New invoke_ddc next action type is handled in intentCall
  • Hidden iframe is created and cleaned up properly (no DOM leaks)
  • Timeout mechanism prevents indefinite waiting
  • Redirect respects redirect_mode (required vs if_required)
  • Error handling covers missing iframe_url, timeout, and malformed messages

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions