@cultura/sdk
Version:
SDK for interacting with Cultura, a Layer 2 Ethereum blockchain acting as the global registry for human creativity and IP. It ensures transparent licensing, revenue sharing, and secure provenance.
2,305 lines (2,297 loc) • 307 kB
JavaScript
"use strict";
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
for (var name in all)
__defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
if (from && typeof from === "object" || typeof from === "function") {
for (let key of __getOwnPropNames(from))
if (!__hasOwnProp.call(to, key) && key !== except)
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
}
return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
// src/index.ts
var index_exports = {};
__export(index_exports, {
BondTokenAbi: () => BondTokenAbi,
CASAbi: () => CASAbi,
CONTRACT_TO_ABI_MAP: () => CONTRACT_TO_ABI_MAP,
CRSAbi: () => CRSAbi,
CulturaRightAbi: () => CulturaRightAbi,
CulturaSDK: () => CulturaSDK,
ENVIRONMENTS: () => ENVIRONMENTS,
MockLicensingAttestationAbi: () => MockLicensingAttestationAbi,
POPAbi: () => POPAbi,
QueryClient: () => QueryClient,
SchemaRegistryAbi: () => SchemaRegistryAbi,
VerifierModuleAbi: () => VerifierModuleAbi,
createChainConfig: () => createChainConfig,
culturaChain: () => culturaChain,
getABI: () => getABI,
getAllABIs: () => getAllABIs,
getChainDisplayName: () => getChainDisplayName,
getContractAddress: () => getContractAddress,
getContractAddresses: () => getContractAddresses,
getNetworkName: () => getNetworkName,
utils: () => utils_exports
});
module.exports = __toCommonJS(index_exports);
// src/client.ts
var import_viem13 = require("viem");
// ../../submodules/CAS/deployments/localhost.json
var localhost_default = {
schemaRegistry: "0x5FbDB2315678afecb367f032d93F642f64180aa3",
mockERC20: "0xe7f1725E7734CE288F8367e1Bb143E90bb3F0512",
CASProxy: "0xDc64a140Aa3E981100a9becA4E685f962f0cF6C9",
CulturaDigitalAsset: "0x9fE46736679d2D9a65F0992F2272dE9f3c7fa6e0",
CulturaRoyaltyModule: "0x5FC8d32690cc91D4c39d9d3abcBD16989F875707",
VerifierModule: "0x0165878A594ca255338adfa4d48449f69242Eb8F",
POP: "0x2279B7A0a67DB372996a5FaB50D91eAA73d2eBe6",
LicensingAttestationMock: "0x8A791620dd6260079BF849Dc5567aDC3F2FdC318"
};
// ../../submodules/CAS/deployments/conduit_devnet.json
var conduit_devnet_default = { schemaRegistry: "0x099b90bD793aFccF3Cb272B452564a45d3B38cBe", mockERC20: "0x94B1215cf3a7A80Ff006Fe6a088bF0aef4e8723E", CASProxy: "0x730804d0bd3A29B77c5D07Ffcf1A4C9F965FCd28", CulturaDigitalAsset: "0xc03B38Da60410119A8bE0b3c8a167dAe6d062F7C", CulturaRoyaltyModule: "0xe281ed653157ebab1facb9616eF078d27F3E88af", VerifierModule: "0x3d884E909979e220046A054ca3637b12C85307e0", POP: "0x4aB6a0466044323d7f6b8845ac53992a355C4Ba7", LicensingAttestationMock: "0x4D338CcAFe5A43F4B724CD7D874060Fb9222b152" };
// ../../submodules/CAS/deployments/conduit_testnet.json
var conduit_testnet_default = {
schemaRegistry: "0xc50362623DF286f1947688a6fa02086dE90FC7dF",
mockERC20: "0xb90e5a2fBe67c4C16517b909aa246bE6C889e21F",
CASProxy: "0xCDDda673Aa3138087F3a310B5Ba502e0E0B0343f",
CulturaDigitalAsset: "0xa7f1df597e238B2e0865a512e4109Bc1225B735E",
CulturaRoyaltyModule: "0x767F996Cb2E99B53B45EC4f2fb1A61cd02A7B966",
VerifierModule: "0x1E51dc3A8359C1EA0F4d419C0f05aCC64611Eb8a",
POP: "0x1A62ac7CA19B83D8C987DC27169c1F15186Ad1fA",
LicensingAttestationMock: "0xF2A6A0876a9093258f2b39B94D9c9752099e4413"
};
// ../../submodules/CAS/deployments/spacenet.json
var spacenet_default = { schemaRegistry: "0x5FbDB2315678afecb367f032d93F642f64180aa3", mockERC20: "0xe7f1725E7734CE288F8367e1Bb143E90bb3F0512", CASProxy: "0x5FC8d32690cc91D4c39d9d3abcBD16989F875707", CulturaDigitalAsset: "0x9fE46736679d2D9a65F0992F2272dE9f3c7fa6e0", CulturaRoyaltyModule: "0x0165878A594ca255338adfa4d48449f69242Eb8F", VerifierModule: "0xa513E6E4b8f2a923D98304ec87F64353C4D5C853", POP: "0x8A791620dd6260079BF849Dc5567aDC3F2FdC318", LicensingAttestationMock: "0x610178dA211FEF7D417bC0e6FeD39F05609AD788" };
// src/abi/generated.ts
var CASAbi = [
{
"inputs": [],
"stateMutability": "nonpayable",
"type": "constructor"
},
{
"inputs": [
{
"internalType": "address",
"name": "target",
"type": "address"
}
],
"name": "AddressEmptyCode",
"type": "error"
},
{
"inputs": [],
"name": "AssetHasToBeVerifiedRights",
"type": "error"
},
{
"inputs": [],
"name": "AttestationDoesNotExist",
"type": "error"
},
{
"inputs": [],
"name": "ClassDoesNotExist",
"type": "error"
},
{
"inputs": [],
"name": "DigitalAssetCollectionCantBe0Address",
"type": "error"
},
{
"inputs": [],
"name": "ECDSAInvalidSignature",
"type": "error"
},
{
"inputs": [],
"name": "ECDSAInvalidSignature",
"type": "error"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "length",
"type": "uint256"
}
],
"name": "ECDSAInvalidSignatureLength",
"type": "error"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "s",
"type": "bytes32"
}
],
"name": "ECDSAInvalidSignatureS",
"type": "error"
},
{
"inputs": [
{
"internalType": "address",
"name": "implementation",
"type": "address"
}
],
"name": "ERC1967InvalidImplementation",
"type": "error"
},
{
"inputs": [],
"name": "ERC1967NonPayable",
"type": "error"
},
{
"inputs": [],
"name": "FailedCall",
"type": "error"
},
{
"inputs": [],
"name": "InvalidExpirationTime",
"type": "error"
},
{
"inputs": [],
"name": "InvalidInitialization",
"type": "error"
},
{
"inputs": [],
"name": "InvalidSchema",
"type": "error"
},
{
"inputs": [],
"name": "Irrevocable",
"type": "error"
},
{
"inputs": [],
"name": "NotFound",
"type": "error"
},
{
"inputs": [],
"name": "NotInitializing",
"type": "error"
},
{
"inputs": [
{
"internalType": "address",
"name": "owner",
"type": "address"
}
],
"name": "OwnableInvalidOwner",
"type": "error"
},
{
"inputs": [
{
"internalType": "address",
"name": "account",
"type": "address"
}
],
"name": "OwnableUnauthorizedAccount",
"type": "error"
},
{
"inputs": [],
"name": "TransferFailed",
"type": "error"
},
{
"inputs": [],
"name": "UUPSUnauthorizedCallContext",
"type": "error"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "slot",
"type": "bytes32"
}
],
"name": "UUPSUnsupportedProxiableUUID",
"type": "error"
},
{
"inputs": [],
"name": "ValueSentLessThanClassFee",
"type": "error"
},
{
"inputs": [],
"name": "VerifierNotWhitelisted",
"type": "error"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "recipient",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "attester",
"type": "address"
},
{
"indexed": false,
"internalType": "bytes32",
"name": "uid",
"type": "bytes32"
},
{
"indexed": true,
"internalType": "bytes32",
"name": "schemaUID",
"type": "bytes32"
},
{
"indexed": false,
"internalType": "uint256",
"name": "assetClass",
"type": "uint256"
}
],
"name": "Attested",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "challenger",
"type": "address"
},
{
"indexed": false,
"internalType": "bytes32",
"name": "uid",
"type": "bytes32"
},
{
"indexed": false,
"internalType": "uint256",
"name": "bondedAmount",
"type": "uint256"
}
],
"name": "Challenged",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"components": [
{
"internalType": "address",
"name": "rightsBoundAccount",
"type": "address"
},
{
"internalType": "address",
"name": "attester",
"type": "address"
},
{
"internalType": "address",
"name": "digitalAssetAddress",
"type": "address"
},
{
"internalType": "uint256",
"name": "digitalAssetId",
"type": "uint256"
}
],
"indexed": false,
"internalType": "struct CulturaRightsBoundAccountInfo",
"name": "rightsBoundAccount",
"type": "tuple"
}
],
"name": "CulturaRightsBoundAccountDeployed",
"type": "event"
},
{
"anonymous": false,
"inputs": [],
"name": "EIP712DomainChanged",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "uint64",
"name": "version",
"type": "uint64"
}
],
"name": "Initialized",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "previousOwner",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "newOwner",
"type": "address"
}
],
"name": "OwnershipTransferred",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "recipient",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "attester",
"type": "address"
},
{
"indexed": false,
"internalType": "bytes32",
"name": "uid",
"type": "bytes32"
},
{
"indexed": true,
"internalType": "bytes32",
"name": "schemaUID",
"type": "bytes32"
}
],
"name": "Revoked",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "revoker",
"type": "address"
},
{
"indexed": true,
"internalType": "bytes32",
"name": "data",
"type": "bytes32"
},
{
"indexed": true,
"internalType": "uint64",
"name": "timestamp",
"type": "uint64"
}
],
"name": "RevokedOffchain",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "bytes32",
"name": "data",
"type": "bytes32"
},
{
"indexed": true,
"internalType": "uint64",
"name": "timestamp",
"type": "uint64"
}
],
"name": "Timestamped",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "implementation",
"type": "address"
}
],
"name": "Upgraded",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "address",
"name": "attester",
"type": "address"
},
{
"indexed": false,
"internalType": "bytes32",
"name": "attestationUID",
"type": "bytes32"
}
],
"name": "Verified",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "address",
"name": "verifier",
"type": "address"
},
{
"indexed": false,
"internalType": "bool",
"name": "isWhitelisted",
"type": "bool"
}
],
"name": "VerifierWLStateChanged",
"type": "event"
},
{
"inputs": [],
"name": "UPGRADE_INTERFACE_VERSION",
"outputs": [
{
"internalType": "string",
"name": "",
"type": "string"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "verifier",
"type": "address"
}
],
"name": "addWLVerifier",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"name": "assetClasses",
"outputs": [
{
"internalType": "string",
"name": "name",
"type": "string"
},
{
"internalType": "uint256",
"name": "fee",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "requiredTokens",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "requiredWLVerifiers",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "requiredCommunityUsers",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"components": [
{
"internalType": "bytes32",
"name": "schema",
"type": "bytes32"
},
{
"components": [
{
"internalType": "address",
"name": "recipient",
"type": "address"
},
{
"internalType": "uint64",
"name": "expirationTime",
"type": "uint64"
},
{
"internalType": "bool",
"name": "revocable",
"type": "bool"
},
{
"internalType": "bytes32",
"name": "refUID",
"type": "bytes32"
},
{
"internalType": "bytes",
"name": "data",
"type": "bytes"
}
],
"internalType": "struct AttestationRequestData",
"name": "data",
"type": "tuple"
}
],
"internalType": "struct AttestationRequest",
"name": "request",
"type": "tuple"
},
{
"internalType": "address",
"name": "digitalAssetAddress",
"type": "address"
},
{
"internalType": "uint256",
"name": "digitalAssetId",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "assetClass",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "attest",
"outputs": [
{
"internalType": "bytes32",
"name": "",
"type": "bytes32"
}
],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"components": [
{
"internalType": "bytes32",
"name": "attestation",
"type": "bytes32"
},
{
"components": [
{
"internalType": "address",
"name": "recipient",
"type": "address"
},
{
"internalType": "uint64",
"name": "expirationTime",
"type": "uint64"
},
{
"internalType": "bool",
"name": "revocable",
"type": "bool"
},
{
"internalType": "bytes32",
"name": "refUID",
"type": "bytes32"
},
{
"internalType": "bytes",
"name": "data",
"type": "bytes"
},
{
"internalType": "uint256",
"name": "value",
"type": "uint256"
}
],
"internalType": "struct ChallengeRequestData",
"name": "data",
"type": "tuple"
}
],
"internalType": "struct ChallengeRequest",
"name": "request",
"type": "tuple"
},
{
"internalType": "uint256",
"name": "challengeAmount",
"type": "uint256"
}
],
"name": "challengeAttestation",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "culturaTreasuryAddress",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "levelValue",
"type": "uint256"
}
],
"name": "deactivateLevel",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"components": [
{
"internalType": "bytes",
"name": "signature",
"type": "bytes"
},
{
"internalType": "address",
"name": "signer",
"type": "address"
},
{
"internalType": "uint8",
"name": "v",
"type": "uint8"
},
{
"internalType": "bytes32",
"name": "r",
"type": "bytes32"
},
{
"internalType": "bytes32",
"name": "s",
"type": "bytes32"
}
],
"internalType": "struct SignatureUtils.SignatureParams",
"name": "delegatedSignature",
"type": "tuple"
},
{
"components": [
{
"internalType": "bytes32",
"name": "schema",
"type": "bytes32"
},
{
"components": [
{
"internalType": "address",
"name": "recipient",
"type": "address"
},
{
"internalType": "uint64",
"name": "expirationTime",
"type": "uint64"
},
{
"internalType": "bool",
"name": "revocable",
"type": "bool"
},
{
"internalType": "bytes32",
"name": "refUID",
"type": "bytes32"
},
{
"internalType": "bytes",
"name": "data",
"type": "bytes"
}
],
"internalType": "struct AttestationRequestData",
"name": "data",
"type": "tuple"
}
],
"internalType": "struct AttestationRequest",
"name": "request",
"type": "tuple"
},
{
"internalType": "address",
"name": "digitalAssetAddress",
"type": "address"
},
{
"internalType": "uint256",
"name": "digitalAssetId",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "assetClass",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
},
{
"internalType": "address",
"name": "attester",
"type": "address"
}
],
"name": "delegatedAttest",
"outputs": [
{
"internalType": "bytes32",
"name": "",
"type": "bytes32"
}
],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "",
"type": "bytes32"
}
],
"name": "digitalAssetBoundAccounts",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "",
"type": "bytes32"
}
],
"name": "digitalAssetClasses",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "",
"type": "bytes32"
}
],
"name": "digitalAssetLevels",
"outputs": [
{
"internalType": "uint8",
"name": "",
"type": "uint8"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "eip712Domain",
"outputs": [
{
"internalType": "bytes1",
"name": "fields",
"type": "bytes1"
},
{
"internalType": "string",
"name": "name",
"type": "string"
},
{
"internalType": "string",
"name": "version",
"type": "string"
},
{
"internalType": "uint256",
"name": "chainId",
"type": "uint256"
},
{
"internalType": "address",
"name": "verifyingContract",
"type": "address"
},
{
"internalType": "bytes32",
"name": "salt",
"type": "bytes32"
},
{
"internalType": "uint256[]",
"name": "extensions",
"type": "uint256[]"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "feeManagerAddress",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "uid",
"type": "bytes32"
}
],
"name": "getAttestation",
"outputs": [
{
"components": [
{
"internalType": "bytes32",
"name": "uid",
"type": "bytes32"
},
{
"internalType": "bytes32",
"name": "schema",
"type": "bytes32"
},
{
"internalType": "uint64",
"name": "time",
"type": "uint64"
},
{
"internalType": "uint64",
"name": "expirationTime",
"type": "uint64"
},
{
"internalType": "uint64",
"name": "revocationTime",
"type": "uint64"
},
{
"internalType": "bytes32",
"name": "refUID",
"type": "bytes32"
},
{
"internalType": "address",
"name": "recipient",
"type": "address"
},
{
"internalType": "address",
"name": "attester",
"type": "address"
},
{
"internalType": "uint256",
"name": "verifierCount",
"type": "uint256"
},
{
"internalType": "bool",
"name": "revocable",
"type": "bool"
},
{
"internalType": "bytes",
"name": "data",
"type": "bytes"
},
{
"internalType": "uint256",
"name": "bondedAmount",
"type": "uint256"
},
{
"internalType": "address",
"name": "digitalAssetAddress",
"type": "address"
},
{
"internalType": "uint256",
"name": "digitalAssetId",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "communityUserCount",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "WLVerifierCount",
"type": "uint256"
}
],
"internalType": "struct Attestation",
"name": "",
"type": "tuple"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "user",
"type": "address"
}
],
"name": "getNonce",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "getSchemaRegistry",
"outputs": [
{
"internalType": "contract ISchemaRegistry",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "initialOwner",
"type": "address"
},
{
"internalType": "contract ISchemaRegistry",
"name": "initialSchemaRegistry",
"type": "address"
},
{
"internalType": "address",
"name": "bondToken",
"type": "address"
},
{
"internalType": "address",
"name": "_culturaTreasury",
"type": "address"
},
{
"internalType": "address",
"name": "_feeManager",
"type": "address"
}
],
"name": "initialize",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "uid",
"type": "bytes32"
}
],
"name": "isAttestationValid",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"name": "isWLVerifier",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"name": "levels",
"outputs": [
{
"internalType": "bool",
"name": "active",
"type": "bool"
},
{
"internalType": "uint256",
"name": "minTokensLocked",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "minVerifiers",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "minCouncilVerifiers",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "owner",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "proxiableUUID",
"outputs": [
{
"internalType": "bytes32",
"name": "",
"type": "bytes32"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "verifier",
"type": "address"
}
],
"name": "removeWLVerifier",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "renounceOwnership",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint8",
"name": "levelValue",
"type": "uint8"
},
{
"components": [
{
"internalType": "bool",
"name": "active",
"type": "bool"
},
{
"internalType": "uint256",
"name": "minTokensLocked",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "minVerifiers",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "minCouncilVerifiers",
"type": "uint256"
}
],
"internalType": "struct VerifiedLevel",
"name": "level",
"type": "tuple"
}
],
"name": "setLevel",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISchemaRegistry",
"name": "newSchemaRegistry",
"type": "address"
}
],
"name": "setSchemaRegistry",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "_verifierModuleAddress",
"type": "address"
}
],
"name": "setVerifierModule",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"components": [
{
"internalType": "bytes32",
"name": "schema",
"type": "bytes32"
},
{
"components": [
{
"internalType": "address",
"name": "recipient",
"type": "address"
},
{
"internalType": "uint64",
"name": "expirationTime",
"type": "uint64"
},
{
"internalType": "bool",
"name": "revocable",
"type": "bool"
},
{
"internalType": "bytes32",
"name": "refUID",
"type": "bytes32"
},
{
"internalType": "bytes",
"name": "data",
"type": "bytes"
}
],
"internalType": "struct AttestationRequestData",
"name": "data",
"type": "tuple"
}
],
"internalType": "struct AttestationRequest",
"name": "request",
"type": "tuple"
},
{
"internalType": "address",
"name": "digitalAssetAddress",
"type": "address"
},
{
"internalType": "uint256",
"name": "digitalAssetId",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "assetClass",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
},
{
"internalType": "address",
"name": "payer",
"type": "address"
}
],
"name": "sponsoredAttest",
"outputs": [
{
"internalType": "bytes32",
"name": "",
"type": "bytes32"
}
],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"components": [
{
"internalType": "bytes",
"name": "signature",
"type": "bytes"
},
{
"internalType": "address",
"name": "signer",
"type": "address"
},
{
"internalType": "uint8",
"name": "v",
"type": "uint8"
},
{
"internalType": "bytes32",
"name": "r",
"type": "bytes32"
},
{
"internalType": "bytes32",
"name": "s",
"type": "bytes32"
}
],
"internalType": "struct SignatureUtils.SignatureParams",
"name": "delegatedSignature",
"type": "tuple"
},
{
"components": [
{
"internalType": "bytes32",
"name": "schema",
"type": "bytes32"
},
{
"components": [
{
"internalType": "address",
"name": "recipient",
"type": "address"
},
{
"internalType": "uint64",
"name": "expirationTime",
"type": "uint64"
},
{
"internalType": "bool",
"name": "revocable",
"type": "bool"
},
{
"internalType": "bytes32",
"name": "refUID",
"type": "bytes32"
},
{
"internalType": "bytes",
"name": "data",
"type": "bytes"
}
],
"internalType": "struct AttestationRequestData",
"name": "data",
"type": "tuple"
}
],
"internalType": "struct AttestationRequest",
"name": "request",
"type": "tuple"
},
{
"internalType": "address",
"name": "digitalAssetAddress",
"type": "address"
},
{
"internalType": "uint256",
"name": "digitalAssetId",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "assetClass",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
},
{
"internalType": "address",
"name": "attester",
"type": "address"
},
{
"internalType": "address",
"name": "payer",
"type": "address"
}
],
"name": "sponsoredDelegatedAttest",
"outputs": [
{
"internalType": "bytes32",
"name": "",
"type": "bytes32"
}
],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "newOwner",
"type": "address"
}
],
"name": "transferOwnership",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "newImplementation",
"type": "address"
},
{
"internalType": "bytes",
"name": "data",
"type": "bytes"
}
],
"name": "upgradeToAndCall",
"outputs": [],
"stateMutability": "payable",
"type": "function"
},
{
"inputs": [],
"name": "verifierModuleAddress",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "attestationUID",
"type": "bytes32"
},
{
"internalType": "uint256",
"name": "bondedAmount",
"type": "uint256"
}
],
"name": "verifyAttestation",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "withdrawBondToken",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
}
];
var SchemaRegistryAbi = [
{
"inputs": [],
"stateMutability": "nonpayable",
"type": "constructor"
},
{
"inputs": [],
"name": "AlreadyExists",
"type": "error"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "bytes32",
"name": "uid",
"type": "bytes32"
},
{
"indexed": true,
"internalType": "address",
"name": "registerer",
"type": "address"
},
{
"components": [
{
"internalType": "bytes32",
"name": "uid",
"type": "bytes32"
},
{
"internalType": "bool",
"name": "revocable",
"type": "bool"
},
{
"internalType": "string",
"name": "schema",
"type": "string"
}
],
"indexed": false,
"internalType": "struct SchemaRecord",
"name": "schema",
"type": "tuple"
}
],
"name": "Registered",
"type": "event"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "uid",
"type": "bytes32"
}
],
"name": "getSchema",
"outputs": [
{
"components": [
{
"internalType": "bytes32",
"name": "uid",
"type": "bytes32"
},
{
"internalType": "bool",
"name": "revocable",
"type": "bool"
},
{
"internalType": "string",
"name": "schema",
"type": "string"
}
],
"internalType": "struct SchemaRecord",
"name": "",
"type": "tuple"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "string",
"name": "schema",
"type": "string"
},
{
"internalType": "bool",
"name": "revocable",
"type": "bool"
}
],
"name": "register",
"outputs": [
{
"internalType": "bytes32",
"name": "",
"type": "bytes32"
}
],
"stateMutability": "nonpayable",
"type": "function"
}
];
var SignatureUtilsAbi = [
{
"inputs": [],
"name": "_DELEGATEDSELFATTEST_TYPEHASH",
"outputs": [
{
"internalType": "bytes32",
"name": "",
"type": "bytes32"
}
],
"stateMutability": "view",
"type": "function"
}
];
var CulturaRightAbi = [
{
"inputs": [
{
"internalType": "address",
"name": "defaultAdmin",
"type": "address"
},
{
"internalType": "address",
"name": "minter",
"type": "address"
},
{
"internalType": "address",
"name": "culturaTreasuryAddress",
"type": "address"
},
{
"internalType": "uint256",
"name": "culturaTreasurySplit",
"type": "uint256"
}
],
"stateMutability": "nonpayable",
"type": "constructor"
},
{
"inputs": [],
"name": "AccessControlBadConfirmation",
"type": "error"
},
{
"inputs": [
{
"internalType": "address",
"name": "account",
"type": "address"
},
{
"internalType": "bytes32",
"name": "neededRole",
"type": "bytes32"
}
],
"name": "AccessControlUnauthorizedAccount",
"type": "error"
},
{
"inputs": [],
"name": "ERC721EnumerableForbiddenBatchMint",
"type": "error"
},
{
"inputs": [
{
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"internalType": "uint256",
"name": "tokenId",
"type": "uint256"
},
{
"internalType": "address",
"name": "owner",
"type": "address"
}
],
"name": "ERC721IncorrectOwner",
"type": "error"
},
{
"inputs": [
{
"internalType": "address",
"name": "operator",
"type": "address"
},
{
"internalType": "uint256",
"name": "tokenId",
"type": "uint256"
}
],
"name": "ERC721InsufficientApproval",
"type": "error"
},
{
"inputs": [
{
"internalType": "address",
"name": "approver",
"type": "address"
}
],
"name": "ERC721InvalidApprover",
"type": "error"
},
{
"inputs": [
{
"internalType": "address",
"name": "operator",
"type": "address"
}
],
"name": "ERC721InvalidOperator",
"type": "error"
},
{
"inputs": [
{
"internalType": "address",
"name": "owner",
"type": "address"
}
],
"name": "ERC721InvalidOwner",
"type": "error"
},
{
"inputs": [
{
"internalType": "address",
"name": "receiver",
"type": "address"
}
],
"name": "ERC721InvalidReceiver",
"type": "error"
},
{
"inputs": [
{
"internalType": "address",
"name": "sender",
"type": "address"
}
],
"name": "ERC721InvalidSender",
"type": "error"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "tokenId",
"type": "uint256"
}
],
"name": "ERC721NonexistentToken",
"type": "error"
},
{
"inputs": [
{
"internalType": "address",
"name": "owner",
"type": "address"
},
{
"internalType": "uint256",
"name": "index",
"type": "uint256"
}
],
"name": "ERC721OutOfBoundsIndex",
"type": "error"
},
{
"inputs": [
{
"internalType": "address",
"name": "parentOwner",
"type": "address"
}
],
"name": "ParentOwnerMustBeRightsBoundAccount",
"type": "error"
},
{
"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": "uint256",
"name": "_fromTokenId",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "_toTokenId",
"type": "uint256"
}
],
"name": "BatchMetadataUpdate",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "uint256",
"name": "tokenId",
"type": "uint256"
},
{
"indexed": true,
"internalType": "address",
"name": "minter",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "owner",
"type": "address"
},
{
"indexed": false,
"internalType": "string",
"name": "digitalAssetName",
"type": "string"
},
{
"indexed": false,
"internalType": "string",
"name": "digitalAssetDescription",
"type": "string"
},
{
"components": [
{
"internalType": "address",
"name": "rightsBoundAccount",
"type": "address"
},
{
"internalType": "uint256",
"name": "royaltySplit",
"type": "uint256"
},
{
"internalType": "bytes32",
"name": "payeeType",
"type": "bytes32"
},
{
"components": [
{
"internalType": "address",
"name": "agentAddress",
"type": "address"
},
{
"internalType": "uint256",
"name": "agentAmountBps",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "agentFeeBps",
"type": "uint256"
}
],
"internalType": "struct ILicensed_ERC.AgentPlan[]",
"name": "agents",
"type": "tuple[]"
}
],
"indexed": false,
"internalType": "struct ILicensed_ERC.RoyaltyPayeesInfo[]",
"name": "royaltyPayeesInfo",
"type": "tuple[]"
},
{
"indexed": false,
"internalType": "string",
"name": "termsURI",
"type": "string"
},
{
"indexed": false,
"internalType": "bool",
"name": "isLicensed",
"type": "bool"
}
],
"name": "LicenseTokenMinted",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "uint256",
"name": "_tokenId",
"type": "uint256"
}
],
"name": "MetadataUpdate",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "bytes32",
"name": "role",
"type": "bytes32"
},
{
"indexed": true,
"internalType": "bytes32",
"name": "previousAdminRole",
"type": "bytes32"
},
{
"indexed": true,
"internalType": "bytes32",
"name": "newAdminRole",
"type": "bytes32"
}
],
"name": "RoleAdminChanged",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "bytes32",
"name": "role",
"type": "bytes32"
},
{
"indexed": true,
"internalType": "address",
"name": "account",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "sender",
"type": "address"
}
],
"name": "RoleGranted",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "bytes32",
"name": "role",
"type": "bytes32"
},
{
"indexed": true,
"internalType": "address",
"name": "account",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "sender",
"type": "address"
}
],
"name": "RoleRevoked",
"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"
},
{
"inputs": [],
"name": "DEFAULT_ADMIN_ROLE",
"outputs": [
{
"internalType": "bytes32",
"name": "",
"type": "bytes32"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "MINTER_ROLE",
"outputs": [
{
"internalType": "bytes32",
"name": "",
"type": "bytes32"
}
],
"stateMutability": "view",
"type": "function"
},
{
"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": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "culturaTreasury",
"outputs": [
{
"internalType": "address",
"name": "treasury",
"type": "address"
},
{
"internalType": "uint256",
"name": "treasurySplit",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "tokenId",
"type": "uint256"
}
],
"name": "getApproved",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "tokenId",
"type": "uint256"
}
],
"name": "getLicenseInfo",
"outputs": [
{
"components": [
{
"internalType": "string",