constructSimpleSDK is the recommended entry point for most integrators. You pass it a chainId, an HTTP client, and (optionally) a wallet; in return you get an SDK with every Velora method available under flat namespaces.
When to use this
- You want one import that exposes the whole API surface.
- You’re fine with the SDK returning transaction hashes (
string) for write calls, instead of library-typed responses. - You don’t need to share a single contract caller across multiple SDK instances.
Construct it
Pick your HTTP client.fetch keeps the bundle smaller; axios is convenient if you already use it.
Add a wallet
Pass a second argument with your provider to enable write methods (approveToken, signDeltaOrder, submitDeltaOrder, buildTx-then-send).
Write calls always resolve to a transaction hash (
string). If you need the library-typed response object (viem’s Hex, ethers.ContractTransaction, etc.), use constructFullSDK with the <TxResponse> generic.