From e288dfc3209dcc22223732fb8e87aa3082fbe7e0 Mon Sep 17 00:00:00 2001 From: Baby Bear <132609968+smallbabybear@users.noreply.github.com> Date: Thu, 4 Dec 2025 07:39:52 +0700 Subject: [PATCH] docs: Add batch size limits information to API reference --- .../intmax-client-sdk/api-reference.md | 21 ++++++++++++++++++- developers-hub/intmax-client-sdk/overview.md | 11 +++++++++- 2 files changed, 30 insertions(+), 2 deletions(-) diff --git a/developers-hub/intmax-client-sdk/api-reference.md b/developers-hub/intmax-client-sdk/api-reference.md index 623e166..37aaa3f 100644 --- a/developers-hub/intmax-client-sdk/api-reference.md +++ b/developers-hub/intmax-client-sdk/api-reference.md @@ -511,9 +511,28 @@ const claim = await client.claimWithdrawal(withdrawals.need_claim); ## Technical Terms - **Nullifier**: A unique identifier used to prevent the same deposit/withdrawal from being used more than once. -- **Salt**: A random value added during encryption or hashing to ensure different outputs from identical inputs. Used to conceal the recipient’s deposit address. +- **Salt**: A random value added during encryption or hashing to ensure different outputs from identical inputs. Used to conceal the recipient's deposit address. - **Token index**: A numerical ID uniquely identifying tokens within the INTMAX network. +## Batch Size Limits + +The INTMAX Client SDK enforces batch size limits for certain operations to ensure optimal performance and prevent resource exhaustion: + +### Transaction Broadcasting + +- **Maximum transactions per `broadcastTransaction` call**: 63 transactions +- This limit applies when batching multiple transfers in a single transaction broadcast + +### Data Fetching Operations + +- **Maximum items per internal API request**: 64 items +- This limit applies to internal pagination used by: + - `fetchDeposits()` + - `fetchTransfers()` + - `fetchTransactions()` +- The SDK automatically handles pagination, so you don't need to manage this limit when using high-level APIs +- Specifying a value greater than 64 will result in an error: `Limit exceeds max batch size` or `Batch size exceeds maximum limit of 64` + ## Fee Please refer to the following for details about the fees. diff --git a/developers-hub/intmax-client-sdk/overview.md b/developers-hub/intmax-client-sdk/overview.md index d438615..f5c7f1c 100644 --- a/developers-hub/intmax-client-sdk/overview.md +++ b/developers-hub/intmax-client-sdk/overview.md @@ -146,9 +146,18 @@ IntMaxClient.init({ environment: "testnet" }); The INTMAX privacy model ensures that **only the wallet owner with the private key can view their balance and transaction history**. -- Unlike public blockchains, third parties cannot directly check an address’s balance or history. +- Unlike public blockchains, third parties cannot directly check an address's balance or history. - Transfer data uses `salt` and `nullifier` values to hide recipient addresses and prevent linking transactions to each other. +### Batch Size Limits + +The SDK enforces batch size limits for optimal performance: + +- **Transaction broadcasting**: Maximum 63 transactions per `broadcastTransaction` call +- **Data fetching**: Maximum 64 items per internal API request. The SDK automatically handles pagination for high-level APIs like `fetchDeposits()`, `fetchTransfers()`, and `fetchTransactions()`. + +For more details, see the [API Reference](./api-reference.md#batch-size-limits). + ## Tips ### How to Run a Local Balance Prover