a fork of opensea sdk to generate calldata, create buy order, create sell order and cancel order.
npm install
You need to create an '.env' file to configurate
privateKey
rinkeby provider url
mainner provider url
opensea api key
-
Generate calldata for Opensea 'atomicMatch_' function.
Output would exist in 'src/calldata.txt'.
Arguments
- tokenAddress: the address of the opensea NFT
- tokenId: the token id of the opensea NFT
- accountAddress: the buyer of the NFT, can be an EOA or a contract address
Example
node src/gen-calldata.js --tokenId="3" --tokenAddress="0x12EE22Fb3e55Ae219164AF8e37A7aE59c0A45858" --accountAddress="0xB84F9393e064762b3B3FB4e35B6c89871aB122b6"
-
Create buy, sell and cancel order using opensea's sdk.
You need to change the parameters in 'src/make-offer.js' manually.
Example
node src/make-offer.js
-
Fulfill buy order using opensea's sdk.
You need to change the parameters in 'src/fulfill-buynow-order.js' manually.
Example
node src/fulfill-buynow-order.js