UNPKG

gray-market-js

Version:

Utility library for the Gray Market rental marketplace

249 lines 6.29 kB
[ { "inputs": [ { "internalType": "address", "name": "_approvalProxyAddress", "type": "address" } ], "stateMutability": "nonpayable", "type": "constructor" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "bytes32", "name": "listingHash", "type": "bytes32" }, { "indexed": false, "internalType": "address", "name": "renter", "type": "address" }, { "indexed": false, "internalType": "address", "name": "keeper", "type": "address" }, { "indexed": false, "internalType": "uint48", "name": "until", "type": "uint48" } ], "name": "ListingExecuted", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "bytes32", "name": "listingHash", "type": "bytes32" } ], "name": "ListingWithdrawn", "type": "event" }, { "inputs": [], "name": "approvalProxy", "outputs": [ { "internalType": "contract IApprovalProxy", "name": "", "type": "address" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "components": [ { "components": [ { "internalType": "address payable", "name": "lender", "type": "address" }, { "internalType": "bool", "name": "recurring", "type": "bool" }, { "internalType": "uint8", "name": "tokenType", "type": "uint8" }, { "internalType": "uint48", "name": "validUntil", "type": "uint48" }, { "internalType": "address", "name": "collectionAddress", "type": "address" }, { "internalType": "uint32", "name": "minRentalLength", "type": "uint32" }, { "internalType": "uint32", "name": "maxRentalLength", "type": "uint32" }, { "internalType": "address", "name": "authorizedCustodyProviderAddress", "type": "address" }, { "internalType": "uint256", "name": "tokenID", "type": "uint256" }, { "internalType": "uint256", "name": "amount", "type": "uint256" }, { "internalType": "uint256", "name": "costPerSecond", "type": "uint256" } ], "internalType": "struct Listing", "name": "listing", "type": "tuple" }, { "internalType": "bytes", "name": "lenderSignature", "type": "bytes" }, { "components": [ { "internalType": "address", "name": "collectionAddress", "type": "address" }, { "internalType": "address[]", "name": "availableKeepers", "type": "address[]" } ], "internalType": "struct CustodyProviderData", "name": "custodyProviderData", "type": "tuple" }, { "internalType": "bytes", "name": "custodyProviderSignature", "type": "bytes" }, { "internalType": "uint48", "name": "rentalLength", "type": "uint48" } ], "internalType": "struct RentalOrder", "name": "_order", "type": "tuple" } ], "name": "execute", "outputs": [], "stateMutability": "payable", "type": "function" }, { "inputs": [ { "components": [ { "internalType": "address payable", "name": "lender", "type": "address" }, { "internalType": "bool", "name": "recurring", "type": "bool" }, { "internalType": "uint8", "name": "tokenType", "type": "uint8" }, { "internalType": "uint48", "name": "validUntil", "type": "uint48" }, { "internalType": "address", "name": "collectionAddress", "type": "address" }, { "internalType": "uint32", "name": "minRentalLength", "type": "uint32" }, { "internalType": "uint32", "name": "maxRentalLength", "type": "uint32" }, { "internalType": "address", "name": "authorizedCustodyProviderAddress", "type": "address" }, { "internalType": "uint256", "name": "tokenID", "type": "uint256" }, { "internalType": "uint256", "name": "amount", "type": "uint256" }, { "internalType": "uint256", "name": "costPerSecond", "type": "uint256" } ], "internalType": "struct Listing", "name": "_listing", "type": "tuple" } ], "name": "withdraw", "outputs": [], "stateMutability": "nonpayable", "type": "function" } ]