Zluri SDK Migration Guide
This guide walks you through the steps to migrate your SDK integration from the V1 API to the V2 API. Follow these steps to ensure a smooth transition with enhanced functionality.
Prerequisites
-
List Existing Integrations: Use the "List Integration API" call to retrieve the list of your current integrations and instance configurations.
-
Authentication: Use the same authentication key you currently use for your V1 integrations.
If you need a new API key, please reach out to our support, CSE, or CSM team for assistance.
-
V2 Data Entities: The V2 API now supports six data entities:
- Users
- User Activity
- Groups
- User Groups
- Transactions
- Contracts
Ensure you prepare the necessary data for each entity before uploading it to Zluri. Make sure each schema includes the unique ID and other required fields.
Example: The User schema should include the
Unique_Idfield, which helps maintain a distinct identifier for each user, ensuring accurate updates to user attributes.
Steps to Migrate
Step 1: Update SDK Integration Configuration
First, update the configuration of your existing SDK integration using the Update Integration Instance API. This API allows you to:
- Change notification email addresses for alerts regarding sync failures, data issues, and other important events.
- Update the connection status (e.g., connected or not-connected).
API Request Example:
curl --request PUT \\
--url <https://api-ext.zluri.com/v2/integrations-sync/instances/instance_id> \\
--header 'accept: application/json' \\
--header 'content-type: application/json' \\
--data '
{
"notification_emails": [
"[email protected]",
"[email protected]"
],
"status": "not-connected",
"created_by": "[email protected]"
}
Step 2: Validate the Update
Once the configuration is updated, validate the changes using the Get Integration Instance API. This will confirm that the notification emails, app ID, and creator fields are correctly updated.
Sample API Response:
{
"instance_id": "6xxxxxxxxxxxxxx",
"name": "sync_slack1",
"app_id": "6xxxxxxxxxxxxxxxxxxx",
"status": "connected",
"notification_emails": [
"[email protected]"
]
}Step 3: Update Sync Initiator API Call to V2
Next, update your Sync Initiator API call to the V2 version. This step ensures you take full advantage of the new capabilities and improvements in V2.
Step 4: Choose the Right Data Models for Upload
SDK V2 provides two data models for uploading data:
- Snapshot Data: This model reflects the current state of an entity and replaces any previous data.
- Entities: Users, Groups, Group-users.
- Incremental Data: This model appends new records without overwriting existing data.
- Entities: Contracts, Transactions, User-activity.
Understand the dependent entities before triggering the sync.
Refer to the SDK documentation to select the appropriate model for your integration.
Step 5: Update Finish Sync API Call
Update the Finish Sync API call according to the latest SDK V2 documentation. This step ensures the synchronization process concludes correctly.
Step 6: Run a Sample Sync and Abort If Needed
Once your setup is complete, run a sample sync to test the new flow. If you need to cancel the sync, use the Abort Sync API to safely terminate the synchronization process.
Updated 16 minutes ago
