Important: Starting with version 2.0.0 (originally introduced in v1.10.1, now properly versioned), the unified MxPlatformApi class has been replaced with domain-specific API classes. If you're upgrading from v1.10.0 or earlier, you'll need to update your imports and API instantiation.
Note: Versions v1.10.1 through v1.12.1 are deprecated. If you're on any of these versions, please upgrade to v2.0.0 (functionally identical to v1.12.1, just properly versioned).
The library now provides granular API classes organized by domain (Users, Members, Accounts, Transactions, etc.) instead of a single MxPlatformApi class. This aligns with the OpenAPI specification structure and provides better code organization.
Before (v1.10.0 and earlier):
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const client = new MxPlatformApi(configuration);
await client.createUser(requestBody);
await client.listMembers(userGuid);
await client.listAccounts(userGuid);After (v2.0.0+):
import { Configuration, UsersApi, MembersApi, AccountsApi } from 'mx-platform-node';
const usersApi = new UsersApi(configuration);
const membersApi = new MembersApi(configuration);
const accountsApi = new AccountsApi(configuration);
await usersApi.createUser(requestBody);
await membersApi.listMembers(userGuid);
await accountsApi.listAccounts(userGuid);The new structure includes the following API classes:
AccountsApi- Account operationsAuthorizationApi- Authorization operationsBudgetsApi- Budget operationsCategoriesApi- Category operationsGoalsApi- Goal operationsInsightsApi- Insight operationsInstitutionsApi- Institution operationsInvestmentHoldingsApi- Investment holding operationsManagedDataApi- Managed data operationsMembersApi- Member operationsMerchantsApi- Merchant operationsMicrodepositsApi- Microdeposit operationsMonthlyCashFlowProfileApi- Monthly cash flow profile operationsNotificationsApi- Notification operationsProcessorTokenApi- Processor token operationsRewardsApi- Rewards operationsSpendingPlanApi- Spending plan operationsStatementsApi- Statement operationsTaggingsApi- Tagging operationsTagsApi- Tag operationsTransactionRulesApi- Transaction rule operationsTransactionsApi- Transaction operationsUsersApi- User operationsVerifiableCredentialsApi- Verifiable credential operationsWidgetsApi- Widget operations
For the complete list of available methods, please refer to the API documentation.
- Update your imports: Replace
MxPlatformApiwith the specific API classes you need - Update instantiation: Create separate instances for each API class instead of a single client
- Update method calls: Call methods on the appropriate API class instance
- Test thoroughly: Verify all API calls work as expected with the new structure
- Update documentation: If you have internal docs referencing the old API, update them
If you encounter any issues during migration, please open an issue on GitHub.