Skip to content

Migration to v2

This guide helps you migrate your Platform SDK integration from version 1.x to version 2.x.

Important

Platform SDK v1 has reached end-of-life (EOL) and will no longer receive updates, including security patches and bug fixes. All customers are strongly advised to upgrade to v2. For details, see Changelog.

What's new

Version 2 introduces several improvements to the SDK architecture and configuration.

Breaking changes:

  • The serverPath parameter becomes mandatory for all SDK modules.
  • Fraud Prevention is disabled by default and must be explicitly initialized.
  • Deprecating Fraud Prevention functions: unidentifiedUser(), identifyUser() and setUser().
  • Webauthn methods were refactored to use a single parameter object pattern instead of multiple positional parameters.

Changes:

  • The Orchestration (IDO) module now uses separate typing files.

Migrate your app to SDK v2

Step 1: Add serverPath to all modules

The serverPath parameter is now mandatory for all SDK modules. Review all initialize() calls and add serverPath for each module you use.

Before (v1):

await initialize({
  clientId: 'your-client-id',
  ido: {
    // serverPath was optional, defaulted to US region
  }
});

After (v2):

await initialize({
  clientId: 'your-client-id',
  ido: {
    serverPath: 'https://api.transmitsecurity.io/ido' // Required
  }
});

Use the appropriate serverPath for your environment:

EnvironmentserverPath
UShttps://api.transmitsecurity.io/ido
EUhttps://api.eu.transmitsecurity.io/ido
Canadahttps://api.ca.transmitsecurity.io/ido
Australiahttps://api.au.transmitsecurity.io/ido
Sandboxhttps://api.sbx.transmitsecurity.io/ido
Custom domainhttps://<your_custom_domain>/ido

Step 2: Update renamed Fraud Prevention functions

If your application uses any of the following Fraud Prevention functions, update them to the new names:

v1 functionv2 function
unidentifiedUser()clearUser()
identifyUser()setAuthenticatedUser()
setUser()setAuthenticatedUser()

See Fraud Prevention SDK reference for details.

Step 3: Update WebAuthn method signatures

WebAuthn methods have been refactored to use a single parameter object instead of multiple positional parameters:

Before (v1):

webauthn.register('user@email.com', { displayName: 'Display Name' });

After (v2):

webauthn.register({ username: 'user@email.com', options: { displayName: 'Display Name' } });

See WebAuthn SDK reference for the updated method signatures.

Step 4: Update Orchestration type imports

The Orchestration (IDO) module now uses separate typing files. If your TypeScript application imports IDO types, update the import paths:

Before (v1):

import { IdoServiceResponse, ClientResponseOptionType } from '@transmitsecurity/platform-web-sdk';

After (v2):

import type { IdoServiceResponse, ClientResponseOptionType } from '@transmitsecurity/platform-web-sdk/ido';

Step 5: Update SDK version

Update the SDK package or CDN script to version 2:

Note

The latest will remain frozen on the last v1 release. To receive ongoing v2 updates, explicitly install a v2 version.

  • NPM: Update to @transmitsecurity/platform-web-sdk@^2
  • CDN: Change script URL from 1.x to 2.x

Step 6: Test your integration

  • Verify all SDK functionality works as expected
  • Check browser console for any initialization errors