Skip to content

Migrate ts sdk over to mysten sdk v2 and bump up npm package version to 2.0.0-beta.0#286

Open
nikita-seedlabs wants to merge 4 commits intomainfrom
nikita/update_sui_sdk
Open

Migrate ts sdk over to mysten sdk v2 and bump up npm package version to 2.0.0-beta.0#286
nikita-seedlabs wants to merge 4 commits intomainfrom
nikita/update_sui_sdk

Conversation

@nikita-seedlabs
Copy link
Contributor

Migrates typescript pro-sdk over to use mysten v2 sdk

Copilot AI review requested due to automatic review settings March 19, 2026 23:57
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Migrates the TypeScript Pro SDK to the Mysten Sui SDK v2 ecosystem and prepares a 2.0.0-beta.0 release, updating build configuration and consumer-facing examples/docs accordingly.

Changes:

  • Bump TS SDK package version to 2.0.0-beta.0, update dependencies to Mysten v2, and adjust lockfiles.
  • Switch TS build output/config toward ESM-only (remove CJS build config and update tsconfigs).
  • Update README/docs/example to the new SuiClient initialization shape (adding network).

Reviewed changes

Copilot reviewed 8 out of 10 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
ts/sdk/yarn.lock Updates dependency graph/versions for Mysten v2 + library-sui beta.
ts/sdk/package-lock.json Mirrors lockfile updates, including new transitive deps and engine constraints.
ts/sdk/package.json Bumps version to 2.0.0-beta.0, moves to ESM-only exports/build, updates deps/peer deps.
ts/sdk/tsconfig.types.json Updates declaration build to ESNext + Bundler resolution and removes path mapping.
ts/sdk/tsconfig.example.json Updates example TS config to ESNext + Bundler resolution.
ts/sdk/tsconfig.esm.json Updates ESM build TS config to ESNext + Bundler resolution.
ts/sdk/tsconfig.cjs.json Removes CJS build config.
ts/sdk/example.ts Updates SuiClient construction to include network.
ts/sdk/docs/batch-claim-rewards-guide.md Updates example client initialization to include network.
ts/sdk/README.md Updates quickstart client initialization to include network.
Files not reviewed (1)
  • ts/sdk/package-lock.json: Language not supported

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Contributor

@lucasfronza lucasfronza Mar 20, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: Looks like pro-sdk has both a yarn.lock and package-lock.json files. Probably worth keeping just one and making sure it sticks to either npm install or yarn install.

signer,
"mainnet", // or "testnet" for staging
new SuiClient({ url: "https://fullnode.mainnet.sui.io:443" })
new SuiClient({ url: "https://fullnode.mainnet.sui.io:443", network: "mainnet" })
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think these examples should now use SuiJsonRpcClient instead of SuiClient.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think there's something missing in the code as well, because the constructor of BluefinProSdk should also be updated to accept either a SuiJsonRpcClient or a ClientWithCoreApi, and then likely this change will cause some other things to be needed to be updated accordingly.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Copy link
Contributor Author

@nikita-seedlabs nikita-seedlabs Mar 21, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lucasfronza it looks like we need to update the bluefin aggregator sdk to mysten v2 to resolve yarn dependencies here https://github.com/fireflyprotocol/bluefin7k-typescript-sdk/blob/d906868d1e30dc0b57685d3eb3f9da6ef4de94eb/package.json#L75. Forced it to use v2 in the meantime

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants