From 827fd6081c9fb138cea4eedc0752689829a7e073 Mon Sep 17 00:00:00 2001 From: Albert Folch Date: Thu, 29 Dec 2022 16:02:39 +0100 Subject: [PATCH 1/9] chore: update protocol contracts submodule --- contracts/protocol-contracts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contracts/protocol-contracts b/contracts/protocol-contracts index 752ba8bd0..38c7ba384 160000 --- a/contracts/protocol-contracts +++ b/contracts/protocol-contracts @@ -1 +1 @@ -Subproject commit 752ba8bd0830109c1d5ec555e615172b0c270d20 +Subproject commit 38c7ba384e55486aee4ea76bb80b4f29d1a86175 From a4fe89aeacd1ed3ba3862826afacc1dad2738729 Mon Sep 17 00:00:00 2001 From: Albert Folch Date: Thu, 29 Dec 2022 16:52:28 +0100 Subject: [PATCH 2/9] wip --- e2e/docker-compose.yml | 2 +- packages/common/src/abis/ERC1155.json | 276 -- packages/common/src/abis/ERC20.json | 222 -- .../common/src/abis/ERC721Enumerable.json | 434 --- .../common/src/abis/IBosonAccountHandler.json | 2158 ----------- .../common/src/abis/IBosonDisputeHandler.json | 645 ---- .../src/abis/IBosonExchangeHandler.json | 1065 ------ .../common/src/abis/IBosonFundsHandler.json | 269 -- .../common/src/abis/IBosonGroupHandler.json | 418 --- .../abis/IBosonMetaTransactionsHandler.json | 106 - .../common/src/abis/IBosonOfferHandler.json | 784 ---- .../src/abis/IBosonOrchestrationHandler.json | 3314 ----------------- packages/common/src/abis/IBosonVoucher.json | 521 --- .../src/abis/MockNativeMetaTransaction.json | 111 - packages/common/src/abis/ProtocolDiamond.json | 48 - 15 files changed, 1 insertion(+), 10372 deletions(-) delete mode 100644 packages/common/src/abis/ERC1155.json delete mode 100644 packages/common/src/abis/ERC20.json delete mode 100644 packages/common/src/abis/ERC721Enumerable.json delete mode 100644 packages/common/src/abis/IBosonAccountHandler.json delete mode 100644 packages/common/src/abis/IBosonDisputeHandler.json delete mode 100644 packages/common/src/abis/IBosonExchangeHandler.json delete mode 100644 packages/common/src/abis/IBosonFundsHandler.json delete mode 100644 packages/common/src/abis/IBosonGroupHandler.json delete mode 100644 packages/common/src/abis/IBosonMetaTransactionsHandler.json delete mode 100644 packages/common/src/abis/IBosonOfferHandler.json delete mode 100644 packages/common/src/abis/IBosonOrchestrationHandler.json delete mode 100644 packages/common/src/abis/IBosonVoucher.json delete mode 100644 packages/common/src/abis/MockNativeMetaTransaction.json delete mode 100644 packages/common/src/abis/ProtocolDiamond.json diff --git a/e2e/docker-compose.yml b/e2e/docker-compose.yml index 30025c1be..1c1605fe8 100644 --- a/e2e/docker-compose.yml +++ b/e2e/docker-compose.yml @@ -19,7 +19,7 @@ services: hardhat-node: build: ../contracts - image: hardhat-node:752ba8bd0830109c1d5ec555e615172b0c270d20_0 + image: hardhat-node:38c7ba384e55486aee4ea76bb80b4f29d1a86175 ports: - "8545:8545" diff --git a/packages/common/src/abis/ERC1155.json b/packages/common/src/abis/ERC1155.json deleted file mode 100644 index 0107f8f70..000000000 --- a/packages/common/src/abis/ERC1155.json +++ /dev/null @@ -1,276 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "_owner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "_operator", - "type": "address" - }, - { - "indexed": false, - "internalType": "bool", - "name": "_approved", - "type": "bool" - } - ], - "name": "ApprovalForAll", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "_operator", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "_from", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "_to", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256[]", - "name": "_ids", - "type": "uint256[]" - }, - { - "indexed": false, - "internalType": "uint256[]", - "name": "_amounts", - "type": "uint256[]" - } - ], - "name": "TransferBatch", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "_operator", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "_from", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "_to", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "_id", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "_amount", - "type": "uint256" - } - ], - "name": "TransferSingle", - "type": "event" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_owner", - "type": "address" - }, - { - "internalType": "uint256", - "name": "_id", - "type": "uint256" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address[]", - "name": "_owners", - "type": "address[]" - }, - { - "internalType": "uint256[]", - "name": "_ids", - "type": "uint256[]" - } - ], - "name": "balanceOfBatch", - "outputs": [ - { - "internalType": "uint256[]", - "name": "", - "type": "uint256[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_owner", - "type": "address" - }, - { - "internalType": "address", - "name": "_operator", - "type": "address" - } - ], - "name": "isApprovedForAll", - "outputs": [ - { - "internalType": "bool", - "name": "isOperator", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_from", - "type": "address" - }, - { - "internalType": "address", - "name": "_to", - "type": "address" - }, - { - "internalType": "uint256[]", - "name": "_ids", - "type": "uint256[]" - }, - { - "internalType": "uint256[]", - "name": "_amounts", - "type": "uint256[]" - }, - { - "internalType": "bytes", - "name": "_data", - "type": "bytes" - } - ], - "name": "safeBatchTransferFrom", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_from", - "type": "address" - }, - { - "internalType": "address", - "name": "_to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "_id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "_amount", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "_data", - "type": "bytes" - } - ], - "name": "safeTransferFrom", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_operator", - "type": "address" - }, - { - "internalType": "bool", - "name": "_approved", - "type": "bool" - } - ], - "name": "setApprovalForAll", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes4", - "name": "_interfaceID", - "type": "bytes4" - } - ], - "name": "supportsInterface", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "pure", - "type": "function" - } - ] \ No newline at end of file diff --git a/packages/common/src/abis/ERC20.json b/packages/common/src/abis/ERC20.json deleted file mode 100644 index 405d6b364..000000000 --- a/packages/common/src/abis/ERC20.json +++ /dev/null @@ -1,222 +0,0 @@ -[ - { - "constant": true, - "inputs": [], - "name": "name", - "outputs": [ - { - "name": "", - "type": "string" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { - "name": "_spender", - "type": "address" - }, - { - "name": "_value", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [ - { - "name": "", - "type": "bool" - } - ], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "totalSupply", - "outputs": [ - { - "name": "", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { - "name": "_from", - "type": "address" - }, - { - "name": "_to", - "type": "address" - }, - { - "name": "_value", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [ - { - "name": "", - "type": "bool" - } - ], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "decimals", - "outputs": [ - { - "name": "", - "type": "uint8" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { - "name": "_owner", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "name": "balance", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": true, - "inputs": [], - "name": "symbol", - "outputs": [ - { - "name": "", - "type": "string" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "constant": false, - "inputs": [ - { - "name": "_to", - "type": "address" - }, - { - "name": "_value", - "type": "uint256" - } - ], - "name": "transfer", - "outputs": [ - { - "name": "", - "type": "bool" - } - ], - "payable": false, - "stateMutability": "nonpayable", - "type": "function" - }, - { - "constant": true, - "inputs": [ - { - "name": "_owner", - "type": "address" - }, - { - "name": "_spender", - "type": "address" - } - ], - "name": "allowance", - "outputs": [ - { - "name": "", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function" - }, - { - "payable": true, - "stateMutability": "payable", - "type": "fallback" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "name": "spender", - "type": "address" - }, - { - "indexed": false, - "name": "value", - "type": "uint256" - } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "name": "from", - "type": "address" - }, - { - "indexed": true, - "name": "to", - "type": "address" - }, - { - "indexed": false, - "name": "value", - "type": "uint256" - } - ], - "name": "Transfer", - "type": "event" - } -] diff --git a/packages/common/src/abis/ERC721Enumerable.json b/packages/common/src/abis/ERC721Enumerable.json deleted file mode 100644 index b972378ed..000000000 --- a/packages/common/src/abis/ERC721Enumerable.json +++ /dev/null @@ -1,434 +0,0 @@ -[ - { - "constant": true, - "inputs": [ - { - "name": "interfaceId", - "type": "bytes4" - } - ], - "name": "supportsInterface", - "outputs": [ - { - "name": "", - "type": "bool" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function", - "signature": "0x01ffc9a7" - }, - { - "constant": true, - "inputs": [], - "name": "name", - "outputs": [ - { - "name": "", - "type": "string" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function", - "signature": "0x06fdde03" - }, - { - "constant": true, - "inputs": [ - { - "name": "tokenId", - "type": "uint256" - } - ], - "name": "getApproved", - "outputs": [ - { - "name": "", - "type": "address" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function", - "signature": "0x081812fc" - }, - { - "constant": false, - "inputs": [ - { - "name": "to", - "type": "address" - }, - { - "name": "tokenId", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function", - "signature": "0x095ea7b3" - }, - { - "constant": true, - "inputs": [], - "name": "totalSupply", - "outputs": [ - { - "name": "", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function", - "signature": "0x18160ddd" - }, - { - "constant": false, - "inputs": [ - { - "name": "from", - "type": "address" - }, - { - "name": "to", - "type": "address" - }, - { - "name": "tokenId", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function", - "signature": "0x23b872dd" - }, - { - "constant": true, - "inputs": [ - { - "name": "owner", - "type": "address" - }, - { - "name": "index", - "type": "uint256" - } - ], - "name": "tokenOfOwnerByIndex", - "outputs": [ - { - "name": "", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function", - "signature": "0x2f745c59" - }, - { - "constant": false, - "inputs": [ - { - "name": "from", - "type": "address" - }, - { - "name": "to", - "type": "address" - }, - { - "name": "tokenId", - "type": "uint256" - } - ], - "name": "safeTransferFrom", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function", - "signature": "0x42842e0e" - }, - { - "constant": true, - "inputs": [ - { - "name": "index", - "type": "uint256" - } - ], - "name": "tokenByIndex", - "outputs": [ - { - "name": "", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function", - "signature": "0x4f6ccce7" - }, - { - "constant": true, - "inputs": [ - { - "name": "tokenId", - "type": "uint256" - } - ], - "name": "ownerOf", - "outputs": [ - { - "name": "", - "type": "address" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function", - "signature": "0x6352211e" - }, - { - "constant": true, - "inputs": [ - { - "name": "owner", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "name": "", - "type": "uint256" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function", - "signature": "0x70a08231" - }, - { - "constant": true, - "inputs": [], - "name": "symbol", - "outputs": [ - { - "name": "", - "type": "string" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function", - "signature": "0x95d89b41" - }, - { - "constant": false, - "inputs": [ - { - "name": "to", - "type": "address" - }, - { - "name": "approved", - "type": "bool" - } - ], - "name": "setApprovalForAll", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function", - "signature": "0xa22cb465" - }, - { - "constant": false, - "inputs": [ - { - "name": "from", - "type": "address" - }, - { - "name": "to", - "type": "address" - }, - { - "name": "tokenId", - "type": "uint256" - }, - { - "name": "_data", - "type": "bytes" - } - ], - "name": "safeTransferFrom", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function", - "signature": "0xb88d4fde" - }, - { - "constant": true, - "inputs": [ - { - "name": "tokenId", - "type": "uint256" - } - ], - "name": "tokenURI", - "outputs": [ - { - "name": "", - "type": "string" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function", - "signature": "0xc87b56dd" - }, - { - "constant": true, - "inputs": [ - { - "name": "owner", - "type": "address" - }, - { - "name": "operator", - "type": "address" - } - ], - "name": "isApprovedForAll", - "outputs": [ - { - "name": "", - "type": "bool" - } - ], - "payable": false, - "stateMutability": "view", - "type": "function", - "signature": "0xe985e9c5" - }, - { - "inputs": [ - { - "name": "name", - "type": "string" - }, - { - "name": "symbol", - "type": "string" - } - ], - "payable": false, - "stateMutability": "nonpayable", - "type": "constructor", - "signature": "constructor" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "name": "from", - "type": "address" - }, - { - "indexed": true, - "name": "to", - "type": "address" - }, - { - "indexed": true, - "name": "tokenId", - "type": "uint256" - } - ], - "name": "Transfer", - "type": "event", - "signature": "0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "name": "approved", - "type": "address" - }, - { - "indexed": true, - "name": "tokenId", - "type": "uint256" - } - ], - "name": "Approval", - "type": "event", - "signature": "0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "name": "operator", - "type": "address" - }, - { - "indexed": false, - "name": "approved", - "type": "bool" - } - ], - "name": "ApprovalForAll", - "type": "event", - "signature": "0x17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31" - }, - { - "constant": false, - "inputs": [ - { - "name": "to", - "type": "address" - }, - { - "name": "tokenId", - "type": "uint256" - }, - { - "name": "tokenURI", - "type": "string" - } - ], - "name": "mint", - "outputs": [], - "payable": false, - "stateMutability": "nonpayable", - "type": "function", - "signature": "0xd3fc9864" - } -] \ No newline at end of file diff --git a/packages/common/src/abis/IBosonAccountHandler.json b/packages/common/src/abis/IBosonAccountHandler.json deleted file mode 100644 index 9d4254903..000000000 --- a/packages/common/src/abis/IBosonAccountHandler.json +++ /dev/null @@ -1,2158 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "agentId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "feePercentage", - "type": "uint256" - }, - { - "internalType": "address payable", - "name": "wallet", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Agent", - "name": "agent", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "AgentCreated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "agentId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "feePercentage", - "type": "uint256" - }, - { - "internalType": "address payable", - "name": "wallet", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Agent", - "name": "agent", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "AgentUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256[]", - "name": "addedSellers", - "type": "uint256[]" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "AllowedSellersAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256[]", - "name": "removedSellers", - "type": "uint256[]" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "AllowedSellersRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "buyerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address payable", - "name": "wallet", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Buyer", - "name": "buyer", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "BuyerCreated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "buyerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address payable", - "name": "wallet", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Buyer", - "name": "buyer", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "BuyerUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolver", - "name": "disputeResolver", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeResolverActivated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolver", - "name": "disputeResolver", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "tokenName", - "type": "string" - }, - { - "internalType": "uint256", - "name": "feeAmount", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolverFee[]", - "name": "disputeResolverFees", - "type": "tuple[]" - }, - { - "indexed": false, - "internalType": "uint256[]", - "name": "sellerAllowList", - "type": "uint256[]" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeResolverCreated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "tokenName", - "type": "string" - }, - { - "internalType": "uint256", - "name": "feeAmount", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolverFee[]", - "name": "disputeResolverFees", - "type": "tuple[]" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeResolverFeesAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address[]", - "name": "feeTokensRemoved", - "type": "address[]" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeResolverFeesRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolver", - "name": "disputeResolver", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolver", - "name": "pendingDisputeResolver", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeResolverUpdateApplied", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolver", - "name": "pendingDisputeResolver", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeResolverUpdatePending", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolver", - "name": "disputeResolver", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeResolverUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Seller", - "name": "seller", - "type": "tuple" - }, - { - "indexed": false, - "internalType": "address", - "name": "voucherCloneAddress", - "type": "address" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.AuthToken", - "name": "authToken", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "SellerCreated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Seller", - "name": "seller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Seller", - "name": "pendingSeller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.AuthToken", - "name": "authToken", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.AuthToken", - "name": "pendingAuthToken", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "SellerUpdateApplied", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Seller", - "name": "pendingSeller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.AuthToken", - "name": "pendingAuthToken", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "SellerUpdatePending", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Seller", - "name": "seller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.AuthToken", - "name": "authToken", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "SellerUpdated", - "type": "event" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - } - ], - "name": "activateDisputeResolver", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "tokenName", - "type": "string" - }, - { - "internalType": "uint256", - "name": "feeAmount", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.DisputeResolverFee[]", - "name": "_disputeResolverFees", - "type": "tuple[]" - } - ], - "name": "addFeesToDisputeResolver", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - }, - { - "internalType": "uint256[]", - "name": "_sellerAllowList", - "type": "uint256[]" - } - ], - "name": "addSellersToAllowList", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - }, - { - "internalType": "uint256[]", - "name": "_sellerIds", - "type": "uint256[]" - } - ], - "name": "areSellersAllowed", - "outputs": [ - { - "internalType": "bool[]", - "name": "sellerAllowed", - "type": "bool[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "feePercentage", - "type": "uint256" - }, - { - "internalType": "address payable", - "name": "wallet", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Agent", - "name": "_agent", - "type": "tuple" - } - ], - "name": "createAgent", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address payable", - "name": "wallet", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Buyer", - "name": "_buyer", - "type": "tuple" - } - ], - "name": "createBuyer", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.DisputeResolver", - "name": "_disputeResolver", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "tokenName", - "type": "string" - }, - { - "internalType": "uint256", - "name": "feeAmount", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.DisputeResolverFee[]", - "name": "_disputeResolverFees", - "type": "tuple[]" - }, - { - "internalType": "uint256[]", - "name": "_sellerAllowList", - "type": "uint256[]" - } - ], - "name": "createDisputeResolver", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Seller", - "name": "_seller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.AuthToken", - "name": "_authToken", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "string", - "name": "contractURI", - "type": "string" - }, - { - "internalType": "uint256", - "name": "royaltyPercentage", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.VoucherInitValues", - "name": "_voucherInitValues", - "type": "tuple" - } - ], - "name": "createSeller", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_agentId", - "type": "uint256" - } - ], - "name": "getAgent", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "feePercentage", - "type": "uint256" - }, - { - "internalType": "address payable", - "name": "wallet", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Agent", - "name": "agent", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_buyerId", - "type": "uint256" - } - ], - "name": "getBuyer", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address payable", - "name": "wallet", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Buyer", - "name": "buyer", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - } - ], - "name": "getDisputeResolver", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.DisputeResolver", - "name": "disputeResolver", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "tokenName", - "type": "string" - }, - { - "internalType": "uint256", - "name": "feeAmount", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.DisputeResolverFee[]", - "name": "disputeResolverFees", - "type": "tuple[]" - }, - { - "internalType": "uint256[]", - "name": "sellerAllowList", - "type": "uint256[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_associatedAddress", - "type": "address" - } - ], - "name": "getDisputeResolverByAddress", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.DisputeResolver", - "name": "disputeResolver", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "tokenName", - "type": "string" - }, - { - "internalType": "uint256", - "name": "feeAmount", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.DisputeResolverFee[]", - "name": "disputeResolverFees", - "type": "tuple[]" - }, - { - "internalType": "uint256[]", - "name": "sellerAllowList", - "type": "uint256[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getNextAccountId", - "outputs": [ - { - "internalType": "uint256", - "name": "nextAccountId", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_sellerId", - "type": "uint256" - } - ], - "name": "getSeller", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Seller", - "name": "seller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.AuthToken", - "name": "authToken", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_associatedAddress", - "type": "address" - } - ], - "name": "getSellerByAddress", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Seller", - "name": "seller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.AuthToken", - "name": "authToken", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.AuthToken", - "name": "_associatedAuthToken", - "type": "tuple" - } - ], - "name": "getSellerByAuthToken", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Seller", - "name": "seller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.AuthToken", - "name": "authToken", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.DisputeResolverUpdateFields[]", - "name": "_fieldsToUpdate", - "type": "uint8[]" - } - ], - "name": "optInToDisputeResolverUpdate", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_sellerId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.SellerUpdateFields[]", - "name": "_fieldsToUpdate", - "type": "uint8[]" - } - ], - "name": "optInToSellerUpdate", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - }, - { - "internalType": "address[]", - "name": "_feeTokenAddresses", - "type": "address[]" - } - ], - "name": "removeFeesFromDisputeResolver", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - }, - { - "internalType": "uint256[]", - "name": "_sellerAllowList", - "type": "uint256[]" - } - ], - "name": "removeSellersFromAllowList", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "feePercentage", - "type": "uint256" - }, - { - "internalType": "address payable", - "name": "wallet", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Agent", - "name": "_agent", - "type": "tuple" - } - ], - "name": "updateAgent", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address payable", - "name": "wallet", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Buyer", - "name": "_buyer", - "type": "tuple" - } - ], - "name": "updateBuyer", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.DisputeResolver", - "name": "_disputeResolver", - "type": "tuple" - } - ], - "name": "updateDisputeResolver", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Seller", - "name": "_seller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.AuthToken", - "name": "_authToken", - "type": "tuple" - } - ], - "name": "updateSeller", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/packages/common/src/abis/IBosonDisputeHandler.json b/packages/common/src/abis/IBosonDisputeHandler.json deleted file mode 100644 index 17ee9a627..000000000 --- a/packages/common/src/abis/IBosonDisputeHandler.json +++ /dev/null @@ -1,645 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "_buyerPercent", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeDecided", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeEscalated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeExpired", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "buyerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeRaised", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "_buyerPercent", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeResolved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeRetracted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newDisputeTimeout", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeTimeoutExtended", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "EscalatedDisputeExpired", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "EscalatedDisputeRefused", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "entityId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "FundsEncumbered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "entityId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "FundsReleased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "withdrawnTo", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "FundsWithdrawn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "ProtocolFeeCollected", - "type": "event" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "_buyerPercent", - "type": "uint256" - } - ], - "name": "decideDispute", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "escalateDispute", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "expireDispute", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256[]", - "name": "_exchangeIds", - "type": "uint256[]" - } - ], - "name": "expireDisputeBatch", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "expireEscalatedDispute", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "_newDisputeTimeout", - "type": "uint256" - } - ], - "name": "extendDisputeTimeout", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "getDispute", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerPercent", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.DisputeState", - "name": "state", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.Dispute", - "name": "dispute", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputed", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalated", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "finalized", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "timeout", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.DisputeDates", - "name": "disputeDates", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "getDisputeState", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "internalType": "enum BosonTypes.DisputeState", - "name": "state", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "getDisputeTimeout", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "internalType": "uint256", - "name": "timeout", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "isDisputeFinalized", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "internalType": "bool", - "name": "isFinalized", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "raiseDispute", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "refuseEscalatedDispute", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "_buyerPercent", - "type": "uint256" - }, - { - "internalType": "bytes32", - "name": "_sigR", - "type": "bytes32" - }, - { - "internalType": "bytes32", - "name": "_sigS", - "type": "bytes32" - }, - { - "internalType": "uint8", - "name": "_sigV", - "type": "uint8" - } - ], - "name": "resolveDispute", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "retractDispute", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/packages/common/src/abis/IBosonExchangeHandler.json b/packages/common/src/abis/IBosonExchangeHandler.json deleted file mode 100644 index fab289f4d..000000000 --- a/packages/common/src/abis/IBosonExchangeHandler.json +++ /dev/null @@ -1,1065 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "buyerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "finalizedDate", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.ExchangeState", - "name": "state", - "type": "uint8" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Exchange", - "name": "exchange", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "committedDate", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "validUntilDate", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "redeemedDate", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "expired", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Voucher", - "name": "voucher", - "type": "tuple" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "BuyerCommitted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "buyerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "ExchangeCompleted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "entityId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "FundsEncumbered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "entityId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "FundsReleased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "withdrawnTo", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "FundsWithdrawn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "ProtocolFeeCollected", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "twinId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "supplyAvailable", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Twin", - "name": "twin", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "TwinCreated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "twinId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "TwinDeleted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "twinId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "TwinTransferFailed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "twinId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "TwinTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "VoucherCanceled", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "VoucherExpired", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "validUntil", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "VoucherExtended", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "VoucherRedeemed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "VoucherRevoked", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "newBuyerId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "VoucherTransferred", - "type": "event" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "cancelVoucher", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address payable", - "name": "_buyer", - "type": "address" - }, - { - "internalType": "uint256", - "name": "_offerId", - "type": "uint256" - } - ], - "name": "commitToOffer", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "completeExchange", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256[]", - "name": "_exchangeIds", - "type": "uint256[]" - } - ], - "name": "completeExchangeBatch", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "expireVoucher", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "_validUntilDate", - "type": "uint256" - } - ], - "name": "extendVoucher", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "getExchange", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "finalizedDate", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.ExchangeState", - "name": "state", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.Exchange", - "name": "exchange", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "committedDate", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "validUntilDate", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "redeemedDate", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "expired", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Voucher", - "name": "voucher", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "getExchangeState", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "internalType": "enum BosonTypes.ExchangeState", - "name": "state", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getNextExchangeId", - "outputs": [ - { - "internalType": "uint256", - "name": "nextExchangeId", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "getReceipt", - "outputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerDeposit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerCancelPenalty", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "protocolFee", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "agentFee", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferFees", - "name": "offerFees", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "agentId", - "type": "uint256" - }, - { - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "internalType": "uint256", - "name": "finalizedDate", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "enum BosonTypes.EvaluationMethod", - "name": "method", - "type": "uint8" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "threshold", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxCommits", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.Condition", - "name": "condition", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "committedDate", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "redeemedDate", - "type": "uint256" - }, - { - "internalType": "bool", - "name": "voucherExpired", - "type": "bool" - }, - { - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "disputedDate", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalatedDate", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.DisputeState", - "name": "disputeState", - "type": "uint8" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "twinId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.TwinReceipt[]", - "name": "twinReceipts", - "type": "tuple[]" - } - ], - "internalType": "struct BosonTypes.Receipt", - "name": "receipt", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "isExchangeFinalized", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "internalType": "bool", - "name": "isFinalized", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - }, - { - "internalType": "address payable", - "name": "_newBuyer", - "type": "address" - } - ], - "name": "onVoucherTransferred", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "redeemVoucher", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "revokeVoucher", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/packages/common/src/abis/IBosonFundsHandler.json b/packages/common/src/abis/IBosonFundsHandler.json deleted file mode 100644 index 35771a880..000000000 --- a/packages/common/src/abis/IBosonFundsHandler.json +++ /dev/null @@ -1,269 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "FundsDeposited", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "entityId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "FundsEncumbered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "entityId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "FundsReleased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "withdrawnTo", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "FundsWithdrawn", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "ProtocolFeeCollected", - "type": "event" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_sellerId", - "type": "uint256" - }, - { - "internalType": "address", - "name": "_tokenAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "_amount", - "type": "uint256" - } - ], - "name": "depositFunds", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_entityId", - "type": "uint256" - } - ], - "name": "getAvailableFunds", - "outputs": [ - { - "components": [ - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "tokenName", - "type": "string" - }, - { - "internalType": "uint256", - "name": "availableAmount", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.Funds[]", - "name": "availableFunds", - "type": "tuple[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_entityId", - "type": "uint256" - }, - { - "internalType": "address[]", - "name": "_tokenList", - "type": "address[]" - }, - { - "internalType": "uint256[]", - "name": "_tokenAmounts", - "type": "uint256[]" - } - ], - "name": "withdrawFunds", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address[]", - "name": "_tokenList", - "type": "address[]" - }, - { - "internalType": "uint256[]", - "name": "_tokenAmounts", - "type": "uint256[]" - } - ], - "name": "withdrawProtocolFees", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/packages/common/src/abis/IBosonGroupHandler.json b/packages/common/src/abis/IBosonGroupHandler.json deleted file mode 100644 index e01f518c2..000000000 --- a/packages/common/src/abis/IBosonGroupHandler.json +++ /dev/null @@ -1,418 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "groupId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256[]", - "name": "offerIds", - "type": "uint256[]" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Group", - "name": "group", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "enum BosonTypes.EvaluationMethod", - "name": "method", - "type": "uint8" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "threshold", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxCommits", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Condition", - "name": "condition", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "GroupCreated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "groupId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256[]", - "name": "offerIds", - "type": "uint256[]" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Group", - "name": "group", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "enum BosonTypes.EvaluationMethod", - "name": "method", - "type": "uint8" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "threshold", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxCommits", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Condition", - "name": "condition", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "GroupUpdated", - "type": "event" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_groupId", - "type": "uint256" - }, - { - "internalType": "uint256[]", - "name": "_offerIds", - "type": "uint256[]" - } - ], - "name": "addOffersToGroup", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256[]", - "name": "offerIds", - "type": "uint256[]" - } - ], - "internalType": "struct BosonTypes.Group", - "name": "_group", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "enum BosonTypes.EvaluationMethod", - "name": "method", - "type": "uint8" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "threshold", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxCommits", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.Condition", - "name": "_condition", - "type": "tuple" - } - ], - "name": "createGroup", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_groupId", - "type": "uint256" - } - ], - "name": "getGroup", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256[]", - "name": "offerIds", - "type": "uint256[]" - } - ], - "internalType": "struct BosonTypes.Group", - "name": "group", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "enum BosonTypes.EvaluationMethod", - "name": "method", - "type": "uint8" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "threshold", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxCommits", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.Condition", - "name": "condition", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getNextGroupId", - "outputs": [ - { - "internalType": "uint256", - "name": "nextGroupId", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_groupId", - "type": "uint256" - }, - { - "internalType": "uint256[]", - "name": "_offerIds", - "type": "uint256[]" - } - ], - "name": "removeOffersFromGroup", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_groupId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "enum BosonTypes.EvaluationMethod", - "name": "method", - "type": "uint8" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "threshold", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxCommits", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.Condition", - "name": "_condition", - "type": "tuple" - } - ], - "name": "setGroupCondition", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/packages/common/src/abis/IBosonMetaTransactionsHandler.json b/packages/common/src/abis/IBosonMetaTransactionsHandler.json deleted file mode 100644 index 73fc3e156..000000000 --- a/packages/common/src/abis/IBosonMetaTransactionsHandler.json +++ /dev/null @@ -1,106 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "userAddress", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "relayerAddress", - "type": "address" - }, - { - "indexed": true, - "internalType": "string", - "name": "functionName", - "type": "string" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - } - ], - "name": "MetaTransactionExecuted", - "type": "event" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_userAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "_functionName", - "type": "string" - }, - { - "internalType": "bytes", - "name": "_functionSignature", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "_nonce", - "type": "uint256" - }, - { - "internalType": "bytes32", - "name": "_sigR", - "type": "bytes32" - }, - { - "internalType": "bytes32", - "name": "_sigS", - "type": "bytes32" - }, - { - "internalType": "uint8", - "name": "_sigV", - "type": "uint8" - } - ], - "name": "executeMetaTransaction", - "outputs": [ - { - "internalType": "bytes", - "name": "", - "type": "bytes" - } - ], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "_associatedAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "_nonce", - "type": "uint256" - } - ], - "name": "isUsedNonce", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/packages/common/src/abis/IBosonOfferHandler.json b/packages/common/src/abis/IBosonOfferHandler.json deleted file mode 100644 index 2eacb3351..000000000 --- a/packages/common/src/abis/IBosonOfferHandler.json +++ /dev/null @@ -1,784 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerDeposit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerCancelPenalty", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "quantityAvailable", - "type": "uint256" - }, - { - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "string", - "name": "metadataHash", - "type": "string" - }, - { - "internalType": "bool", - "name": "voided", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Offer", - "name": "offer", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "validFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "validUntil", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableUntil", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.OfferDates", - "name": "offerDates", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherValid", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "resolutionPeriod", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.OfferDurations", - "name": "offerDurations", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "feeAmount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerEscalationDeposit", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolutionTerms", - "name": "disputeResolutionTerms", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "protocolFee", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "agentFee", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.OfferFees", - "name": "offerFees", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "agentId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "OfferCreated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "validUntilDate", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "OfferExtended", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "OfferVoided", - "type": "event" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerDeposit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerCancelPenalty", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "quantityAvailable", - "type": "uint256" - }, - { - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "string", - "name": "metadataHash", - "type": "string" - }, - { - "internalType": "bool", - "name": "voided", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Offer", - "name": "_offer", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "validFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "validUntil", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableUntil", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDates", - "name": "_offerDates", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherValid", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "resolutionPeriod", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDurations", - "name": "_offerDurations", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "_agentId", - "type": "uint256" - } - ], - "name": "createOffer", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerDeposit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerCancelPenalty", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "quantityAvailable", - "type": "uint256" - }, - { - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "string", - "name": "metadataHash", - "type": "string" - }, - { - "internalType": "bool", - "name": "voided", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Offer[]", - "name": "_offers", - "type": "tuple[]" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "validFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "validUntil", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableUntil", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDates[]", - "name": "_offerDates", - "type": "tuple[]" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherValid", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "resolutionPeriod", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDurations[]", - "name": "_offerDurations", - "type": "tuple[]" - }, - { - "internalType": "uint256[]", - "name": "_disputeResolverIds", - "type": "uint256[]" - }, - { - "internalType": "uint256[]", - "name": "_agentIds", - "type": "uint256[]" - } - ], - "name": "createOfferBatch", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_offerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "_validUntilDate", - "type": "uint256" - } - ], - "name": "extendOffer", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256[]", - "name": "_offerIds", - "type": "uint256[]" - }, - { - "internalType": "uint256", - "name": "_validUntilDate", - "type": "uint256" - } - ], - "name": "extendOfferBatch", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_offerId", - "type": "uint256" - } - ], - "name": "getAgentIdByOffer", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "internalType": "uint256", - "name": "agentId", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getNextOfferId", - "outputs": [ - { - "internalType": "uint256", - "name": "nextOfferId", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_offerId", - "type": "uint256" - } - ], - "name": "getOffer", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerDeposit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerCancelPenalty", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "quantityAvailable", - "type": "uint256" - }, - { - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "string", - "name": "metadataHash", - "type": "string" - }, - { - "internalType": "bool", - "name": "voided", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Offer", - "name": "offer", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "validFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "validUntil", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableUntil", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDates", - "name": "offerDates", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherValid", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "resolutionPeriod", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDurations", - "name": "offerDurations", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "feeAmount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerEscalationDeposit", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.DisputeResolutionTerms", - "name": "disputeResolutionTerms", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "protocolFee", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "agentFee", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferFees", - "name": "offerFees", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_offerId", - "type": "uint256" - } - ], - "name": "isOfferVoided", - "outputs": [ - { - "internalType": "bool", - "name": "exists", - "type": "bool" - }, - { - "internalType": "bool", - "name": "offerVoided", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_offerId", - "type": "uint256" - } - ], - "name": "voidOffer", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256[]", - "name": "_offerIds", - "type": "uint256[]" - } - ], - "name": "voidOfferBatch", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/packages/common/src/abis/IBosonOrchestrationHandler.json b/packages/common/src/abis/IBosonOrchestrationHandler.json deleted file mode 100644 index 02207a635..000000000 --- a/packages/common/src/abis/IBosonOrchestrationHandler.json +++ /dev/null @@ -1,3314 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "agentId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "feePercentage", - "type": "uint256" - }, - { - "internalType": "address payable", - "name": "wallet", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Agent", - "name": "agent", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "AgentCreated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "agentId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "feePercentage", - "type": "uint256" - }, - { - "internalType": "address payable", - "name": "wallet", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Agent", - "name": "agent", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "AgentUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256[]", - "name": "addedSellers", - "type": "uint256[]" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "AllowedSellersAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256[]", - "name": "removedSellers", - "type": "uint256[]" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "AllowedSellersRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "bundleId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256[]", - "name": "offerIds", - "type": "uint256[]" - }, - { - "internalType": "uint256[]", - "name": "twinIds", - "type": "uint256[]" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Bundle", - "name": "bundle", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "BundleCreated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "buyerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address payable", - "name": "wallet", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Buyer", - "name": "buyer", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "BuyerCreated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "buyerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address payable", - "name": "wallet", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Buyer", - "name": "buyer", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "BuyerUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolver", - "name": "disputeResolver", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeResolverActivated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolver", - "name": "disputeResolver", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "tokenName", - "type": "string" - }, - { - "internalType": "uint256", - "name": "feeAmount", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolverFee[]", - "name": "disputeResolverFees", - "type": "tuple[]" - }, - { - "indexed": false, - "internalType": "uint256[]", - "name": "sellerAllowList", - "type": "uint256[]" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeResolverCreated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "string", - "name": "tokenName", - "type": "string" - }, - { - "internalType": "uint256", - "name": "feeAmount", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolverFee[]", - "name": "disputeResolverFees", - "type": "tuple[]" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeResolverFeesAdded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address[]", - "name": "feeTokensRemoved", - "type": "address[]" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeResolverFeesRemoved", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolver", - "name": "disputeResolver", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolver", - "name": "pendingDisputeResolver", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeResolverUpdateApplied", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolver", - "name": "pendingDisputeResolver", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeResolverUpdatePending", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolver", - "name": "disputeResolver", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "DisputeResolverUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "groupId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256[]", - "name": "offerIds", - "type": "uint256[]" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Group", - "name": "group", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "enum BosonTypes.EvaluationMethod", - "name": "method", - "type": "uint8" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "threshold", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxCommits", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Condition", - "name": "condition", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "GroupCreated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "groupId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256[]", - "name": "offerIds", - "type": "uint256[]" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Group", - "name": "group", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "enum BosonTypes.EvaluationMethod", - "name": "method", - "type": "uint8" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "threshold", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxCommits", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Condition", - "name": "condition", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "GroupUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerDeposit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerCancelPenalty", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "quantityAvailable", - "type": "uint256" - }, - { - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "string", - "name": "metadataHash", - "type": "string" - }, - { - "internalType": "bool", - "name": "voided", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Offer", - "name": "offer", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "validFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "validUntil", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableUntil", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.OfferDates", - "name": "offerDates", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherValid", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "resolutionPeriod", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.OfferDurations", - "name": "offerDurations", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputeResolverId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "escalationResponsePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "feeAmount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerEscalationDeposit", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.DisputeResolutionTerms", - "name": "disputeResolutionTerms", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "protocolFee", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "agentFee", - "type": "uint256" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.OfferFees", - "name": "offerFees", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "agentId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "OfferCreated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "validUntilDate", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "OfferExtended", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "offerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "OfferVoided", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Seller", - "name": "seller", - "type": "tuple" - }, - { - "indexed": false, - "internalType": "address", - "name": "voucherCloneAddress", - "type": "address" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.AuthToken", - "name": "authToken", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "SellerCreated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Seller", - "name": "seller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Seller", - "name": "pendingSeller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.AuthToken", - "name": "authToken", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.AuthToken", - "name": "pendingAuthToken", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "SellerUpdateApplied", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Seller", - "name": "pendingSeller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.AuthToken", - "name": "pendingAuthToken", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "SellerUpdatePending", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Seller", - "name": "seller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.AuthToken", - "name": "authToken", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "SellerUpdated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "twinId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "supplyAvailable", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "indexed": false, - "internalType": "struct BosonTypes.Twin", - "name": "twin", - "type": "tuple" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "TwinCreated", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "twinId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "TwinDeleted", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "twinId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "TwinTransferFailed", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "twinId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "exchangeId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "address", - "name": "executedBy", - "type": "address" - } - ], - "name": "TwinTransferred", - "type": "event" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerDeposit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerCancelPenalty", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "quantityAvailable", - "type": "uint256" - }, - { - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "string", - "name": "metadataHash", - "type": "string" - }, - { - "internalType": "bool", - "name": "voided", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Offer", - "name": "_offer", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "validFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "validUntil", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableUntil", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDates", - "name": "_offerDates", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherValid", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "resolutionPeriod", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDurations", - "name": "_offerDurations", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "_groupId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "_agentId", - "type": "uint256" - } - ], - "name": "createOfferAddToGroup", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerDeposit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerCancelPenalty", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "quantityAvailable", - "type": "uint256" - }, - { - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "string", - "name": "metadataHash", - "type": "string" - }, - { - "internalType": "bool", - "name": "voided", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Offer", - "name": "_offer", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "validFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "validUntil", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableUntil", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDates", - "name": "_offerDates", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherValid", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "resolutionPeriod", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDurations", - "name": "_offerDurations", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "supplyAvailable", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.Twin", - "name": "_twin", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_agentId", - "type": "uint256" - } - ], - "name": "createOfferAndTwinWithBundle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerDeposit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerCancelPenalty", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "quantityAvailable", - "type": "uint256" - }, - { - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "string", - "name": "metadataHash", - "type": "string" - }, - { - "internalType": "bool", - "name": "voided", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Offer", - "name": "_offer", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "validFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "validUntil", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableUntil", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDates", - "name": "_offerDates", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherValid", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "resolutionPeriod", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDurations", - "name": "_offerDurations", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "enum BosonTypes.EvaluationMethod", - "name": "method", - "type": "uint8" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "threshold", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxCommits", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.Condition", - "name": "_condition", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_agentId", - "type": "uint256" - } - ], - "name": "createOfferWithCondition", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerDeposit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerCancelPenalty", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "quantityAvailable", - "type": "uint256" - }, - { - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "string", - "name": "metadataHash", - "type": "string" - }, - { - "internalType": "bool", - "name": "voided", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Offer", - "name": "_offer", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "validFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "validUntil", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableUntil", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDates", - "name": "_offerDates", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherValid", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "resolutionPeriod", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDurations", - "name": "_offerDurations", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "enum BosonTypes.EvaluationMethod", - "name": "method", - "type": "uint8" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "threshold", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxCommits", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.Condition", - "name": "_condition", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "supplyAvailable", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.Twin", - "name": "_twin", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_agentId", - "type": "uint256" - } - ], - "name": "createOfferWithConditionAndTwinAndBundle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Seller", - "name": "_seller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerDeposit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerCancelPenalty", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "quantityAvailable", - "type": "uint256" - }, - { - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "string", - "name": "metadataHash", - "type": "string" - }, - { - "internalType": "bool", - "name": "voided", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Offer", - "name": "_offer", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "validFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "validUntil", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableUntil", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDates", - "name": "_offerDates", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherValid", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "resolutionPeriod", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDurations", - "name": "_offerDurations", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.AuthToken", - "name": "_authToken", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "string", - "name": "contractURI", - "type": "string" - }, - { - "internalType": "uint256", - "name": "royaltyPercentage", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.VoucherInitValues", - "name": "_voucherInitValues", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_agentId", - "type": "uint256" - } - ], - "name": "createSellerAndOffer", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Seller", - "name": "_seller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerDeposit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerCancelPenalty", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "quantityAvailable", - "type": "uint256" - }, - { - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "string", - "name": "metadataHash", - "type": "string" - }, - { - "internalType": "bool", - "name": "voided", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Offer", - "name": "_offer", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "validFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "validUntil", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableUntil", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDates", - "name": "_offerDates", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherValid", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "resolutionPeriod", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDurations", - "name": "_offerDurations", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "supplyAvailable", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.Twin", - "name": "_twin", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.AuthToken", - "name": "_authToken", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "string", - "name": "contractURI", - "type": "string" - }, - { - "internalType": "uint256", - "name": "royaltyPercentage", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.VoucherInitValues", - "name": "_voucherInitValues", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_agentId", - "type": "uint256" - } - ], - "name": "createSellerAndOfferAndTwinWithBundle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Seller", - "name": "_seller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerDeposit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerCancelPenalty", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "quantityAvailable", - "type": "uint256" - }, - { - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "string", - "name": "metadataHash", - "type": "string" - }, - { - "internalType": "bool", - "name": "voided", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Offer", - "name": "_offer", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "validFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "validUntil", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableUntil", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDates", - "name": "_offerDates", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherValid", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "resolutionPeriod", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDurations", - "name": "_offerDurations", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "enum BosonTypes.EvaluationMethod", - "name": "method", - "type": "uint8" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "threshold", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxCommits", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.Condition", - "name": "_condition", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.AuthToken", - "name": "_authToken", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "string", - "name": "contractURI", - "type": "string" - }, - { - "internalType": "uint256", - "name": "royaltyPercentage", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.VoucherInitValues", - "name": "_voucherInitValues", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_agentId", - "type": "uint256" - } - ], - "name": "createSellerAndOfferWithCondition", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "address", - "name": "admin", - "type": "address" - }, - { - "internalType": "address", - "name": "clerk", - "type": "address" - }, - { - "internalType": "address payable", - "name": "treasury", - "type": "address" - }, - { - "internalType": "bool", - "name": "active", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Seller", - "name": "_seller", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "price", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerDeposit", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "buyerCancelPenalty", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "quantityAvailable", - "type": "uint256" - }, - { - "internalType": "address", - "name": "exchangeToken", - "type": "address" - }, - { - "internalType": "string", - "name": "metadataUri", - "type": "string" - }, - { - "internalType": "string", - "name": "metadataHash", - "type": "string" - }, - { - "internalType": "bool", - "name": "voided", - "type": "bool" - } - ], - "internalType": "struct BosonTypes.Offer", - "name": "_offer", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "validFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "validUntil", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableFrom", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherRedeemableUntil", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDates", - "name": "_offerDates", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "disputePeriod", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "voucherValid", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "resolutionPeriod", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.OfferDurations", - "name": "_offerDurations", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_disputeResolverId", - "type": "uint256" - }, - { - "components": [ - { - "internalType": "enum BosonTypes.EvaluationMethod", - "name": "method", - "type": "uint8" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "threshold", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "maxCommits", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.Condition", - "name": "_condition", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "id", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "supplyAvailable", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "address", - "name": "tokenAddress", - "type": "address" - }, - { - "internalType": "enum BosonTypes.TokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.Twin", - "name": "_twin", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "enum BosonTypes.AuthTokenType", - "name": "tokenType", - "type": "uint8" - } - ], - "internalType": "struct BosonTypes.AuthToken", - "name": "_authToken", - "type": "tuple" - }, - { - "components": [ - { - "internalType": "string", - "name": "contractURI", - "type": "string" - }, - { - "internalType": "uint256", - "name": "royaltyPercentage", - "type": "uint256" - } - ], - "internalType": "struct BosonTypes.VoucherInitValues", - "name": "_voucherInitValues", - "type": "tuple" - }, - { - "internalType": "uint256", - "name": "_agentId", - "type": "uint256" - } - ], - "name": "createSellerAndOfferWithConditionAndTwinAndBundle", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/packages/common/src/abis/IBosonVoucher.json b/packages/common/src/abis/IBosonVoucher.json deleted file mode 100644 index 3d3372be3..000000000 --- a/packages/common/src/abis/IBosonVoucher.json +++ /dev/null @@ -1,521 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "approved", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - } - ], - "name": "Approval", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "indexed": false, - "internalType": "bool", - "name": "approved", - "type": "bool" - } - ], - "name": "ApprovalForAll", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "string", - "name": "contractURI", - "type": "string" - } - ], - "name": "ContractURIChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint256", - "name": "royaltyPercentage", - "type": "uint256" - } - ], - "name": "RoyaltyPercentageChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - } - ], - "name": "Transfer", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "sellerId", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint256", - "name": "royaltyPercentage", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "string", - "name": "contractURI", - "type": "string" - } - ], - "name": "VoucherInitialized", - "type": "event" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "owner", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "internalType": "uint256", - "name": "balance", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - } - ], - "name": "burnVoucher", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "contractURI", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - } - ], - "name": "getApproved", - "outputs": [ - { - "internalType": "address", - "name": "operator", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getRoyaltyPercentage", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getSellerId", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "internalType": "address", - "name": "operator", - "type": "address" - } - ], - "name": "isApprovedForAll", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_exchangeId", - "type": "uint256" - }, - { - "internalType": "address", - "name": "_buyer", - "type": "address" - } - ], - "name": "issueVoucher", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "name", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - } - ], - "name": "ownerOf", - "outputs": [ - { - "internalType": "address", - "name": "owner", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_tokenId", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "_salePrice", - "type": "uint256" - } - ], - "name": "royaltyInfo", - "outputs": [ - { - "internalType": "address", - "name": "receiver", - "type": "address" - }, - { - "internalType": "uint256", - "name": "royaltyAmount", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - } - ], - "name": "safeTransferFrom", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "safeTransferFrom", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "operator", - "type": "address" - }, - { - "internalType": "bool", - "name": "_approved", - "type": "bool" - } - ], - "name": "setApprovalForAll", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "string", - "name": "_newContractURI", - "type": "string" - } - ], - "name": "setContractURI", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "_newRoyaltyPercentage", - "type": "uint256" - } - ], - "name": "setRoyaltyPercentage", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes4", - "name": "interfaceId", - "type": "bytes4" - } - ], - "name": "supportsInterface", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "symbol", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - } - ], - "name": "tokenURI", - "outputs": [ - { - "internalType": "string", - "name": "", - "type": "string" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - } -] diff --git a/packages/common/src/abis/MockNativeMetaTransaction.json b/packages/common/src/abis/MockNativeMetaTransaction.json deleted file mode 100644 index 66e38c116..000000000 --- a/packages/common/src/abis/MockNativeMetaTransaction.json +++ /dev/null @@ -1,111 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "userAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "address payable", - "name": "relayerAddress", - "type": "address" - }, - { - "indexed": false, - "internalType": "bytes", - "name": "functionSignature", - "type": "bytes" - } - ], - "name": "MetaTransactionExecuted", - "type": "event" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "userAddress", - "type": "address" - }, - { - "internalType": "bytes", - "name": "functionSignature", - "type": "bytes" - }, - { - "internalType": "bytes32", - "name": "sigR", - "type": "bytes32" - }, - { - "internalType": "bytes32", - "name": "sigS", - "type": "bytes32" - }, - { - "internalType": "uint8", - "name": "sigV", - "type": "uint8" - } - ], - "name": "executeMetaTransaction", - "outputs": [ - { - "internalType": "bytes", - "name": "", - "type": "bytes" - } - ], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [], - "name": "getChainId", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getDomainSeperator", - "outputs": [ - { - "internalType": "bytes32", - "name": "", - "type": "bytes32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "user", - "type": "address" - } - ], - "name": "getNonce", - "outputs": [ - { - "internalType": "uint256", - "name": "nonce", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - } -] diff --git a/packages/common/src/abis/ProtocolDiamond.json b/packages/common/src/abis/ProtocolDiamond.json deleted file mode 100644 index e7cc746a2..000000000 --- a/packages/common/src/abis/ProtocolDiamond.json +++ /dev/null @@ -1,48 +0,0 @@ -[ - { - "inputs": [ - { - "internalType": "contract IAccessControl", - "name": "_accessController", - "type": "address" - }, - { - "components": [ - { - "internalType": "address", - "name": "facetAddress", - "type": "address" - }, - { - "internalType": "enum IDiamondCut.FacetCutAction", - "name": "action", - "type": "uint8" - }, - { - "internalType": "bytes4[]", - "name": "functionSelectors", - "type": "bytes4[]" - } - ], - "internalType": "struct IDiamondCut.FacetCut[]", - "name": "_facetCuts", - "type": "tuple[]" - }, - { - "internalType": "bytes4[]", - "name": "_interfaceIds", - "type": "bytes4[]" - } - ], - "stateMutability": "nonpayable", - "type": "constructor" - }, - { - "stateMutability": "payable", - "type": "fallback" - }, - { - "stateMutability": "payable", - "type": "receive" - } -] From a4c4bb6d9aee5f45ad2a8abbd9423f2eec7ab67f Mon Sep 17 00:00:00 2001 From: Albert Folch Date: Fri, 30 Dec 2022 13:50:31 +0100 Subject: [PATCH 3/9] upgrade --- contracts/hardhat.config.js | 13 +- contracts/scripts/deploy.js | 14 - e2e/tests/utils.ts | 12 +- packages/common/src/abis/ERC1155.json | 276 + packages/common/src/abis/ERC20.json | 222 + .../common/src/abis/ERC721Enumerable.json | 434 ++ .../common/src/abis/IBosonAccountHandler.json | 2073 +++++++ .../common/src/abis/IBosonDisputeHandler.json | 645 +++ .../src/abis/IBosonExchangeHandler.json | 1088 ++++ .../common/src/abis/IBosonFundsHandler.json | 269 + .../common/src/abis/IBosonGroupHandler.json | 418 ++ .../abis/IBosonMetaTransactionsHandler.json | 187 + .../common/src/abis/IBosonOfferHandler.json | 839 +++ .../src/abis/IBosonOrchestrationHandler.json | 4792 +++++++++++++++++ packages/common/src/abis/IBosonVoucher.json | 686 +++ .../src/abis/MockNativeMetaTransaction.json | 111 + packages/common/src/abis/ProtocolDiamond.json | 48 + packages/common/src/configs.ts | 4 +- packages/ethers-sdk/src/contracts/ERC1155.ts | 443 ++ .../src/contracts/IBosonAccountHandler.ts | 248 +- .../src/contracts/IBosonExchangeHandler.ts | 44 + .../src/contracts/IBosonGroupHandler.ts | 417 ++ .../IBosonMetaTransactionsHandler.ts | 120 + .../src/contracts/IBosonOfferHandler.ts | 69 + .../contracts/IBosonOrchestrationHandler.ts | 869 ++- .../ethers-sdk/src/contracts/IBosonVoucher.ts | 228 + .../contracts/MockNativeMetaTransaction.ts | 199 + .../contracts/factories/ERC1155__factory.ts | 297 + .../IBosonAccountHandler__factory.ts | 423 +- .../IBosonExchangeHandler__factory.ts | 23 + .../factories/IBosonGroupHandler__factory.ts | 442 ++ .../IBosonMetaTransactionsHandler__factory.ts | 81 + .../factories/IBosonOfferHandler__factory.ts | 55 + .../IBosonOrchestrationHandler__factory.ts | 2034 ++++++- .../factories/IBosonVoucher__factory.ts | 165 + .../MockNativeMetaTransaction__factory.ts | 139 + packages/ethers-sdk/src/contracts/index.ts | 6 + 37 files changed, 18241 insertions(+), 192 deletions(-) create mode 100644 packages/common/src/abis/ERC1155.json create mode 100644 packages/common/src/abis/ERC20.json create mode 100644 packages/common/src/abis/ERC721Enumerable.json create mode 100644 packages/common/src/abis/IBosonAccountHandler.json create mode 100644 packages/common/src/abis/IBosonDisputeHandler.json create mode 100644 packages/common/src/abis/IBosonExchangeHandler.json create mode 100644 packages/common/src/abis/IBosonFundsHandler.json create mode 100644 packages/common/src/abis/IBosonGroupHandler.json create mode 100644 packages/common/src/abis/IBosonMetaTransactionsHandler.json create mode 100644 packages/common/src/abis/IBosonOfferHandler.json create mode 100644 packages/common/src/abis/IBosonOrchestrationHandler.json create mode 100644 packages/common/src/abis/IBosonVoucher.json create mode 100644 packages/common/src/abis/MockNativeMetaTransaction.json create mode 100644 packages/common/src/abis/ProtocolDiamond.json create mode 100644 packages/ethers-sdk/src/contracts/ERC1155.ts create mode 100644 packages/ethers-sdk/src/contracts/IBosonGroupHandler.ts create mode 100644 packages/ethers-sdk/src/contracts/MockNativeMetaTransaction.ts create mode 100644 packages/ethers-sdk/src/contracts/factories/ERC1155__factory.ts create mode 100644 packages/ethers-sdk/src/contracts/factories/IBosonGroupHandler__factory.ts create mode 100644 packages/ethers-sdk/src/contracts/factories/MockNativeMetaTransaction__factory.ts diff --git a/contracts/hardhat.config.js b/contracts/hardhat.config.js index 87ce1440c..85f8dc9a5 100644 --- a/contracts/hardhat.config.js +++ b/contracts/hardhat.config.js @@ -25,7 +25,18 @@ const accountsFromEnv = process.env.DEPLOYER_PK * @type import('hardhat/config').HardhatUserConfig */ module.exports = { - solidity: "0.8.9", + solidity: { + version: "0.8.9", + settings: { + optimizer: { + enabled: true, + runs: 200, + details: { + yul: true + } + } + } + }, networks: { hardhat: { allowUnlimitedContractSize: true, diff --git a/contracts/scripts/deploy.js b/contracts/scripts/deploy.js index 901b9d8a8..f6886cd33 100644 --- a/contracts/scripts/deploy.js +++ b/contracts/scripts/deploy.js @@ -17,9 +17,6 @@ const { const { deployProtocolClients } = require("../protocol-contracts/scripts/util/deploy-protocol-clients.js"); -const { - deployProtocolConfigFacet -} = require("../protocol-contracts/scripts/util/deploy-protocol-config-facet.js"); const { deployProtocolHandlerFacets } = require("../protocol-contracts/scripts/util/deploy-protocol-handler-facets.js"); @@ -157,17 +154,6 @@ async function main() { // Temporarily grant UPGRADER role to deployer account await accessController.grantRole(Role.UPGRADER, deployer); - const { - facets: [configHandlerFacet] - } = await deployProtocolConfigFacet(protocolDiamond, config, gasLimit); - deploymentComplete( - "ConfigHandlerFacet", - configHandlerFacet.address, - [], - "", - contracts - ); - // Deploy and cut facets const deployedFacets = await deployProtocolHandlerFacets( protocolDiamond, diff --git a/e2e/tests/utils.ts b/e2e/tests/utils.ts index f8b98eaf5..a5fa77a75 100644 --- a/e2e/tests/utils.ts +++ b/e2e/tests/utils.ts @@ -272,6 +272,7 @@ export async function createDisputeResolver( const receipt = await ( await drCoreSDK.createDisputeResolver(disputeResolverToCreate) ).wait(); + console.log("receipt", receipt); const disputeResolverId = drCoreSDK.getDisputeResolverIdFromLogs( receipt.logs ); @@ -432,7 +433,10 @@ export async function createSeller( ); await waitForGraphNodeIndexing(); - const seller = await coreSDK.getSellerById(createdSellerId as string); + if (createdSellerId === null) { + throw new Error("Failed to create seller"); + } + const seller = await coreSDK.getSellerById(createdSellerId); return seller; } @@ -503,9 +507,11 @@ export async function createSellerAndOffer( const createdOfferId = coreSDK.getCreatedOfferIdFromLogs( createOfferTxReceipt.logs ); - + if (createdOfferId === null) { + throw new Error("Failed to create offer"); + } await waitForGraphNodeIndexing(); - const offer = await coreSDK.getOfferById(createdOfferId as string); + const offer = await coreSDK.getOfferById(createdOfferId); return offer; } diff --git a/packages/common/src/abis/ERC1155.json b/packages/common/src/abis/ERC1155.json new file mode 100644 index 000000000..0107f8f70 --- /dev/null +++ b/packages/common/src/abis/ERC1155.json @@ -0,0 +1,276 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "_owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "_operator", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "_approved", + "type": "bool" + } + ], + "name": "ApprovalForAll", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "_operator", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "_from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "_to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256[]", + "name": "_ids", + "type": "uint256[]" + }, + { + "indexed": false, + "internalType": "uint256[]", + "name": "_amounts", + "type": "uint256[]" + } + ], + "name": "TransferBatch", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "_operator", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "_from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "_to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "_id", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "_amount", + "type": "uint256" + } + ], + "name": "TransferSingle", + "type": "event" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_owner", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_id", + "type": "uint256" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "_owners", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "_ids", + "type": "uint256[]" + } + ], + "name": "balanceOfBatch", + "outputs": [ + { + "internalType": "uint256[]", + "name": "", + "type": "uint256[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_owner", + "type": "address" + }, + { + "internalType": "address", + "name": "_operator", + "type": "address" + } + ], + "name": "isApprovedForAll", + "outputs": [ + { + "internalType": "bool", + "name": "isOperator", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_from", + "type": "address" + }, + { + "internalType": "address", + "name": "_to", + "type": "address" + }, + { + "internalType": "uint256[]", + "name": "_ids", + "type": "uint256[]" + }, + { + "internalType": "uint256[]", + "name": "_amounts", + "type": "uint256[]" + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes" + } + ], + "name": "safeBatchTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_from", + "type": "address" + }, + { + "internalType": "address", + "name": "_to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_amount", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes" + } + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_operator", + "type": "address" + }, + { + "internalType": "bool", + "name": "_approved", + "type": "bool" + } + ], + "name": "setApprovalForAll", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "_interfaceID", + "type": "bytes4" + } + ], + "name": "supportsInterface", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "pure", + "type": "function" + } + ] \ No newline at end of file diff --git a/packages/common/src/abis/ERC20.json b/packages/common/src/abis/ERC20.json new file mode 100644 index 000000000..405d6b364 --- /dev/null +++ b/packages/common/src/abis/ERC20.json @@ -0,0 +1,222 @@ +[ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_spender", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_from", + "type": "address" + }, + { + "name": "_to", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint8" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_owner", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "balance", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_to", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_owner", + "type": "address" + }, + { + "name": "_spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "payable": true, + "stateMutability": "payable", + "type": "fallback" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + } +] diff --git a/packages/common/src/abis/ERC721Enumerable.json b/packages/common/src/abis/ERC721Enumerable.json new file mode 100644 index 000000000..b972378ed --- /dev/null +++ b/packages/common/src/abis/ERC721Enumerable.json @@ -0,0 +1,434 @@ +[ + { + "constant": true, + "inputs": [ + { + "name": "interfaceId", + "type": "bytes4" + } + ], + "name": "supportsInterface", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function", + "signature": "0x01ffc9a7" + }, + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function", + "signature": "0x06fdde03" + }, + { + "constant": true, + "inputs": [ + { + "name": "tokenId", + "type": "uint256" + } + ], + "name": "getApproved", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function", + "signature": "0x081812fc" + }, + { + "constant": false, + "inputs": [ + { + "name": "to", + "type": "address" + }, + { + "name": "tokenId", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function", + "signature": "0x095ea7b3" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function", + "signature": "0x18160ddd" + }, + { + "constant": false, + "inputs": [ + { + "name": "from", + "type": "address" + }, + { + "name": "to", + "type": "address" + }, + { + "name": "tokenId", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function", + "signature": "0x23b872dd" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "index", + "type": "uint256" + } + ], + "name": "tokenOfOwnerByIndex", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function", + "signature": "0x2f745c59" + }, + { + "constant": false, + "inputs": [ + { + "name": "from", + "type": "address" + }, + { + "name": "to", + "type": "address" + }, + { + "name": "tokenId", + "type": "uint256" + } + ], + "name": "safeTransferFrom", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function", + "signature": "0x42842e0e" + }, + { + "constant": true, + "inputs": [ + { + "name": "index", + "type": "uint256" + } + ], + "name": "tokenByIndex", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function", + "signature": "0x4f6ccce7" + }, + { + "constant": true, + "inputs": [ + { + "name": "tokenId", + "type": "uint256" + } + ], + "name": "ownerOf", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function", + "signature": "0x6352211e" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function", + "signature": "0x70a08231" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function", + "signature": "0x95d89b41" + }, + { + "constant": false, + "inputs": [ + { + "name": "to", + "type": "address" + }, + { + "name": "approved", + "type": "bool" + } + ], + "name": "setApprovalForAll", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function", + "signature": "0xa22cb465" + }, + { + "constant": false, + "inputs": [ + { + "name": "from", + "type": "address" + }, + { + "name": "to", + "type": "address" + }, + { + "name": "tokenId", + "type": "uint256" + }, + { + "name": "_data", + "type": "bytes" + } + ], + "name": "safeTransferFrom", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function", + "signature": "0xb88d4fde" + }, + { + "constant": true, + "inputs": [ + { + "name": "tokenId", + "type": "uint256" + } + ], + "name": "tokenURI", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function", + "signature": "0xc87b56dd" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "operator", + "type": "address" + } + ], + "name": "isApprovedForAll", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function", + "signature": "0xe985e9c5" + }, + { + "inputs": [ + { + "name": "name", + "type": "string" + }, + { + "name": "symbol", + "type": "string" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor", + "signature": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": true, + "name": "tokenId", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event", + "signature": "0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "approved", + "type": "address" + }, + { + "indexed": true, + "name": "tokenId", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event", + "signature": "0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "operator", + "type": "address" + }, + { + "indexed": false, + "name": "approved", + "type": "bool" + } + ], + "name": "ApprovalForAll", + "type": "event", + "signature": "0x17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31" + }, + { + "constant": false, + "inputs": [ + { + "name": "to", + "type": "address" + }, + { + "name": "tokenId", + "type": "uint256" + }, + { + "name": "tokenURI", + "type": "string" + } + ], + "name": "mint", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function", + "signature": "0xd3fc9864" + } +] \ No newline at end of file diff --git a/packages/common/src/abis/IBosonAccountHandler.json b/packages/common/src/abis/IBosonAccountHandler.json new file mode 100644 index 000000000..98b4d10bf --- /dev/null +++ b/packages/common/src/abis/IBosonAccountHandler.json @@ -0,0 +1,2073 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "agentId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "feePercentage", + "type": "uint256" + }, + { + "internalType": "address payable", + "name": "wallet", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Agent", + "name": "agent", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "AgentCreated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "agentId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "feePercentage", + "type": "uint256" + }, + { + "internalType": "address payable", + "name": "wallet", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Agent", + "name": "agent", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "AgentUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256[]", + "name": "addedSellers", + "type": "uint256[]" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "AllowedSellersAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256[]", + "name": "removedSellers", + "type": "uint256[]" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "AllowedSellersRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "buyerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address payable", + "name": "wallet", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Buyer", + "name": "buyer", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "BuyerCreated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "buyerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address payable", + "name": "wallet", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Buyer", + "name": "buyer", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "BuyerUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { "internalType": "uint256", "name": "id", "type": "uint256" }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { "internalType": "address", "name": "operator", "type": "address" }, + { "internalType": "address", "name": "admin", "type": "address" }, + { "internalType": "address", "name": "clerk", "type": "address" }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { "internalType": "string", "name": "metadataUri", "type": "string" }, + { "internalType": "bool", "name": "active", "type": "bool" } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolver", + "name": "disputeResolver", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeResolverActivated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolver", + "name": "disputeResolver", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "tokenName", + "type": "string" + }, + { + "internalType": "uint256", + "name": "feeAmount", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolverFee[]", + "name": "disputeResolverFees", + "type": "tuple[]" + }, + { + "indexed": false, + "internalType": "uint256[]", + "name": "sellerAllowList", + "type": "uint256[]" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeResolverCreated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "tokenName", + "type": "string" + }, + { + "internalType": "uint256", + "name": "feeAmount", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolverFee[]", + "name": "disputeResolverFees", + "type": "tuple[]" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeResolverFeesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address[]", + "name": "feeTokensRemoved", + "type": "address[]" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeResolverFeesRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolver", + "name": "disputeResolver", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolver", + "name": "pendingDisputeResolver", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeResolverUpdateApplied", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolver", + "name": "pendingDisputeResolver", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeResolverUpdatePending", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { "internalType": "uint256", "name": "id", "type": "uint256" }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { "internalType": "address", "name": "operator", "type": "address" }, + { "internalType": "address", "name": "admin", "type": "address" }, + { "internalType": "address", "name": "clerk", "type": "address" }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { "internalType": "string", "name": "metadataUri", "type": "string" }, + { "internalType": "bool", "name": "active", "type": "bool" } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolver", + "name": "disputeResolver", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeResolverUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Seller", + "name": "seller", + "type": "tuple" + }, + { + "indexed": false, + "internalType": "address", + "name": "voucherCloneAddress", + "type": "address" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.AuthToken", + "name": "authToken", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "SellerCreated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Seller", + "name": "seller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Seller", + "name": "pendingSeller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.AuthToken", + "name": "authToken", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.AuthToken", + "name": "pendingAuthToken", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "SellerUpdateApplied", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Seller", + "name": "pendingSeller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.AuthToken", + "name": "pendingAuthToken", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "SellerUpdatePending", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { "internalType": "uint256", "name": "id", "type": "uint256" }, + { "internalType": "address", "name": "operator", "type": "address" }, + { "internalType": "address", "name": "admin", "type": "address" }, + { "internalType": "address", "name": "clerk", "type": "address" }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { "internalType": "bool", "name": "active", "type": "bool" } + ], + "indexed": false, + "internalType": "struct BosonTypes.Seller", + "name": "seller", + "type": "tuple" + }, + { + "components": [ + { "internalType": "uint256", "name": "tokenId", "type": "uint256" }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.AuthToken", + "name": "authToken", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "SellerUpdated", + "type": "event" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "tokenName", + "type": "string" + }, + { + "internalType": "uint256", + "name": "feeAmount", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.DisputeResolverFee[]", + "name": "_disputeResolverFees", + "type": "tuple[]" + } + ], + "name": "addFeesToDisputeResolver", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256[]", + "name": "_sellerAllowList", + "type": "uint256[]" + } + ], + "name": "addSellersToAllowList", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256[]", + "name": "_sellerIds", + "type": "uint256[]" + } + ], + "name": "areSellersAllowed", + "outputs": [ + { + "internalType": "bool[]", + "name": "sellerAllowed", + "type": "bool[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "feePercentage", + "type": "uint256" + }, + { + "internalType": "address payable", + "name": "wallet", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Agent", + "name": "_agent", + "type": "tuple" + } + ], + "name": "createAgent", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address payable", + "name": "wallet", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Buyer", + "name": "_buyer", + "type": "tuple" + } + ], + "name": "createBuyer", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.DisputeResolver", + "name": "_disputeResolver", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "tokenName", + "type": "string" + }, + { + "internalType": "uint256", + "name": "feeAmount", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.DisputeResolverFee[]", + "name": "_disputeResolverFees", + "type": "tuple[]" + }, + { + "internalType": "uint256[]", + "name": "_sellerAllowList", + "type": "uint256[]" + } + ], + "name": "createDisputeResolver", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Seller", + "name": "_seller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.AuthToken", + "name": "_authToken", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "string", + "name": "contractURI", + "type": "string" + }, + { + "internalType": "uint256", + "name": "royaltyPercentage", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.VoucherInitValues", + "name": "_voucherInitValues", + "type": "tuple" + } + ], + "name": "createSeller", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "getAgent", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "feePercentage", + "type": "uint256" + }, + { + "internalType": "address payable", + "name": "wallet", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Agent", + "name": "agent", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_buyerId", + "type": "uint256" + } + ], + "name": "getBuyer", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address payable", + "name": "wallet", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Buyer", + "name": "buyer", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + } + ], + "name": "getDisputeResolver", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.DisputeResolver", + "name": "disputeResolver", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "tokenName", + "type": "string" + }, + { + "internalType": "uint256", + "name": "feeAmount", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.DisputeResolverFee[]", + "name": "disputeResolverFees", + "type": "tuple[]" + }, + { + "internalType": "uint256[]", + "name": "sellerAllowList", + "type": "uint256[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_associatedAddress", + "type": "address" + } + ], + "name": "getDisputeResolverByAddress", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.DisputeResolver", + "name": "disputeResolver", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "tokenName", + "type": "string" + }, + { + "internalType": "uint256", + "name": "feeAmount", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.DisputeResolverFee[]", + "name": "disputeResolverFees", + "type": "tuple[]" + }, + { + "internalType": "uint256[]", + "name": "sellerAllowList", + "type": "uint256[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getNextAccountId", + "outputs": [ + { + "internalType": "uint256", + "name": "nextAccountId", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_sellerId", + "type": "uint256" + } + ], + "name": "getSeller", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Seller", + "name": "seller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.AuthToken", + "name": "authToken", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_associatedAddress", + "type": "address" + } + ], + "name": "getSellerByAddress", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Seller", + "name": "seller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.AuthToken", + "name": "authToken", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.AuthToken", + "name": "_associatedAuthToken", + "type": "tuple" + } + ], + "name": "getSellerByAuthToken", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Seller", + "name": "seller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.AuthToken", + "name": "authToken", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.DisputeResolverUpdateFields[]", + "name": "_fieldsToUpdate", + "type": "uint8[]" + } + ], + "name": "optInToDisputeResolverUpdate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_sellerId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.SellerUpdateFields[]", + "name": "_fieldsToUpdate", + "type": "uint8[]" + } + ], + "name": "optInToSellerUpdate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "internalType": "address[]", + "name": "_feeTokenAddresses", + "type": "address[]" + } + ], + "name": "removeFeesFromDisputeResolver", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256[]", + "name": "_sellerAllowList", + "type": "uint256[]" + } + ], + "name": "removeSellersFromAllowList", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "feePercentage", + "type": "uint256" + }, + { + "internalType": "address payable", + "name": "wallet", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Agent", + "name": "_agent", + "type": "tuple" + } + ], + "name": "updateAgent", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address payable", + "name": "wallet", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Buyer", + "name": "_buyer", + "type": "tuple" + } + ], + "name": "updateBuyer", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.DisputeResolver", + "name": "_disputeResolver", + "type": "tuple" + } + ], + "name": "updateDisputeResolver", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Seller", + "name": "_seller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.AuthToken", + "name": "_authToken", + "type": "tuple" + } + ], + "name": "updateSeller", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/packages/common/src/abis/IBosonDisputeHandler.json b/packages/common/src/abis/IBosonDisputeHandler.json new file mode 100644 index 000000000..17ee9a627 --- /dev/null +++ b/packages/common/src/abis/IBosonDisputeHandler.json @@ -0,0 +1,645 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "_buyerPercent", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeDecided", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeEscalated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeExpired", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "buyerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeRaised", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "_buyerPercent", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeResolved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeRetracted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newDisputeTimeout", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeTimeoutExtended", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "EscalatedDisputeExpired", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "EscalatedDisputeRefused", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "entityId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "FundsEncumbered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "entityId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "FundsReleased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "withdrawnTo", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "FundsWithdrawn", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "ProtocolFeeCollected", + "type": "event" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_buyerPercent", + "type": "uint256" + } + ], + "name": "decideDispute", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "escalateDispute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "expireDispute", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256[]", + "name": "_exchangeIds", + "type": "uint256[]" + } + ], + "name": "expireDisputeBatch", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "expireEscalatedDispute", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_newDisputeTimeout", + "type": "uint256" + } + ], + "name": "extendDisputeTimeout", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "getDispute", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerPercent", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.DisputeState", + "name": "state", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.Dispute", + "name": "dispute", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputed", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalated", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "finalized", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "timeout", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.DisputeDates", + "name": "disputeDates", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "getDisputeState", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "internalType": "enum BosonTypes.DisputeState", + "name": "state", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "getDisputeTimeout", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "timeout", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "isDisputeFinalized", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "internalType": "bool", + "name": "isFinalized", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "raiseDispute", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "refuseEscalatedDispute", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_buyerPercent", + "type": "uint256" + }, + { + "internalType": "bytes32", + "name": "_sigR", + "type": "bytes32" + }, + { + "internalType": "bytes32", + "name": "_sigS", + "type": "bytes32" + }, + { + "internalType": "uint8", + "name": "_sigV", + "type": "uint8" + } + ], + "name": "resolveDispute", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "retractDispute", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/packages/common/src/abis/IBosonExchangeHandler.json b/packages/common/src/abis/IBosonExchangeHandler.json new file mode 100644 index 000000000..aeb91b005 --- /dev/null +++ b/packages/common/src/abis/IBosonExchangeHandler.json @@ -0,0 +1,1088 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "buyerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "finalizedDate", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.ExchangeState", + "name": "state", + "type": "uint8" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Exchange", + "name": "exchange", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "committedDate", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntilDate", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "redeemedDate", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "expired", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Voucher", + "name": "voucher", + "type": "tuple" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "BuyerCommitted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "buyerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "ExchangeCompleted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "entityId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "FundsEncumbered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "entityId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "FundsReleased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "withdrawnTo", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "FundsWithdrawn", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "ProtocolFeeCollected", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "twinId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyAvailable", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Twin", + "name": "twin", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "TwinCreated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "twinId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "TwinDeleted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "twinId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "TwinTransferFailed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "twinId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "TwinTransferred", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "VoucherCanceled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "VoucherExpired", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "VoucherExtended", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "VoucherRedeemed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "VoucherRevoked", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "newBuyerId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "VoucherTransferred", + "type": "event" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "cancelVoucher", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address payable", + "name": "_buyer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_offerId", + "type": "uint256" + } + ], + "name": "commitToOffer", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address payable", + "name": "_buyer", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_offerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "commitToPreMintedOffer", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "completeExchange", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256[]", + "name": "_exchangeIds", + "type": "uint256[]" + } + ], + "name": "completeExchangeBatch", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "expireVoucher", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_validUntilDate", + "type": "uint256" + } + ], + "name": "extendVoucher", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "getExchange", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "finalizedDate", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.ExchangeState", + "name": "state", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.Exchange", + "name": "exchange", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "committedDate", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntilDate", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "redeemedDate", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "expired", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Voucher", + "name": "voucher", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "getExchangeState", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "internalType": "enum BosonTypes.ExchangeState", + "name": "state", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getNextExchangeId", + "outputs": [ + { + "internalType": "uint256", + "name": "nextExchangeId", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "getReceipt", + "outputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "protocolFee", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "agentFee", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferFees", + "name": "offerFees", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "agentId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "finalizedDate", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.Condition", + "name": "condition", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "committedDate", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "redeemedDate", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "voucherExpired", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "disputedDate", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalatedDate", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.DisputeState", + "name": "disputeState", + "type": "uint8" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "twinId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.TwinReceipt[]", + "name": "twinReceipts", + "type": "tuple[]" + } + ], + "internalType": "struct BosonTypes.Receipt", + "name": "receipt", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "isExchangeFinalized", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "internalType": "bool", + "name": "isFinalized", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + }, + { + "internalType": "address payable", + "name": "_newBuyer", + "type": "address" + } + ], + "name": "onVoucherTransferred", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "redeemVoucher", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "revokeVoucher", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/packages/common/src/abis/IBosonFundsHandler.json b/packages/common/src/abis/IBosonFundsHandler.json new file mode 100644 index 000000000..35771a880 --- /dev/null +++ b/packages/common/src/abis/IBosonFundsHandler.json @@ -0,0 +1,269 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "FundsDeposited", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "entityId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "FundsEncumbered", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "entityId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "FundsReleased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "withdrawnTo", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "FundsWithdrawn", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "ProtocolFeeCollected", + "type": "event" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_sellerId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "_tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_amount", + "type": "uint256" + } + ], + "name": "depositFunds", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_entityId", + "type": "uint256" + } + ], + "name": "getAvailableFunds", + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "tokenName", + "type": "string" + }, + { + "internalType": "uint256", + "name": "availableAmount", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.Funds[]", + "name": "availableFunds", + "type": "tuple[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_entityId", + "type": "uint256" + }, + { + "internalType": "address[]", + "name": "_tokenList", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "_tokenAmounts", + "type": "uint256[]" + } + ], + "name": "withdrawFunds", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "_tokenList", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "_tokenAmounts", + "type": "uint256[]" + } + ], + "name": "withdrawProtocolFees", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/packages/common/src/abis/IBosonGroupHandler.json b/packages/common/src/abis/IBosonGroupHandler.json new file mode 100644 index 000000000..e01f518c2 --- /dev/null +++ b/packages/common/src/abis/IBosonGroupHandler.json @@ -0,0 +1,418 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "groupId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256[]", + "name": "offerIds", + "type": "uint256[]" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Group", + "name": "group", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Condition", + "name": "condition", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "GroupCreated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "groupId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256[]", + "name": "offerIds", + "type": "uint256[]" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Group", + "name": "group", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Condition", + "name": "condition", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "GroupUpdated", + "type": "event" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_groupId", + "type": "uint256" + }, + { + "internalType": "uint256[]", + "name": "_offerIds", + "type": "uint256[]" + } + ], + "name": "addOffersToGroup", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256[]", + "name": "offerIds", + "type": "uint256[]" + } + ], + "internalType": "struct BosonTypes.Group", + "name": "_group", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.Condition", + "name": "_condition", + "type": "tuple" + } + ], + "name": "createGroup", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_groupId", + "type": "uint256" + } + ], + "name": "getGroup", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256[]", + "name": "offerIds", + "type": "uint256[]" + } + ], + "internalType": "struct BosonTypes.Group", + "name": "group", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.Condition", + "name": "condition", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getNextGroupId", + "outputs": [ + { + "internalType": "uint256", + "name": "nextGroupId", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_groupId", + "type": "uint256" + }, + { + "internalType": "uint256[]", + "name": "_offerIds", + "type": "uint256[]" + } + ], + "name": "removeOffersFromGroup", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_groupId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.Condition", + "name": "_condition", + "type": "tuple" + } + ], + "name": "setGroupCondition", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/packages/common/src/abis/IBosonMetaTransactionsHandler.json b/packages/common/src/abis/IBosonMetaTransactionsHandler.json new file mode 100644 index 000000000..0f436f082 --- /dev/null +++ b/packages/common/src/abis/IBosonMetaTransactionsHandler.json @@ -0,0 +1,187 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "bytes32[]", + "name": "functionNameHashes", + "type": "bytes32[]" + }, + { + "indexed": false, + "internalType": "bool", + "name": "isAllowlisted", + "type": "bool" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "FunctionsAllowlisted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "userAddress", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "relayerAddress", + "type": "address" + }, + { + "indexed": true, + "internalType": "string", + "name": "functionName", + "type": "string" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "nonce", + "type": "uint256" + } + ], + "name": "MetaTransactionExecuted", + "type": "event" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_userAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "_functionName", + "type": "string" + }, + { + "internalType": "bytes", + "name": "_functionSignature", + "type": "bytes" + }, + { + "internalType": "uint256", + "name": "_nonce", + "type": "uint256" + }, + { + "internalType": "bytes32", + "name": "_sigR", + "type": "bytes32" + }, + { + "internalType": "bytes32", + "name": "_sigS", + "type": "bytes32" + }, + { + "internalType": "uint8", + "name": "_sigV", + "type": "uint8" + } + ], + "name": "executeMetaTransaction", + "outputs": [ + { + "internalType": "bytes", + "name": "", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "string", + "name": "_functionName", + "type": "string" + } + ], + "name": "isFunctionAllowlisted", + "outputs": [ + { + "internalType": "bool", + "name": "isAllowlisted", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "_functionNameHash", + "type": "bytes32" + } + ], + "name": "isFunctionAllowlisted", + "outputs": [ + { + "internalType": "bool", + "name": "isAllowlisted", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_associatedAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_nonce", + "type": "uint256" + } + ], + "name": "isUsedNonce", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32[]", + "name": "_functionNameHashes", + "type": "bytes32[]" + }, + { + "internalType": "bool", + "name": "_isAllowlisted", + "type": "bool" + } + ], + "name": "setAllowlistedFunctions", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/packages/common/src/abis/IBosonOfferHandler.json b/packages/common/src/abis/IBosonOfferHandler.json new file mode 100644 index 000000000..f3660212e --- /dev/null +++ b/packages/common/src/abis/IBosonOfferHandler.json @@ -0,0 +1,839 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Offer", + "name": "offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.OfferDates", + "name": "offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.OfferDurations", + "name": "offerDurations", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "feeAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerEscalationDeposit", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolutionTerms", + "name": "disputeResolutionTerms", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "protocolFee", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "agentFee", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.OfferFees", + "name": "offerFees", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "agentId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "OfferCreated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "validUntilDate", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "OfferExtended", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "OfferVoided", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "startExchangeId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "endExchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "RangeReserved", + "type": "event" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createOffer", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer[]", + "name": "_offers", + "type": "tuple[]" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates[]", + "name": "_offerDates", + "type": "tuple[]" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations[]", + "name": "_offerDurations", + "type": "tuple[]" + }, + { + "internalType": "uint256[]", + "name": "_disputeResolverIds", + "type": "uint256[]" + }, + { + "internalType": "uint256[]", + "name": "_agentIds", + "type": "uint256[]" + } + ], + "name": "createOfferBatch", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_offerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_validUntilDate", + "type": "uint256" + } + ], + "name": "extendOffer", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256[]", + "name": "_offerIds", + "type": "uint256[]" + }, + { + "internalType": "uint256", + "name": "_validUntilDate", + "type": "uint256" + } + ], + "name": "extendOfferBatch", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_offerId", + "type": "uint256" + } + ], + "name": "getAgentIdByOffer", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "agentId", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getNextOfferId", + "outputs": [ + { + "internalType": "uint256", + "name": "nextOfferId", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_offerId", + "type": "uint256" + } + ], + "name": "getOffer", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "offerDurations", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "feeAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerEscalationDeposit", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.DisputeResolutionTerms", + "name": "disputeResolutionTerms", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "protocolFee", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "agentFee", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferFees", + "name": "offerFees", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_offerId", + "type": "uint256" + } + ], + "name": "isOfferVoided", + "outputs": [ + { + "internalType": "bool", + "name": "exists", + "type": "bool" + }, + { + "internalType": "bool", + "name": "offerVoided", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_offerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_length", + "type": "uint256" + } + ], + "name": "reserveRange", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_offerId", + "type": "uint256" + } + ], + "name": "voidOffer", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256[]", + "name": "_offerIds", + "type": "uint256[]" + } + ], + "name": "voidOfferBatch", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/packages/common/src/abis/IBosonOrchestrationHandler.json b/packages/common/src/abis/IBosonOrchestrationHandler.json new file mode 100644 index 000000000..aa65980ae --- /dev/null +++ b/packages/common/src/abis/IBosonOrchestrationHandler.json @@ -0,0 +1,4792 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "agentId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "feePercentage", + "type": "uint256" + }, + { + "internalType": "address payable", + "name": "wallet", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Agent", + "name": "agent", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "AgentCreated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "agentId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "feePercentage", + "type": "uint256" + }, + { + "internalType": "address payable", + "name": "wallet", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Agent", + "name": "agent", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "AgentUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256[]", + "name": "addedSellers", + "type": "uint256[]" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "AllowedSellersAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256[]", + "name": "removedSellers", + "type": "uint256[]" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "AllowedSellersRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "bundleId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256[]", + "name": "offerIds", + "type": "uint256[]" + }, + { + "internalType": "uint256[]", + "name": "twinIds", + "type": "uint256[]" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Bundle", + "name": "bundle", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "BundleCreated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "buyerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address payable", + "name": "wallet", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Buyer", + "name": "buyer", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "BuyerCreated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "buyerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address payable", + "name": "wallet", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Buyer", + "name": "buyer", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "BuyerUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolver", + "name": "disputeResolver", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "tokenName", + "type": "string" + }, + { + "internalType": "uint256", + "name": "feeAmount", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolverFee[]", + "name": "disputeResolverFees", + "type": "tuple[]" + }, + { + "indexed": false, + "internalType": "uint256[]", + "name": "sellerAllowList", + "type": "uint256[]" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeResolverCreated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "string", + "name": "tokenName", + "type": "string" + }, + { + "internalType": "uint256", + "name": "feeAmount", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolverFee[]", + "name": "disputeResolverFees", + "type": "tuple[]" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeResolverFeesAdded", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address[]", + "name": "feeTokensRemoved", + "type": "address[]" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeResolverFeesRemoved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolver", + "name": "disputeResolver", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolver", + "name": "pendingDisputeResolver", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeResolverUpdateApplied", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolver", + "name": "pendingDisputeResolver", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "DisputeResolverUpdatePending", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "groupId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256[]", + "name": "offerIds", + "type": "uint256[]" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Group", + "name": "group", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Condition", + "name": "condition", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "GroupCreated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "groupId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256[]", + "name": "offerIds", + "type": "uint256[]" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Group", + "name": "group", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Condition", + "name": "condition", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "GroupUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Offer", + "name": "offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.OfferDates", + "name": "offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.OfferDurations", + "name": "offerDurations", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "escalationResponsePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "feeAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerEscalationDeposit", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.DisputeResolutionTerms", + "name": "disputeResolutionTerms", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "protocolFee", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "agentFee", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.OfferFees", + "name": "offerFees", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "agentId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "OfferCreated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "validUntilDate", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "OfferExtended", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "OfferVoided", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "startExchangeId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "endExchangeId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "RangeReserved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Seller", + "name": "seller", + "type": "tuple" + }, + { + "indexed": false, + "internalType": "address", + "name": "voucherCloneAddress", + "type": "address" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.AuthToken", + "name": "authToken", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "SellerCreated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Seller", + "name": "seller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Seller", + "name": "pendingSeller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.AuthToken", + "name": "authToken", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.AuthToken", + "name": "pendingAuthToken", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "SellerUpdateApplied", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Seller", + "name": "pendingSeller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.AuthToken", + "name": "pendingAuthToken", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "SellerUpdatePending", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "twinId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyAvailable", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "indexed": false, + "internalType": "struct BosonTypes.Twin", + "name": "twin", + "type": "tuple" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "TwinCreated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "twinId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "TwinDeleted", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "twinId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "TwinTransferFailed", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "twinId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "exchangeId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "executedBy", + "type": "address" + } + ], + "name": "TwinTransferred", + "type": "event" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_groupId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createOfferAddToGroup", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyAvailable", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.Twin", + "name": "_twin", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createOfferAndTwinWithBundle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.Condition", + "name": "_condition", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createOfferWithCondition", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.Condition", + "name": "_condition", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyAvailable", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.Twin", + "name": "_twin", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createOfferWithConditionAndTwinAndBundle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_reservedRangeLength", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_groupId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createPremintedOfferAddToGroup", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_reservedRangeLength", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyAvailable", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.Twin", + "name": "_twin", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createPremintedOfferAndTwinWithBundle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_reservedRangeLength", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.Condition", + "name": "_condition", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createPremintedOfferWithCondition", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_reservedRangeLength", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.Condition", + "name": "_condition", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyAvailable", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.Twin", + "name": "_twin", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createPremintedOfferWithConditionAndTwinAndBundle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Seller", + "name": "_seller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.AuthToken", + "name": "_authToken", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "string", + "name": "contractURI", + "type": "string" + }, + { + "internalType": "uint256", + "name": "royaltyPercentage", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.VoucherInitValues", + "name": "_voucherInitValues", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createSellerAndOffer", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Seller", + "name": "_seller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyAvailable", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.Twin", + "name": "_twin", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.AuthToken", + "name": "_authToken", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "string", + "name": "contractURI", + "type": "string" + }, + { + "internalType": "uint256", + "name": "royaltyPercentage", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.VoucherInitValues", + "name": "_voucherInitValues", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createSellerAndOfferAndTwinWithBundle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Seller", + "name": "_seller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.Condition", + "name": "_condition", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.AuthToken", + "name": "_authToken", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "string", + "name": "contractURI", + "type": "string" + }, + { + "internalType": "uint256", + "name": "royaltyPercentage", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.VoucherInitValues", + "name": "_voucherInitValues", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createSellerAndOfferWithCondition", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Seller", + "name": "_seller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.Condition", + "name": "_condition", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyAvailable", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.Twin", + "name": "_twin", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.AuthToken", + "name": "_authToken", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "string", + "name": "contractURI", + "type": "string" + }, + { + "internalType": "uint256", + "name": "royaltyPercentage", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.VoucherInitValues", + "name": "_voucherInitValues", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createSellerAndOfferWithConditionAndTwinAndBundle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Seller", + "name": "_seller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_reservedRangeLength", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.AuthToken", + "name": "_authToken", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "string", + "name": "contractURI", + "type": "string" + }, + { + "internalType": "uint256", + "name": "royaltyPercentage", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.VoucherInitValues", + "name": "_voucherInitValues", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createSellerAndPremintedOffer", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Seller", + "name": "_seller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_reservedRangeLength", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyAvailable", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.Twin", + "name": "_twin", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.AuthToken", + "name": "_authToken", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "string", + "name": "contractURI", + "type": "string" + }, + { + "internalType": "uint256", + "name": "royaltyPercentage", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.VoucherInitValues", + "name": "_voucherInitValues", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createSellerAndPremintedOfferAndTwinWithBundle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Seller", + "name": "_seller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_reservedRangeLength", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.Condition", + "name": "_condition", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.AuthToken", + "name": "_authToken", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "string", + "name": "contractURI", + "type": "string" + }, + { + "internalType": "uint256", + "name": "royaltyPercentage", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.VoucherInitValues", + "name": "_voucherInitValues", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createSellerAndPremintedOfferWithCondition", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "address", + "name": "admin", + "type": "address" + }, + { + "internalType": "address", + "name": "clerk", + "type": "address" + }, + { + "internalType": "address payable", + "name": "treasury", + "type": "address" + }, + { + "internalType": "bool", + "name": "active", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Seller", + "name": "_seller", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "price", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerDeposit", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "buyerCancelPenalty", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "quantityAvailable", + "type": "uint256" + }, + { + "internalType": "address", + "name": "exchangeToken", + "type": "address" + }, + { + "internalType": "string", + "name": "metadataUri", + "type": "string" + }, + { + "internalType": "string", + "name": "metadataHash", + "type": "string" + }, + { + "internalType": "bool", + "name": "voided", + "type": "bool" + } + ], + "internalType": "struct BosonTypes.Offer", + "name": "_offer", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "validFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "validUntil", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableFrom", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherRedeemableUntil", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDates", + "name": "_offerDates", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "disputePeriod", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "voucherValid", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "resolutionPeriod", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.OfferDurations", + "name": "_offerDurations", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_disputeResolverId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_reservedRangeLength", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "enum BosonTypes.EvaluationMethod", + "name": "method", + "type": "uint8" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "maxCommits", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.Condition", + "name": "_condition", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "supplyAvailable", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + }, + { + "internalType": "enum BosonTypes.TokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.Twin", + "name": "_twin", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "enum BosonTypes.AuthTokenType", + "name": "tokenType", + "type": "uint8" + } + ], + "internalType": "struct BosonTypes.AuthToken", + "name": "_authToken", + "type": "tuple" + }, + { + "components": [ + { + "internalType": "string", + "name": "contractURI", + "type": "string" + }, + { + "internalType": "uint256", + "name": "royaltyPercentage", + "type": "uint256" + } + ], + "internalType": "struct BosonTypes.VoucherInitValues", + "name": "_voucherInitValues", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "_agentId", + "type": "uint256" + } + ], + "name": "createSellerAndPremintedOfferWithConditionAndTwinAndBundle", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "raiseAndEscalateDispute", + "outputs": [], + "stateMutability": "payable", + "type": "function" + } +] diff --git a/packages/common/src/abis/IBosonVoucher.json b/packages/common/src/abis/IBosonVoucher.json new file mode 100644 index 000000000..2edfc2af8 --- /dev/null +++ b/packages/common/src/abis/IBosonVoucher.json @@ -0,0 +1,686 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "approved", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "approved", + "type": "bool" + } + ], + "name": "ApprovalForAll", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "string", + "name": "contractURI", + "type": "string" + } + ], + "name": "ContractURIChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "start", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "length", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "minted", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lastBurnedTokenId", + "type": "uint256" + } + ], + "indexed": false, + "internalType": "struct IBosonVoucher.Range", + "name": "range", + "type": "tuple" + } + ], + "name": "RangeReserved", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "royaltyPercentage", + "type": "uint256" + } + ], + "name": "RoyaltyPercentageChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "sellerId", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "royaltyPercentage", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "string", + "name": "contractURI", + "type": "string" + } + ], + "name": "VoucherInitialized", + "type": "event" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "balance", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_offerId", + "type": "uint256" + } + ], + "name": "burnPremintedVouchers", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + } + ], + "name": "burnVoucher", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "contractURI", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "getApproved", + "outputs": [ + { + "internalType": "address", + "name": "operator", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_offerId", + "type": "uint256" + } + ], + "name": "getAvailablePreMints", + "outputs": [ + { + "internalType": "uint256", + "name": "count", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_offerId", + "type": "uint256" + } + ], + "name": "getRangeByOfferId", + "outputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "offerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "start", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "length", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "minted", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "lastBurnedTokenId", + "type": "uint256" + } + ], + "internalType": "struct IBosonVoucher.Range", + "name": "range", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getRoyaltyPercentage", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getSellerId", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + } + ], + "name": "isApprovedForAll", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_exchangeId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "_buyer", + "type": "address" + } + ], + "name": "issueVoucher", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "ownerOf", + "outputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_offerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_amount", + "type": "uint256" + } + ], + "name": "preMint", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_offerId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_start", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_length", + "type": "uint256" + } + ], + "name": "reserveRange", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_tokenId", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "_salePrice", + "type": "uint256" + } + ], + "name": "royaltyInfo", + "outputs": [ + { + "internalType": "address", + "name": "receiver", + "type": "address" + }, + { + "internalType": "uint256", + "name": "royaltyAmount", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "bool", + "name": "_approved", + "type": "bool" + } + ], + "name": "setApprovalForAll", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "string", + "name": "_newContractURI", + "type": "string" + } + ], + "name": "setContractURI", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_newRoyaltyPercentage", + "type": "uint256" + } + ], + "name": "setRoyaltyPercentage", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "interfaceId", + "type": "bytes4" + } + ], + "name": "supportsInterface", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "tokenURI", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } +] diff --git a/packages/common/src/abis/MockNativeMetaTransaction.json b/packages/common/src/abis/MockNativeMetaTransaction.json new file mode 100644 index 000000000..66e38c116 --- /dev/null +++ b/packages/common/src/abis/MockNativeMetaTransaction.json @@ -0,0 +1,111 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "userAddress", + "type": "address" + }, + { + "indexed": false, + "internalType": "address payable", + "name": "relayerAddress", + "type": "address" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "functionSignature", + "type": "bytes" + } + ], + "name": "MetaTransactionExecuted", + "type": "event" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "userAddress", + "type": "address" + }, + { + "internalType": "bytes", + "name": "functionSignature", + "type": "bytes" + }, + { + "internalType": "bytes32", + "name": "sigR", + "type": "bytes32" + }, + { + "internalType": "bytes32", + "name": "sigS", + "type": "bytes32" + }, + { + "internalType": "uint8", + "name": "sigV", + "type": "uint8" + } + ], + "name": "executeMetaTransaction", + "outputs": [ + { + "internalType": "bytes", + "name": "", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [], + "name": "getChainId", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getDomainSeperator", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "user", + "type": "address" + } + ], + "name": "getNonce", + "outputs": [ + { + "internalType": "uint256", + "name": "nonce", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/packages/common/src/abis/ProtocolDiamond.json b/packages/common/src/abis/ProtocolDiamond.json new file mode 100644 index 000000000..e7cc746a2 --- /dev/null +++ b/packages/common/src/abis/ProtocolDiamond.json @@ -0,0 +1,48 @@ +[ + { + "inputs": [ + { + "internalType": "contract IAccessControl", + "name": "_accessController", + "type": "address" + }, + { + "components": [ + { + "internalType": "address", + "name": "facetAddress", + "type": "address" + }, + { + "internalType": "enum IDiamondCut.FacetCutAction", + "name": "action", + "type": "uint8" + }, + { + "internalType": "bytes4[]", + "name": "functionSelectors", + "type": "bytes4[]" + } + ], + "internalType": "struct IDiamondCut.FacetCut[]", + "name": "_facetCuts", + "type": "tuple[]" + }, + { + "internalType": "bytes4[]", + "name": "_interfaceIds", + "type": "bytes4[]" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "stateMutability": "payable", + "type": "receive" + } +] diff --git a/packages/common/src/configs.ts b/packages/common/src/configs.ts index 83852802f..62fdbe374 100644 --- a/packages/common/src/configs.ts +++ b/packages/common/src/configs.ts @@ -116,8 +116,8 @@ export const defaultConfigs: ProtocolConfig[] = [ theGraphIpfsUrl: "https://api.thegraph.com/ipfs/api/v0", ipfsMetadataUrl: "https://ipfs.infura.io:5001", contracts: { - // from https://github.com/bosonprotocol/boson-protocol-contracts/commit/8be49ba4ff83e80542e4a89bf674b0799f1ee913 - protocolDiamond: "0x5099CA7839e1580bD0C12FC5FECfA45147886BeB" + // from https://github.com/bosonprotocol/boson-protocol-contracts/commit/38c7ba384e55486aee4ea76bb80b4f29d1a86175 + protocolDiamond: "0xf9719c7e641964D83cC50ea2d4d0D4e6C300d50E" }, metaTx: { relayerUrl: "https://api.biconomy.io" diff --git a/packages/ethers-sdk/src/contracts/ERC1155.ts b/packages/ethers-sdk/src/contracts/ERC1155.ts new file mode 100644 index 000000000..dcea0f445 --- /dev/null +++ b/packages/ethers-sdk/src/contracts/ERC1155.ts @@ -0,0 +1,443 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import { FunctionFragment, Result, EventFragment } from "@ethersproject/abi"; +import { Listener, Provider } from "@ethersproject/providers"; +import { TypedEventFilter, TypedEvent, TypedListener, OnEvent } from "./common"; + +export interface ERC1155Interface extends utils.Interface { + contractName: "ERC1155"; + functions: { + "balanceOf(address,uint256)": FunctionFragment; + "balanceOfBatch(address[],uint256[])": FunctionFragment; + "isApprovedForAll(address,address)": FunctionFragment; + "safeBatchTransferFrom(address,address,uint256[],uint256[],bytes)": FunctionFragment; + "safeTransferFrom(address,address,uint256,uint256,bytes)": FunctionFragment; + "setApprovalForAll(address,bool)": FunctionFragment; + "supportsInterface(bytes4)": FunctionFragment; + }; + + encodeFunctionData( + functionFragment: "balanceOf", + values: [string, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "balanceOfBatch", + values: [string[], BigNumberish[]] + ): string; + encodeFunctionData( + functionFragment: "isApprovedForAll", + values: [string, string] + ): string; + encodeFunctionData( + functionFragment: "safeBatchTransferFrom", + values: [string, string, BigNumberish[], BigNumberish[], BytesLike] + ): string; + encodeFunctionData( + functionFragment: "safeTransferFrom", + values: [string, string, BigNumberish, BigNumberish, BytesLike] + ): string; + encodeFunctionData( + functionFragment: "setApprovalForAll", + values: [string, boolean] + ): string; + encodeFunctionData( + functionFragment: "supportsInterface", + values: [BytesLike] + ): string; + + decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "balanceOfBatch", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "isApprovedForAll", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "safeBatchTransferFrom", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "safeTransferFrom", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setApprovalForAll", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "supportsInterface", + data: BytesLike + ): Result; + + events: { + "ApprovalForAll(address,address,bool)": EventFragment; + "TransferBatch(address,address,address,uint256[],uint256[])": EventFragment; + "TransferSingle(address,address,address,uint256,uint256)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "ApprovalForAll"): EventFragment; + getEvent(nameOrSignatureOrTopic: "TransferBatch"): EventFragment; + getEvent(nameOrSignatureOrTopic: "TransferSingle"): EventFragment; +} + +export type ApprovalForAllEvent = TypedEvent< + [string, string, boolean], + { _owner: string; _operator: string; _approved: boolean } +>; + +export type ApprovalForAllEventFilter = TypedEventFilter; + +export type TransferBatchEvent = TypedEvent< + [string, string, string, BigNumber[], BigNumber[]], + { + _operator: string; + _from: string; + _to: string; + _ids: BigNumber[]; + _amounts: BigNumber[]; + } +>; + +export type TransferBatchEventFilter = TypedEventFilter; + +export type TransferSingleEvent = TypedEvent< + [string, string, string, BigNumber, BigNumber], + { + _operator: string; + _from: string; + _to: string; + _id: BigNumber; + _amount: BigNumber; + } +>; + +export type TransferSingleEventFilter = TypedEventFilter; + +export interface ERC1155 extends BaseContract { + contractName: "ERC1155"; + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: ERC1155Interface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + balanceOf( + _owner: string, + _id: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + balanceOfBatch( + _owners: string[], + _ids: BigNumberish[], + overrides?: CallOverrides + ): Promise<[BigNumber[]]>; + + isApprovedForAll( + _owner: string, + _operator: string, + overrides?: CallOverrides + ): Promise<[boolean] & { isOperator: boolean }>; + + safeBatchTransferFrom( + _from: string, + _to: string, + _ids: BigNumberish[], + _amounts: BigNumberish[], + _data: BytesLike, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + safeTransferFrom( + _from: string, + _to: string, + _id: BigNumberish, + _amount: BigNumberish, + _data: BytesLike, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + setApprovalForAll( + _operator: string, + _approved: boolean, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + supportsInterface( + _interfaceID: BytesLike, + overrides?: CallOverrides + ): Promise<[boolean]>; + }; + + balanceOf( + _owner: string, + _id: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOfBatch( + _owners: string[], + _ids: BigNumberish[], + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + _owner: string, + _operator: string, + overrides?: CallOverrides + ): Promise; + + safeBatchTransferFrom( + _from: string, + _to: string, + _ids: BigNumberish[], + _amounts: BigNumberish[], + _data: BytesLike, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + safeTransferFrom( + _from: string, + _to: string, + _id: BigNumberish, + _amount: BigNumberish, + _data: BytesLike, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + setApprovalForAll( + _operator: string, + _approved: boolean, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + supportsInterface( + _interfaceID: BytesLike, + overrides?: CallOverrides + ): Promise; + + callStatic: { + balanceOf( + _owner: string, + _id: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOfBatch( + _owners: string[], + _ids: BigNumberish[], + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + _owner: string, + _operator: string, + overrides?: CallOverrides + ): Promise; + + safeBatchTransferFrom( + _from: string, + _to: string, + _ids: BigNumberish[], + _amounts: BigNumberish[], + _data: BytesLike, + overrides?: CallOverrides + ): Promise; + + safeTransferFrom( + _from: string, + _to: string, + _id: BigNumberish, + _amount: BigNumberish, + _data: BytesLike, + overrides?: CallOverrides + ): Promise; + + setApprovalForAll( + _operator: string, + _approved: boolean, + overrides?: CallOverrides + ): Promise; + + supportsInterface( + _interfaceID: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "ApprovalForAll(address,address,bool)"( + _owner?: string | null, + _operator?: string | null, + _approved?: null + ): ApprovalForAllEventFilter; + ApprovalForAll( + _owner?: string | null, + _operator?: string | null, + _approved?: null + ): ApprovalForAllEventFilter; + + "TransferBatch(address,address,address,uint256[],uint256[])"( + _operator?: string | null, + _from?: string | null, + _to?: string | null, + _ids?: null, + _amounts?: null + ): TransferBatchEventFilter; + TransferBatch( + _operator?: string | null, + _from?: string | null, + _to?: string | null, + _ids?: null, + _amounts?: null + ): TransferBatchEventFilter; + + "TransferSingle(address,address,address,uint256,uint256)"( + _operator?: string | null, + _from?: string | null, + _to?: string | null, + _id?: null, + _amount?: null + ): TransferSingleEventFilter; + TransferSingle( + _operator?: string | null, + _from?: string | null, + _to?: string | null, + _id?: null, + _amount?: null + ): TransferSingleEventFilter; + }; + + estimateGas: { + balanceOf( + _owner: string, + _id: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOfBatch( + _owners: string[], + _ids: BigNumberish[], + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + _owner: string, + _operator: string, + overrides?: CallOverrides + ): Promise; + + safeBatchTransferFrom( + _from: string, + _to: string, + _ids: BigNumberish[], + _amounts: BigNumberish[], + _data: BytesLike, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + safeTransferFrom( + _from: string, + _to: string, + _id: BigNumberish, + _amount: BigNumberish, + _data: BytesLike, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + setApprovalForAll( + _operator: string, + _approved: boolean, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + supportsInterface( + _interfaceID: BytesLike, + overrides?: CallOverrides + ): Promise; + }; + + populateTransaction: { + balanceOf( + _owner: string, + _id: BigNumberish, + overrides?: CallOverrides + ): Promise; + + balanceOfBatch( + _owners: string[], + _ids: BigNumberish[], + overrides?: CallOverrides + ): Promise; + + isApprovedForAll( + _owner: string, + _operator: string, + overrides?: CallOverrides + ): Promise; + + safeBatchTransferFrom( + _from: string, + _to: string, + _ids: BigNumberish[], + _amounts: BigNumberish[], + _data: BytesLike, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + safeTransferFrom( + _from: string, + _to: string, + _id: BigNumberish, + _amount: BigNumberish, + _data: BytesLike, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + setApprovalForAll( + _operator: string, + _approved: boolean, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + supportsInterface( + _interfaceID: BytesLike, + overrides?: CallOverrides + ): Promise; + }; +} diff --git a/packages/ethers-sdk/src/contracts/IBosonAccountHandler.ts b/packages/ethers-sdk/src/contracts/IBosonAccountHandler.ts index 5e1c04740..6ccb1febe 100644 --- a/packages/ethers-sdk/src/contracts/IBosonAccountHandler.ts +++ b/packages/ethers-sdk/src/contracts/IBosonAccountHandler.ts @@ -136,7 +136,6 @@ export declare namespace BosonTypes { export interface IBosonAccountHandlerInterface extends utils.Interface { contractName: "IBosonAccountHandler"; functions: { - "activateDisputeResolver(uint256)": FunctionFragment; "addFeesToDisputeResolver(uint256,(address,string,uint256)[])": FunctionFragment; "addSellersToAllowList(uint256,uint256[])": FunctionFragment; "areSellersAllowed(uint256,uint256[])": FunctionFragment; @@ -152,6 +151,8 @@ export interface IBosonAccountHandlerInterface extends utils.Interface { "getSeller(uint256)": FunctionFragment; "getSellerByAddress(address)": FunctionFragment; "getSellerByAuthToken((uint256,uint8))": FunctionFragment; + "optInToDisputeResolverUpdate(uint256,uint8[])": FunctionFragment; + "optInToSellerUpdate(uint256,uint8[])": FunctionFragment; "removeFeesFromDisputeResolver(uint256,address[])": FunctionFragment; "removeSellersFromAllowList(uint256,uint256[])": FunctionFragment; "updateAgent((uint256,uint256,address,bool))": FunctionFragment; @@ -160,10 +161,6 @@ export interface IBosonAccountHandlerInterface extends utils.Interface { "updateSeller((uint256,address,address,address,address,bool),(uint256,uint8))": FunctionFragment; }; - encodeFunctionData( - functionFragment: "activateDisputeResolver", - values: [BigNumberish] - ): string; encodeFunctionData( functionFragment: "addFeesToDisputeResolver", values: [BigNumberish, BosonTypes.DisputeResolverFeeStruct[]] @@ -232,6 +229,14 @@ export interface IBosonAccountHandlerInterface extends utils.Interface { functionFragment: "getSellerByAuthToken", values: [BosonTypes.AuthTokenStruct] ): string; + encodeFunctionData( + functionFragment: "optInToDisputeResolverUpdate", + values: [BigNumberish, BigNumberish[]] + ): string; + encodeFunctionData( + functionFragment: "optInToSellerUpdate", + values: [BigNumberish, BigNumberish[]] + ): string; encodeFunctionData( functionFragment: "removeFeesFromDisputeResolver", values: [BigNumberish, string[]] @@ -257,10 +262,6 @@ export interface IBosonAccountHandlerInterface extends utils.Interface { values: [BosonTypes.SellerStruct, BosonTypes.AuthTokenStruct] ): string; - decodeFunctionResult( - functionFragment: "activateDisputeResolver", - data: BytesLike - ): Result; decodeFunctionResult( functionFragment: "addFeesToDisputeResolver", data: BytesLike @@ -312,6 +313,14 @@ export interface IBosonAccountHandlerInterface extends utils.Interface { functionFragment: "getSellerByAuthToken", data: BytesLike ): Result; + decodeFunctionResult( + functionFragment: "optInToDisputeResolverUpdate", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "optInToSellerUpdate", + data: BytesLike + ): Result; decodeFunctionResult( functionFragment: "removeFeesFromDisputeResolver", data: BytesLike @@ -348,8 +357,12 @@ export interface IBosonAccountHandlerInterface extends utils.Interface { "DisputeResolverCreated(uint256,tuple,tuple[],uint256[],address)": EventFragment; "DisputeResolverFeesAdded(uint256,tuple[],address)": EventFragment; "DisputeResolverFeesRemoved(uint256,address[],address)": EventFragment; + "DisputeResolverUpdateApplied(uint256,tuple,tuple,address)": EventFragment; + "DisputeResolverUpdatePending(uint256,tuple,address)": EventFragment; "DisputeResolverUpdated(uint256,tuple,address)": EventFragment; "SellerCreated(uint256,tuple,address,tuple,address)": EventFragment; + "SellerUpdateApplied(uint256,tuple,tuple,tuple,tuple,address)": EventFragment; + "SellerUpdatePending(uint256,tuple,tuple,address)": EventFragment; "SellerUpdated(uint256,tuple,tuple,address)": EventFragment; }; @@ -363,8 +376,16 @@ export interface IBosonAccountHandlerInterface extends utils.Interface { getEvent(nameOrSignatureOrTopic: "DisputeResolverCreated"): EventFragment; getEvent(nameOrSignatureOrTopic: "DisputeResolverFeesAdded"): EventFragment; getEvent(nameOrSignatureOrTopic: "DisputeResolverFeesRemoved"): EventFragment; + getEvent( + nameOrSignatureOrTopic: "DisputeResolverUpdateApplied" + ): EventFragment; + getEvent( + nameOrSignatureOrTopic: "DisputeResolverUpdatePending" + ): EventFragment; getEvent(nameOrSignatureOrTopic: "DisputeResolverUpdated"): EventFragment; getEvent(nameOrSignatureOrTopic: "SellerCreated"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SellerUpdateApplied"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SellerUpdatePending"): EventFragment; getEvent(nameOrSignatureOrTopic: "SellerUpdated"): EventFragment; } @@ -492,6 +513,36 @@ export type DisputeResolverFeesRemovedEvent = TypedEvent< export type DisputeResolverFeesRemovedEventFilter = TypedEventFilter; +export type DisputeResolverUpdateAppliedEvent = TypedEvent< + [ + BigNumber, + BosonTypes.DisputeResolverStructOutput, + BosonTypes.DisputeResolverStructOutput, + string + ], + { + disputeResolverId: BigNumber; + disputeResolver: BosonTypes.DisputeResolverStructOutput; + pendingDisputeResolver: BosonTypes.DisputeResolverStructOutput; + executedBy: string; + } +>; + +export type DisputeResolverUpdateAppliedEventFilter = + TypedEventFilter; + +export type DisputeResolverUpdatePendingEvent = TypedEvent< + [BigNumber, BosonTypes.DisputeResolverStructOutput, string], + { + disputeResolverId: BigNumber; + pendingDisputeResolver: BosonTypes.DisputeResolverStructOutput; + executedBy: string; + } +>; + +export type DisputeResolverUpdatePendingEventFilter = + TypedEventFilter; + export type DisputeResolverUpdatedEvent = TypedEvent< [BigNumber, BosonTypes.DisputeResolverStructOutput, string], { @@ -523,6 +574,46 @@ export type SellerCreatedEvent = TypedEvent< export type SellerCreatedEventFilter = TypedEventFilter; +export type SellerUpdateAppliedEvent = TypedEvent< + [ + BigNumber, + BosonTypes.SellerStructOutput, + BosonTypes.SellerStructOutput, + BosonTypes.AuthTokenStructOutput, + BosonTypes.AuthTokenStructOutput, + string + ], + { + sellerId: BigNumber; + seller: BosonTypes.SellerStructOutput; + pendingSeller: BosonTypes.SellerStructOutput; + authToken: BosonTypes.AuthTokenStructOutput; + pendingAuthToken: BosonTypes.AuthTokenStructOutput; + executedBy: string; + } +>; + +export type SellerUpdateAppliedEventFilter = + TypedEventFilter; + +export type SellerUpdatePendingEvent = TypedEvent< + [ + BigNumber, + BosonTypes.SellerStructOutput, + BosonTypes.AuthTokenStructOutput, + string + ], + { + sellerId: BigNumber; + pendingSeller: BosonTypes.SellerStructOutput; + pendingAuthToken: BosonTypes.AuthTokenStructOutput; + executedBy: string; + } +>; + +export type SellerUpdatePendingEventFilter = + TypedEventFilter; + export type SellerUpdatedEvent = TypedEvent< [ BigNumber, @@ -568,11 +659,6 @@ export interface IBosonAccountHandler extends BaseContract { removeListener: OnEvent; functions: { - activateDisputeResolver( - _disputeResolverId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - addFeesToDisputeResolver( _disputeResolverId: BigNumberish, _disputeResolverFees: BosonTypes.DisputeResolverFeeStruct[], @@ -718,6 +804,18 @@ export interface IBosonAccountHandler extends BaseContract { } >; + optInToDisputeResolverUpdate( + _disputeResolverId: BigNumberish, + _fieldsToUpdate: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + optInToSellerUpdate( + _sellerId: BigNumberish, + _fieldsToUpdate: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + removeFeesFromDisputeResolver( _disputeResolverId: BigNumberish, _feeTokenAddresses: string[], @@ -752,11 +850,6 @@ export interface IBosonAccountHandler extends BaseContract { ): Promise; }; - activateDisputeResolver( - _disputeResolverId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - addFeesToDisputeResolver( _disputeResolverId: BigNumberish, _disputeResolverFees: BosonTypes.DisputeResolverFeeStruct[], @@ -900,6 +993,18 @@ export interface IBosonAccountHandler extends BaseContract { } >; + optInToDisputeResolverUpdate( + _disputeResolverId: BigNumberish, + _fieldsToUpdate: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + optInToSellerUpdate( + _sellerId: BigNumberish, + _fieldsToUpdate: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + removeFeesFromDisputeResolver( _disputeResolverId: BigNumberish, _feeTokenAddresses: string[], @@ -934,11 +1039,6 @@ export interface IBosonAccountHandler extends BaseContract { ): Promise; callStatic: { - activateDisputeResolver( - _disputeResolverId: BigNumberish, - overrides?: CallOverrides - ): Promise; - addFeesToDisputeResolver( _disputeResolverId: BigNumberish, _disputeResolverFees: BosonTypes.DisputeResolverFeeStruct[], @@ -1082,6 +1182,18 @@ export interface IBosonAccountHandler extends BaseContract { } >; + optInToDisputeResolverUpdate( + _disputeResolverId: BigNumberish, + _fieldsToUpdate: BigNumberish[], + overrides?: CallOverrides + ): Promise; + + optInToSellerUpdate( + _sellerId: BigNumberish, + _fieldsToUpdate: BigNumberish[], + overrides?: CallOverrides + ): Promise; + removeFeesFromDisputeResolver( _disputeResolverId: BigNumberish, _feeTokenAddresses: string[], @@ -1231,6 +1343,30 @@ export interface IBosonAccountHandler extends BaseContract { executedBy?: string | null ): DisputeResolverFeesRemovedEventFilter; + "DisputeResolverUpdateApplied(uint256,tuple,tuple,address)"( + disputeResolverId?: BigNumberish | null, + disputeResolver?: null, + pendingDisputeResolver?: null, + executedBy?: string | null + ): DisputeResolverUpdateAppliedEventFilter; + DisputeResolverUpdateApplied( + disputeResolverId?: BigNumberish | null, + disputeResolver?: null, + pendingDisputeResolver?: null, + executedBy?: string | null + ): DisputeResolverUpdateAppliedEventFilter; + + "DisputeResolverUpdatePending(uint256,tuple,address)"( + disputeResolverId?: BigNumberish | null, + pendingDisputeResolver?: null, + executedBy?: string | null + ): DisputeResolverUpdatePendingEventFilter; + DisputeResolverUpdatePending( + disputeResolverId?: BigNumberish | null, + pendingDisputeResolver?: null, + executedBy?: string | null + ): DisputeResolverUpdatePendingEventFilter; + "DisputeResolverUpdated(uint256,tuple,address)"( disputeResolverId?: BigNumberish | null, disputeResolver?: null, @@ -1257,6 +1393,36 @@ export interface IBosonAccountHandler extends BaseContract { executedBy?: string | null ): SellerCreatedEventFilter; + "SellerUpdateApplied(uint256,tuple,tuple,tuple,tuple,address)"( + sellerId?: BigNumberish | null, + seller?: null, + pendingSeller?: null, + authToken?: null, + pendingAuthToken?: null, + executedBy?: string | null + ): SellerUpdateAppliedEventFilter; + SellerUpdateApplied( + sellerId?: BigNumberish | null, + seller?: null, + pendingSeller?: null, + authToken?: null, + pendingAuthToken?: null, + executedBy?: string | null + ): SellerUpdateAppliedEventFilter; + + "SellerUpdatePending(uint256,tuple,tuple,address)"( + sellerId?: BigNumberish | null, + pendingSeller?: null, + pendingAuthToken?: null, + executedBy?: string | null + ): SellerUpdatePendingEventFilter; + SellerUpdatePending( + sellerId?: BigNumberish | null, + pendingSeller?: null, + pendingAuthToken?: null, + executedBy?: string | null + ): SellerUpdatePendingEventFilter; + "SellerUpdated(uint256,tuple,tuple,address)"( sellerId?: BigNumberish | null, seller?: null, @@ -1272,11 +1438,6 @@ export interface IBosonAccountHandler extends BaseContract { }; estimateGas: { - activateDisputeResolver( - _disputeResolverId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - addFeesToDisputeResolver( _disputeResolverId: BigNumberish, _disputeResolverFees: BosonTypes.DisputeResolverFeeStruct[], @@ -1356,6 +1517,18 @@ export interface IBosonAccountHandler extends BaseContract { overrides?: CallOverrides ): Promise; + optInToDisputeResolverUpdate( + _disputeResolverId: BigNumberish, + _fieldsToUpdate: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + optInToSellerUpdate( + _sellerId: BigNumberish, + _fieldsToUpdate: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + removeFeesFromDisputeResolver( _disputeResolverId: BigNumberish, _feeTokenAddresses: string[], @@ -1391,11 +1564,6 @@ export interface IBosonAccountHandler extends BaseContract { }; populateTransaction: { - activateDisputeResolver( - _disputeResolverId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - addFeesToDisputeResolver( _disputeResolverId: BigNumberish, _disputeResolverFees: BosonTypes.DisputeResolverFeeStruct[], @@ -1475,6 +1643,18 @@ export interface IBosonAccountHandler extends BaseContract { overrides?: CallOverrides ): Promise; + optInToDisputeResolverUpdate( + _disputeResolverId: BigNumberish, + _fieldsToUpdate: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + optInToSellerUpdate( + _sellerId: BigNumberish, + _fieldsToUpdate: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + removeFeesFromDisputeResolver( _disputeResolverId: BigNumberish, _feeTokenAddresses: string[], diff --git a/packages/ethers-sdk/src/contracts/IBosonExchangeHandler.ts b/packages/ethers-sdk/src/contracts/IBosonExchangeHandler.ts index 3f9158f15..639a782c2 100644 --- a/packages/ethers-sdk/src/contracts/IBosonExchangeHandler.ts +++ b/packages/ethers-sdk/src/contracts/IBosonExchangeHandler.ts @@ -218,6 +218,7 @@ export interface IBosonExchangeHandlerInterface extends utils.Interface { functions: { "cancelVoucher(uint256)": FunctionFragment; "commitToOffer(address,uint256)": FunctionFragment; + "commitToPreMintedOffer(address,uint256,uint256)": FunctionFragment; "completeExchange(uint256)": FunctionFragment; "completeExchangeBatch(uint256[])": FunctionFragment; "expireVoucher(uint256)": FunctionFragment; @@ -240,6 +241,10 @@ export interface IBosonExchangeHandlerInterface extends utils.Interface { functionFragment: "commitToOffer", values: [string, BigNumberish] ): string; + encodeFunctionData( + functionFragment: "commitToPreMintedOffer", + values: [string, BigNumberish, BigNumberish] + ): string; encodeFunctionData( functionFragment: "completeExchange", values: [BigNumberish] @@ -297,6 +302,10 @@ export interface IBosonExchangeHandlerInterface extends utils.Interface { functionFragment: "commitToOffer", data: BytesLike ): Result; + decodeFunctionResult( + functionFragment: "commitToPreMintedOffer", + data: BytesLike + ): Result; decodeFunctionResult( functionFragment: "completeExchange", data: BytesLike @@ -605,6 +614,13 @@ export interface IBosonExchangeHandler extends BaseContract { overrides?: PayableOverrides & { from?: string | Promise } ): Promise; + commitToPreMintedOffer( + _buyer: string, + _offerId: BigNumberish, + _exchangeId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + completeExchange( _exchangeId: BigNumberish, overrides?: Overrides & { from?: string | Promise } @@ -692,6 +708,13 @@ export interface IBosonExchangeHandler extends BaseContract { overrides?: PayableOverrides & { from?: string | Promise } ): Promise; + commitToPreMintedOffer( + _buyer: string, + _offerId: BigNumberish, + _exchangeId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + completeExchange( _exchangeId: BigNumberish, overrides?: Overrides & { from?: string | Promise } @@ -773,6 +796,13 @@ export interface IBosonExchangeHandler extends BaseContract { overrides?: CallOverrides ): Promise; + commitToPreMintedOffer( + _buyer: string, + _offerId: BigNumberish, + _exchangeId: BigNumberish, + overrides?: CallOverrides + ): Promise; + completeExchange( _exchangeId: BigNumberish, overrides?: CallOverrides @@ -1071,6 +1101,13 @@ export interface IBosonExchangeHandler extends BaseContract { overrides?: PayableOverrides & { from?: string | Promise } ): Promise; + commitToPreMintedOffer( + _buyer: string, + _offerId: BigNumberish, + _exchangeId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + completeExchange( _exchangeId: BigNumberish, overrides?: Overrides & { from?: string | Promise } @@ -1143,6 +1180,13 @@ export interface IBosonExchangeHandler extends BaseContract { overrides?: PayableOverrides & { from?: string | Promise } ): Promise; + commitToPreMintedOffer( + _buyer: string, + _offerId: BigNumberish, + _exchangeId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + completeExchange( _exchangeId: BigNumberish, overrides?: Overrides & { from?: string | Promise } diff --git a/packages/ethers-sdk/src/contracts/IBosonGroupHandler.ts b/packages/ethers-sdk/src/contracts/IBosonGroupHandler.ts new file mode 100644 index 000000000..12ce5cdb3 --- /dev/null +++ b/packages/ethers-sdk/src/contracts/IBosonGroupHandler.ts @@ -0,0 +1,417 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import { FunctionFragment, Result, EventFragment } from "@ethersproject/abi"; +import { Listener, Provider } from "@ethersproject/providers"; +import { TypedEventFilter, TypedEvent, TypedListener, OnEvent } from "./common"; + +export declare namespace BosonTypes { + export type GroupStruct = { + id: BigNumberish; + sellerId: BigNumberish; + offerIds: BigNumberish[]; + }; + + export type GroupStructOutput = [BigNumber, BigNumber, BigNumber[]] & { + id: BigNumber; + sellerId: BigNumber; + offerIds: BigNumber[]; + }; + + export type ConditionStruct = { + method: BigNumberish; + tokenType: BigNumberish; + tokenAddress: string; + tokenId: BigNumberish; + threshold: BigNumberish; + maxCommits: BigNumberish; + }; + + export type ConditionStructOutput = [ + number, + number, + string, + BigNumber, + BigNumber, + BigNumber + ] & { + method: number; + tokenType: number; + tokenAddress: string; + tokenId: BigNumber; + threshold: BigNumber; + maxCommits: BigNumber; + }; +} + +export interface IBosonGroupHandlerInterface extends utils.Interface { + contractName: "IBosonGroupHandler"; + functions: { + "addOffersToGroup(uint256,uint256[])": FunctionFragment; + "createGroup((uint256,uint256,uint256[]),(uint8,uint8,address,uint256,uint256,uint256))": FunctionFragment; + "getGroup(uint256)": FunctionFragment; + "getNextGroupId()": FunctionFragment; + "removeOffersFromGroup(uint256,uint256[])": FunctionFragment; + "setGroupCondition(uint256,(uint8,uint8,address,uint256,uint256,uint256))": FunctionFragment; + }; + + encodeFunctionData( + functionFragment: "addOffersToGroup", + values: [BigNumberish, BigNumberish[]] + ): string; + encodeFunctionData( + functionFragment: "createGroup", + values: [BosonTypes.GroupStruct, BosonTypes.ConditionStruct] + ): string; + encodeFunctionData( + functionFragment: "getGroup", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "getNextGroupId", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "removeOffersFromGroup", + values: [BigNumberish, BigNumberish[]] + ): string; + encodeFunctionData( + functionFragment: "setGroupCondition", + values: [BigNumberish, BosonTypes.ConditionStruct] + ): string; + + decodeFunctionResult( + functionFragment: "addOffersToGroup", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "createGroup", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "getGroup", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getNextGroupId", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "removeOffersFromGroup", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "setGroupCondition", + data: BytesLike + ): Result; + + events: { + "GroupCreated(uint256,uint256,tuple,tuple,address)": EventFragment; + "GroupUpdated(uint256,uint256,tuple,tuple,address)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "GroupCreated"): EventFragment; + getEvent(nameOrSignatureOrTopic: "GroupUpdated"): EventFragment; +} + +export type GroupCreatedEvent = TypedEvent< + [ + BigNumber, + BigNumber, + BosonTypes.GroupStructOutput, + BosonTypes.ConditionStructOutput, + string + ], + { + groupId: BigNumber; + sellerId: BigNumber; + group: BosonTypes.GroupStructOutput; + condition: BosonTypes.ConditionStructOutput; + executedBy: string; + } +>; + +export type GroupCreatedEventFilter = TypedEventFilter; + +export type GroupUpdatedEvent = TypedEvent< + [ + BigNumber, + BigNumber, + BosonTypes.GroupStructOutput, + BosonTypes.ConditionStructOutput, + string + ], + { + groupId: BigNumber; + sellerId: BigNumber; + group: BosonTypes.GroupStructOutput; + condition: BosonTypes.ConditionStructOutput; + executedBy: string; + } +>; + +export type GroupUpdatedEventFilter = TypedEventFilter; + +export interface IBosonGroupHandler extends BaseContract { + contractName: "IBosonGroupHandler"; + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: IBosonGroupHandlerInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + addOffersToGroup( + _groupId: BigNumberish, + _offerIds: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createGroup( + _group: BosonTypes.GroupStruct, + _condition: BosonTypes.ConditionStruct, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + getGroup( + _groupId: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + boolean, + BosonTypes.GroupStructOutput, + BosonTypes.ConditionStructOutput + ] & { + exists: boolean; + group: BosonTypes.GroupStructOutput; + condition: BosonTypes.ConditionStructOutput; + } + >; + + getNextGroupId( + overrides?: CallOverrides + ): Promise<[BigNumber] & { nextGroupId: BigNumber }>; + + removeOffersFromGroup( + _groupId: BigNumberish, + _offerIds: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + setGroupCondition( + _groupId: BigNumberish, + _condition: BosonTypes.ConditionStruct, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + }; + + addOffersToGroup( + _groupId: BigNumberish, + _offerIds: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createGroup( + _group: BosonTypes.GroupStruct, + _condition: BosonTypes.ConditionStruct, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + getGroup( + _groupId: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + boolean, + BosonTypes.GroupStructOutput, + BosonTypes.ConditionStructOutput + ] & { + exists: boolean; + group: BosonTypes.GroupStructOutput; + condition: BosonTypes.ConditionStructOutput; + } + >; + + getNextGroupId(overrides?: CallOverrides): Promise; + + removeOffersFromGroup( + _groupId: BigNumberish, + _offerIds: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + setGroupCondition( + _groupId: BigNumberish, + _condition: BosonTypes.ConditionStruct, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + callStatic: { + addOffersToGroup( + _groupId: BigNumberish, + _offerIds: BigNumberish[], + overrides?: CallOverrides + ): Promise; + + createGroup( + _group: BosonTypes.GroupStruct, + _condition: BosonTypes.ConditionStruct, + overrides?: CallOverrides + ): Promise; + + getGroup( + _groupId: BigNumberish, + overrides?: CallOverrides + ): Promise< + [ + boolean, + BosonTypes.GroupStructOutput, + BosonTypes.ConditionStructOutput + ] & { + exists: boolean; + group: BosonTypes.GroupStructOutput; + condition: BosonTypes.ConditionStructOutput; + } + >; + + getNextGroupId(overrides?: CallOverrides): Promise; + + removeOffersFromGroup( + _groupId: BigNumberish, + _offerIds: BigNumberish[], + overrides?: CallOverrides + ): Promise; + + setGroupCondition( + _groupId: BigNumberish, + _condition: BosonTypes.ConditionStruct, + overrides?: CallOverrides + ): Promise; + }; + + filters: { + "GroupCreated(uint256,uint256,tuple,tuple,address)"( + groupId?: BigNumberish | null, + sellerId?: BigNumberish | null, + group?: null, + condition?: null, + executedBy?: string | null + ): GroupCreatedEventFilter; + GroupCreated( + groupId?: BigNumberish | null, + sellerId?: BigNumberish | null, + group?: null, + condition?: null, + executedBy?: string | null + ): GroupCreatedEventFilter; + + "GroupUpdated(uint256,uint256,tuple,tuple,address)"( + groupId?: BigNumberish | null, + sellerId?: BigNumberish | null, + group?: null, + condition?: null, + executedBy?: string | null + ): GroupUpdatedEventFilter; + GroupUpdated( + groupId?: BigNumberish | null, + sellerId?: BigNumberish | null, + group?: null, + condition?: null, + executedBy?: string | null + ): GroupUpdatedEventFilter; + }; + + estimateGas: { + addOffersToGroup( + _groupId: BigNumberish, + _offerIds: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createGroup( + _group: BosonTypes.GroupStruct, + _condition: BosonTypes.ConditionStruct, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + getGroup( + _groupId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + getNextGroupId(overrides?: CallOverrides): Promise; + + removeOffersFromGroup( + _groupId: BigNumberish, + _offerIds: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + setGroupCondition( + _groupId: BigNumberish, + _condition: BosonTypes.ConditionStruct, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + }; + + populateTransaction: { + addOffersToGroup( + _groupId: BigNumberish, + _offerIds: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createGroup( + _group: BosonTypes.GroupStruct, + _condition: BosonTypes.ConditionStruct, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + getGroup( + _groupId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + getNextGroupId(overrides?: CallOverrides): Promise; + + removeOffersFromGroup( + _groupId: BigNumberish, + _offerIds: BigNumberish[], + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + setGroupCondition( + _groupId: BigNumberish, + _condition: BosonTypes.ConditionStruct, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + }; +} diff --git a/packages/ethers-sdk/src/contracts/IBosonMetaTransactionsHandler.ts b/packages/ethers-sdk/src/contracts/IBosonMetaTransactionsHandler.ts index 7aa5f0119..cc9c5155a 100644 --- a/packages/ethers-sdk/src/contracts/IBosonMetaTransactionsHandler.ts +++ b/packages/ethers-sdk/src/contracts/IBosonMetaTransactionsHandler.ts @@ -8,6 +8,7 @@ import { BytesLike, CallOverrides, ContractTransaction, + Overrides, PayableOverrides, PopulatedTransaction, Signer, @@ -22,7 +23,9 @@ export interface IBosonMetaTransactionsHandlerInterface contractName: "IBosonMetaTransactionsHandler"; functions: { "executeMetaTransaction(address,string,bytes,uint256,bytes32,bytes32,uint8)": FunctionFragment; + "isFunctionAllowlisted(string)": FunctionFragment; "isUsedNonce(address,uint256)": FunctionFragment; + "setAllowlistedFunctions(bytes32[],bool)": FunctionFragment; }; encodeFunctionData( @@ -37,27 +40,53 @@ export interface IBosonMetaTransactionsHandlerInterface BigNumberish ] ): string; + encodeFunctionData( + functionFragment: "isFunctionAllowlisted", + values: [string] + ): string; encodeFunctionData( functionFragment: "isUsedNonce", values: [string, BigNumberish] ): string; + encodeFunctionData( + functionFragment: "setAllowlistedFunctions", + values: [BytesLike[], boolean] + ): string; decodeFunctionResult( functionFragment: "executeMetaTransaction", data: BytesLike ): Result; + decodeFunctionResult( + functionFragment: "isFunctionAllowlisted", + data: BytesLike + ): Result; decodeFunctionResult( functionFragment: "isUsedNonce", data: BytesLike ): Result; + decodeFunctionResult( + functionFragment: "setAllowlistedFunctions", + data: BytesLike + ): Result; events: { + "FunctionsAllowlisted(bytes32[],bool,address)": EventFragment; "MetaTransactionExecuted(address,address,string,uint256)": EventFragment; }; + getEvent(nameOrSignatureOrTopic: "FunctionsAllowlisted"): EventFragment; getEvent(nameOrSignatureOrTopic: "MetaTransactionExecuted"): EventFragment; } +export type FunctionsAllowlistedEvent = TypedEvent< + [string[], boolean, string], + { functionNameHashes: string[]; isAllowlisted: boolean; executedBy: string } +>; + +export type FunctionsAllowlistedEventFilter = + TypedEventFilter; + export type MetaTransactionExecutedEvent = TypedEvent< [string, string, string, BigNumber], { @@ -110,11 +139,27 @@ export interface IBosonMetaTransactionsHandler extends BaseContract { overrides?: PayableOverrides & { from?: string | Promise } ): Promise; + "isFunctionAllowlisted(string)"( + _functionName: string, + overrides?: CallOverrides + ): Promise<[boolean] & { isAllowlisted: boolean }>; + + "isFunctionAllowlisted(bytes32)"( + _functionNameHash: BytesLike, + overrides?: CallOverrides + ): Promise<[boolean] & { isAllowlisted: boolean }>; + isUsedNonce( _associatedAddress: string, _nonce: BigNumberish, overrides?: CallOverrides ): Promise<[boolean]>; + + setAllowlistedFunctions( + _functionNameHashes: BytesLike[], + _isAllowlisted: boolean, + overrides?: Overrides & { from?: string | Promise } + ): Promise; }; executeMetaTransaction( @@ -128,12 +173,28 @@ export interface IBosonMetaTransactionsHandler extends BaseContract { overrides?: PayableOverrides & { from?: string | Promise } ): Promise; + "isFunctionAllowlisted(string)"( + _functionName: string, + overrides?: CallOverrides + ): Promise; + + "isFunctionAllowlisted(bytes32)"( + _functionNameHash: BytesLike, + overrides?: CallOverrides + ): Promise; + isUsedNonce( _associatedAddress: string, _nonce: BigNumberish, overrides?: CallOverrides ): Promise; + setAllowlistedFunctions( + _functionNameHashes: BytesLike[], + _isAllowlisted: boolean, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + callStatic: { executeMetaTransaction( _userAddress: string, @@ -146,14 +207,41 @@ export interface IBosonMetaTransactionsHandler extends BaseContract { overrides?: CallOverrides ): Promise; + "isFunctionAllowlisted(string)"( + _functionName: string, + overrides?: CallOverrides + ): Promise; + + "isFunctionAllowlisted(bytes32)"( + _functionNameHash: BytesLike, + overrides?: CallOverrides + ): Promise; + isUsedNonce( _associatedAddress: string, _nonce: BigNumberish, overrides?: CallOverrides ): Promise; + + setAllowlistedFunctions( + _functionNameHashes: BytesLike[], + _isAllowlisted: boolean, + overrides?: CallOverrides + ): Promise; }; filters: { + "FunctionsAllowlisted(bytes32[],bool,address)"( + functionNameHashes?: null, + isAllowlisted?: null, + executedBy?: string | null + ): FunctionsAllowlistedEventFilter; + FunctionsAllowlisted( + functionNameHashes?: null, + isAllowlisted?: null, + executedBy?: string | null + ): FunctionsAllowlistedEventFilter; + "MetaTransactionExecuted(address,address,string,uint256)"( userAddress?: string | null, relayerAddress?: string | null, @@ -180,11 +268,27 @@ export interface IBosonMetaTransactionsHandler extends BaseContract { overrides?: PayableOverrides & { from?: string | Promise } ): Promise; + "isFunctionAllowlisted(string)"( + _functionName: string, + overrides?: CallOverrides + ): Promise; + + "isFunctionAllowlisted(bytes32)"( + _functionNameHash: BytesLike, + overrides?: CallOverrides + ): Promise; + isUsedNonce( _associatedAddress: string, _nonce: BigNumberish, overrides?: CallOverrides ): Promise; + + setAllowlistedFunctions( + _functionNameHashes: BytesLike[], + _isAllowlisted: boolean, + overrides?: Overrides & { from?: string | Promise } + ): Promise; }; populateTransaction: { @@ -199,10 +303,26 @@ export interface IBosonMetaTransactionsHandler extends BaseContract { overrides?: PayableOverrides & { from?: string | Promise } ): Promise; + "isFunctionAllowlisted(string)"( + _functionName: string, + overrides?: CallOverrides + ): Promise; + + "isFunctionAllowlisted(bytes32)"( + _functionNameHash: BytesLike, + overrides?: CallOverrides + ): Promise; + isUsedNonce( _associatedAddress: string, _nonce: BigNumberish, overrides?: CallOverrides ): Promise; + + setAllowlistedFunctions( + _functionNameHashes: BytesLike[], + _isAllowlisted: boolean, + overrides?: Overrides & { from?: string | Promise } + ): Promise; }; } diff --git a/packages/ethers-sdk/src/contracts/IBosonOfferHandler.ts b/packages/ethers-sdk/src/contracts/IBosonOfferHandler.ts index bc35cd5a7..c781c5586 100644 --- a/packages/ethers-sdk/src/contracts/IBosonOfferHandler.ts +++ b/packages/ethers-sdk/src/contracts/IBosonOfferHandler.ts @@ -127,6 +127,7 @@ export interface IBosonOfferHandlerInterface extends utils.Interface { "getNextOfferId()": FunctionFragment; "getOffer(uint256)": FunctionFragment; "isOfferVoided(uint256)": FunctionFragment; + "reserveRange(uint256,uint256)": FunctionFragment; "voidOffer(uint256)": FunctionFragment; "voidOfferBatch(uint256[])": FunctionFragment; }; @@ -175,6 +176,10 @@ export interface IBosonOfferHandlerInterface extends utils.Interface { functionFragment: "isOfferVoided", values: [BigNumberish] ): string; + encodeFunctionData( + functionFragment: "reserveRange", + values: [BigNumberish, BigNumberish] + ): string; encodeFunctionData( functionFragment: "voidOffer", values: [BigNumberish] @@ -213,6 +218,10 @@ export interface IBosonOfferHandlerInterface extends utils.Interface { functionFragment: "isOfferVoided", data: BytesLike ): Result; + decodeFunctionResult( + functionFragment: "reserveRange", + data: BytesLike + ): Result; decodeFunctionResult(functionFragment: "voidOffer", data: BytesLike): Result; decodeFunctionResult( functionFragment: "voidOfferBatch", @@ -223,11 +232,13 @@ export interface IBosonOfferHandlerInterface extends utils.Interface { "OfferCreated(uint256,uint256,tuple,tuple,tuple,tuple,tuple,uint256,address)": EventFragment; "OfferExtended(uint256,uint256,uint256,address)": EventFragment; "OfferVoided(uint256,uint256,address)": EventFragment; + "RangeReserved(uint256,uint256,uint256,uint256,address)": EventFragment; }; getEvent(nameOrSignatureOrTopic: "OfferCreated"): EventFragment; getEvent(nameOrSignatureOrTopic: "OfferExtended"): EventFragment; getEvent(nameOrSignatureOrTopic: "OfferVoided"): EventFragment; + getEvent(nameOrSignatureOrTopic: "RangeReserved"): EventFragment; } export type OfferCreatedEvent = TypedEvent< @@ -276,6 +287,19 @@ export type OfferVoidedEvent = TypedEvent< export type OfferVoidedEventFilter = TypedEventFilter; +export type RangeReservedEvent = TypedEvent< + [BigNumber, BigNumber, BigNumber, BigNumber, string], + { + offerId: BigNumber; + sellerId: BigNumber; + startExchangeId: BigNumber; + endExchangeId: BigNumber; + executedBy: string; + } +>; + +export type RangeReservedEventFilter = TypedEventFilter; + export interface IBosonOfferHandler extends BaseContract { contractName: "IBosonOfferHandler"; connect(signerOrProvider: Signer | Provider | string): this; @@ -369,6 +393,12 @@ export interface IBosonOfferHandler extends BaseContract { overrides?: CallOverrides ): Promise<[boolean, boolean] & { exists: boolean; offerVoided: boolean }>; + reserveRange( + _offerId: BigNumberish, + _length: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + voidOffer( _offerId: BigNumberish, overrides?: Overrides & { from?: string | Promise } @@ -443,6 +473,12 @@ export interface IBosonOfferHandler extends BaseContract { overrides?: CallOverrides ): Promise<[boolean, boolean] & { exists: boolean; offerVoided: boolean }>; + reserveRange( + _offerId: BigNumberish, + _length: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + voidOffer( _offerId: BigNumberish, overrides?: Overrides & { from?: string | Promise } @@ -517,6 +553,12 @@ export interface IBosonOfferHandler extends BaseContract { overrides?: CallOverrides ): Promise<[boolean, boolean] & { exists: boolean; offerVoided: boolean }>; + reserveRange( + _offerId: BigNumberish, + _length: BigNumberish, + overrides?: CallOverrides + ): Promise; + voidOffer(_offerId: BigNumberish, overrides?: CallOverrides): Promise; voidOfferBatch( @@ -572,6 +614,21 @@ export interface IBosonOfferHandler extends BaseContract { sellerId?: BigNumberish | null, executedBy?: string | null ): OfferVoidedEventFilter; + + "RangeReserved(uint256,uint256,uint256,uint256,address)"( + offerId?: BigNumberish | null, + sellerId?: BigNumberish | null, + startExchangeId?: null, + endExchangeId?: null, + executedBy?: string | null + ): RangeReservedEventFilter; + RangeReserved( + offerId?: BigNumberish | null, + sellerId?: BigNumberish | null, + startExchangeId?: null, + endExchangeId?: null, + executedBy?: string | null + ): RangeReservedEventFilter; }; estimateGas: { @@ -622,6 +679,12 @@ export interface IBosonOfferHandler extends BaseContract { overrides?: CallOverrides ): Promise; + reserveRange( + _offerId: BigNumberish, + _length: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + voidOffer( _offerId: BigNumberish, overrides?: Overrides & { from?: string | Promise } @@ -681,6 +744,12 @@ export interface IBosonOfferHandler extends BaseContract { overrides?: CallOverrides ): Promise; + reserveRange( + _offerId: BigNumberish, + _length: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + voidOffer( _offerId: BigNumberish, overrides?: Overrides & { from?: string | Promise } diff --git a/packages/ethers-sdk/src/contracts/IBosonOrchestrationHandler.ts b/packages/ethers-sdk/src/contracts/IBosonOrchestrationHandler.ts index 874984425..a2b999b64 100644 --- a/packages/ethers-sdk/src/contracts/IBosonOrchestrationHandler.ts +++ b/packages/ethers-sdk/src/contracts/IBosonOrchestrationHandler.ts @@ -9,6 +9,7 @@ import { CallOverrides, ContractTransaction, Overrides, + PayableOverrides, PopulatedTransaction, Signer, utils, @@ -321,10 +322,19 @@ export interface IBosonOrchestrationHandlerInterface extends utils.Interface { "createOfferAndTwinWithBundle((uint256,uint256,uint256,uint256,uint256,uint256,address,string,string,bool),(uint256,uint256,uint256,uint256),(uint256,uint256,uint256),uint256,(uint256,uint256,uint256,uint256,uint256,address,uint8),uint256)": FunctionFragment; "createOfferWithCondition((uint256,uint256,uint256,uint256,uint256,uint256,address,string,string,bool),(uint256,uint256,uint256,uint256),(uint256,uint256,uint256),uint256,(uint8,uint8,address,uint256,uint256,uint256),uint256)": FunctionFragment; "createOfferWithConditionAndTwinAndBundle((uint256,uint256,uint256,uint256,uint256,uint256,address,string,string,bool),(uint256,uint256,uint256,uint256),(uint256,uint256,uint256),uint256,(uint8,uint8,address,uint256,uint256,uint256),(uint256,uint256,uint256,uint256,uint256,address,uint8),uint256)": FunctionFragment; + "createPremintedOfferAddToGroup((uint256,uint256,uint256,uint256,uint256,uint256,address,string,string,bool),(uint256,uint256,uint256,uint256),(uint256,uint256,uint256),uint256,uint256,uint256,uint256)": FunctionFragment; + "createPremintedOfferAndTwinWithBundle((uint256,uint256,uint256,uint256,uint256,uint256,address,string,string,bool),(uint256,uint256,uint256,uint256),(uint256,uint256,uint256),uint256,uint256,(uint256,uint256,uint256,uint256,uint256,address,uint8),uint256)": FunctionFragment; + "createPremintedOfferWithCondition((uint256,uint256,uint256,uint256,uint256,uint256,address,string,string,bool),(uint256,uint256,uint256,uint256),(uint256,uint256,uint256),uint256,uint256,(uint8,uint8,address,uint256,uint256,uint256),uint256)": FunctionFragment; + "createPremintedOfferWithConditionAndTwinAndBundle((uint256,uint256,uint256,uint256,uint256,uint256,address,string,string,bool),(uint256,uint256,uint256,uint256),(uint256,uint256,uint256),uint256,uint256,(uint8,uint8,address,uint256,uint256,uint256),(uint256,uint256,uint256,uint256,uint256,address,uint8),uint256)": FunctionFragment; "createSellerAndOffer((uint256,address,address,address,address,bool),(uint256,uint256,uint256,uint256,uint256,uint256,address,string,string,bool),(uint256,uint256,uint256,uint256),(uint256,uint256,uint256),uint256,(uint256,uint8),(string,uint256),uint256)": FunctionFragment; "createSellerAndOfferAndTwinWithBundle((uint256,address,address,address,address,bool),(uint256,uint256,uint256,uint256,uint256,uint256,address,string,string,bool),(uint256,uint256,uint256,uint256),(uint256,uint256,uint256),uint256,(uint256,uint256,uint256,uint256,uint256,address,uint8),(uint256,uint8),(string,uint256),uint256)": FunctionFragment; "createSellerAndOfferWithCondition((uint256,address,address,address,address,bool),(uint256,uint256,uint256,uint256,uint256,uint256,address,string,string,bool),(uint256,uint256,uint256,uint256),(uint256,uint256,uint256),uint256,(uint8,uint8,address,uint256,uint256,uint256),(uint256,uint8),(string,uint256),uint256)": FunctionFragment; "createSellerAndOfferWithConditionAndTwinAndBundle((uint256,address,address,address,address,bool),(uint256,uint256,uint256,uint256,uint256,uint256,address,string,string,bool),(uint256,uint256,uint256,uint256),(uint256,uint256,uint256),uint256,(uint8,uint8,address,uint256,uint256,uint256),(uint256,uint256,uint256,uint256,uint256,address,uint8),(uint256,uint8),(string,uint256),uint256)": FunctionFragment; + "createSellerAndPremintedOffer((uint256,address,address,address,address,bool),(uint256,uint256,uint256,uint256,uint256,uint256,address,string,string,bool),(uint256,uint256,uint256,uint256),(uint256,uint256,uint256),uint256,uint256,(uint256,uint8),(string,uint256),uint256)": FunctionFragment; + "createSellerAndPremintedOfferAndTwinWithBundle((uint256,address,address,address,address,bool),(uint256,uint256,uint256,uint256,uint256,uint256,address,string,string,bool),(uint256,uint256,uint256,uint256),(uint256,uint256,uint256),uint256,uint256,(uint256,uint256,uint256,uint256,uint256,address,uint8),(uint256,uint8),(string,uint256),uint256)": FunctionFragment; + "createSellerAndPremintedOfferWithCondition((uint256,address,address,address,address,bool),(uint256,uint256,uint256,uint256,uint256,uint256,address,string,string,bool),(uint256,uint256,uint256,uint256),(uint256,uint256,uint256),uint256,uint256,(uint8,uint8,address,uint256,uint256,uint256),(uint256,uint8),(string,uint256),uint256)": FunctionFragment; + "createSellerAndPremintedOfferWithConditionAndTwinAndBundle((uint256,address,address,address,address,bool),(uint256,uint256,uint256,uint256,uint256,uint256,address,string,string,bool),(uint256,uint256,uint256,uint256),(uint256,uint256,uint256),uint256,uint256,(uint8,uint8,address,uint256,uint256,uint256),(uint256,uint256,uint256,uint256,uint256,address,uint8),(uint256,uint8),(string,uint256),uint256)": FunctionFragment; + "raiseAndEscalateDispute(uint256)": FunctionFragment; }; encodeFunctionData( @@ -372,6 +382,55 @@ export interface IBosonOrchestrationHandlerInterface extends utils.Interface { BigNumberish ] ): string; + encodeFunctionData( + functionFragment: "createPremintedOfferAddToGroup", + values: [ + BosonTypes.OfferStruct, + BosonTypes.OfferDatesStruct, + BosonTypes.OfferDurationsStruct, + BigNumberish, + BigNumberish, + BigNumberish, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "createPremintedOfferAndTwinWithBundle", + values: [ + BosonTypes.OfferStruct, + BosonTypes.OfferDatesStruct, + BosonTypes.OfferDurationsStruct, + BigNumberish, + BigNumberish, + BosonTypes.TwinStruct, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "createPremintedOfferWithCondition", + values: [ + BosonTypes.OfferStruct, + BosonTypes.OfferDatesStruct, + BosonTypes.OfferDurationsStruct, + BigNumberish, + BigNumberish, + BosonTypes.ConditionStruct, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "createPremintedOfferWithConditionAndTwinAndBundle", + values: [ + BosonTypes.OfferStruct, + BosonTypes.OfferDatesStruct, + BosonTypes.OfferDurationsStruct, + BigNumberish, + BigNumberish, + BosonTypes.ConditionStruct, + BosonTypes.TwinStruct, + BigNumberish + ] + ): string; encodeFunctionData( functionFragment: "createSellerAndOffer", values: [ @@ -428,6 +487,70 @@ export interface IBosonOrchestrationHandlerInterface extends utils.Interface { BigNumberish ] ): string; + encodeFunctionData( + functionFragment: "createSellerAndPremintedOffer", + values: [ + BosonTypes.SellerStruct, + BosonTypes.OfferStruct, + BosonTypes.OfferDatesStruct, + BosonTypes.OfferDurationsStruct, + BigNumberish, + BigNumberish, + BosonTypes.AuthTokenStruct, + BosonTypes.VoucherInitValuesStruct, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "createSellerAndPremintedOfferAndTwinWithBundle", + values: [ + BosonTypes.SellerStruct, + BosonTypes.OfferStruct, + BosonTypes.OfferDatesStruct, + BosonTypes.OfferDurationsStruct, + BigNumberish, + BigNumberish, + BosonTypes.TwinStruct, + BosonTypes.AuthTokenStruct, + BosonTypes.VoucherInitValuesStruct, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "createSellerAndPremintedOfferWithCondition", + values: [ + BosonTypes.SellerStruct, + BosonTypes.OfferStruct, + BosonTypes.OfferDatesStruct, + BosonTypes.OfferDurationsStruct, + BigNumberish, + BigNumberish, + BosonTypes.ConditionStruct, + BosonTypes.AuthTokenStruct, + BosonTypes.VoucherInitValuesStruct, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "createSellerAndPremintedOfferWithConditionAndTwinAndBundle", + values: [ + BosonTypes.SellerStruct, + BosonTypes.OfferStruct, + BosonTypes.OfferDatesStruct, + BosonTypes.OfferDurationsStruct, + BigNumberish, + BigNumberish, + BosonTypes.ConditionStruct, + BosonTypes.TwinStruct, + BosonTypes.AuthTokenStruct, + BosonTypes.VoucherInitValuesStruct, + BigNumberish + ] + ): string; + encodeFunctionData( + functionFragment: "raiseAndEscalateDispute", + values: [BigNumberish] + ): string; decodeFunctionResult( functionFragment: "createOfferAddToGroup", @@ -445,6 +568,22 @@ export interface IBosonOrchestrationHandlerInterface extends utils.Interface { functionFragment: "createOfferWithConditionAndTwinAndBundle", data: BytesLike ): Result; + decodeFunctionResult( + functionFragment: "createPremintedOfferAddToGroup", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "createPremintedOfferAndTwinWithBundle", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "createPremintedOfferWithCondition", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "createPremintedOfferWithConditionAndTwinAndBundle", + data: BytesLike + ): Result; decodeFunctionResult( functionFragment: "createSellerAndOffer", data: BytesLike @@ -461,6 +600,26 @@ export interface IBosonOrchestrationHandlerInterface extends utils.Interface { functionFragment: "createSellerAndOfferWithConditionAndTwinAndBundle", data: BytesLike ): Result; + decodeFunctionResult( + functionFragment: "createSellerAndPremintedOffer", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "createSellerAndPremintedOfferAndTwinWithBundle", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "createSellerAndPremintedOfferWithCondition", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "createSellerAndPremintedOfferWithConditionAndTwinAndBundle", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "raiseAndEscalateDispute", + data: BytesLike + ): Result; events: { "AgentCreated(uint256,tuple,address)": EventFragment; @@ -470,18 +629,20 @@ export interface IBosonOrchestrationHandlerInterface extends utils.Interface { "BundleCreated(uint256,uint256,tuple,address)": EventFragment; "BuyerCreated(uint256,tuple,address)": EventFragment; "BuyerUpdated(uint256,tuple,address)": EventFragment; - "DisputeResolverActivated(uint256,tuple,address)": EventFragment; "DisputeResolverCreated(uint256,tuple,tuple[],uint256[],address)": EventFragment; "DisputeResolverFeesAdded(uint256,tuple[],address)": EventFragment; "DisputeResolverFeesRemoved(uint256,address[],address)": EventFragment; - "DisputeResolverUpdated(uint256,tuple,address)": EventFragment; + "DisputeResolverUpdateApplied(uint256,tuple,tuple,address)": EventFragment; + "DisputeResolverUpdatePending(uint256,tuple,address)": EventFragment; "GroupCreated(uint256,uint256,tuple,tuple,address)": EventFragment; "GroupUpdated(uint256,uint256,tuple,tuple,address)": EventFragment; "OfferCreated(uint256,uint256,tuple,tuple,tuple,tuple,tuple,uint256,address)": EventFragment; "OfferExtended(uint256,uint256,uint256,address)": EventFragment; "OfferVoided(uint256,uint256,address)": EventFragment; + "RangeReserved(uint256,uint256,uint256,uint256,address)": EventFragment; "SellerCreated(uint256,tuple,address,tuple,address)": EventFragment; - "SellerUpdated(uint256,tuple,tuple,address)": EventFragment; + "SellerUpdateApplied(uint256,tuple,tuple,tuple,tuple,address)": EventFragment; + "SellerUpdatePending(uint256,tuple,tuple,address)": EventFragment; "TwinCreated(uint256,uint256,tuple,address)": EventFragment; "TwinDeleted(uint256,uint256,address)": EventFragment; "TwinTransferFailed(uint256,address,uint256,uint256,uint256,address)": EventFragment; @@ -495,18 +656,24 @@ export interface IBosonOrchestrationHandlerInterface extends utils.Interface { getEvent(nameOrSignatureOrTopic: "BundleCreated"): EventFragment; getEvent(nameOrSignatureOrTopic: "BuyerCreated"): EventFragment; getEvent(nameOrSignatureOrTopic: "BuyerUpdated"): EventFragment; - getEvent(nameOrSignatureOrTopic: "DisputeResolverActivated"): EventFragment; getEvent(nameOrSignatureOrTopic: "DisputeResolverCreated"): EventFragment; getEvent(nameOrSignatureOrTopic: "DisputeResolverFeesAdded"): EventFragment; getEvent(nameOrSignatureOrTopic: "DisputeResolverFeesRemoved"): EventFragment; - getEvent(nameOrSignatureOrTopic: "DisputeResolverUpdated"): EventFragment; + getEvent( + nameOrSignatureOrTopic: "DisputeResolverUpdateApplied" + ): EventFragment; + getEvent( + nameOrSignatureOrTopic: "DisputeResolverUpdatePending" + ): EventFragment; getEvent(nameOrSignatureOrTopic: "GroupCreated"): EventFragment; getEvent(nameOrSignatureOrTopic: "GroupUpdated"): EventFragment; getEvent(nameOrSignatureOrTopic: "OfferCreated"): EventFragment; getEvent(nameOrSignatureOrTopic: "OfferExtended"): EventFragment; getEvent(nameOrSignatureOrTopic: "OfferVoided"): EventFragment; + getEvent(nameOrSignatureOrTopic: "RangeReserved"): EventFragment; getEvent(nameOrSignatureOrTopic: "SellerCreated"): EventFragment; - getEvent(nameOrSignatureOrTopic: "SellerUpdated"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SellerUpdateApplied"): EventFragment; + getEvent(nameOrSignatureOrTopic: "SellerUpdatePending"): EventFragment; getEvent(nameOrSignatureOrTopic: "TwinCreated"): EventFragment; getEvent(nameOrSignatureOrTopic: "TwinDeleted"): EventFragment; getEvent(nameOrSignatureOrTopic: "TwinTransferFailed"): EventFragment; @@ -593,18 +760,6 @@ export type BuyerUpdatedEvent = TypedEvent< export type BuyerUpdatedEventFilter = TypedEventFilter; -export type DisputeResolverActivatedEvent = TypedEvent< - [BigNumber, BosonTypes.DisputeResolverStructOutput, string], - { - disputeResolverId: BigNumber; - disputeResolver: BosonTypes.DisputeResolverStructOutput; - executedBy: string; - } ->; - -export type DisputeResolverActivatedEventFilter = - TypedEventFilter; - export type DisputeResolverCreatedEvent = TypedEvent< [ BigNumber, @@ -649,17 +804,35 @@ export type DisputeResolverFeesRemovedEvent = TypedEvent< export type DisputeResolverFeesRemovedEventFilter = TypedEventFilter; -export type DisputeResolverUpdatedEvent = TypedEvent< - [BigNumber, BosonTypes.DisputeResolverStructOutput, string], +export type DisputeResolverUpdateAppliedEvent = TypedEvent< + [ + BigNumber, + BosonTypes.DisputeResolverStructOutput, + BosonTypes.DisputeResolverStructOutput, + string + ], { disputeResolverId: BigNumber; disputeResolver: BosonTypes.DisputeResolverStructOutput; + pendingDisputeResolver: BosonTypes.DisputeResolverStructOutput; + executedBy: string; + } +>; + +export type DisputeResolverUpdateAppliedEventFilter = + TypedEventFilter; + +export type DisputeResolverUpdatePendingEvent = TypedEvent< + [BigNumber, BosonTypes.DisputeResolverStructOutput, string], + { + disputeResolverId: BigNumber; + pendingDisputeResolver: BosonTypes.DisputeResolverStructOutput; executedBy: string; } >; -export type DisputeResolverUpdatedEventFilter = - TypedEventFilter; +export type DisputeResolverUpdatePendingEventFilter = + TypedEventFilter; export type GroupCreatedEvent = TypedEvent< [ @@ -745,6 +918,19 @@ export type OfferVoidedEvent = TypedEvent< export type OfferVoidedEventFilter = TypedEventFilter; +export type RangeReservedEvent = TypedEvent< + [BigNumber, BigNumber, BigNumber, BigNumber, string], + { + offerId: BigNumber; + sellerId: BigNumber; + startExchangeId: BigNumber; + endExchangeId: BigNumber; + executedBy: string; + } +>; + +export type RangeReservedEventFilter = TypedEventFilter; + export type SellerCreatedEvent = TypedEvent< [ BigNumber, @@ -764,22 +950,45 @@ export type SellerCreatedEvent = TypedEvent< export type SellerCreatedEventFilter = TypedEventFilter; -export type SellerUpdatedEvent = TypedEvent< +export type SellerUpdateAppliedEvent = TypedEvent< [ BigNumber, BosonTypes.SellerStructOutput, + BosonTypes.SellerStructOutput, + BosonTypes.AuthTokenStructOutput, BosonTypes.AuthTokenStructOutput, string ], { sellerId: BigNumber; seller: BosonTypes.SellerStructOutput; + pendingSeller: BosonTypes.SellerStructOutput; authToken: BosonTypes.AuthTokenStructOutput; + pendingAuthToken: BosonTypes.AuthTokenStructOutput; executedBy: string; } >; -export type SellerUpdatedEventFilter = TypedEventFilter; +export type SellerUpdateAppliedEventFilter = + TypedEventFilter; + +export type SellerUpdatePendingEvent = TypedEvent< + [ + BigNumber, + BosonTypes.SellerStructOutput, + BosonTypes.AuthTokenStructOutput, + string + ], + { + sellerId: BigNumber; + pendingSeller: BosonTypes.SellerStructOutput; + pendingAuthToken: BosonTypes.AuthTokenStructOutput; + executedBy: string; + } +>; + +export type SellerUpdatePendingEventFilter = + TypedEventFilter; export type TwinCreatedEvent = TypedEvent< [BigNumber, BigNumber, BosonTypes.TwinStructOutput, string], @@ -898,6 +1107,51 @@ export interface IBosonOrchestrationHandler extends BaseContract { overrides?: Overrides & { from?: string | Promise } ): Promise; + createPremintedOfferAddToGroup( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _groupId: BigNumberish, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createPremintedOfferAndTwinWithBundle( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _twin: BosonTypes.TwinStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createPremintedOfferWithCondition( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createPremintedOfferWithConditionAndTwinAndBundle( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _twin: BosonTypes.TwinStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + createSellerAndOffer( _seller: BosonTypes.SellerStruct, _offer: BosonTypes.OfferStruct, @@ -949,6 +1203,67 @@ export interface IBosonOrchestrationHandler extends BaseContract { _agentId: BigNumberish, overrides?: Overrides & { from?: string | Promise } ): Promise; + + createSellerAndPremintedOffer( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createSellerAndPremintedOfferAndTwinWithBundle( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _twin: BosonTypes.TwinStruct, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createSellerAndPremintedOfferWithCondition( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createSellerAndPremintedOfferWithConditionAndTwinAndBundle( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _twin: BosonTypes.TwinStruct, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + raiseAndEscalateDispute( + _exchangeId: BigNumberish, + overrides?: PayableOverrides & { from?: string | Promise } + ): Promise; }; createOfferAddToGroup( @@ -992,6 +1307,51 @@ export interface IBosonOrchestrationHandler extends BaseContract { overrides?: Overrides & { from?: string | Promise } ): Promise; + createPremintedOfferAddToGroup( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _groupId: BigNumberish, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createPremintedOfferAndTwinWithBundle( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _twin: BosonTypes.TwinStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createPremintedOfferWithCondition( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createPremintedOfferWithConditionAndTwinAndBundle( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _twin: BosonTypes.TwinStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + createSellerAndOffer( _seller: BosonTypes.SellerStruct, _offer: BosonTypes.OfferStruct, @@ -1044,42 +1404,148 @@ export interface IBosonOrchestrationHandler extends BaseContract { overrides?: Overrides & { from?: string | Promise } ): Promise; - callStatic: { - createOfferAddToGroup( + createSellerAndPremintedOffer( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createSellerAndPremintedOfferAndTwinWithBundle( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _twin: BosonTypes.TwinStruct, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createSellerAndPremintedOfferWithCondition( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createSellerAndPremintedOfferWithConditionAndTwinAndBundle( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _twin: BosonTypes.TwinStruct, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + raiseAndEscalateDispute( + _exchangeId: BigNumberish, + overrides?: PayableOverrides & { from?: string | Promise } + ): Promise; + + callStatic: { + createOfferAddToGroup( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _groupId: BigNumberish, + _agentId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + createOfferAndTwinWithBundle( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _twin: BosonTypes.TwinStruct, + _agentId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + createOfferWithCondition( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _agentId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + createOfferWithConditionAndTwinAndBundle( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _twin: BosonTypes.TwinStruct, + _agentId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + createPremintedOfferAddToGroup( _offer: BosonTypes.OfferStruct, _offerDates: BosonTypes.OfferDatesStruct, _offerDurations: BosonTypes.OfferDurationsStruct, _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, _groupId: BigNumberish, _agentId: BigNumberish, overrides?: CallOverrides ): Promise; - createOfferAndTwinWithBundle( + createPremintedOfferAndTwinWithBundle( _offer: BosonTypes.OfferStruct, _offerDates: BosonTypes.OfferDatesStruct, _offerDurations: BosonTypes.OfferDurationsStruct, _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, _twin: BosonTypes.TwinStruct, _agentId: BigNumberish, overrides?: CallOverrides ): Promise; - createOfferWithCondition( + createPremintedOfferWithCondition( _offer: BosonTypes.OfferStruct, _offerDates: BosonTypes.OfferDatesStruct, _offerDurations: BosonTypes.OfferDurationsStruct, _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, _condition: BosonTypes.ConditionStruct, _agentId: BigNumberish, overrides?: CallOverrides ): Promise; - createOfferWithConditionAndTwinAndBundle( + createPremintedOfferWithConditionAndTwinAndBundle( _offer: BosonTypes.OfferStruct, _offerDates: BosonTypes.OfferDatesStruct, _offerDurations: BosonTypes.OfferDurationsStruct, _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, _condition: BosonTypes.ConditionStruct, _twin: BosonTypes.TwinStruct, _agentId: BigNumberish, @@ -1137,6 +1603,67 @@ export interface IBosonOrchestrationHandler extends BaseContract { _agentId: BigNumberish, overrides?: CallOverrides ): Promise; + + createSellerAndPremintedOffer( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + createSellerAndPremintedOfferAndTwinWithBundle( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _twin: BosonTypes.TwinStruct, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + createSellerAndPremintedOfferWithCondition( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + createSellerAndPremintedOfferWithConditionAndTwinAndBundle( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _twin: BosonTypes.TwinStruct, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + raiseAndEscalateDispute( + _exchangeId: BigNumberish, + overrides?: CallOverrides + ): Promise; }; filters: { @@ -1219,17 +1746,6 @@ export interface IBosonOrchestrationHandler extends BaseContract { executedBy?: string | null ): BuyerUpdatedEventFilter; - "DisputeResolverActivated(uint256,tuple,address)"( - disputeResolverId?: BigNumberish | null, - disputeResolver?: null, - executedBy?: string | null - ): DisputeResolverActivatedEventFilter; - DisputeResolverActivated( - disputeResolverId?: BigNumberish | null, - disputeResolver?: null, - executedBy?: string | null - ): DisputeResolverActivatedEventFilter; - "DisputeResolverCreated(uint256,tuple,tuple[],uint256[],address)"( disputeResolverId?: BigNumberish | null, disputeResolver?: null, @@ -1267,16 +1783,29 @@ export interface IBosonOrchestrationHandler extends BaseContract { executedBy?: string | null ): DisputeResolverFeesRemovedEventFilter; - "DisputeResolverUpdated(uint256,tuple,address)"( + "DisputeResolverUpdateApplied(uint256,tuple,tuple,address)"( disputeResolverId?: BigNumberish | null, disputeResolver?: null, + pendingDisputeResolver?: null, executedBy?: string | null - ): DisputeResolverUpdatedEventFilter; - DisputeResolverUpdated( + ): DisputeResolverUpdateAppliedEventFilter; + DisputeResolverUpdateApplied( disputeResolverId?: BigNumberish | null, disputeResolver?: null, + pendingDisputeResolver?: null, + executedBy?: string | null + ): DisputeResolverUpdateAppliedEventFilter; + + "DisputeResolverUpdatePending(uint256,tuple,address)"( + disputeResolverId?: BigNumberish | null, + pendingDisputeResolver?: null, executedBy?: string | null - ): DisputeResolverUpdatedEventFilter; + ): DisputeResolverUpdatePendingEventFilter; + DisputeResolverUpdatePending( + disputeResolverId?: BigNumberish | null, + pendingDisputeResolver?: null, + executedBy?: string | null + ): DisputeResolverUpdatePendingEventFilter; "GroupCreated(uint256,uint256,tuple,tuple,address)"( groupId?: BigNumberish | null, @@ -1355,6 +1884,21 @@ export interface IBosonOrchestrationHandler extends BaseContract { executedBy?: string | null ): OfferVoidedEventFilter; + "RangeReserved(uint256,uint256,uint256,uint256,address)"( + offerId?: BigNumberish | null, + sellerId?: BigNumberish | null, + startExchangeId?: null, + endExchangeId?: null, + executedBy?: string | null + ): RangeReservedEventFilter; + RangeReserved( + offerId?: BigNumberish | null, + sellerId?: BigNumberish | null, + startExchangeId?: null, + endExchangeId?: null, + executedBy?: string | null + ): RangeReservedEventFilter; + "SellerCreated(uint256,tuple,address,tuple,address)"( sellerId?: BigNumberish | null, seller?: null, @@ -1370,18 +1914,35 @@ export interface IBosonOrchestrationHandler extends BaseContract { executedBy?: string | null ): SellerCreatedEventFilter; - "SellerUpdated(uint256,tuple,tuple,address)"( + "SellerUpdateApplied(uint256,tuple,tuple,tuple,tuple,address)"( sellerId?: BigNumberish | null, seller?: null, + pendingSeller?: null, authToken?: null, + pendingAuthToken?: null, executedBy?: string | null - ): SellerUpdatedEventFilter; - SellerUpdated( + ): SellerUpdateAppliedEventFilter; + SellerUpdateApplied( sellerId?: BigNumberish | null, seller?: null, + pendingSeller?: null, authToken?: null, + pendingAuthToken?: null, + executedBy?: string | null + ): SellerUpdateAppliedEventFilter; + + "SellerUpdatePending(uint256,tuple,tuple,address)"( + sellerId?: BigNumberish | null, + pendingSeller?: null, + pendingAuthToken?: null, executedBy?: string | null - ): SellerUpdatedEventFilter; + ): SellerUpdatePendingEventFilter; + SellerUpdatePending( + sellerId?: BigNumberish | null, + pendingSeller?: null, + pendingAuthToken?: null, + executedBy?: string | null + ): SellerUpdatePendingEventFilter; "TwinCreated(uint256,uint256,tuple,address)"( twinId?: BigNumberish | null, @@ -1484,6 +2045,51 @@ export interface IBosonOrchestrationHandler extends BaseContract { overrides?: Overrides & { from?: string | Promise } ): Promise; + createPremintedOfferAddToGroup( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _groupId: BigNumberish, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createPremintedOfferAndTwinWithBundle( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _twin: BosonTypes.TwinStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createPremintedOfferWithCondition( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createPremintedOfferWithConditionAndTwinAndBundle( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _twin: BosonTypes.TwinStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + createSellerAndOffer( _seller: BosonTypes.SellerStruct, _offer: BosonTypes.OfferStruct, @@ -1535,6 +2141,67 @@ export interface IBosonOrchestrationHandler extends BaseContract { _agentId: BigNumberish, overrides?: Overrides & { from?: string | Promise } ): Promise; + + createSellerAndPremintedOffer( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createSellerAndPremintedOfferAndTwinWithBundle( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _twin: BosonTypes.TwinStruct, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createSellerAndPremintedOfferWithCondition( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createSellerAndPremintedOfferWithConditionAndTwinAndBundle( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _twin: BosonTypes.TwinStruct, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + raiseAndEscalateDispute( + _exchangeId: BigNumberish, + overrides?: PayableOverrides & { from?: string | Promise } + ): Promise; }; populateTransaction: { @@ -1579,6 +2246,51 @@ export interface IBosonOrchestrationHandler extends BaseContract { overrides?: Overrides & { from?: string | Promise } ): Promise; + createPremintedOfferAddToGroup( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _groupId: BigNumberish, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createPremintedOfferAndTwinWithBundle( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _twin: BosonTypes.TwinStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createPremintedOfferWithCondition( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createPremintedOfferWithConditionAndTwinAndBundle( + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _twin: BosonTypes.TwinStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + createSellerAndOffer( _seller: BosonTypes.SellerStruct, _offer: BosonTypes.OfferStruct, @@ -1630,5 +2342,66 @@ export interface IBosonOrchestrationHandler extends BaseContract { _agentId: BigNumberish, overrides?: Overrides & { from?: string | Promise } ): Promise; + + createSellerAndPremintedOffer( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createSellerAndPremintedOfferAndTwinWithBundle( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _twin: BosonTypes.TwinStruct, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createSellerAndPremintedOfferWithCondition( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + createSellerAndPremintedOfferWithConditionAndTwinAndBundle( + _seller: BosonTypes.SellerStruct, + _offer: BosonTypes.OfferStruct, + _offerDates: BosonTypes.OfferDatesStruct, + _offerDurations: BosonTypes.OfferDurationsStruct, + _disputeResolverId: BigNumberish, + _reservedRangeLength: BigNumberish, + _condition: BosonTypes.ConditionStruct, + _twin: BosonTypes.TwinStruct, + _authToken: BosonTypes.AuthTokenStruct, + _voucherInitValues: BosonTypes.VoucherInitValuesStruct, + _agentId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + raiseAndEscalateDispute( + _exchangeId: BigNumberish, + overrides?: PayableOverrides & { from?: string | Promise } + ): Promise; }; } diff --git a/packages/ethers-sdk/src/contracts/IBosonVoucher.ts b/packages/ethers-sdk/src/contracts/IBosonVoucher.ts index 6e9178a07..4698a37c2 100644 --- a/packages/ethers-sdk/src/contracts/IBosonVoucher.ts +++ b/packages/ethers-sdk/src/contracts/IBosonVoucher.ts @@ -17,20 +17,49 @@ import { FunctionFragment, Result, EventFragment } from "@ethersproject/abi"; import { Listener, Provider } from "@ethersproject/providers"; import { TypedEventFilter, TypedEvent, TypedListener, OnEvent } from "./common"; +export declare namespace IBosonVoucher { + export type RangeStruct = { + offerId: BigNumberish; + start: BigNumberish; + length: BigNumberish; + minted: BigNumberish; + lastBurnedTokenId: BigNumberish; + }; + + export type RangeStructOutput = [ + BigNumber, + BigNumber, + BigNumber, + BigNumber, + BigNumber + ] & { + offerId: BigNumber; + start: BigNumber; + length: BigNumber; + minted: BigNumber; + lastBurnedTokenId: BigNumber; + }; +} + export interface IBosonVoucherInterface extends utils.Interface { contractName: "IBosonVoucher"; functions: { "approve(address,uint256)": FunctionFragment; "balanceOf(address)": FunctionFragment; + "burnPremintedVouchers(uint256)": FunctionFragment; "burnVoucher(uint256)": FunctionFragment; "contractURI()": FunctionFragment; "getApproved(uint256)": FunctionFragment; + "getAvailablePreMints(uint256)": FunctionFragment; + "getRangeByOfferId(uint256)": FunctionFragment; "getRoyaltyPercentage()": FunctionFragment; "getSellerId()": FunctionFragment; "isApprovedForAll(address,address)": FunctionFragment; "issueVoucher(uint256,address)": FunctionFragment; "name()": FunctionFragment; "ownerOf(uint256)": FunctionFragment; + "preMint(uint256,uint256)": FunctionFragment; + "reserveRange(uint256,uint256,uint256)": FunctionFragment; "royaltyInfo(uint256,uint256)": FunctionFragment; "safeTransferFrom(address,address,uint256)": FunctionFragment; "setApprovalForAll(address,bool)": FunctionFragment; @@ -48,6 +77,10 @@ export interface IBosonVoucherInterface extends utils.Interface { values: [string, BigNumberish] ): string; encodeFunctionData(functionFragment: "balanceOf", values: [string]): string; + encodeFunctionData( + functionFragment: "burnPremintedVouchers", + values: [BigNumberish] + ): string; encodeFunctionData( functionFragment: "burnVoucher", values: [BigNumberish] @@ -60,6 +93,14 @@ export interface IBosonVoucherInterface extends utils.Interface { functionFragment: "getApproved", values: [BigNumberish] ): string; + encodeFunctionData( + functionFragment: "getAvailablePreMints", + values: [BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "getRangeByOfferId", + values: [BigNumberish] + ): string; encodeFunctionData( functionFragment: "getRoyaltyPercentage", values?: undefined @@ -81,6 +122,14 @@ export interface IBosonVoucherInterface extends utils.Interface { functionFragment: "ownerOf", values: [BigNumberish] ): string; + encodeFunctionData( + functionFragment: "preMint", + values: [BigNumberish, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "reserveRange", + values: [BigNumberish, BigNumberish, BigNumberish] + ): string; encodeFunctionData( functionFragment: "royaltyInfo", values: [BigNumberish, BigNumberish] @@ -121,6 +170,10 @@ export interface IBosonVoucherInterface extends utils.Interface { decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result; decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "burnPremintedVouchers", + data: BytesLike + ): Result; decodeFunctionResult( functionFragment: "burnVoucher", data: BytesLike @@ -133,6 +186,14 @@ export interface IBosonVoucherInterface extends utils.Interface { functionFragment: "getApproved", data: BytesLike ): Result; + decodeFunctionResult( + functionFragment: "getAvailablePreMints", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "getRangeByOfferId", + data: BytesLike + ): Result; decodeFunctionResult( functionFragment: "getRoyaltyPercentage", data: BytesLike @@ -151,6 +212,11 @@ export interface IBosonVoucherInterface extends utils.Interface { ): Result; decodeFunctionResult(functionFragment: "name", data: BytesLike): Result; decodeFunctionResult(functionFragment: "ownerOf", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "preMint", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "reserveRange", + data: BytesLike + ): Result; decodeFunctionResult( functionFragment: "royaltyInfo", data: BytesLike @@ -190,6 +256,7 @@ export interface IBosonVoucherInterface extends utils.Interface { "Approval(address,address,uint256)": EventFragment; "ApprovalForAll(address,address,bool)": EventFragment; "ContractURIChanged(string)": EventFragment; + "RangeReserved(uint256,tuple)": EventFragment; "RoyaltyPercentageChanged(uint256)": EventFragment; "Transfer(address,address,uint256)": EventFragment; "VoucherInitialized(uint256,uint256,string)": EventFragment; @@ -198,6 +265,7 @@ export interface IBosonVoucherInterface extends utils.Interface { getEvent(nameOrSignatureOrTopic: "Approval"): EventFragment; getEvent(nameOrSignatureOrTopic: "ApprovalForAll"): EventFragment; getEvent(nameOrSignatureOrTopic: "ContractURIChanged"): EventFragment; + getEvent(nameOrSignatureOrTopic: "RangeReserved"): EventFragment; getEvent(nameOrSignatureOrTopic: "RoyaltyPercentageChanged"): EventFragment; getEvent(nameOrSignatureOrTopic: "Transfer"): EventFragment; getEvent(nameOrSignatureOrTopic: "VoucherInitialized"): EventFragment; @@ -225,6 +293,13 @@ export type ContractURIChangedEvent = TypedEvent< export type ContractURIChangedEventFilter = TypedEventFilter; +export type RangeReservedEvent = TypedEvent< + [BigNumber, IBosonVoucher.RangeStructOutput], + { offerId: BigNumber; range: IBosonVoucher.RangeStructOutput } +>; + +export type RangeReservedEventFilter = TypedEventFilter; + export type RoyaltyPercentageChangedEvent = TypedEvent< [BigNumber], { royaltyPercentage: BigNumber } @@ -287,6 +362,11 @@ export interface IBosonVoucher extends BaseContract { overrides?: CallOverrides ): Promise<[BigNumber] & { balance: BigNumber }>; + burnPremintedVouchers( + _offerId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + burnVoucher( _exchangeId: BigNumberish, overrides?: Overrides & { from?: string | Promise } @@ -299,6 +379,20 @@ export interface IBosonVoucher extends BaseContract { overrides?: CallOverrides ): Promise<[string] & { operator: string }>; + getAvailablePreMints( + _offerId: BigNumberish, + overrides?: CallOverrides + ): Promise<[BigNumber] & { count: BigNumber }>; + + getRangeByOfferId( + _offerId: BigNumberish, + overrides?: CallOverrides + ): Promise< + [IBosonVoucher.RangeStructOutput] & { + range: IBosonVoucher.RangeStructOutput; + } + >; + getRoyaltyPercentage(overrides?: CallOverrides): Promise<[BigNumber]>; getSellerId(overrides?: CallOverrides): Promise<[BigNumber]>; @@ -322,6 +416,19 @@ export interface IBosonVoucher extends BaseContract { overrides?: CallOverrides ): Promise<[string] & { owner: string }>; + preMint( + _offerId: BigNumberish, + _amount: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + reserveRange( + _offerId: BigNumberish, + _start: BigNumberish, + _length: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + royaltyInfo( _tokenId: BigNumberish, _salePrice: BigNumberish, @@ -394,6 +501,11 @@ export interface IBosonVoucher extends BaseContract { balanceOf(owner: string, overrides?: CallOverrides): Promise; + burnPremintedVouchers( + _offerId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + burnVoucher( _exchangeId: BigNumberish, overrides?: Overrides & { from?: string | Promise } @@ -406,6 +518,16 @@ export interface IBosonVoucher extends BaseContract { overrides?: CallOverrides ): Promise; + getAvailablePreMints( + _offerId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + getRangeByOfferId( + _offerId: BigNumberish, + overrides?: CallOverrides + ): Promise; + getRoyaltyPercentage(overrides?: CallOverrides): Promise; getSellerId(overrides?: CallOverrides): Promise; @@ -426,6 +548,19 @@ export interface IBosonVoucher extends BaseContract { ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + preMint( + _offerId: BigNumberish, + _amount: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + reserveRange( + _offerId: BigNumberish, + _start: BigNumberish, + _length: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + royaltyInfo( _tokenId: BigNumberish, _salePrice: BigNumberish, @@ -495,6 +630,11 @@ export interface IBosonVoucher extends BaseContract { balanceOf(owner: string, overrides?: CallOverrides): Promise; + burnPremintedVouchers( + _offerId: BigNumberish, + overrides?: CallOverrides + ): Promise; + burnVoucher( _exchangeId: BigNumberish, overrides?: CallOverrides @@ -507,6 +647,16 @@ export interface IBosonVoucher extends BaseContract { overrides?: CallOverrides ): Promise; + getAvailablePreMints( + _offerId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + getRangeByOfferId( + _offerId: BigNumberish, + overrides?: CallOverrides + ): Promise; + getRoyaltyPercentage(overrides?: CallOverrides): Promise; getSellerId(overrides?: CallOverrides): Promise; @@ -527,6 +677,19 @@ export interface IBosonVoucher extends BaseContract { ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + preMint( + _offerId: BigNumberish, + _amount: BigNumberish, + overrides?: CallOverrides + ): Promise; + + reserveRange( + _offerId: BigNumberish, + _start: BigNumberish, + _length: BigNumberish, + overrides?: CallOverrides + ): Promise; + royaltyInfo( _tokenId: BigNumberish, _salePrice: BigNumberish, @@ -616,6 +779,15 @@ export interface IBosonVoucher extends BaseContract { ): ContractURIChangedEventFilter; ContractURIChanged(contractURI?: null): ContractURIChangedEventFilter; + "RangeReserved(uint256,tuple)"( + offerId?: BigNumberish | null, + range?: null + ): RangeReservedEventFilter; + RangeReserved( + offerId?: BigNumberish | null, + range?: null + ): RangeReservedEventFilter; + "RoyaltyPercentageChanged(uint256)"( royaltyPercentage?: null ): RoyaltyPercentageChangedEventFilter; @@ -655,6 +827,11 @@ export interface IBosonVoucher extends BaseContract { balanceOf(owner: string, overrides?: CallOverrides): Promise; + burnPremintedVouchers( + _offerId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + burnVoucher( _exchangeId: BigNumberish, overrides?: Overrides & { from?: string | Promise } @@ -667,6 +844,16 @@ export interface IBosonVoucher extends BaseContract { overrides?: CallOverrides ): Promise; + getAvailablePreMints( + _offerId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + getRangeByOfferId( + _offerId: BigNumberish, + overrides?: CallOverrides + ): Promise; + getRoyaltyPercentage(overrides?: CallOverrides): Promise; getSellerId(overrides?: CallOverrides): Promise; @@ -690,6 +877,19 @@ export interface IBosonVoucher extends BaseContract { overrides?: CallOverrides ): Promise; + preMint( + _offerId: BigNumberish, + _amount: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + reserveRange( + _offerId: BigNumberish, + _start: BigNumberish, + _length: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + royaltyInfo( _tokenId: BigNumberish, _salePrice: BigNumberish, @@ -764,6 +964,11 @@ export interface IBosonVoucher extends BaseContract { overrides?: CallOverrides ): Promise; + burnPremintedVouchers( + _offerId: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + burnVoucher( _exchangeId: BigNumberish, overrides?: Overrides & { from?: string | Promise } @@ -776,6 +981,16 @@ export interface IBosonVoucher extends BaseContract { overrides?: CallOverrides ): Promise; + getAvailablePreMints( + _offerId: BigNumberish, + overrides?: CallOverrides + ): Promise; + + getRangeByOfferId( + _offerId: BigNumberish, + overrides?: CallOverrides + ): Promise; + getRoyaltyPercentage( overrides?: CallOverrides ): Promise; @@ -801,6 +1016,19 @@ export interface IBosonVoucher extends BaseContract { overrides?: CallOverrides ): Promise; + preMint( + _offerId: BigNumberish, + _amount: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + + reserveRange( + _offerId: BigNumberish, + _start: BigNumberish, + _length: BigNumberish, + overrides?: Overrides & { from?: string | Promise } + ): Promise; + royaltyInfo( _tokenId: BigNumberish, _salePrice: BigNumberish, diff --git a/packages/ethers-sdk/src/contracts/MockNativeMetaTransaction.ts b/packages/ethers-sdk/src/contracts/MockNativeMetaTransaction.ts new file mode 100644 index 000000000..a32920795 --- /dev/null +++ b/packages/ethers-sdk/src/contracts/MockNativeMetaTransaction.ts @@ -0,0 +1,199 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + PayableOverrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import { FunctionFragment, Result, EventFragment } from "@ethersproject/abi"; +import { Listener, Provider } from "@ethersproject/providers"; +import { TypedEventFilter, TypedEvent, TypedListener, OnEvent } from "./common"; + +export interface MockNativeMetaTransactionInterface extends utils.Interface { + contractName: "MockNativeMetaTransaction"; + functions: { + "executeMetaTransaction(address,bytes,bytes32,bytes32,uint8)": FunctionFragment; + "getChainId()": FunctionFragment; + "getDomainSeperator()": FunctionFragment; + "getNonce(address)": FunctionFragment; + }; + + encodeFunctionData( + functionFragment: "executeMetaTransaction", + values: [string, BytesLike, BytesLike, BytesLike, BigNumberish] + ): string; + encodeFunctionData( + functionFragment: "getChainId", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "getDomainSeperator", + values?: undefined + ): string; + encodeFunctionData(functionFragment: "getNonce", values: [string]): string; + + decodeFunctionResult( + functionFragment: "executeMetaTransaction", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "getChainId", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "getDomainSeperator", + data: BytesLike + ): Result; + decodeFunctionResult(functionFragment: "getNonce", data: BytesLike): Result; + + events: { + "MetaTransactionExecuted(address,address,bytes)": EventFragment; + }; + + getEvent(nameOrSignatureOrTopic: "MetaTransactionExecuted"): EventFragment; +} + +export type MetaTransactionExecutedEvent = TypedEvent< + [string, string, string], + { userAddress: string; relayerAddress: string; functionSignature: string } +>; + +export type MetaTransactionExecutedEventFilter = + TypedEventFilter; + +export interface MockNativeMetaTransaction extends BaseContract { + contractName: "MockNativeMetaTransaction"; + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: MockNativeMetaTransactionInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + executeMetaTransaction( + userAddress: string, + functionSignature: BytesLike, + sigR: BytesLike, + sigS: BytesLike, + sigV: BigNumberish, + overrides?: PayableOverrides & { from?: string | Promise } + ): Promise; + + getChainId(overrides?: CallOverrides): Promise<[BigNumber]>; + + getDomainSeperator(overrides?: CallOverrides): Promise<[string]>; + + getNonce( + user: string, + overrides?: CallOverrides + ): Promise<[BigNumber] & { nonce: BigNumber }>; + }; + + executeMetaTransaction( + userAddress: string, + functionSignature: BytesLike, + sigR: BytesLike, + sigS: BytesLike, + sigV: BigNumberish, + overrides?: PayableOverrides & { from?: string | Promise } + ): Promise; + + getChainId(overrides?: CallOverrides): Promise; + + getDomainSeperator(overrides?: CallOverrides): Promise; + + getNonce(user: string, overrides?: CallOverrides): Promise; + + callStatic: { + executeMetaTransaction( + userAddress: string, + functionSignature: BytesLike, + sigR: BytesLike, + sigS: BytesLike, + sigV: BigNumberish, + overrides?: CallOverrides + ): Promise; + + getChainId(overrides?: CallOverrides): Promise; + + getDomainSeperator(overrides?: CallOverrides): Promise; + + getNonce(user: string, overrides?: CallOverrides): Promise; + }; + + filters: { + "MetaTransactionExecuted(address,address,bytes)"( + userAddress?: null, + relayerAddress?: null, + functionSignature?: null + ): MetaTransactionExecutedEventFilter; + MetaTransactionExecuted( + userAddress?: null, + relayerAddress?: null, + functionSignature?: null + ): MetaTransactionExecutedEventFilter; + }; + + estimateGas: { + executeMetaTransaction( + userAddress: string, + functionSignature: BytesLike, + sigR: BytesLike, + sigS: BytesLike, + sigV: BigNumberish, + overrides?: PayableOverrides & { from?: string | Promise } + ): Promise; + + getChainId(overrides?: CallOverrides): Promise; + + getDomainSeperator(overrides?: CallOverrides): Promise; + + getNonce(user: string, overrides?: CallOverrides): Promise; + }; + + populateTransaction: { + executeMetaTransaction( + userAddress: string, + functionSignature: BytesLike, + sigR: BytesLike, + sigS: BytesLike, + sigV: BigNumberish, + overrides?: PayableOverrides & { from?: string | Promise } + ): Promise; + + getChainId(overrides?: CallOverrides): Promise; + + getDomainSeperator( + overrides?: CallOverrides + ): Promise; + + getNonce( + user: string, + overrides?: CallOverrides + ): Promise; + }; +} diff --git a/packages/ethers-sdk/src/contracts/factories/ERC1155__factory.ts b/packages/ethers-sdk/src/contracts/factories/ERC1155__factory.ts new file mode 100644 index 000000000..d60c56b2a --- /dev/null +++ b/packages/ethers-sdk/src/contracts/factories/ERC1155__factory.ts @@ -0,0 +1,297 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import { Provider } from "@ethersproject/providers"; +import type { ERC1155, ERC1155Interface } from "../ERC1155"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "_owner", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "_operator", + type: "address", + }, + { + indexed: false, + internalType: "bool", + name: "_approved", + type: "bool", + }, + ], + name: "ApprovalForAll", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "_operator", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "_from", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "_to", + type: "address", + }, + { + indexed: false, + internalType: "uint256[]", + name: "_ids", + type: "uint256[]", + }, + { + indexed: false, + internalType: "uint256[]", + name: "_amounts", + type: "uint256[]", + }, + ], + name: "TransferBatch", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "_operator", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "_from", + type: "address", + }, + { + indexed: true, + internalType: "address", + name: "_to", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "_id", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "_amount", + type: "uint256", + }, + ], + name: "TransferSingle", + type: "event", + }, + { + inputs: [ + { + internalType: "address", + name: "_owner", + type: "address", + }, + { + internalType: "uint256", + name: "_id", + type: "uint256", + }, + ], + name: "balanceOf", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address[]", + name: "_owners", + type: "address[]", + }, + { + internalType: "uint256[]", + name: "_ids", + type: "uint256[]", + }, + ], + name: "balanceOfBatch", + outputs: [ + { + internalType: "uint256[]", + name: "", + type: "uint256[]", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "_owner", + type: "address", + }, + { + internalType: "address", + name: "_operator", + type: "address", + }, + ], + name: "isApprovedForAll", + outputs: [ + { + internalType: "bool", + name: "isOperator", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "_from", + type: "address", + }, + { + internalType: "address", + name: "_to", + type: "address", + }, + { + internalType: "uint256[]", + name: "_ids", + type: "uint256[]", + }, + { + internalType: "uint256[]", + name: "_amounts", + type: "uint256[]", + }, + { + internalType: "bytes", + name: "_data", + type: "bytes", + }, + ], + name: "safeBatchTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "_from", + type: "address", + }, + { + internalType: "address", + name: "_to", + type: "address", + }, + { + internalType: "uint256", + name: "_id", + type: "uint256", + }, + { + internalType: "uint256", + name: "_amount", + type: "uint256", + }, + { + internalType: "bytes", + name: "_data", + type: "bytes", + }, + ], + name: "safeTransferFrom", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "_operator", + type: "address", + }, + { + internalType: "bool", + name: "_approved", + type: "bool", + }, + ], + name: "setApprovalForAll", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "bytes4", + name: "_interfaceID", + type: "bytes4", + }, + ], + name: "supportsInterface", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "pure", + type: "function", + }, +]; + +export class ERC1155__factory { + static readonly abi = _abi; + static createInterface(): ERC1155Interface { + return new utils.Interface(_abi) as ERC1155Interface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): ERC1155 { + return new Contract(address, _abi, signerOrProvider) as ERC1155; + } +} diff --git a/packages/ethers-sdk/src/contracts/factories/IBosonAccountHandler__factory.ts b/packages/ethers-sdk/src/contracts/factories/IBosonAccountHandler__factory.ts index 02813b00c..477109792 100644 --- a/packages/ethers-sdk/src/contracts/factories/IBosonAccountHandler__factory.ts +++ b/packages/ethers-sdk/src/contracts/factories/IBosonAccountHandler__factory.ts @@ -468,6 +468,188 @@ const _abi = [ name: "DisputeResolverFeesRemoved", type: "event", }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "disputeResolverId", + type: "uint256", + }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "escalationResponsePeriod", + type: "uint256", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "admin", + type: "address", + }, + { + internalType: "address", + name: "clerk", + type: "address", + }, + { + internalType: "address payable", + name: "treasury", + type: "address", + }, + { + internalType: "string", + name: "metadataUri", + type: "string", + }, + { + internalType: "bool", + name: "active", + type: "bool", + }, + ], + indexed: false, + internalType: "struct BosonTypes.DisputeResolver", + name: "disputeResolver", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "escalationResponsePeriod", + type: "uint256", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "admin", + type: "address", + }, + { + internalType: "address", + name: "clerk", + type: "address", + }, + { + internalType: "address payable", + name: "treasury", + type: "address", + }, + { + internalType: "string", + name: "metadataUri", + type: "string", + }, + { + internalType: "bool", + name: "active", + type: "bool", + }, + ], + indexed: false, + internalType: "struct BosonTypes.DisputeResolver", + name: "pendingDisputeResolver", + type: "tuple", + }, + { + indexed: true, + internalType: "address", + name: "executedBy", + type: "address", + }, + ], + name: "DisputeResolverUpdateApplied", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "disputeResolverId", + type: "uint256", + }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "escalationResponsePeriod", + type: "uint256", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "admin", + type: "address", + }, + { + internalType: "address", + name: "clerk", + type: "address", + }, + { + internalType: "address payable", + name: "treasury", + type: "address", + }, + { + internalType: "string", + name: "metadataUri", + type: "string", + }, + { + internalType: "bool", + name: "active", + type: "bool", + }, + ], + indexed: false, + internalType: "struct BosonTypes.DisputeResolver", + name: "pendingDisputeResolver", + type: "tuple", + }, + { + indexed: true, + internalType: "address", + name: "executedBy", + type: "address", + }, + ], + name: "DisputeResolverUpdatePending", + type: "event", + }, { anonymous: false, inputs: [ @@ -663,6 +845,44 @@ const _abi = [ name: "seller", type: "tuple", }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "admin", + type: "address", + }, + { + internalType: "address", + name: "clerk", + type: "address", + }, + { + internalType: "address payable", + name: "treasury", + type: "address", + }, + { + internalType: "bool", + name: "active", + type: "bool", + }, + ], + indexed: false, + internalType: "struct BosonTypes.Seller", + name: "pendingSeller", + type: "tuple", + }, { components: [ { @@ -681,6 +901,24 @@ const _abi = [ name: "authToken", type: "tuple", }, + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "enum BosonTypes.AuthTokenType", + name: "tokenType", + type: "uint8", + }, + ], + indexed: false, + internalType: "struct BosonTypes.AuthToken", + name: "pendingAuthToken", + type: "tuple", + }, { indexed: true, internalType: "address", @@ -688,21 +926,158 @@ const _abi = [ type: "address", }, ], - name: "SellerUpdated", + name: "SellerUpdateApplied", type: "event", }, { + anonymous: false, inputs: [ { + indexed: true, internalType: "uint256", - name: "_disputeResolverId", + name: "sellerId", type: "uint256", }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "admin", + type: "address", + }, + { + internalType: "address", + name: "clerk", + type: "address", + }, + { + internalType: "address payable", + name: "treasury", + type: "address", + }, + { + internalType: "bool", + name: "active", + type: "bool", + }, + ], + indexed: false, + internalType: "struct BosonTypes.Seller", + name: "pendingSeller", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "enum BosonTypes.AuthTokenType", + name: "tokenType", + type: "uint8", + }, + ], + indexed: false, + internalType: "struct BosonTypes.AuthToken", + name: "pendingAuthToken", + type: "tuple", + }, + { + indexed: true, + internalType: "address", + name: "executedBy", + type: "address", + }, ], - name: "activateDisputeResolver", - outputs: [], - stateMutability: "nonpayable", - type: "function", + name: "SellerUpdatePending", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "admin", + type: "address", + }, + { + internalType: "address", + name: "clerk", + type: "address", + }, + { + internalType: "address payable", + name: "treasury", + type: "address", + }, + { + internalType: "bool", + name: "active", + type: "bool", + }, + ], + indexed: false, + internalType: "struct BosonTypes.Seller", + name: "seller", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "enum BosonTypes.AuthTokenType", + name: "tokenType", + type: "uint8", + }, + ], + indexed: false, + internalType: "struct BosonTypes.AuthToken", + name: "authToken", + type: "tuple", + }, + { + indexed: true, + internalType: "address", + name: "executedBy", + type: "address", + }, + ], + name: "SellerUpdated", + type: "event", }, { inputs: [ @@ -1524,6 +1899,42 @@ const _abi = [ stateMutability: "view", type: "function", }, + { + inputs: [ + { + internalType: "uint256", + name: "_disputeResolverId", + type: "uint256", + }, + { + internalType: "enum BosonTypes.DisputeResolverUpdateFields[]", + name: "_fieldsToUpdate", + type: "uint8[]", + }, + ], + name: "optInToDisputeResolverUpdate", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "_sellerId", + type: "uint256", + }, + { + internalType: "enum BosonTypes.SellerUpdateFields[]", + name: "_fieldsToUpdate", + type: "uint8[]", + }, + ], + name: "optInToSellerUpdate", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, { inputs: [ { diff --git a/packages/ethers-sdk/src/contracts/factories/IBosonExchangeHandler__factory.ts b/packages/ethers-sdk/src/contracts/factories/IBosonExchangeHandler__factory.ts index 5fe66dc86..df1cb4762 100644 --- a/packages/ethers-sdk/src/contracts/factories/IBosonExchangeHandler__factory.ts +++ b/packages/ethers-sdk/src/contracts/factories/IBosonExchangeHandler__factory.ts @@ -641,6 +641,29 @@ const _abi = [ stateMutability: "payable", type: "function", }, + { + inputs: [ + { + internalType: "address payable", + name: "_buyer", + type: "address", + }, + { + internalType: "uint256", + name: "_offerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "_exchangeId", + type: "uint256", + }, + ], + name: "commitToPreMintedOffer", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, { inputs: [ { diff --git a/packages/ethers-sdk/src/contracts/factories/IBosonGroupHandler__factory.ts b/packages/ethers-sdk/src/contracts/factories/IBosonGroupHandler__factory.ts new file mode 100644 index 000000000..420f0fa61 --- /dev/null +++ b/packages/ethers-sdk/src/contracts/factories/IBosonGroupHandler__factory.ts @@ -0,0 +1,442 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import { Provider } from "@ethersproject/providers"; +import type { + IBosonGroupHandler, + IBosonGroupHandlerInterface, +} from "../IBosonGroupHandler"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "groupId", + type: "uint256", + }, + { + indexed: true, + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256[]", + name: "offerIds", + type: "uint256[]", + }, + ], + indexed: false, + internalType: "struct BosonTypes.Group", + name: "group", + type: "tuple", + }, + { + components: [ + { + internalType: "enum BosonTypes.EvaluationMethod", + name: "method", + type: "uint8", + }, + { + internalType: "enum BosonTypes.TokenType", + name: "tokenType", + type: "uint8", + }, + { + internalType: "address", + name: "tokenAddress", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "threshold", + type: "uint256", + }, + { + internalType: "uint256", + name: "maxCommits", + type: "uint256", + }, + ], + indexed: false, + internalType: "struct BosonTypes.Condition", + name: "condition", + type: "tuple", + }, + { + indexed: true, + internalType: "address", + name: "executedBy", + type: "address", + }, + ], + name: "GroupCreated", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "groupId", + type: "uint256", + }, + { + indexed: true, + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256[]", + name: "offerIds", + type: "uint256[]", + }, + ], + indexed: false, + internalType: "struct BosonTypes.Group", + name: "group", + type: "tuple", + }, + { + components: [ + { + internalType: "enum BosonTypes.EvaluationMethod", + name: "method", + type: "uint8", + }, + { + internalType: "enum BosonTypes.TokenType", + name: "tokenType", + type: "uint8", + }, + { + internalType: "address", + name: "tokenAddress", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "threshold", + type: "uint256", + }, + { + internalType: "uint256", + name: "maxCommits", + type: "uint256", + }, + ], + indexed: false, + internalType: "struct BosonTypes.Condition", + name: "condition", + type: "tuple", + }, + { + indexed: true, + internalType: "address", + name: "executedBy", + type: "address", + }, + ], + name: "GroupUpdated", + type: "event", + }, + { + inputs: [ + { + internalType: "uint256", + name: "_groupId", + type: "uint256", + }, + { + internalType: "uint256[]", + name: "_offerIds", + type: "uint256[]", + }, + ], + name: "addOffersToGroup", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256[]", + name: "offerIds", + type: "uint256[]", + }, + ], + internalType: "struct BosonTypes.Group", + name: "_group", + type: "tuple", + }, + { + components: [ + { + internalType: "enum BosonTypes.EvaluationMethod", + name: "method", + type: "uint8", + }, + { + internalType: "enum BosonTypes.TokenType", + name: "tokenType", + type: "uint8", + }, + { + internalType: "address", + name: "tokenAddress", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "threshold", + type: "uint256", + }, + { + internalType: "uint256", + name: "maxCommits", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.Condition", + name: "_condition", + type: "tuple", + }, + ], + name: "createGroup", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "_groupId", + type: "uint256", + }, + ], + name: "getGroup", + outputs: [ + { + internalType: "bool", + name: "exists", + type: "bool", + }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256[]", + name: "offerIds", + type: "uint256[]", + }, + ], + internalType: "struct BosonTypes.Group", + name: "group", + type: "tuple", + }, + { + components: [ + { + internalType: "enum BosonTypes.EvaluationMethod", + name: "method", + type: "uint8", + }, + { + internalType: "enum BosonTypes.TokenType", + name: "tokenType", + type: "uint8", + }, + { + internalType: "address", + name: "tokenAddress", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "threshold", + type: "uint256", + }, + { + internalType: "uint256", + name: "maxCommits", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.Condition", + name: "condition", + type: "tuple", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "getNextGroupId", + outputs: [ + { + internalType: "uint256", + name: "nextGroupId", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "_groupId", + type: "uint256", + }, + { + internalType: "uint256[]", + name: "_offerIds", + type: "uint256[]", + }, + ], + name: "removeOffersFromGroup", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "_groupId", + type: "uint256", + }, + { + components: [ + { + internalType: "enum BosonTypes.EvaluationMethod", + name: "method", + type: "uint8", + }, + { + internalType: "enum BosonTypes.TokenType", + name: "tokenType", + type: "uint8", + }, + { + internalType: "address", + name: "tokenAddress", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "threshold", + type: "uint256", + }, + { + internalType: "uint256", + name: "maxCommits", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.Condition", + name: "_condition", + type: "tuple", + }, + ], + name: "setGroupCondition", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, +]; + +export class IBosonGroupHandler__factory { + static readonly abi = _abi; + static createInterface(): IBosonGroupHandlerInterface { + return new utils.Interface(_abi) as IBosonGroupHandlerInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): IBosonGroupHandler { + return new Contract(address, _abi, signerOrProvider) as IBosonGroupHandler; + } +} diff --git a/packages/ethers-sdk/src/contracts/factories/IBosonMetaTransactionsHandler__factory.ts b/packages/ethers-sdk/src/contracts/factories/IBosonMetaTransactionsHandler__factory.ts index c546408cc..d27f71548 100644 --- a/packages/ethers-sdk/src/contracts/factories/IBosonMetaTransactionsHandler__factory.ts +++ b/packages/ethers-sdk/src/contracts/factories/IBosonMetaTransactionsHandler__factory.ts @@ -10,6 +10,31 @@ import type { } from "../IBosonMetaTransactionsHandler"; const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "bytes32[]", + name: "functionNameHashes", + type: "bytes32[]", + }, + { + indexed: false, + internalType: "bool", + name: "isAllowlisted", + type: "bool", + }, + { + indexed: true, + internalType: "address", + name: "executedBy", + type: "address", + }, + ], + name: "FunctionsAllowlisted", + type: "event", + }, { anonymous: false, inputs: [ @@ -90,6 +115,44 @@ const _abi = [ stateMutability: "payable", type: "function", }, + { + inputs: [ + { + internalType: "string", + name: "_functionName", + type: "string", + }, + ], + name: "isFunctionAllowlisted", + outputs: [ + { + internalType: "bool", + name: "isAllowlisted", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "bytes32", + name: "_functionNameHash", + type: "bytes32", + }, + ], + name: "isFunctionAllowlisted", + outputs: [ + { + internalType: "bool", + name: "isAllowlisted", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, { inputs: [ { @@ -114,6 +177,24 @@ const _abi = [ stateMutability: "view", type: "function", }, + { + inputs: [ + { + internalType: "bytes32[]", + name: "_functionNameHashes", + type: "bytes32[]", + }, + { + internalType: "bool", + name: "_isAllowlisted", + type: "bool", + }, + ], + name: "setAllowlistedFunctions", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, ]; export class IBosonMetaTransactionsHandler__factory { diff --git a/packages/ethers-sdk/src/contracts/factories/IBosonOfferHandler__factory.ts b/packages/ethers-sdk/src/contracts/factories/IBosonOfferHandler__factory.ts index 7b5e41786..dbafed67a 100644 --- a/packages/ethers-sdk/src/contracts/factories/IBosonOfferHandler__factory.ts +++ b/packages/ethers-sdk/src/contracts/factories/IBosonOfferHandler__factory.ts @@ -252,6 +252,43 @@ const _abi = [ name: "OfferVoided", type: "event", }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "offerId", + type: "uint256", + }, + { + indexed: true, + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "startExchangeId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "endExchangeId", + type: "uint256", + }, + { + indexed: true, + internalType: "address", + name: "executedBy", + type: "address", + }, + ], + name: "RangeReserved", + type: "event", + }, { inputs: [ { @@ -766,6 +803,24 @@ const _abi = [ stateMutability: "view", type: "function", }, + { + inputs: [ + { + internalType: "uint256", + name: "_offerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "_length", + type: "uint256", + }, + ], + name: "reserveRange", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, { inputs: [ { diff --git a/packages/ethers-sdk/src/contracts/factories/IBosonOrchestrationHandler__factory.ts b/packages/ethers-sdk/src/contracts/factories/IBosonOrchestrationHandler__factory.ts index 9728b84c7..dab6ef91a 100644 --- a/packages/ethers-sdk/src/contracts/factories/IBosonOrchestrationHandler__factory.ts +++ b/packages/ethers-sdk/src/contracts/factories/IBosonOrchestrationHandler__factory.ts @@ -291,73 +291,6 @@ const _abi = [ name: "BuyerUpdated", type: "event", }, - { - anonymous: false, - inputs: [ - { - indexed: true, - internalType: "uint256", - name: "disputeResolverId", - type: "uint256", - }, - { - components: [ - { - internalType: "uint256", - name: "id", - type: "uint256", - }, - { - internalType: "uint256", - name: "escalationResponsePeriod", - type: "uint256", - }, - { - internalType: "address", - name: "operator", - type: "address", - }, - { - internalType: "address", - name: "admin", - type: "address", - }, - { - internalType: "address", - name: "clerk", - type: "address", - }, - { - internalType: "address payable", - name: "treasury", - type: "address", - }, - { - internalType: "string", - name: "metadataUri", - type: "string", - }, - { - internalType: "bool", - name: "active", - type: "bool", - }, - ], - indexed: false, - internalType: "struct BosonTypes.DisputeResolver", - name: "disputeResolver", - type: "tuple", - }, - { - indexed: true, - internalType: "address", - name: "executedBy", - type: "address", - }, - ], - name: "DisputeResolverActivated", - type: "event", - }, { anonymous: false, inputs: [ @@ -578,6 +511,121 @@ const _abi = [ name: "disputeResolver", type: "tuple", }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "escalationResponsePeriod", + type: "uint256", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "admin", + type: "address", + }, + { + internalType: "address", + name: "clerk", + type: "address", + }, + { + internalType: "address payable", + name: "treasury", + type: "address", + }, + { + internalType: "string", + name: "metadataUri", + type: "string", + }, + { + internalType: "bool", + name: "active", + type: "bool", + }, + ], + indexed: false, + internalType: "struct BosonTypes.DisputeResolver", + name: "pendingDisputeResolver", + type: "tuple", + }, + { + indexed: true, + internalType: "address", + name: "executedBy", + type: "address", + }, + ], + name: "DisputeResolverUpdateApplied", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "disputeResolverId", + type: "uint256", + }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "escalationResponsePeriod", + type: "uint256", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "admin", + type: "address", + }, + { + internalType: "address", + name: "clerk", + type: "address", + }, + { + internalType: "address payable", + name: "treasury", + type: "address", + }, + { + internalType: "string", + name: "metadataUri", + type: "string", + }, + { + internalType: "bool", + name: "active", + type: "bool", + }, + ], + indexed: false, + internalType: "struct BosonTypes.DisputeResolver", + name: "pendingDisputeResolver", + type: "tuple", + }, { indexed: true, internalType: "address", @@ -585,7 +633,7 @@ const _abi = [ type: "address", }, ], - name: "DisputeResolverUpdated", + name: "DisputeResolverUpdatePending", type: "event", }, { @@ -1002,6 +1050,43 @@ const _abi = [ name: "OfferVoided", type: "event", }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "offerId", + type: "uint256", + }, + { + indexed: true, + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "startExchangeId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "endExchangeId", + type: "uint256", + }, + { + indexed: true, + internalType: "address", + name: "executedBy", + type: "address", + }, + ], + name: "RangeReserved", + type: "event", + }, { anonymous: false, inputs: [ @@ -1130,6 +1215,44 @@ const _abi = [ name: "seller", type: "tuple", }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "admin", + type: "address", + }, + { + internalType: "address", + name: "clerk", + type: "address", + }, + { + internalType: "address payable", + name: "treasury", + type: "address", + }, + { + internalType: "bool", + name: "active", + type: "bool", + }, + ], + indexed: false, + internalType: "struct BosonTypes.Seller", + name: "pendingSeller", + type: "tuple", + }, { components: [ { @@ -1149,14 +1272,107 @@ const _abi = [ type: "tuple", }, { - indexed: true, - internalType: "address", - name: "executedBy", - type: "address", - }, - ], - name: "SellerUpdated", - type: "event", + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "enum BosonTypes.AuthTokenType", + name: "tokenType", + type: "uint8", + }, + ], + indexed: false, + internalType: "struct BosonTypes.AuthToken", + name: "pendingAuthToken", + type: "tuple", + }, + { + indexed: true, + internalType: "address", + name: "executedBy", + type: "address", + }, + ], + name: "SellerUpdateApplied", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "admin", + type: "address", + }, + { + internalType: "address", + name: "clerk", + type: "address", + }, + { + internalType: "address payable", + name: "treasury", + type: "address", + }, + { + internalType: "bool", + name: "active", + type: "bool", + }, + ], + indexed: false, + internalType: "struct BosonTypes.Seller", + name: "pendingSeller", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "enum BosonTypes.AuthTokenType", + name: "tokenType", + type: "uint8", + }, + ], + indexed: false, + internalType: "struct BosonTypes.AuthToken", + name: "pendingAuthToken", + type: "tuple", + }, + { + indexed: true, + internalType: "address", + name: "executedBy", + type: "address", + }, + ], + name: "SellerUpdatePending", + type: "event", }, { anonymous: false, @@ -1461,13 +1677,1454 @@ const _abi = [ type: "uint256", }, ], - name: "createOfferAddToGroup", + name: "createOfferAddToGroup", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "price", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerDeposit", + type: "uint256", + }, + { + internalType: "uint256", + name: "buyerCancelPenalty", + type: "uint256", + }, + { + internalType: "uint256", + name: "quantityAvailable", + type: "uint256", + }, + { + internalType: "address", + name: "exchangeToken", + type: "address", + }, + { + internalType: "string", + name: "metadataUri", + type: "string", + }, + { + internalType: "string", + name: "metadataHash", + type: "string", + }, + { + internalType: "bool", + name: "voided", + type: "bool", + }, + ], + internalType: "struct BosonTypes.Offer", + name: "_offer", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "validFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "validUntil", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableUntil", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDates", + name: "_offerDates", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "disputePeriod", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherValid", + type: "uint256", + }, + { + internalType: "uint256", + name: "resolutionPeriod", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDurations", + name: "_offerDurations", + type: "tuple", + }, + { + internalType: "uint256", + name: "_disputeResolverId", + type: "uint256", + }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount", + type: "uint256", + }, + { + internalType: "uint256", + name: "supplyAvailable", + type: "uint256", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "address", + name: "tokenAddress", + type: "address", + }, + { + internalType: "enum BosonTypes.TokenType", + name: "tokenType", + type: "uint8", + }, + ], + internalType: "struct BosonTypes.Twin", + name: "_twin", + type: "tuple", + }, + { + internalType: "uint256", + name: "_agentId", + type: "uint256", + }, + ], + name: "createOfferAndTwinWithBundle", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "price", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerDeposit", + type: "uint256", + }, + { + internalType: "uint256", + name: "buyerCancelPenalty", + type: "uint256", + }, + { + internalType: "uint256", + name: "quantityAvailable", + type: "uint256", + }, + { + internalType: "address", + name: "exchangeToken", + type: "address", + }, + { + internalType: "string", + name: "metadataUri", + type: "string", + }, + { + internalType: "string", + name: "metadataHash", + type: "string", + }, + { + internalType: "bool", + name: "voided", + type: "bool", + }, + ], + internalType: "struct BosonTypes.Offer", + name: "_offer", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "validFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "validUntil", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableUntil", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDates", + name: "_offerDates", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "disputePeriod", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherValid", + type: "uint256", + }, + { + internalType: "uint256", + name: "resolutionPeriod", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDurations", + name: "_offerDurations", + type: "tuple", + }, + { + internalType: "uint256", + name: "_disputeResolverId", + type: "uint256", + }, + { + components: [ + { + internalType: "enum BosonTypes.EvaluationMethod", + name: "method", + type: "uint8", + }, + { + internalType: "enum BosonTypes.TokenType", + name: "tokenType", + type: "uint8", + }, + { + internalType: "address", + name: "tokenAddress", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "threshold", + type: "uint256", + }, + { + internalType: "uint256", + name: "maxCommits", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.Condition", + name: "_condition", + type: "tuple", + }, + { + internalType: "uint256", + name: "_agentId", + type: "uint256", + }, + ], + name: "createOfferWithCondition", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "price", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerDeposit", + type: "uint256", + }, + { + internalType: "uint256", + name: "buyerCancelPenalty", + type: "uint256", + }, + { + internalType: "uint256", + name: "quantityAvailable", + type: "uint256", + }, + { + internalType: "address", + name: "exchangeToken", + type: "address", + }, + { + internalType: "string", + name: "metadataUri", + type: "string", + }, + { + internalType: "string", + name: "metadataHash", + type: "string", + }, + { + internalType: "bool", + name: "voided", + type: "bool", + }, + ], + internalType: "struct BosonTypes.Offer", + name: "_offer", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "validFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "validUntil", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableUntil", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDates", + name: "_offerDates", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "disputePeriod", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherValid", + type: "uint256", + }, + { + internalType: "uint256", + name: "resolutionPeriod", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDurations", + name: "_offerDurations", + type: "tuple", + }, + { + internalType: "uint256", + name: "_disputeResolverId", + type: "uint256", + }, + { + components: [ + { + internalType: "enum BosonTypes.EvaluationMethod", + name: "method", + type: "uint8", + }, + { + internalType: "enum BosonTypes.TokenType", + name: "tokenType", + type: "uint8", + }, + { + internalType: "address", + name: "tokenAddress", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "threshold", + type: "uint256", + }, + { + internalType: "uint256", + name: "maxCommits", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.Condition", + name: "_condition", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount", + type: "uint256", + }, + { + internalType: "uint256", + name: "supplyAvailable", + type: "uint256", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "address", + name: "tokenAddress", + type: "address", + }, + { + internalType: "enum BosonTypes.TokenType", + name: "tokenType", + type: "uint8", + }, + ], + internalType: "struct BosonTypes.Twin", + name: "_twin", + type: "tuple", + }, + { + internalType: "uint256", + name: "_agentId", + type: "uint256", + }, + ], + name: "createOfferWithConditionAndTwinAndBundle", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "price", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerDeposit", + type: "uint256", + }, + { + internalType: "uint256", + name: "buyerCancelPenalty", + type: "uint256", + }, + { + internalType: "uint256", + name: "quantityAvailable", + type: "uint256", + }, + { + internalType: "address", + name: "exchangeToken", + type: "address", + }, + { + internalType: "string", + name: "metadataUri", + type: "string", + }, + { + internalType: "string", + name: "metadataHash", + type: "string", + }, + { + internalType: "bool", + name: "voided", + type: "bool", + }, + ], + internalType: "struct BosonTypes.Offer", + name: "_offer", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "validFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "validUntil", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableUntil", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDates", + name: "_offerDates", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "disputePeriod", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherValid", + type: "uint256", + }, + { + internalType: "uint256", + name: "resolutionPeriod", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDurations", + name: "_offerDurations", + type: "tuple", + }, + { + internalType: "uint256", + name: "_disputeResolverId", + type: "uint256", + }, + { + internalType: "uint256", + name: "_reservedRangeLength", + type: "uint256", + }, + { + internalType: "uint256", + name: "_groupId", + type: "uint256", + }, + { + internalType: "uint256", + name: "_agentId", + type: "uint256", + }, + ], + name: "createPremintedOfferAddToGroup", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "price", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerDeposit", + type: "uint256", + }, + { + internalType: "uint256", + name: "buyerCancelPenalty", + type: "uint256", + }, + { + internalType: "uint256", + name: "quantityAvailable", + type: "uint256", + }, + { + internalType: "address", + name: "exchangeToken", + type: "address", + }, + { + internalType: "string", + name: "metadataUri", + type: "string", + }, + { + internalType: "string", + name: "metadataHash", + type: "string", + }, + { + internalType: "bool", + name: "voided", + type: "bool", + }, + ], + internalType: "struct BosonTypes.Offer", + name: "_offer", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "validFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "validUntil", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableUntil", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDates", + name: "_offerDates", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "disputePeriod", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherValid", + type: "uint256", + }, + { + internalType: "uint256", + name: "resolutionPeriod", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDurations", + name: "_offerDurations", + type: "tuple", + }, + { + internalType: "uint256", + name: "_disputeResolverId", + type: "uint256", + }, + { + internalType: "uint256", + name: "_reservedRangeLength", + type: "uint256", + }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount", + type: "uint256", + }, + { + internalType: "uint256", + name: "supplyAvailable", + type: "uint256", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "address", + name: "tokenAddress", + type: "address", + }, + { + internalType: "enum BosonTypes.TokenType", + name: "tokenType", + type: "uint8", + }, + ], + internalType: "struct BosonTypes.Twin", + name: "_twin", + type: "tuple", + }, + { + internalType: "uint256", + name: "_agentId", + type: "uint256", + }, + ], + name: "createPremintedOfferAndTwinWithBundle", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "price", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerDeposit", + type: "uint256", + }, + { + internalType: "uint256", + name: "buyerCancelPenalty", + type: "uint256", + }, + { + internalType: "uint256", + name: "quantityAvailable", + type: "uint256", + }, + { + internalType: "address", + name: "exchangeToken", + type: "address", + }, + { + internalType: "string", + name: "metadataUri", + type: "string", + }, + { + internalType: "string", + name: "metadataHash", + type: "string", + }, + { + internalType: "bool", + name: "voided", + type: "bool", + }, + ], + internalType: "struct BosonTypes.Offer", + name: "_offer", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "validFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "validUntil", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableUntil", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDates", + name: "_offerDates", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "disputePeriod", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherValid", + type: "uint256", + }, + { + internalType: "uint256", + name: "resolutionPeriod", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDurations", + name: "_offerDurations", + type: "tuple", + }, + { + internalType: "uint256", + name: "_disputeResolverId", + type: "uint256", + }, + { + internalType: "uint256", + name: "_reservedRangeLength", + type: "uint256", + }, + { + components: [ + { + internalType: "enum BosonTypes.EvaluationMethod", + name: "method", + type: "uint8", + }, + { + internalType: "enum BosonTypes.TokenType", + name: "tokenType", + type: "uint8", + }, + { + internalType: "address", + name: "tokenAddress", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "threshold", + type: "uint256", + }, + { + internalType: "uint256", + name: "maxCommits", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.Condition", + name: "_condition", + type: "tuple", + }, + { + internalType: "uint256", + name: "_agentId", + type: "uint256", + }, + ], + name: "createPremintedOfferWithCondition", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "price", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerDeposit", + type: "uint256", + }, + { + internalType: "uint256", + name: "buyerCancelPenalty", + type: "uint256", + }, + { + internalType: "uint256", + name: "quantityAvailable", + type: "uint256", + }, + { + internalType: "address", + name: "exchangeToken", + type: "address", + }, + { + internalType: "string", + name: "metadataUri", + type: "string", + }, + { + internalType: "string", + name: "metadataHash", + type: "string", + }, + { + internalType: "bool", + name: "voided", + type: "bool", + }, + ], + internalType: "struct BosonTypes.Offer", + name: "_offer", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "validFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "validUntil", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableUntil", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDates", + name: "_offerDates", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "disputePeriod", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherValid", + type: "uint256", + }, + { + internalType: "uint256", + name: "resolutionPeriod", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDurations", + name: "_offerDurations", + type: "tuple", + }, + { + internalType: "uint256", + name: "_disputeResolverId", + type: "uint256", + }, + { + internalType: "uint256", + name: "_reservedRangeLength", + type: "uint256", + }, + { + components: [ + { + internalType: "enum BosonTypes.EvaluationMethod", + name: "method", + type: "uint8", + }, + { + internalType: "enum BosonTypes.TokenType", + name: "tokenType", + type: "uint8", + }, + { + internalType: "address", + name: "tokenAddress", + type: "address", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "uint256", + name: "threshold", + type: "uint256", + }, + { + internalType: "uint256", + name: "maxCommits", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.Condition", + name: "_condition", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "amount", + type: "uint256", + }, + { + internalType: "uint256", + name: "supplyAvailable", + type: "uint256", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "address", + name: "tokenAddress", + type: "address", + }, + { + internalType: "enum BosonTypes.TokenType", + name: "tokenType", + type: "uint8", + }, + ], + internalType: "struct BosonTypes.Twin", + name: "_twin", + type: "tuple", + }, + { + internalType: "uint256", + name: "_agentId", + type: "uint256", + }, + ], + name: "createPremintedOfferWithConditionAndTwinAndBundle", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "admin", + type: "address", + }, + { + internalType: "address", + name: "clerk", + type: "address", + }, + { + internalType: "address payable", + name: "treasury", + type: "address", + }, + { + internalType: "bool", + name: "active", + type: "bool", + }, + ], + internalType: "struct BosonTypes.Seller", + name: "_seller", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "price", + type: "uint256", + }, + { + internalType: "uint256", + name: "sellerDeposit", + type: "uint256", + }, + { + internalType: "uint256", + name: "buyerCancelPenalty", + type: "uint256", + }, + { + internalType: "uint256", + name: "quantityAvailable", + type: "uint256", + }, + { + internalType: "address", + name: "exchangeToken", + type: "address", + }, + { + internalType: "string", + name: "metadataUri", + type: "string", + }, + { + internalType: "string", + name: "metadataHash", + type: "string", + }, + { + internalType: "bool", + name: "voided", + type: "bool", + }, + ], + internalType: "struct BosonTypes.Offer", + name: "_offer", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "validFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "validUntil", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableFrom", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherRedeemableUntil", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDates", + name: "_offerDates", + type: "tuple", + }, + { + components: [ + { + internalType: "uint256", + name: "disputePeriod", + type: "uint256", + }, + { + internalType: "uint256", + name: "voucherValid", + type: "uint256", + }, + { + internalType: "uint256", + name: "resolutionPeriod", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.OfferDurations", + name: "_offerDurations", + type: "tuple", + }, + { + internalType: "uint256", + name: "_disputeResolverId", + type: "uint256", + }, + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "enum BosonTypes.AuthTokenType", + name: "tokenType", + type: "uint8", + }, + ], + internalType: "struct BosonTypes.AuthToken", + name: "_authToken", + type: "tuple", + }, + { + components: [ + { + internalType: "string", + name: "contractURI", + type: "string", + }, + { + internalType: "uint256", + name: "royaltyPercentage", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.VoucherInitValues", + name: "_voucherInitValues", + type: "tuple", + }, + { + internalType: "uint256", + name: "_agentId", + type: "uint256", + }, + ], + name: "createSellerAndOffer", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [ + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "admin", + type: "address", + }, + { + internalType: "address", + name: "clerk", + type: "address", + }, + { + internalType: "address payable", + name: "treasury", + type: "address", + }, + { + internalType: "bool", + name: "active", + type: "bool", + }, + ], + internalType: "struct BosonTypes.Seller", + name: "_seller", + type: "tuple", + }, { components: [ { @@ -1621,19 +3278,90 @@ const _abi = [ name: "_twin", type: "tuple", }, + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "enum BosonTypes.AuthTokenType", + name: "tokenType", + type: "uint8", + }, + ], + internalType: "struct BosonTypes.AuthToken", + name: "_authToken", + type: "tuple", + }, + { + components: [ + { + internalType: "string", + name: "contractURI", + type: "string", + }, + { + internalType: "uint256", + name: "royaltyPercentage", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.VoucherInitValues", + name: "_voucherInitValues", + type: "tuple", + }, { internalType: "uint256", name: "_agentId", type: "uint256", }, ], - name: "createOfferAndTwinWithBundle", + name: "createSellerAndOfferAndTwinWithBundle", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [ + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "admin", + type: "address", + }, + { + internalType: "address", + name: "clerk", + type: "address", + }, + { + internalType: "address payable", + name: "treasury", + type: "address", + }, + { + internalType: "bool", + name: "active", + type: "bool", + }, + ], + internalType: "struct BosonTypes.Seller", + name: "_seller", + type: "tuple", + }, { components: [ { @@ -1782,19 +3510,90 @@ const _abi = [ name: "_condition", type: "tuple", }, + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "enum BosonTypes.AuthTokenType", + name: "tokenType", + type: "uint8", + }, + ], + internalType: "struct BosonTypes.AuthToken", + name: "_authToken", + type: "tuple", + }, + { + components: [ + { + internalType: "string", + name: "contractURI", + type: "string", + }, + { + internalType: "uint256", + name: "royaltyPercentage", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.VoucherInitValues", + name: "_voucherInitValues", + type: "tuple", + }, { internalType: "uint256", name: "_agentId", type: "uint256", }, ], - name: "createOfferWithCondition", + name: "createSellerAndOfferWithCondition", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [ + { + components: [ + { + internalType: "uint256", + name: "id", + type: "uint256", + }, + { + internalType: "address", + name: "operator", + type: "address", + }, + { + internalType: "address", + name: "admin", + type: "address", + }, + { + internalType: "address", + name: "clerk", + type: "address", + }, + { + internalType: "address payable", + name: "treasury", + type: "address", + }, + { + internalType: "bool", + name: "active", + type: "bool", + }, + ], + internalType: "struct BosonTypes.Seller", + name: "_seller", + type: "tuple", + }, { components: [ { @@ -1985,13 +3784,47 @@ const _abi = [ name: "_twin", type: "tuple", }, + { + components: [ + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + internalType: "enum BosonTypes.AuthTokenType", + name: "tokenType", + type: "uint8", + }, + ], + internalType: "struct BosonTypes.AuthToken", + name: "_authToken", + type: "tuple", + }, + { + components: [ + { + internalType: "string", + name: "contractURI", + type: "string", + }, + { + internalType: "uint256", + name: "royaltyPercentage", + type: "uint256", + }, + ], + internalType: "struct BosonTypes.VoucherInitValues", + name: "_voucherInitValues", + type: "tuple", + }, { internalType: "uint256", name: "_agentId", type: "uint256", }, ], - name: "createOfferWithConditionAndTwinAndBundle", + name: "createSellerAndOfferWithConditionAndTwinAndBundle", outputs: [], stateMutability: "nonpayable", type: "function", @@ -2146,6 +3979,11 @@ const _abi = [ name: "_disputeResolverId", type: "uint256", }, + { + internalType: "uint256", + name: "_reservedRangeLength", + type: "uint256", + }, { components: [ { @@ -2186,7 +4024,7 @@ const _abi = [ type: "uint256", }, ], - name: "createSellerAndOffer", + name: "createSellerAndPremintedOffer", outputs: [], stateMutability: "nonpayable", type: "function", @@ -2341,6 +4179,11 @@ const _abi = [ name: "_disputeResolverId", type: "uint256", }, + { + internalType: "uint256", + name: "_reservedRangeLength", + type: "uint256", + }, { components: [ { @@ -2423,7 +4266,7 @@ const _abi = [ type: "uint256", }, ], - name: "createSellerAndOfferAndTwinWithBundle", + name: "createSellerAndPremintedOfferAndTwinWithBundle", outputs: [], stateMutability: "nonpayable", type: "function", @@ -2578,6 +4421,11 @@ const _abi = [ name: "_disputeResolverId", type: "uint256", }, + { + internalType: "uint256", + name: "_reservedRangeLength", + type: "uint256", + }, { components: [ { @@ -2655,7 +4503,7 @@ const _abi = [ type: "uint256", }, ], - name: "createSellerAndOfferWithCondition", + name: "createSellerAndPremintedOfferWithCondition", outputs: [], stateMutability: "nonpayable", type: "function", @@ -2810,6 +4658,11 @@ const _abi = [ name: "_disputeResolverId", type: "uint256", }, + { + internalType: "uint256", + name: "_reservedRangeLength", + type: "uint256", + }, { components: [ { @@ -2929,11 +4782,24 @@ const _abi = [ type: "uint256", }, ], - name: "createSellerAndOfferWithConditionAndTwinAndBundle", + name: "createSellerAndPremintedOfferWithConditionAndTwinAndBundle", outputs: [], stateMutability: "nonpayable", type: "function", }, + { + inputs: [ + { + internalType: "uint256", + name: "_exchangeId", + type: "uint256", + }, + ], + name: "raiseAndEscalateDispute", + outputs: [], + stateMutability: "payable", + type: "function", + }, ]; export class IBosonOrchestrationHandler__factory { diff --git a/packages/ethers-sdk/src/contracts/factories/IBosonVoucher__factory.ts b/packages/ethers-sdk/src/contracts/factories/IBosonVoucher__factory.ts index 2a310a58b..9dfb8d03e 100644 --- a/packages/ethers-sdk/src/contracts/factories/IBosonVoucher__factory.ts +++ b/packages/ethers-sdk/src/contracts/factories/IBosonVoucher__factory.ts @@ -70,6 +70,52 @@ const _abi = [ name: "ContractURIChanged", type: "event", }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "uint256", + name: "offerId", + type: "uint256", + }, + { + components: [ + { + internalType: "uint256", + name: "offerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "start", + type: "uint256", + }, + { + internalType: "uint256", + name: "length", + type: "uint256", + }, + { + internalType: "uint256", + name: "minted", + type: "uint256", + }, + { + internalType: "uint256", + name: "lastBurnedTokenId", + type: "uint256", + }, + ], + indexed: false, + internalType: "struct IBosonVoucher.Range", + name: "range", + type: "tuple", + }, + ], + name: "RangeReserved", + type: "event", + }, { anonymous: false, inputs: [ @@ -170,6 +216,19 @@ const _abi = [ stateMutability: "view", type: "function", }, + { + inputs: [ + { + internalType: "uint256", + name: "_offerId", + type: "uint256", + }, + ], + name: "burnPremintedVouchers", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, { inputs: [ { @@ -215,6 +274,71 @@ const _abi = [ stateMutability: "view", type: "function", }, + { + inputs: [ + { + internalType: "uint256", + name: "_offerId", + type: "uint256", + }, + ], + name: "getAvailablePreMints", + outputs: [ + { + internalType: "uint256", + name: "count", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "_offerId", + type: "uint256", + }, + ], + name: "getRangeByOfferId", + outputs: [ + { + components: [ + { + internalType: "uint256", + name: "offerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "start", + type: "uint256", + }, + { + internalType: "uint256", + name: "length", + type: "uint256", + }, + { + internalType: "uint256", + name: "minted", + type: "uint256", + }, + { + internalType: "uint256", + name: "lastBurnedTokenId", + type: "uint256", + }, + ], + internalType: "struct IBosonVoucher.Range", + name: "range", + type: "tuple", + }, + ], + stateMutability: "view", + type: "function", + }, { inputs: [], name: "getRoyaltyPercentage", @@ -315,6 +439,47 @@ const _abi = [ stateMutability: "view", type: "function", }, + { + inputs: [ + { + internalType: "uint256", + name: "_offerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "_amount", + type: "uint256", + }, + ], + name: "preMint", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "_offerId", + type: "uint256", + }, + { + internalType: "uint256", + name: "_start", + type: "uint256", + }, + { + internalType: "uint256", + name: "_length", + type: "uint256", + }, + ], + name: "reserveRange", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, { inputs: [ { diff --git a/packages/ethers-sdk/src/contracts/factories/MockNativeMetaTransaction__factory.ts b/packages/ethers-sdk/src/contracts/factories/MockNativeMetaTransaction__factory.ts new file mode 100644 index 000000000..4dea34e0d --- /dev/null +++ b/packages/ethers-sdk/src/contracts/factories/MockNativeMetaTransaction__factory.ts @@ -0,0 +1,139 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ + +import { Contract, Signer, utils } from "ethers"; +import { Provider } from "@ethersproject/providers"; +import type { + MockNativeMetaTransaction, + MockNativeMetaTransactionInterface, +} from "../MockNativeMetaTransaction"; + +const _abi = [ + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "userAddress", + type: "address", + }, + { + indexed: false, + internalType: "address payable", + name: "relayerAddress", + type: "address", + }, + { + indexed: false, + internalType: "bytes", + name: "functionSignature", + type: "bytes", + }, + ], + name: "MetaTransactionExecuted", + type: "event", + }, + { + inputs: [ + { + internalType: "address", + name: "userAddress", + type: "address", + }, + { + internalType: "bytes", + name: "functionSignature", + type: "bytes", + }, + { + internalType: "bytes32", + name: "sigR", + type: "bytes32", + }, + { + internalType: "bytes32", + name: "sigS", + type: "bytes32", + }, + { + internalType: "uint8", + name: "sigV", + type: "uint8", + }, + ], + name: "executeMetaTransaction", + outputs: [ + { + internalType: "bytes", + name: "", + type: "bytes", + }, + ], + stateMutability: "payable", + type: "function", + }, + { + inputs: [], + name: "getChainId", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "getDomainSeperator", + outputs: [ + { + internalType: "bytes32", + name: "", + type: "bytes32", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "user", + type: "address", + }, + ], + name: "getNonce", + outputs: [ + { + internalType: "uint256", + name: "nonce", + type: "uint256", + }, + ], + stateMutability: "view", + type: "function", + }, +]; + +export class MockNativeMetaTransaction__factory { + static readonly abi = _abi; + static createInterface(): MockNativeMetaTransactionInterface { + return new utils.Interface(_abi) as MockNativeMetaTransactionInterface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): MockNativeMetaTransaction { + return new Contract( + address, + _abi, + signerOrProvider + ) as MockNativeMetaTransaction; + } +} diff --git a/packages/ethers-sdk/src/contracts/index.ts b/packages/ethers-sdk/src/contracts/index.ts index 23042fbf2..50882a77d 100644 --- a/packages/ethers-sdk/src/contracts/index.ts +++ b/packages/ethers-sdk/src/contracts/index.ts @@ -1,26 +1,32 @@ /* Autogenerated file. Do not edit manually. */ /* tslint:disable */ /* eslint-disable */ +export type { ERC1155 } from "./ERC1155"; export type { ERC20 } from "./ERC20"; export type { ERC721Enumerable } from "./ERC721Enumerable"; export type { IBosonAccountHandler } from "./IBosonAccountHandler"; export type { IBosonDisputeHandler } from "./IBosonDisputeHandler"; export type { IBosonExchangeHandler } from "./IBosonExchangeHandler"; export type { IBosonFundsHandler } from "./IBosonFundsHandler"; +export type { IBosonGroupHandler } from "./IBosonGroupHandler"; export type { IBosonMetaTransactionsHandler } from "./IBosonMetaTransactionsHandler"; export type { IBosonOfferHandler } from "./IBosonOfferHandler"; export type { IBosonOrchestrationHandler } from "./IBosonOrchestrationHandler"; export type { IBosonVoucher } from "./IBosonVoucher"; +export type { MockNativeMetaTransaction } from "./MockNativeMetaTransaction"; export type { ProtocolDiamond } from "./ProtocolDiamond"; +export { ERC1155__factory } from "./factories/ERC1155__factory"; export { ERC20__factory } from "./factories/ERC20__factory"; export { ERC721Enumerable__factory } from "./factories/ERC721Enumerable__factory"; export { IBosonAccountHandler__factory } from "./factories/IBosonAccountHandler__factory"; export { IBosonDisputeHandler__factory } from "./factories/IBosonDisputeHandler__factory"; export { IBosonExchangeHandler__factory } from "./factories/IBosonExchangeHandler__factory"; export { IBosonFundsHandler__factory } from "./factories/IBosonFundsHandler__factory"; +export { IBosonGroupHandler__factory } from "./factories/IBosonGroupHandler__factory"; export { IBosonMetaTransactionsHandler__factory } from "./factories/IBosonMetaTransactionsHandler__factory"; export { IBosonOfferHandler__factory } from "./factories/IBosonOfferHandler__factory"; export { IBosonOrchestrationHandler__factory } from "./factories/IBosonOrchestrationHandler__factory"; export { IBosonVoucher__factory } from "./factories/IBosonVoucher__factory"; +export { MockNativeMetaTransaction__factory } from "./factories/MockNativeMetaTransaction__factory"; export { ProtocolDiamond__factory } from "./factories/ProtocolDiamond__factory"; From 6e817acc6a38b06342da788f55afbc59494feeb0 Mon Sep 17 00:00:00 2001 From: Albert Folch Date: Fri, 30 Dec 2022 17:53:45 +0100 Subject: [PATCH 4/9] update script --- contracts/scripts/deploy.js | 316 +----------------------------------- e2e/tests/utils.ts | 6 +- 2 files changed, 10 insertions(+), 312 deletions(-) diff --git a/contracts/scripts/deploy.js b/contracts/scripts/deploy.js index f6886cd33..9ab400ca2 100644 --- a/contracts/scripts/deploy.js +++ b/contracts/scripts/deploy.js @@ -3,321 +3,17 @@ process.env.CONFIRMATIONS = 1; // required for deployProtocolConfigFacet() process.env.DEPLOYER_GAS_LIMIT_TEST = gasLimit; process.env.AUTH_TOKEN_OWNERS_LOCAL = ""; process.env.TIP_MULTIPLIER = "10"; +require("dotenv").config({ + path: "./protocol-contracts/.env" +}); /* eslint @typescript-eslint/no-var-requires: "off" */ -const hre = require("hardhat"); -const ethers = hre.ethers; -const protocolConfig = require("../protocol-contracts/scripts/config/protocol-parameters"); -const authTokenAddresses = require("../protocol-contracts/scripts/config/auth-token-addresses"); - -const Role = require("../protocol-contracts/scripts/domain/Role"); -const { - deployProtocolDiamond -} = require("../protocol-contracts/scripts/util/deploy-protocol-diamond.js"); -const { - deployProtocolClients -} = require("../protocol-contracts/scripts/util/deploy-protocol-clients.js"); -const { - deployProtocolHandlerFacets -} = require("../protocol-contracts/scripts/util/deploy-protocol-handler-facets.js"); -const { - deploymentComplete -} = require("../protocol-contracts/scripts/util/utils"); const { - deployMockTokens, - deployAndMintMockNFTAuthTokens -} = require("../protocol-contracts/scripts/util/deploy-mock-tokens"); -const { oneMonth } = require("../protocol-contracts/test/util/constants"); -const AuthTokenType = require("../protocol-contracts/scripts/domain/AuthTokenType"); - -function getConfig(network) { - return [ - { - token: protocolConfig.TOKEN[network], - treasury: protocolConfig.TREASURY[network], - voucherBeacon: protocolConfig.BEACON[network], - beaconProxy: protocolConfig.BEACON_PROXY[network] - }, - { - ...protocolConfig.limits, - minDisputePeriod: "1" - }, - protocolConfig.fees - ]; -} - -/** - * Get the contract addresses for supported NFT Auth token contracts - * @returns {lensAddress: string, ensAddress: string} - */ -function getAuthTokenContracts(network) { - if (network === "localhost") { - return { - lensAddress: "0x2bdCC0de6bE1f7D2ee689a0342D76F52E8EFABa3", - ensAddress: "0x7969c5eD335650692Bc04293B07F5BF2e7A673C0" - }; - } - return { - lensAddress: authTokenAddresses.LENS[network], - ensAddress: authTokenAddresses.ENS[network] - }; -} - -/** - * Get a list of no-arg initializer facet names to be cut into the Diamond - */ -function getNoArgFacetNames() { - return [ - "AccountHandlerFacet", - "SellerHandlerFacet", - "BuyerHandlerFacet", - "DisputeResolverHandlerFacet", - "AgentHandlerFacet", - "BundleHandlerFacet", - "DisputeHandlerFacet", - "ExchangeHandlerFacet", - "FundsHandlerFacet", - "GroupHandlerFacet", - "MetaTransactionsHandlerFacet", - "OfferHandlerFacet", - "OrchestrationHandlerFacet", - "TwinHandlerFacet", - "PauseHandlerFacet" - ]; -} + deploySuite +} = require("../protocol-contracts/scripts/deploy-suite.js"); async function main() { - console.log("compile"); - // Compile everything (in case run by node) - await hre.run("compile"); - - // Deployed contracts - let contracts = []; - - // Output script header - const divider = "-".repeat(80); - console.log( - `${divider}\nBoson Protocol V2 Contract Suite Deployer\n${divider}` - ); - console.log(`โ›“ Network: ${hre.network.name}\n๐Ÿ“… ${new Date()}`); - - // Get the protocol config - const config = getConfig(hre.network.name); - const authTokenContracts = getAuthTokenContracts(hre.network.name); - - // Get the accounts - const accounts = await ethers.getSigners(); - const deployerSigner = accounts[0]; - const deployer = deployerSigner.address; - const disputeResolverSigner = accounts[1]; - const disputeResolver = disputeResolverSigner.address; - console.log( - "๐Ÿ”ฑ Deployer account: ", - deployer ? deployer : "not found" && process.exit() - ); - console.log(divider); - - if (hre.network.name === "localhost" || !config[0].token) { - console.log(`\n๐Ÿ’Ž Deploying mock tokens...`); - const [mockBosonToken] = await deployMockTokens(gasLimit); - deploymentComplete("BosonToken", mockBosonToken.address, [], "", contracts); - config[0].token = mockBosonToken.address; - } - - console.log( - `\n๐Ÿ’Ž Deploying AccessController, ProtocolDiamond, and Diamond utility facets...` - ); - - // Deploy the Diamond - const [protocolDiamond, dlf, dcf, erc165f, accessController, diamondArgs] = - await deployProtocolDiamond(gasLimit); - deploymentComplete( - "AccessController", - accessController.address, - [], - "", - contracts - ); - deploymentComplete("DiamondLoupeFacet", dlf.address, [], "", contracts); - deploymentComplete("DiamondCutFacet", dcf.address, [], "", contracts); - deploymentComplete("ERC165Facet", erc165f.address, [], "", contracts); - deploymentComplete( - "ProtocolDiamond", - protocolDiamond.address, - diamondArgs, - "", - contracts - ); - - console.log(`\n๐Ÿ’Ž Deploying and initializing protocol facets...`); - - // Temporarily grant UPGRADER role to deployer account - await accessController.grantRole(Role.UPGRADER, deployer); - - // Deploy and cut facets - const deployedFacets = await deployProtocolHandlerFacets( - protocolDiamond, - getNoArgFacetNames(), - gasLimit - ); - for (let i = 0; i < deployedFacets.length; i++) { - const deployedFacet = deployedFacets[i]; - deploymentComplete( - deployedFacet.name, - deployedFacet.contract.address, - [], - "", - contracts - ); - } - - console.log(`\nโง‰ Deploying Protocol Client implementation/proxy pairs...`); - - // Deploy the Protocol Client implementation/proxy pairs - const protocolClientArgs = [protocolDiamond.address]; - const [impls, beacons, proxies] = await deployProtocolClients( - protocolClientArgs, - gasLimit - ); - const [bosonVoucherImpl] = impls; - const [bosonClientBeacon] = beacons; - const [bosonVoucherProxy] = proxies; - - // Gather the complete args that were used to create the proxies - const bosonVoucherProxyArgs = [ - ...protocolClientArgs, - bosonVoucherImpl.address - ]; - - // Report and prepare for verification - deploymentComplete( - "BosonVoucher Logic", - bosonVoucherImpl.address, - [], - "", - contracts - ); - deploymentComplete( - "BosonVoucher Beacon", - bosonClientBeacon.address, - [], - "", - contracts - ); - deploymentComplete( - "BosonVoucher Proxy", - bosonVoucherProxy.address, - bosonVoucherProxyArgs, - "", - contracts - ); - - console.log(`\n๐ŸŒ๏ธConfiguring and granting roles...`); - - // Cast Diamond to the IBosonConfigHandler interface for further interaction with it - const bosonConfigHandler = await ethers.getContractAt( - "IBosonConfigHandler", - protocolDiamond.address - ); - - // Add Voucher NFT addresses to protocol config - await bosonConfigHandler.setVoucherBeaconAddress(bosonClientBeacon.address); - await bosonConfigHandler.setBeaconProxyAddress(bosonVoucherProxy.address); - - //Add NFT auth token addresses to protocol config - await bosonConfigHandler.setAuthTokenContract( - AuthTokenType.Lens, - authTokenContracts.lensAddress - ); - await bosonConfigHandler.setAuthTokenContract( - AuthTokenType.ENS, - authTokenContracts.ensAddress - ); - - console.log( - `โœ… ConfigHandlerFacet updated with remaining post-initialization config.` - ); - - // Add roles to contracts and addresses that need it - // Renounce temporarily granted UPGRADER role for deployer account - await accessController.renounceRole(Role.UPGRADER, deployer); - await accessController.grantRole(Role.PROTOCOL, protocolDiamond.address); - - console.log(`โœ… Granted roles to appropriate contract and addresses.`); - - // Some custom stuff for e2e setup - if (["localhost", "hardhat"].includes(hre.network.name)) { - console.log(`\n๐ŸŒ๏ธCustom stuff for e2e setup...`); - - // Deploy ERC20-compliant mock token for testing - const [foreign20Token, foreign721Token, foreign1155Token] = - await deployMockTokens(gasLimit, [ - "Foreign20", - "Foreign721", - "Foreign1155" - ]); - deploymentComplete("Foreign20", foreign20Token.address, [], "", contracts); - deploymentComplete( - "Foreign721", - foreign721Token.address, - [], - "", - contracts - ); - deploymentComplete( - "Foreign1155", - foreign1155Token.address, - [], - "", - contracts - ); - - await deployAndMintMockNFTAuthTokens(); - - // Create and activate default dispute resolver - const accountHandler = await ethers.getContractAt( - "IBosonAccountHandler", - protocolDiamond.address - ); - const response = await accountHandler - .connect(disputeResolverSigner) - .createDisputeResolver( - { - id: "1", - escalationResponsePeriod: oneMonth.toString(), - operator: disputeResolver, - admin: disputeResolver, - clerk: disputeResolver, - treasury: disputeResolver, - // TODO: use valid uri - metadataUri: `ipfs://disputeResolver1`, - active: true - }, - [ - { - tokenAddress: ethers.constants.AddressZero, - tokenName: "Native", - feeAmount: "0" - }, - { - tokenAddress: foreign20Token.address, - tokenName: "Foreign20", - feeAmount: "0" - } - ], - [] - ); - const receipt = await response.wait(); - const event = receipt.events.find( - (event) => event.event === "DisputeResolverCreated" - ); - const disputeResolverId = event.args.disputeResolverId; - console.log( - `โœ… Dispute resolver created. ID: ${disputeResolverId} Wallet: ${disputeResolver}` - ); - await accountHandler.activateDisputeResolver(disputeResolverId); - console.log(`โœ… Dispute resolver activated`); - } + await deploySuite("localhost", undefined); } main() diff --git a/e2e/tests/utils.ts b/e2e/tests/utils.ts index a5fa77a75..80071df33 100644 --- a/e2e/tests/utils.ts +++ b/e2e/tests/utils.ts @@ -403,9 +403,11 @@ export async function createSellerAndOfferWithCondition( const createdOfferId = coreSDK.getCreatedOfferIdFromLogs( createOfferTxReceipt.logs ); - + if (createdOfferId === null) { + throw new Error("Failed to create offer with condition"); + } await waitForGraphNodeIndexing(); - const offer = await coreSDK.getOfferById(createdOfferId as string); + const offer = await coreSDK.getOfferById(createdOfferId); return offer; } From e82705fbf7e713d6e126d616802bd20c527d4e42 Mon Sep 17 00:00:00 2001 From: Albert Folch Date: Tue, 3 Jan 2023 12:40:31 +0100 Subject: [PATCH 5/9] fix: some tests --- .gitignore | 1 + contracts/scripts/deploy.js | 7 +- e2e/run-e2e-services.sh | 2 +- e2e/tests/accounts.test.ts | 136 +++++++------------- e2e/tests/core-sdk.test.ts | 52 +++++++- e2e/tests/utils.ts | 16 +-- packages/common/src/configs.ts | 4 +- packages/core-sdk/src/accounts/handler.ts | 12 -- packages/core-sdk/src/accounts/interface.ts | 7 - packages/core-sdk/src/accounts/mixin.ts | 16 --- packages/core-sdk/src/erc721/handler.ts | 4 +- scripts/create-dispute-resolver.ts | 10 +- 12 files changed, 117 insertions(+), 150 deletions(-) diff --git a/.gitignore b/.gitignore index 5d1a8414e..aa014740d 100644 --- a/.gitignore +++ b/.gitignore @@ -12,6 +12,7 @@ build/** dist/** .next/** generated +*.log # yarn .pnp.* diff --git a/contracts/scripts/deploy.js b/contracts/scripts/deploy.js index 9ab400ca2..3ca320712 100644 --- a/contracts/scripts/deploy.js +++ b/contracts/scripts/deploy.js @@ -12,8 +12,13 @@ const { deploySuite } = require("../protocol-contracts/scripts/deploy-suite.js"); +const { + deployAndMintMockNFTAuthTokens +} = require("../protocol-contracts/scripts/util/deploy-mock-tokens.js"); + async function main() { - await deploySuite("localhost", undefined); + await deploySuite("localhost", undefined); // TODO: verify + await deployAndMintMockNFTAuthTokens(); } main() diff --git a/e2e/run-e2e-services.sh b/e2e/run-e2e-services.sh index ffe9dc7bc..e3aa82ddd 100755 --- a/e2e/run-e2e-services.sh +++ b/e2e/run-e2e-services.sh @@ -10,7 +10,7 @@ function cleanup() { cd e2e -docker-compose up -d +docker-compose up -d #--force-recreate echo "Waiting for services..." sleep 15 diff --git a/e2e/tests/accounts.test.ts b/e2e/tests/accounts.test.ts index 54b4d284f..1a0069459 100644 --- a/e2e/tests/accounts.test.ts +++ b/e2e/tests/accounts.test.ts @@ -1,5 +1,5 @@ import { ZERO_ADDRESS } from "./../../packages/core-sdk/tests/mocks"; -import { Wallet, BigNumber } from "ethers"; +import { BigNumber } from "ethers"; import { MSEC_PER_DAY, MSEC_PER_SEC @@ -33,7 +33,7 @@ describe("CoreSDK - accounts", () => { const ethDisputeResolutionFee = { tokenAddress: constants.AddressZero, tokenName: "Native", - feeAmount: utils.parseEther("1") + feeAmount: utils.parseEther("0") }; test("create", async () => { @@ -55,7 +55,7 @@ describe("CoreSDK - accounts", () => { } ); - expect(disputeResolver.active).toBeFalsy(); + expect(disputeResolver.active).toBeTruthy(); expect(disputeResolver.admin).toBe(disputeResolverAddress); expect(disputeResolver.clerk).toBe(disputeResolverAddress); expect(disputeResolver.operator).toBe(disputeResolverAddress); @@ -68,14 +68,14 @@ describe("CoreSDK - accounts", () => { ); }); - test("activate", async () => { - const fundedWallet = await createFundedWallet(protocolAdminWallet); + test("update", async () => { + const { coreSDK, fundedWallet } = await initCoreSDKWithFundedWallet( + protocolAdminWallet + ); const disputeResolverAddress = fundedWallet.address.toLowerCase(); - const { disputeResolver } = await createDisputeResolver( - fundedWallet, - protocolAdminWallet, - { + const { disputeResolver: disputeResolverBeforeUpdate } = + await createDisputeResolver(fundedWallet, protocolAdminWallet, { operator: disputeResolverAddress, clerk: disputeResolverAddress, admin: disputeResolverAddress, @@ -84,39 +84,7 @@ describe("CoreSDK - accounts", () => { escalationResponsePeriodInMS, fees: [], sellerAllowList: [] - }, - { - activate: true - } - ); - - expect(disputeResolver.active).toBeTruthy(); - }); - - test("update", async () => { - const { coreSDK, fundedWallet } = await initCoreSDKWithFundedWallet( - protocolAdminWallet - ); - const disputeResolverAddress = fundedWallet.address.toLowerCase(); - - const { disputeResolver: disputeResolverBeforeUpdate } = - await createDisputeResolver( - fundedWallet, - protocolAdminWallet, - { - operator: disputeResolverAddress, - clerk: disputeResolverAddress, - admin: disputeResolverAddress, - treasury: disputeResolverAddress, - metadataUri, - escalationResponsePeriodInMS, - fees: [], - sellerAllowList: [] - }, - { - activate: true - } - ); + }); const { coreSDK: coreSDK2, fundedWallet: randomWallet } = await initCoreSDKWithFundedWallet(seedWallet3); @@ -186,18 +154,17 @@ describe("CoreSDK - accounts", () => { treasury: disputeResolverAddress, metadataUri, escalationResponsePeriodInMS, - fees: [], + fees: [ethDisputeResolutionFee], sellerAllowList: [] - }, - { - activate: true } ); - + const secondFee = { + tokenAddress: "0x0000000000000000000000000000000000000001", + tokenName: "Not-Native", + feeAmount: utils.parseEther("0") + }; await ( - await coreSDK.addFeesToDisputeResolver(disputeResolver.id, [ - ethDisputeResolutionFee - ]) + await coreSDK.addFeesToDisputeResolver(disputeResolver.id, [secondFee]) ).wait(); await waitForGraphNodeIndexing(); @@ -216,6 +183,18 @@ describe("CoreSDK - accounts", () => { ); expect(disputeResolverAfterUpdate.fees[0].token.decimals).toBe("18"); expect(disputeResolverAfterUpdate.fees[0].token.symbol).toBe("ETH"); + + expect(disputeResolverAfterUpdate.fees[1].tokenAddress).toBe( + secondFee.tokenAddress + ); + expect(disputeResolverAfterUpdate.fees[1].tokenName).toBe( + secondFee.tokenName + ); + expect(disputeResolverAfterUpdate.fees[1].feeAmount).toBe( + secondFee.feeAmount.toString() + ); + expect(disputeResolverAfterUpdate.fees[1].token.decimals).toBe("0"); + expect(disputeResolverAfterUpdate.fees[1].token.symbol).toBe("unknown"); }); test("remove fees", async () => { @@ -225,23 +204,16 @@ describe("CoreSDK - accounts", () => { const disputeResolverAddress = fundedWallet.address.toLowerCase(); const { disputeResolver: disputeResolverBeforeUpdate } = - await createDisputeResolver( - fundedWallet, - protocolAdminWallet, - { - operator: disputeResolverAddress, - clerk: disputeResolverAddress, - admin: disputeResolverAddress, - treasury: disputeResolverAddress, - metadataUri, - escalationResponsePeriodInMS, - fees: [ethDisputeResolutionFee], - sellerAllowList: [] - }, - { - activate: true - } - ); + await createDisputeResolver(fundedWallet, protocolAdminWallet, { + operator: disputeResolverAddress, + clerk: disputeResolverAddress, + admin: disputeResolverAddress, + treasury: disputeResolverAddress, + metadataUri, + escalationResponsePeriodInMS, + fees: [ethDisputeResolutionFee], + sellerAllowList: [] + }); await ( await coreSDK.removeFeesFromDisputeResolver( @@ -279,9 +251,6 @@ describe("CoreSDK - accounts", () => { escalationResponsePeriodInMS, fees: [], sellerAllowList: [] - }, - { - activate: true } ); @@ -308,23 +277,16 @@ describe("CoreSDK - accounts", () => { const disputeResolverAddress = fundedWallet.address.toLowerCase(); const { disputeResolver: disputeResolverBeforeUpdate } = - await createDisputeResolver( - fundedWallet, - protocolAdminWallet, - { - operator: disputeResolverAddress, - clerk: disputeResolverAddress, - admin: disputeResolverAddress, - treasury: disputeResolverAddress, - metadataUri, - escalationResponsePeriodInMS, - fees: [], - sellerAllowList: [seller.id] - }, - { - activate: true - } - ); + await createDisputeResolver(fundedWallet, protocolAdminWallet, { + operator: disputeResolverAddress, + clerk: disputeResolverAddress, + admin: disputeResolverAddress, + treasury: disputeResolverAddress, + metadataUri, + escalationResponsePeriodInMS, + fees: [], + sellerAllowList: [seller.id] + }); await ( await coreSDK.removeSellersFromDisputeResolverAllowList( diff --git a/e2e/tests/core-sdk.test.ts b/e2e/tests/core-sdk.test.ts index 1b10a15cb..6359281c5 100644 --- a/e2e/tests/core-sdk.test.ts +++ b/e2e/tests/core-sdk.test.ts @@ -5,7 +5,10 @@ import { ExchangeFieldsFragment } from "./../../packages/core-sdk/src/subgraph"; import { utils, constants, BigNumber, BigNumberish } from "ethers"; - +import { + MSEC_PER_DAY, + MSEC_PER_SEC +} from "./../../packages/common/src/utils/timestamp"; import { mockCreateOfferArgs } from "../../packages/common/tests/mocks"; import { CoreSDK } from "../../packages/core-sdk/src"; import { @@ -34,10 +37,13 @@ import { createOfferWithCondition, createSellerAndOfferWithCondition, createSeller, - createSellerAndOffer + createSellerAndOffer, + createDisputeResolver, + deployerWallet } from "./utils"; import { EvaluationMethod, TokenType } from "@bosonprotocol/common"; +const protocolAdminWallet = deployerWallet; const seedWallet = seedWallet4; // be sure the seedWallet is not used by another test (to allow concurrent run) const sellerWallet2 = seedWallet5; // be sure the seedWallet is not used by another test (to allow concurrent run) const buyerWallet2 = seedWallet6; // be sure the seedWallet is not used by another test (to allow concurrent run) @@ -45,6 +51,48 @@ const buyerWallet2 = seedWallet6; // be sure the seedWallet is not used by anoth jest.setTimeout(60_000); describe("core-sdk", () => { + beforeAll(async () => { + const { coreSDK, fundedWallet } = await initCoreSDKWithFundedWallet( + protocolAdminWallet + ); + const ethDisputeResolutionFee = { + tokenAddress: constants.AddressZero, + tokenName: "Native", + feeAmount: utils.parseEther("0") + }; + const erc20DisputeResolutionFee = { + tokenAddress: MOCK_ERC20_ADDRESS, + tokenName: "erc20", + feeAmount: utils.parseEther("0") + }; + const disputeResolverId = 1; + const dr = await coreSDK.getDisputeResolverById(1); + if (dr && !dr.fees.length) { + await ( + await coreSDK.addFeesToDisputeResolver(disputeResolverId, [ + ethDisputeResolutionFee, + erc20DisputeResolutionFee + ]) + ).wait(); + await waitForGraphNodeIndexing(); + } else if (!dr) { + const metadataUri = "ipfs://dispute-resolver-uri"; + const escalationResponsePeriodInMS = 90 * MSEC_PER_DAY - 1 * MSEC_PER_SEC; + const disputeResolverAddress = fundedWallet.address; + + await createDisputeResolver(fundedWallet, protocolAdminWallet, { + operator: disputeResolverAddress, + clerk: disputeResolverAddress, + admin: disputeResolverAddress, + treasury: disputeResolverAddress, + metadataUri, + escalationResponsePeriodInMS, + fees: [ethDisputeResolutionFee, erc20DisputeResolutionFee], + sellerAllowList: [] + }); + } + }); + describe("core user flows", () => { test("create seller and offer", async () => { const { coreSDK, fundedWallet } = await initCoreSDKWithFundedWallet( diff --git a/e2e/tests/utils.ts b/e2e/tests/utils.ts index 80071df33..b51e75693 100644 --- a/e2e/tests/utils.ts +++ b/e2e/tests/utils.ts @@ -261,18 +261,14 @@ export async function ensureMintedERC1155( export async function createDisputeResolver( drWallet: Wallet, protocolWallet: Wallet, - disputeResolverToCreate: accounts.CreateDisputeResolverArgs, - options: Partial<{ - activate: boolean; - }> = {} + disputeResolverToCreate: accounts.CreateDisputeResolverArgs ) { const drCoreSDK = initCoreSDKWithWallet(drWallet); const protocolAdminCoreSDK = initCoreSDKWithWallet(protocolWallet); - const receipt = await ( await drCoreSDK.createDisputeResolver(disputeResolverToCreate) ).wait(); - console.log("receipt", receipt); + const disputeResolverId = drCoreSDK.getDisputeResolverIdFromLogs( receipt.logs ); @@ -281,12 +277,6 @@ export async function createDisputeResolver( throw new Error("Failed to create dispute resolver"); } - if (options.activate && disputeResolverId) { - await ( - await protocolAdminCoreSDK.activateDisputeResolver(disputeResolverId) - ).wait(); - } - await waitForGraphNodeIndexing(); const disputeResolver = await drCoreSDK.getDisputeResolverById( @@ -545,7 +535,7 @@ export async function mintLensToken( // Mint the token in the mocked LENS contract for the future seller const tx = await lensContract.connect(wallet).mint(to, tokenId); - tx.wait(); + await tx.wait(); return tokenId; } diff --git a/packages/common/src/configs.ts b/packages/common/src/configs.ts index 62fdbe374..8f57d1858 100644 --- a/packages/common/src/configs.ts +++ b/packages/common/src/configs.ts @@ -158,7 +158,7 @@ export const defaultConfigs: ProtocolConfig[] = [ theGraphIpfsUrl: "http://127.0.0.1:5001", ipfsMetadataUrl: "http://127.0.0.1:5001", contracts: { - protocolDiamond: "0x2279B7A0a67DB372996a5FaB50D91eAA73d2eBe6", + protocolDiamond: "0xDc64a140Aa3E981100a9becA4E685f962f0cF6C9", testErc20: "0xb7278A61aa25c888815aFC32Ad3cC52fF24fE575", // Foreign20 contract testErc721: "0xCD8a1C3ba11CF5ECfa6267617243239504a98d90", // Foreign721 contract testErc1155: "0x82e01223d51Eb87e16A03E24687EDF0F294da6f1" // Foreign1155 contract @@ -167,7 +167,7 @@ export const defaultConfigs: ProtocolConfig[] = [ relayerUrl: "http://localhost:8888" }, lens: { - LENS_HUB_CONTRACT: "0x2bdCC0de6bE1f7D2ee689a0342D76F52E8EFABa3", + LENS_HUB_CONTRACT: "0x851356ae760d987E095750cCeb3bC6014560891C", // see contracts/protocol-contracts/scripts/config -> LENS -> localhost LENS_PERIPHERY_CONTRACT: "0x0000000000000000000000000000000000000000" } } diff --git a/packages/core-sdk/src/accounts/handler.ts b/packages/core-sdk/src/accounts/handler.ts index fadd743b0..5508683cd 100644 --- a/packages/core-sdk/src/accounts/handler.ts +++ b/packages/core-sdk/src/accounts/handler.ts @@ -9,7 +9,6 @@ import { encodeCreateSeller, encodeUpdateSeller, encodeCreateDisputeResolver, - encodeActivateDisputeResolver, encodeAddFeesToDisputeResolver, encodeAddSellersToAllowList, encodeRemoveFeesFromDisputeResolver, @@ -76,17 +75,6 @@ export async function createDisputeResolver(args: { }); } -export async function activateDisputeResolver(args: { - disputeResolverId: BigNumberish; - contractAddress: string; - web3Lib: Web3LibAdapter; -}) { - return args.web3Lib.sendTransaction({ - to: args.contractAddress, - data: encodeActivateDisputeResolver(args.disputeResolverId) - }); -} - export async function addFeesToDisputeResolver(args: { disputeResolverId: BigNumberish; fees: DisputeResolutionFee[]; diff --git a/packages/core-sdk/src/accounts/interface.ts b/packages/core-sdk/src/accounts/interface.ts index 723ce9242..6c82a4c2d 100644 --- a/packages/core-sdk/src/accounts/interface.ts +++ b/packages/core-sdk/src/accounts/interface.ts @@ -61,13 +61,6 @@ export function encodeCreateDisputeResolver(args: CreateDisputeResolverArgs) { ]); } -export function encodeActivateDisputeResolver(disputeResolverId: BigNumberish) { - return bosonAccountHandlerIface.encodeFunctionData( - "activateDisputeResolver", - [disputeResolverId] - ); -} - export function encodeAddFeesToDisputeResolver(args: { disputeResolverId: BigNumberish; fees: DisputeResolutionFee[]; diff --git a/packages/core-sdk/src/accounts/mixin.ts b/packages/core-sdk/src/accounts/mixin.ts index 930968d93..b011ee43b 100644 --- a/packages/core-sdk/src/accounts/mixin.ts +++ b/packages/core-sdk/src/accounts/mixin.ts @@ -493,22 +493,6 @@ export class AccountsMixin extends BaseCoreSDK { }); } - /** - * Activates a dispute resolver account by calling the `AccountHandlerFacet` contract. - * Note, that the caller needs to have the ADMIN role. - * @param disputeResolverId - Id of dispute resolver to activate. - * @returns Transaction response. - */ - public async activateDisputeResolver( - disputeResolverId: BigNumberish - ): Promise { - return accounts.handler.activateDisputeResolver({ - disputeResolverId, - contractAddress: this._protocolDiamond, - web3Lib: this._web3Lib - }); - } - /** * Adds fees to a dispute resolver account by calling the `AccountHandlerFacet` * contract. Note, that the caller must be the specified `admin` address of the dispute diff --git a/packages/core-sdk/src/erc721/handler.ts b/packages/core-sdk/src/erc721/handler.ts index c268ba63c..f134b1001 100644 --- a/packages/core-sdk/src/erc721/handler.ts +++ b/packages/core-sdk/src/erc721/handler.ts @@ -7,9 +7,11 @@ export async function balanceOf(args: { owner: string; web3Lib: Web3LibAdapter; }): Promise { + const data = erc721Iface.encodeFunctionData("balanceOf", [args.owner]); + const result = await args.web3Lib.call({ to: args.contractAddress, - data: erc721Iface.encodeFunctionData("balanceOf", [args.owner]) + data: data }); const [balance] = erc721Iface.decodeFunctionResult("balanceOf", result); diff --git a/scripts/create-dispute-resolver.ts b/scripts/create-dispute-resolver.ts index 18f078710..41b3e9694 100644 --- a/scripts/create-dispute-resolver.ts +++ b/scripts/create-dispute-resolver.ts @@ -98,15 +98,9 @@ async function main() { const disputeResolverId = coreSDKDRAdmin.getDisputeResolverIdFromLogs( receipt.logs ); - console.log(`Dispute resolver with id ${disputeResolverId} created.`); - - console.log(`Activating dispute resolver...`); - const txResponse2 = await coreSDKProtocolAdmin.activateDisputeResolver( - disputeResolverId as string + console.log( + `Dispute resolver with id ${disputeResolverId} created and activated.` ); - console.log(`Tx hash: ${txResponse2.hash}`); - await txResponse2.wait(); - console.log(`Dispute resolver with id ${disputeResolverId} activated.`); } main() From 3afdde665982fc02bc8391e2d8a66981e92b3904 Mon Sep 17 00:00:00 2001 From: Albert Folch Date: Tue, 3 Jan 2023 16:34:43 +0100 Subject: [PATCH 6/9] fix tests --- contracts/accounts.js | 12 ++++++-- contracts/scripts/deploy.js | 13 ++++++-- e2e/run-e2e-services.sh | 2 +- e2e/tests/core-sdk.test.ts | 48 ++--------------------------- e2e/tests/meta-tx.test.ts | 25 +++++++++++---- e2e/tests/native-meta-tx.test.ts | 6 +++- e2e/tests/utils.ts | 53 +++++++++++++++++++++++++++++++- packages/common/src/configs.ts | 6 ++-- 8 files changed, 103 insertions(+), 62 deletions(-) diff --git a/contracts/accounts.js b/contracts/accounts.js index eb295db04..afd948d98 100644 --- a/contracts/accounts.js +++ b/contracts/accounts.js @@ -69,6 +69,12 @@ const ACCOUNT_12 = { privateKey: "35253a0b89df66fa7c4fb98e46925f6e8804b55a80e2e1c3f22cb1b90a11567b" }; +const ACCOUNT_13 = { + address: "0xC448891cE3d85d141C43E9D95236B7C735bd74BB", + privateKey: + "0x23b745a17fdcdfcc13a8d5af456898700cd798b25ef5ef3767ae859cc8114df1" +}; + const ACCOUNTS = [ ACCOUNT_1, ACCOUNT_2, @@ -81,7 +87,8 @@ const ACCOUNTS = [ ACCOUNT_9, ACCOUNT_10, ACCOUNT_11, - ACCOUNT_12 + ACCOUNT_12, + ACCOUNT_13 ]; module.exports = { @@ -97,5 +104,6 @@ module.exports = { ACCOUNT_9, ACCOUNT_10, ACCOUNT_11, - ACCOUNT_12 + ACCOUNT_12, + ACCOUNT_13 }; diff --git a/contracts/scripts/deploy.js b/contracts/scripts/deploy.js index 3ca320712..27fd1c4fb 100644 --- a/contracts/scripts/deploy.js +++ b/contracts/scripts/deploy.js @@ -13,12 +13,21 @@ const { } = require("../protocol-contracts/scripts/deploy-suite.js"); const { - deployAndMintMockNFTAuthTokens + deployAndMintMockNFTAuthTokens, + deployMockTokens } = require("../protocol-contracts/scripts/util/deploy-mock-tokens.js"); async function main() { - await deploySuite("localhost", undefined); // TODO: verify + await deploySuite("localhost", undefined); await deployAndMintMockNFTAuthTokens(); + const mockTokens = ["Foreign20", "Foreign721", "Foreign1155"]; + const deployedTokens = await deployMockTokens(mockTokens); + console.log(`โœ… Mock tokens deployed: ${deployedTokens.length}`); + for (const [index, mockToken] of Object.entries(mockTokens)) { + console.log( + `โœ… Mock token ${mockToken} has been deployed at ${deployedTokens[index].address}` + ); + } } main() diff --git a/e2e/run-e2e-services.sh b/e2e/run-e2e-services.sh index e3aa82ddd..342a35f39 100755 --- a/e2e/run-e2e-services.sh +++ b/e2e/run-e2e-services.sh @@ -10,7 +10,7 @@ function cleanup() { cd e2e -docker-compose up -d #--force-recreate +docker-compose up -d --build echo "Waiting for services..." sleep 15 diff --git a/e2e/tests/core-sdk.test.ts b/e2e/tests/core-sdk.test.ts index 6359281c5..2f382faf2 100644 --- a/e2e/tests/core-sdk.test.ts +++ b/e2e/tests/core-sdk.test.ts @@ -5,10 +5,6 @@ import { ExchangeFieldsFragment } from "./../../packages/core-sdk/src/subgraph"; import { utils, constants, BigNumber, BigNumberish } from "ethers"; -import { - MSEC_PER_DAY, - MSEC_PER_SEC -} from "./../../packages/common/src/utils/timestamp"; import { mockCreateOfferArgs } from "../../packages/common/tests/mocks"; import { CoreSDK } from "../../packages/core-sdk/src"; import { @@ -38,12 +34,10 @@ import { createSellerAndOfferWithCondition, createSeller, createSellerAndOffer, - createDisputeResolver, - deployerWallet + createDisputeResolverIfRequired } from "./utils"; import { EvaluationMethod, TokenType } from "@bosonprotocol/common"; -const protocolAdminWallet = deployerWallet; const seedWallet = seedWallet4; // be sure the seedWallet is not used by another test (to allow concurrent run) const sellerWallet2 = seedWallet5; // be sure the seedWallet is not used by another test (to allow concurrent run) const buyerWallet2 = seedWallet6; // be sure the seedWallet is not used by another test (to allow concurrent run) @@ -52,45 +46,7 @@ jest.setTimeout(60_000); describe("core-sdk", () => { beforeAll(async () => { - const { coreSDK, fundedWallet } = await initCoreSDKWithFundedWallet( - protocolAdminWallet - ); - const ethDisputeResolutionFee = { - tokenAddress: constants.AddressZero, - tokenName: "Native", - feeAmount: utils.parseEther("0") - }; - const erc20DisputeResolutionFee = { - tokenAddress: MOCK_ERC20_ADDRESS, - tokenName: "erc20", - feeAmount: utils.parseEther("0") - }; - const disputeResolverId = 1; - const dr = await coreSDK.getDisputeResolverById(1); - if (dr && !dr.fees.length) { - await ( - await coreSDK.addFeesToDisputeResolver(disputeResolverId, [ - ethDisputeResolutionFee, - erc20DisputeResolutionFee - ]) - ).wait(); - await waitForGraphNodeIndexing(); - } else if (!dr) { - const metadataUri = "ipfs://dispute-resolver-uri"; - const escalationResponsePeriodInMS = 90 * MSEC_PER_DAY - 1 * MSEC_PER_SEC; - const disputeResolverAddress = fundedWallet.address; - - await createDisputeResolver(fundedWallet, protocolAdminWallet, { - operator: disputeResolverAddress, - clerk: disputeResolverAddress, - admin: disputeResolverAddress, - treasury: disputeResolverAddress, - metadataUri, - escalationResponsePeriodInMS, - fees: [ethDisputeResolutionFee, erc20DisputeResolutionFee], - sellerAllowList: [] - }); - } + await createDisputeResolverIfRequired(); }); describe("core user flows", () => { diff --git a/e2e/tests/meta-tx.test.ts b/e2e/tests/meta-tx.test.ts index 4eb94c3f9..31c7e5bc5 100644 --- a/e2e/tests/meta-tx.test.ts +++ b/e2e/tests/meta-tx.test.ts @@ -18,7 +18,9 @@ import { seedWallet11, ensureMintedERC1155, MOCK_ERC1155_ADDRESS, - initCoreSDKWithFundedWallet + initCoreSDKWithFundedWallet, + createDisputeResolverIfRequired, + seedWallet13 } from "./utils"; import { CoreSDK } from "../../packages/core-sdk/src"; import EvaluationMethod from "../../contracts/protocol-contracts/scripts/domain/EvaluationMethod"; @@ -39,6 +41,7 @@ describe("meta-tx", () => { let offerToCommit: OfferFieldsFragment; beforeAll(async () => { + await createDisputeResolverIfRequired(); await ensureCreatedSeller(sellerWallet); await ensureMintedAndAllowedTokens([sellerWallet]); // do not approve for buyer (we expect commit to do it when needed) @@ -60,17 +63,27 @@ describe("meta-tx", () => { if (existingSeller) { // Change all addresses used by the seller to be able to create another one with the original address // Useful when repeating the test suite on the same contracts - const randomWallet = Wallet.createRandom(); const updateTx = await newSellerCoreSDK.updateSeller({ id: existingSeller.id, - admin: randomWallet.address, - operator: randomWallet.address, - clerk: randomWallet.address, - treasury: randomWallet.address, + admin: seedWallet13.address, + operator: seedWallet13.address, + clerk: seedWallet13.address, + treasury: seedWallet13.address, authTokenId: "0", authTokenType: 0 }); await updateTx.wait(); + const randomSellerCoreSDK = initCoreSDKWithWallet(seedWallet13); + const optinTx = await randomSellerCoreSDK.optInToSellerUpdate({ + id: existingSeller.id, + fieldsToUpdate: { + admin: true, + operator: true, + clerk: true, + authToken: true + } + }); + await optinTx.wait(); } // Random seller signs meta tx diff --git a/e2e/tests/native-meta-tx.test.ts b/e2e/tests/native-meta-tx.test.ts index b59c0f4f5..9cb74b7de 100644 --- a/e2e/tests/native-meta-tx.test.ts +++ b/e2e/tests/native-meta-tx.test.ts @@ -2,7 +2,8 @@ import { BigNumber } from "ethers"; import { seedWallet12, initCoreSDKWithWallet, - MOCK_ERC20_ADDRESS + MOCK_ERC20_ADDRESS, + createDisputeResolverIfRequired } from "./utils"; const seedWallet = seedWallet12; // be sure the seedWallet is not used by another test (to allow concurrent run) @@ -13,6 +14,9 @@ const coreSDK = initCoreSDKWithWallet(seedWallet); jest.setTimeout(60_000); describe("native-meta-tx", () => { + beforeAll(async () => { + await createDisputeResolverIfRequired(); + }); test("approve ERC20 token", async () => { const allowanceBefore = await coreSDK.getProtocolAllowance( MOCK_ERC20_ADDRESS diff --git a/e2e/tests/utils.ts b/e2e/tests/utils.ts index b51e75693..b6eb26d36 100644 --- a/e2e/tests/utils.ts +++ b/e2e/tests/utils.ts @@ -7,6 +7,7 @@ import { providers, Wallet, utils, + constants, Contract, BigNumber, BigNumberish @@ -32,7 +33,8 @@ import { ACCOUNT_9, ACCOUNT_10, ACCOUNT_11, - ACCOUNT_12 + ACCOUNT_12, + ACCOUNT_13 } from "../../contracts/accounts"; import { MOCK_ERC1155_ABI, @@ -43,6 +45,10 @@ import { import { BaseMetadata } from "@bosonprotocol/metadata/src/base"; import { SellerFieldsFragment } from "../../packages/core-sdk/src/subgraph"; import { ZERO_ADDRESS } from "../../packages/core-sdk/tests/mocks"; +import { + MSEC_PER_DAY, + MSEC_PER_SEC +} from "../../packages/common/src/utils/timestamp"; export const MOCK_ERC20_ADDRESS = getDefaultConfig("local").contracts.testErc20 || @@ -82,6 +88,7 @@ export const seedWallet7 = new Wallet(ACCOUNT_7.privateKey, provider); export const seedWallet8 = new Wallet(ACCOUNT_8.privateKey, provider); export const seedWallet9 = new Wallet(ACCOUNT_9.privateKey, provider); export const seedWallet11 = new Wallet(ACCOUNT_11.privateKey, provider); +export const seedWallet13 = new Wallet(ACCOUNT_13.privateKey, provider); // seedWallets used by native-meta-tx test export const seedWallet12 = new Wallet(ACCOUNT_12.privateKey, provider); // seedWallets used by productV1 test @@ -291,6 +298,50 @@ export async function createDisputeResolver( }; } +export async function createDisputeResolverIfRequired() { + const protocolAdminWallet = deployerWallet; + + const { coreSDK, fundedWallet } = await initCoreSDKWithFundedWallet( + protocolAdminWallet + ); + const ethDisputeResolutionFee = { + tokenAddress: constants.AddressZero, + tokenName: "Native", + feeAmount: utils.parseEther("0") + }; + const erc20DisputeResolutionFee = { + tokenAddress: MOCK_ERC20_ADDRESS, + tokenName: "erc20", + feeAmount: utils.parseEther("0") + }; + const disputeResolverId = 1; + const dr = await coreSDK.getDisputeResolverById(disputeResolverId); + if (dr && !dr.fees.length) { + await ( + await coreSDK.addFeesToDisputeResolver(disputeResolverId, [ + ethDisputeResolutionFee, + erc20DisputeResolutionFee + ]) + ).wait(); + await waitForGraphNodeIndexing(); + } else if (!dr) { + const metadataUri = "ipfs://dispute-resolver-uri"; + const escalationResponsePeriodInMS = 90 * MSEC_PER_DAY - 1 * MSEC_PER_SEC; + const disputeResolverAddress = fundedWallet.address; + + await createDisputeResolver(fundedWallet, protocolAdminWallet, { + operator: disputeResolverAddress, + clerk: disputeResolverAddress, + admin: disputeResolverAddress, + treasury: disputeResolverAddress, + metadataUri, + escalationResponsePeriodInMS, + fees: [ethDisputeResolutionFee, erc20DisputeResolutionFee], + sellerAllowList: [] + }); + } +} + export async function createOffer( coreSDK: CoreSDK, offerParams?: Partial diff --git a/packages/common/src/configs.ts b/packages/common/src/configs.ts index 8f57d1858..b71be7b54 100644 --- a/packages/common/src/configs.ts +++ b/packages/common/src/configs.ts @@ -159,9 +159,9 @@ export const defaultConfigs: ProtocolConfig[] = [ ipfsMetadataUrl: "http://127.0.0.1:5001", contracts: { protocolDiamond: "0xDc64a140Aa3E981100a9becA4E685f962f0cF6C9", - testErc20: "0xb7278A61aa25c888815aFC32Ad3cC52fF24fE575", // Foreign20 contract - testErc721: "0xCD8a1C3ba11CF5ECfa6267617243239504a98d90", // Foreign721 contract - testErc1155: "0x82e01223d51Eb87e16A03E24687EDF0F294da6f1" // Foreign1155 contract + testErc20: "0x95401dc811bb5740090279Ba06cfA8fcF6113778", // Foreign20 contract + testErc721: "0x998abeb3E57409262aE5b751f60747921B33613E", // Foreign721 contract + testErc1155: "0x70e0bA845a1A0F2DA3359C97E0285013525FFC49" // Foreign1155 contract }, metaTx: { relayerUrl: "http://localhost:8888" From 252cd9747a4d130f610d7065ab1f3fff03610f7a Mon Sep 17 00:00:00 2001 From: Albert Folch Date: Tue, 3 Jan 2023 17:13:55 +0100 Subject: [PATCH 7/9] fix tests --- contracts/scripts/deploy.js | 3 +-- e2e/docker-compose.yml | 2 ++ 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/contracts/scripts/deploy.js b/contracts/scripts/deploy.js index 27fd1c4fb..46e8a4ee2 100644 --- a/contracts/scripts/deploy.js +++ b/contracts/scripts/deploy.js @@ -21,8 +21,7 @@ async function main() { await deploySuite("localhost", undefined); await deployAndMintMockNFTAuthTokens(); const mockTokens = ["Foreign20", "Foreign721", "Foreign1155"]; - const deployedTokens = await deployMockTokens(mockTokens); - console.log(`โœ… Mock tokens deployed: ${deployedTokens.length}`); + const deployedTokens = await deployMockTokens([...mockTokens]); for (const [index, mockToken] of Object.entries(mockTokens)) { console.log( `โœ… Mock token ${mockToken} has been deployed at ${deployedTokens[index].address}` diff --git a/e2e/docker-compose.yml b/e2e/docker-compose.yml index 1c1605fe8..fe905eb24 100644 --- a/e2e/docker-compose.yml +++ b/e2e/docker-compose.yml @@ -22,6 +22,8 @@ services: image: hardhat-node:38c7ba384e55486aee4ea76bb80b4f29d1a86175 ports: - "8545:8545" + volumes: + - ../contracts/scripts/deploy.js:/app/scripts/deploy.js graph-node: image: graphprotocol/graph-node:v0.27.0 # TODO: find out why ^0.28.0 not starting to index From a1c07438dcb95015a163af89ba67cbdb7ab3fbf4 Mon Sep 17 00:00:00 2001 From: Albert Folch Date: Tue, 3 Jan 2023 17:26:46 +0100 Subject: [PATCH 8/9] fix tests --- contracts/scripts/deploy.js | 1 + 1 file changed, 1 insertion(+) diff --git a/contracts/scripts/deploy.js b/contracts/scripts/deploy.js index 46e8a4ee2..6e9dfd680 100644 --- a/contracts/scripts/deploy.js +++ b/contracts/scripts/deploy.js @@ -3,6 +3,7 @@ process.env.CONFIRMATIONS = 1; // required for deployProtocolConfigFacet() process.env.DEPLOYER_GAS_LIMIT_TEST = gasLimit; process.env.AUTH_TOKEN_OWNERS_LOCAL = ""; process.env.TIP_MULTIPLIER = "10"; +process.env.ADMIN_ADDRESS_LOCAL = "0x5131738127d2E5Edc999b1634342833667eBC8Bc"; // any non-zero address require("dotenv").config({ path: "./protocol-contracts/.env" }); From db9aaf846917573fc684ea1db9ba985d4d3689f7 Mon Sep 17 00:00:00 2001 From: Ludovic Levalleux Date: Wed, 4 Jan 2023 11:12:57 +0000 Subject: [PATCH 9/9] chore: remove @bosonprotocol/common dependency --- e2e/meta-tx-gateway/package.json | 4 ++-- e2e/meta-tx-gateway/src/services/meta-tx.ts | 2 +- e2e/meta-tx-gateway/tsconfig.json | 8 ++++++-- package-lock.json | 15 +++++++-------- 4 files changed, 16 insertions(+), 13 deletions(-) diff --git a/e2e/meta-tx-gateway/package.json b/e2e/meta-tx-gateway/package.json index 37af2810f..1fe1bd43e 100644 --- a/e2e/meta-tx-gateway/package.json +++ b/e2e/meta-tx-gateway/package.json @@ -23,7 +23,6 @@ }, "homepage": "https://github.com/bosonprotocol/core-components#readme", "dependencies": { - "@bosonprotocol/common": "^1.20.2", "cors": "^2.8.5", "dotenv": "^16.0.2", "ethers": "^5.7.0", @@ -31,7 +30,8 @@ "express-validator": "^6.14.2", "morgan": "^1.10.0", "ts-command-line-args": "^2.3.1", - "winston": "^3.8.2" + "winston": "^3.8.2", + "yup": "^0.32.11" }, "devDependencies": { "@types/cors": "^2.8.12", diff --git a/e2e/meta-tx-gateway/src/services/meta-tx.ts b/e2e/meta-tx-gateway/src/services/meta-tx.ts index ef2a5ec19..57bc4c1a1 100644 --- a/e2e/meta-tx-gateway/src/services/meta-tx.ts +++ b/e2e/meta-tx-gateway/src/services/meta-tx.ts @@ -1,6 +1,6 @@ import { logger } from "./../utils/logger"; import { ContractTransaction } from "ethers"; -import { abis } from "@bosonprotocol/common"; +import * as abis from "@bosonprotocol/common/src/abis"; import { Interface } from "@ethersproject/abi"; import { ethers } from "ethers"; import { Config, getConfig } from "../config"; diff --git a/e2e/meta-tx-gateway/tsconfig.json b/e2e/meta-tx-gateway/tsconfig.json index 2cefe16f2..14dc80cff 100644 --- a/e2e/meta-tx-gateway/tsconfig.json +++ b/e2e/meta-tx-gateway/tsconfig.json @@ -2,10 +2,14 @@ "compilerOptions": { "module": "commonjs", "target": "es6", - "rootDir": "./", + // "rootDir": "./", "esModuleInterop": true, "outDir": "./build", - "resolveJsonModule": true + "resolveJsonModule": true, + "paths": { + "@bosonprotocol/common": ["../../packages/common"], + "@bosonprotocol/metadata": ["../../packages/metadata"] + } }, "include": ["src", "index.ts"] } diff --git a/package-lock.json b/package-lock.json index 1a4f7ed6c..cb5e3b3ef 100644 --- a/package-lock.json +++ b/package-lock.json @@ -36,7 +36,6 @@ "version": "1.2.4", "license": "ISC", "dependencies": { - "@bosonprotocol/common": "^1.20.2", "cors": "^2.8.5", "dotenv": "^16.0.2", "ethers": "^5.7.0", @@ -44,7 +43,8 @@ "express-validator": "^6.14.2", "morgan": "^1.10.0", "ts-command-line-args": "^2.3.1", - "winston": "^3.8.2" + "winston": "^3.8.2", + "yup": "^0.32.11" }, "devDependencies": { "@types/cors": "^2.8.12", @@ -49859,7 +49859,7 @@ "@storybook/ui": "6.5.12", "@types/node": "^14.0.10 || ^16.0.0", "@types/webpack": "^4.41.26", - "autoprefixer": "10.4.5", + "autoprefixer": "^9.8.6", "babel-loader": "^8.0.0", "case-sensitive-paths-webpack-plugin": "^2.3.0", "core-js": "^3.8.2", @@ -56562,8 +56562,7 @@ "dev": true }, "autoprefixer": { - "version": "10.4.5", - "resolved": "https://registry.npmjs.org/autoprefixer/-/autoprefixer-10.4.5.tgz", + "version": "https://registry.npmjs.org/autoprefixer/-/autoprefixer-10.4.5.tgz", "integrity": "sha512-Fvd8yCoA7lNX/OUllvS+aS1I7WRBclGXsepbvT8ZaPgrH24rgXpZzF0/6Hh3ZEkwg+0AES/Osd196VZmYoEFtw==", "dev": true, "requires": { @@ -67787,7 +67786,6 @@ "meta-tx-gateway": { "version": "file:e2e/meta-tx-gateway", "requires": { - "@bosonprotocol/common": "^1.20.2", "@types/cors": "^2.8.12", "@types/express": "^4.17.13", "@types/morgan": "^1.9.3", @@ -67809,7 +67807,8 @@ "ts-node": "^10.9.1", "ts-node-dev": "^2.0.0", "typescript": "^4.8.3", - "winston": "^3.8.2" + "winston": "^3.8.2", + "yup": "^0.32.11" } }, "methods": { @@ -70928,7 +70927,7 @@ "@csstools/postcss-text-decoration-shorthand": "^1.0.0", "@csstools/postcss-trigonometric-functions": "^1.0.2", "@csstools/postcss-unset-value": "^1.0.2", - "autoprefixer": "10.4.5", + "autoprefixer": "^10.4.11", "browserslist": "^4.21.3", "css-blank-pseudo": "^3.0.3", "css-has-pseudo": "^3.0.4",