nftbunny-sdk v0.0.60
NFTBunny SDK
This is the SDK used to interact with the smart contracts defined in NFTBunny protocol.
Usage
To use this SDK you must instance an NFTBunnySDK
object passing some settings:
const sdk = new NFTBunnySDK(
{
exchange: '0x...',
collection: '0x...',
backend: '0x...',
},
signer
);
This object exposes several methods useful to interact with the smart contracts ecosystem but it does not collect information about signers and providers. These information must be managed by callers.
Testing
A test suite is provided but it requires that a local Ethereum provider is running.
The tests are able to automatically get the contracts deployed on the local network as long as
this in the same folder where this SDK is found it's present also the nftbunny-protocol
package.
In fact, it's needed to run yarn dev
inside the nftbunny-protocol
package to get the contracts
deployed in a newly created local network and the needed nftbunny-protocol/contractsInfo.json
.
Building and publishing
To build the SDK run
yarn build
This will compile the sdk/
folder into the dist/
folder and then will copy the json artifacts (needed in runtime).
To publish the SDK change the version in package.json
and then run
npm publish . --access public
Before doing that it could be necessary to run npm login
.
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago