Test your iOS DRS integration
Before using your Detection and Response Services (DRS) in production, ensure its successful integration and correct functioning within a running environment. This guide walks you through the basic steps to test your iOS integration .
Before testing
To test your integration, you'll need:
- Access to the Detection and Response pages in the Mosaic Admin Portal
- A running environment for the application you've integrated with Transmit
Tip
Add a Rule that always allows actions from the IP addresses (or ranges) you use for testing and automation purposes. This ensures that those IPs are never challenged or denied by Mosaic.
Step 1: Initialize DRS services
Check in your app that the DRS SDK is initialized and collecting telemetry data. his validates Step 3 of your quickstart integration.
- Run your application in XCode , open the Console app , and apply RiskID as filter.
- Navigate to a page in your application that initializes the SDK and click anywhere on the screen several times.
-
Validate that the
RiskID
filter includes multiple
/device/events
requests to Mosaic.
Step 2: Trigger action event
Check if action events on your app are reported to Mosaic. This validates Step 5 of your quickstart integration.
- Navigate to your application.
- Perform an action expected to trigger an action event. For example, enter a username and click the login button, if you implemented DRS logic on the login button.
- Validate that an event related to the triggered action is shown in the Admin Portal's recommendation log ( Detection and Response > Recommendations ). You can click the recommendation to inspect its details.
Step 3: Get recommendation
Check that the application can obtain a recommendation for a triggered action. This validates Step 6 of the quickstart integration.
-
Within your application, perform an action that triggers an action event and intercept the returned
ActionToken
through client-side or server-side logs. - Send a backend GET request to our /recommendation endpoint with the action token.
- Validate that the API returns a successful response that includes the recommendation.
Step 4: Set user
Check that recommendations are associated with a user identifier. This validates Step 4 of your quickstart integration.
- Authenticate a user in your application and report to Mosaic the user identifier.
- Perform an action that triggers an action event according to your implementation.
- Validate that the action event is reported in the Admin Portal's recommendation log ( Detection and Response > Recommendations ), and the recommendation details include the user identifier.