@story-protocol/core-sdk 1.0.0-rc.5 → 1.0.0-rc.6
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/declarations/src/abi/generated.d.ts +60 -60
- package/dist/declarations/src/client.d.ts +0 -1
- package/dist/declarations/src/client.d.ts.map +1 -1
- package/dist/declarations/src/resources/dispute.d.ts +2 -2
- package/dist/declarations/src/resources/ipAccount.d.ts +2 -2
- package/dist/declarations/src/resources/license.d.ts +5 -5
- package/dist/declarations/src/resources/permission.d.ts +1 -1
- package/dist/declarations/src/resources/royalty.d.ts +1 -1
- package/dist/declarations/src/types/config.d.ts +1 -1
- package/dist/declarations/src/types/config.d.ts.map +1 -1
- package/dist/story-protocol-core-sdk.cjs.dev.js +45 -146
- package/dist/story-protocol-core-sdk.cjs.prod.js +45 -146
- package/dist/story-protocol-core-sdk.esm.js +46 -144
- package/package.json +1 -1
@@ -5,9 +5,6 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
5
5
|
var viem = require('viem');
|
6
6
|
var dotenv = require('dotenv');
|
7
7
|
var chains = require('viem/chains');
|
8
|
-
var axios = require('axios');
|
9
|
-
|
10
|
-
function _interopDefault (e) { return e && e.__esModule ? e : { 'default': e }; }
|
11
8
|
|
12
9
|
function _interopNamespace(e) {
|
13
10
|
if (e && e.__esModule) return e;
|
@@ -28,7 +25,6 @@ function _interopNamespace(e) {
|
|
28
25
|
}
|
29
26
|
|
30
27
|
var dotenv__namespace = /*#__PURE__*/_interopNamespace(dotenv);
|
31
|
-
var axios__default = /*#__PURE__*/_interopDefault(axios);
|
32
28
|
|
33
29
|
function toPrimitive(t, r) {
|
34
30
|
if ("object" != typeof t || !t) return t;
|
@@ -515,47 +511,13 @@ function chainStringToViemChain(chainId) {
|
|
515
511
|
case "11155111":
|
516
512
|
case "sepolia":
|
517
513
|
return chains.sepolia;
|
518
|
-
case "1513":
|
519
|
-
case "storyTestnet":
|
520
|
-
return storyTestnet;
|
521
514
|
default:
|
522
515
|
throw new Error("chainId ".concat(chainId, " not supported"));
|
523
516
|
}
|
524
517
|
}
|
525
|
-
var storyTestnet = viem.defineChain({
|
526
|
-
id: 1513,
|
527
|
-
name: "story-network",
|
528
|
-
nativeCurrency: {
|
529
|
-
name: "Ether",
|
530
|
-
symbol: "SEP",
|
531
|
-
decimals: 18
|
532
|
-
},
|
533
|
-
rpcUrls: {
|
534
|
-
"default": {
|
535
|
-
http: ["https://story-network.rpc.caldera.xyz/http"],
|
536
|
-
webSocket: ["wss://story-network.rpc.caldera.xyz/ws"]
|
537
|
-
}
|
538
|
-
},
|
539
|
-
blockExplorers: {
|
540
|
-
"default": {
|
541
|
-
name: "Explorer",
|
542
|
-
url: "https://story-network.explorer.caldera.xyz"
|
543
|
-
}
|
544
|
-
},
|
545
|
-
//TODO: wait for Ze confirm with config information
|
546
|
-
contracts: {
|
547
|
-
multicall3: {
|
548
|
-
address: "0xcA11bde05977b3631167028862bE2a173976CA11",
|
549
|
-
blockCreated: 5882
|
550
|
-
}
|
551
|
-
},
|
552
|
-
testnet: true
|
553
|
-
});
|
554
518
|
var chain = {
|
555
519
|
sepolia: "11155111",
|
556
|
-
|
557
|
-
11155111: "11155111",
|
558
|
-
1513: "1513"
|
520
|
+
11155111: "11155111"
|
559
521
|
};
|
560
522
|
|
561
523
|
function handleError(error, msg) {
|
@@ -631,7 +593,7 @@ function _inherits(subClass, superClass) {
|
|
631
593
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
632
594
|
|
633
595
|
/**
|
634
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
596
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0xF9936a224b3Deb6f9A4645ccAfa66f7ECe83CF0A)
|
635
597
|
*/
|
636
598
|
var accessControllerAbi = [{
|
637
599
|
type: "constructor",
|
@@ -1134,10 +1096,10 @@ var accessControllerAbi = [{
|
|
1134
1096
|
}];
|
1135
1097
|
|
1136
1098
|
/**
|
1137
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
1099
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0xF9936a224b3Deb6f9A4645ccAfa66f7ECe83CF0A)
|
1138
1100
|
*/
|
1139
1101
|
var accessControllerAddress = {
|
1140
|
-
11155111: "
|
1102
|
+
11155111: "0xF9936a224b3Deb6f9A4645ccAfa66f7ECe83CF0A"
|
1141
1103
|
};
|
1142
1104
|
|
1143
1105
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
@@ -1145,7 +1107,7 @@ var accessControllerAddress = {
|
|
1145
1107
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
1146
1108
|
|
1147
1109
|
/**
|
1148
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
1110
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0xEB7B1dd43B81A7be1fA427515a2b173B454A9832)
|
1149
1111
|
*/
|
1150
1112
|
var disputeModuleAbi = [{
|
1151
1113
|
type: "constructor",
|
@@ -2067,10 +2029,10 @@ var disputeModuleAbi = [{
|
|
2067
2029
|
}];
|
2068
2030
|
|
2069
2031
|
/**
|
2070
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
2032
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0xEB7B1dd43B81A7be1fA427515a2b173B454A9832)
|
2071
2033
|
*/
|
2072
2034
|
var disputeModuleAddress = {
|
2073
|
-
11155111: "
|
2035
|
+
11155111: "0xEB7B1dd43B81A7be1fA427515a2b173B454A9832"
|
2074
2036
|
};
|
2075
2037
|
|
2076
2038
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
@@ -2078,7 +2040,7 @@ var disputeModuleAddress = {
|
|
2078
2040
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
2079
2041
|
|
2080
2042
|
/**
|
2081
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
2043
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0x36a5f0D61f6Bab3C6Dde211E5a6762Cb18a8060d)
|
2082
2044
|
*/
|
2083
2045
|
var ipAccountImplAbi = [{
|
2084
2046
|
type: "constructor",
|
@@ -2579,10 +2541,10 @@ var ipAccountImplAbi = [{
|
|
2579
2541
|
}];
|
2580
2542
|
|
2581
2543
|
/**
|
2582
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
2544
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0x36a5f0D61f6Bab3C6Dde211E5a6762Cb18a8060d)
|
2583
2545
|
*/
|
2584
2546
|
var ipAccountImplAddress = {
|
2585
|
-
11155111: "
|
2547
|
+
11155111: "0x36a5f0D61f6Bab3C6Dde211E5a6762Cb18a8060d"
|
2586
2548
|
};
|
2587
2549
|
|
2588
2550
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
@@ -2590,7 +2552,7 @@ var ipAccountImplAddress = {
|
|
2590
2552
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
2591
2553
|
|
2592
2554
|
/**
|
2593
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
2555
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0xd43fE0d865cb5C26b1351d3eAf2E3064BE3276F6)
|
2594
2556
|
*/
|
2595
2557
|
var ipAssetRegistryAbi = [{
|
2596
2558
|
type: "constructor",
|
@@ -3117,10 +3079,10 @@ var ipAssetRegistryAbi = [{
|
|
3117
3079
|
}];
|
3118
3080
|
|
3119
3081
|
/**
|
3120
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
3082
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0xd43fE0d865cb5C26b1351d3eAf2E3064BE3276F6)
|
3121
3083
|
*/
|
3122
3084
|
var ipAssetRegistryAddress = {
|
3123
|
-
11155111: "
|
3085
|
+
11155111: "0xd43fE0d865cb5C26b1351d3eAf2E3064BE3276F6"
|
3124
3086
|
};
|
3125
3087
|
|
3126
3088
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
@@ -3128,7 +3090,7 @@ var ipAssetRegistryAddress = {
|
|
3128
3090
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
3129
3091
|
|
3130
3092
|
/**
|
3131
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
3093
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0xD6c2AfB61085f1359d47159f2271BDD0EeBf19C2)
|
3132
3094
|
*/
|
3133
3095
|
var ipRoyaltyVaultImplAbi = [{
|
3134
3096
|
type: "constructor",
|
@@ -3756,10 +3718,10 @@ var ipRoyaltyVaultImplAbi = [{
|
|
3756
3718
|
}];
|
3757
3719
|
|
3758
3720
|
/**
|
3759
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
3721
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0xD6c2AfB61085f1359d47159f2271BDD0EeBf19C2)
|
3760
3722
|
*/
|
3761
3723
|
var ipRoyaltyVaultImplAddress = {
|
3762
|
-
11155111: "
|
3724
|
+
11155111: "0xD6c2AfB61085f1359d47159f2271BDD0EeBf19C2"
|
3763
3725
|
};
|
3764
3726
|
|
3765
3727
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
@@ -3767,7 +3729,7 @@ var ipRoyaltyVaultImplAddress = {
|
|
3767
3729
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
3768
3730
|
|
3769
3731
|
/**
|
3770
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
3732
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0x4f4b1bf7135C7ff1462826CCA81B048Ed19562ed)
|
3771
3733
|
*/
|
3772
3734
|
var licenseRegistryAbi = [{
|
3773
3735
|
type: "constructor",
|
@@ -4755,10 +4717,10 @@ var licenseRegistryAbi = [{
|
|
4755
4717
|
}];
|
4756
4718
|
|
4757
4719
|
/**
|
4758
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
4720
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0x4f4b1bf7135C7ff1462826CCA81B048Ed19562ed)
|
4759
4721
|
*/
|
4760
4722
|
var licenseRegistryAddress = {
|
4761
|
-
11155111: "
|
4723
|
+
11155111: "0x4f4b1bf7135C7ff1462826CCA81B048Ed19562ed"
|
4762
4724
|
};
|
4763
4725
|
|
4764
4726
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
@@ -4766,7 +4728,7 @@ var licenseRegistryAddress = {
|
|
4766
4728
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
4767
4729
|
|
4768
4730
|
/**
|
4769
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
4731
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0x1333c78A821c9a576209B01a16dDCEF881cAb6f2)
|
4770
4732
|
*/
|
4771
4733
|
var licenseTokenAbi = [{
|
4772
4734
|
type: "constructor",
|
@@ -5651,10 +5613,10 @@ var licenseTokenAbi = [{
|
|
5651
5613
|
}];
|
5652
5614
|
|
5653
5615
|
/**
|
5654
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
5616
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0x1333c78A821c9a576209B01a16dDCEF881cAb6f2)
|
5655
5617
|
*/
|
5656
5618
|
var licenseTokenAddress = {
|
5657
|
-
11155111: "
|
5619
|
+
11155111: "0x1333c78A821c9a576209B01a16dDCEF881cAb6f2"
|
5658
5620
|
};
|
5659
5621
|
|
5660
5622
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
@@ -5662,7 +5624,7 @@ var licenseTokenAddress = {
|
|
5662
5624
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
5663
5625
|
|
5664
5626
|
/**
|
5665
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
5627
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0xe89b0EaA8a0949738efA80bB531a165FB3456CBe)
|
5666
5628
|
*/
|
5667
5629
|
var licensingModuleAbi = [{
|
5668
5630
|
type: "constructor",
|
@@ -6404,10 +6366,10 @@ var licensingModuleAbi = [{
|
|
6404
6366
|
}];
|
6405
6367
|
|
6406
6368
|
/**
|
6407
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
6369
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0xe89b0EaA8a0949738efA80bB531a165FB3456CBe)
|
6408
6370
|
*/
|
6409
6371
|
var licensingModuleAddress = {
|
6410
|
-
11155111: "
|
6372
|
+
11155111: "0xe89b0EaA8a0949738efA80bB531a165FB3456CBe"
|
6411
6373
|
};
|
6412
6374
|
|
6413
6375
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
@@ -6415,7 +6377,7 @@ var licensingModuleAddress = {
|
|
6415
6377
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
6416
6378
|
|
6417
6379
|
/**
|
6418
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
6380
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0x260B6CB6284c89dbE660c0004233f7bB99B5edE7)
|
6419
6381
|
*/
|
6420
6382
|
var piLicenseTemplateAbi = [{
|
6421
6383
|
type: "constructor",
|
@@ -7348,10 +7310,10 @@ var piLicenseTemplateAbi = [{
|
|
7348
7310
|
}];
|
7349
7311
|
|
7350
7312
|
/**
|
7351
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
7313
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0x260B6CB6284c89dbE660c0004233f7bB99B5edE7)
|
7352
7314
|
*/
|
7353
7315
|
var piLicenseTemplateAddress = {
|
7354
|
-
11155111: "
|
7316
|
+
11155111: "0x260B6CB6284c89dbE660c0004233f7bB99B5edE7"
|
7355
7317
|
};
|
7356
7318
|
|
7357
7319
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
@@ -7359,7 +7321,7 @@ var piLicenseTemplateAddress = {
|
|
7359
7321
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
7360
7322
|
|
7361
7323
|
/**
|
7362
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
7324
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0xFAE961dd2b87CD5818dbCDc2591e6AB0b50E96b0)
|
7363
7325
|
*/
|
7364
7326
|
var royaltyModuleAbi = [{
|
7365
7327
|
type: "constructor",
|
@@ -7985,10 +7947,10 @@ var royaltyModuleAbi = [{
|
|
7985
7947
|
}];
|
7986
7948
|
|
7987
7949
|
/**
|
7988
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
7950
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0xFAE961dd2b87CD5818dbCDc2591e6AB0b50E96b0)
|
7989
7951
|
*/
|
7990
7952
|
var royaltyModuleAddress = {
|
7991
|
-
11155111: "
|
7953
|
+
11155111: "0xFAE961dd2b87CD5818dbCDc2591e6AB0b50E96b0"
|
7992
7954
|
};
|
7993
7955
|
|
7994
7956
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
@@ -7996,7 +7958,7 @@ var royaltyModuleAddress = {
|
|
7996
7958
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
7997
7959
|
|
7998
7960
|
/**
|
7999
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
7961
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0xAAbaf349C7a2A84564F9CC4Ac130B3f19A718E86)
|
8000
7962
|
*/
|
8001
7963
|
var royaltyPolicyLapAbi = [{
|
8002
7964
|
type: "constructor",
|
@@ -8550,10 +8512,10 @@ var royaltyPolicyLapAbi = [{
|
|
8550
8512
|
}];
|
8551
8513
|
|
8552
8514
|
/**
|
8553
|
-
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/
|
8515
|
+
* [__View Contract on Sepolia Etherscan__](https://sepolia.etherscan.io/address/0xAAbaf349C7a2A84564F9CC4Ac130B3f19A718E86)
|
8554
8516
|
*/
|
8555
8517
|
var royaltyPolicyLapAddress = {
|
8556
|
-
11155111: "
|
8518
|
+
11155111: "0xAAbaf349C7a2A84564F9CC4Ac130B3f19A718E86"
|
8557
8519
|
};
|
8558
8520
|
|
8559
8521
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
@@ -13945,7 +13907,7 @@ var PermissionClient = /*#__PURE__*/function () {
|
|
13945
13907
|
* address(0) => wildcard
|
13946
13908
|
* bytes4(0) => wildcard
|
13947
13909
|
* Specific permission overrides wildcard permission.
|
13948
|
-
* @param request The request object containing necessary data to set permissions.
|
13910
|
+
* @param request - The request object containing necessary data to set permissions.
|
13949
13911
|
* @param request.ipAsset The address of the IP account that grants the permission for `signer`
|
13950
13912
|
* @param request.signer The address that can call `to` on behalf of the `ipAccount`
|
13951
13913
|
* @param request.to The address that can be called by the `signer` (currently only modules can be `to`)
|
@@ -14038,7 +14000,7 @@ var LicenseClient = /*#__PURE__*/function () {
|
|
14038
14000
|
}
|
14039
14001
|
/**
|
14040
14002
|
* Convenient function to register a PIL non commercial social remix license to the registry
|
14041
|
-
* @param request [Optional] The request object that contains all data needed to register a PIL non commercial social remix license.
|
14003
|
+
* @param request - [Optional] The request object that contains all data needed to register a PIL non commercial social remix license.
|
14042
14004
|
* @param request.txOptions [Optional] The transaction options.
|
14043
14005
|
* @returns A Promise that resolves to an object containing the optional transaction hash and optional license terms Id.
|
14044
14006
|
* @emits LicenseTermsRegistered (licenseTermsId, licenseTemplate, licenseTerms);
|
@@ -14128,7 +14090,7 @@ var LicenseClient = /*#__PURE__*/function () {
|
|
14128
14090
|
}()
|
14129
14091
|
/**
|
14130
14092
|
* Convenient function to register a PIL commercial use license to the registry.
|
14131
|
-
* @param request The request object that contains all data needed to register a PIL commercial use license.
|
14093
|
+
* @param request - The request object that contains all data needed to register a PIL commercial use license.
|
14132
14094
|
* @param request.mintingFee The fee to be paid when minting a license.
|
14133
14095
|
* @param request.currency The ERC20 token to be used to pay the minting fee and the token must be registered in story protocol.
|
14134
14096
|
* @param request.royaltyPolicy The address of the royalty policy contract which required to StoryProtocol in advance.
|
@@ -14222,7 +14184,7 @@ var LicenseClient = /*#__PURE__*/function () {
|
|
14222
14184
|
}()
|
14223
14185
|
/**
|
14224
14186
|
* Convenient function to register a PIL commercial Remix license to the registry.
|
14225
|
-
* @param request The request object that contains all data needed to register license.
|
14187
|
+
* @param request - The request object that contains all data needed to register license.
|
14226
14188
|
* @param request.mintingFee The fee to be paid when minting a license.
|
14227
14189
|
* @param request.commercialRevShare Percentage of revenue that must be shared with the licensor.
|
14228
14190
|
* @param request.currency The ERC20 token to be used to pay the minting fee. the token must be registered in story protocol.
|
@@ -14317,7 +14279,7 @@ var LicenseClient = /*#__PURE__*/function () {
|
|
14317
14279
|
}()
|
14318
14280
|
/**
|
14319
14281
|
* Attaches license terms to an IP.
|
14320
|
-
* @param request The request object that contains all data needed to attach license terms.
|
14282
|
+
* @param request - The request object that contains all data needed to attach license terms.
|
14321
14283
|
* @param request.ipId The address of the IP to which the license terms are attached.
|
14322
14284
|
* @param request.licenseTemplate The address of the license template.
|
14323
14285
|
* @param request.licenseTermsId The ID of the license terms.
|
@@ -14426,7 +14388,7 @@ var LicenseClient = /*#__PURE__*/function () {
|
|
14426
14388
|
* The minting fee is paid in the minting fee token specified in the license terms or configured by the IP owner.
|
14427
14389
|
* IP owners can configure the minting fee of their IPs or
|
14428
14390
|
* configure the minting fee module to determine the minting fee.
|
14429
|
-
* @param request The request object that contains all data needed to mint license tokens.
|
14391
|
+
* @param request - The request object that contains all data needed to mint license tokens.
|
14430
14392
|
* @param request.licensorIpId The licensor IP ID.
|
14431
14393
|
* @param request.licenseTemplate The address of the license template.
|
14432
14394
|
* @param request.licenseTermsId The ID of the license terms within the license template.
|
@@ -14640,7 +14602,7 @@ var DisputeClient = /*#__PURE__*/function () {
|
|
14640
14602
|
}()
|
14641
14603
|
/**
|
14642
14604
|
* Cancels an ongoing dispute
|
14643
|
-
* @param request The request object containing details to cancel the dispute.
|
14605
|
+
* @param request - The request object containing details to cancel the dispute.
|
14644
14606
|
* @param request.disputeId The ID of the dispute to be cancelled.
|
14645
14607
|
* @param request.calldata Optional additional data used in the cancellation process.
|
14646
14608
|
* @returns A Promise that resolves to a CancelDisputeResponse containing the transaction hash.
|
@@ -14696,7 +14658,7 @@ var DisputeClient = /*#__PURE__*/function () {
|
|
14696
14658
|
}()
|
14697
14659
|
/**
|
14698
14660
|
* Resolves a dispute after it has been judged
|
14699
|
-
* @param request The request object containing details to resolve the dispute.
|
14661
|
+
* @param request - The request object containing details to resolve the dispute.
|
14700
14662
|
* @param request.disputeId The ID of the dispute to be resolved.
|
14701
14663
|
* @param request.data The data to resolve the dispute.
|
14702
14664
|
* @returns A Promise that resolves to a ResolveDisputeResponse.
|
@@ -14759,7 +14721,7 @@ var IPAccountClient = /*#__PURE__*/function () {
|
|
14759
14721
|
}
|
14760
14722
|
|
14761
14723
|
/** Executes a transaction from the IP Account.
|
14762
|
-
* @param request The request object containing necessary data to execute IP Account a transaction.
|
14724
|
+
* @param request - The request object containing necessary data to execute IP Account a transaction.
|
14763
14725
|
* @param request.to The recipient of the transaction.
|
14764
14726
|
* @param request.value The amount of Ether to send.
|
14765
14727
|
* @param request.data The data to send along with the transaction.
|
@@ -14811,7 +14773,7 @@ var IPAccountClient = /*#__PURE__*/function () {
|
|
14811
14773
|
return execute;
|
14812
14774
|
}()
|
14813
14775
|
/** Executes a transaction from the IP Account.
|
14814
|
-
* @param request The request object containing necessary data to execute IP Account a transaction.
|
14776
|
+
* @param request - The request object containing necessary data to execute IP Account a transaction.
|
14815
14777
|
* @param request.to The recipient of the transaction.
|
14816
14778
|
* @param request.value The amount of Ether to send.
|
14817
14779
|
* @param request.data The data to send along with the transaction.
|
@@ -14872,68 +14834,6 @@ var IPAccountClient = /*#__PURE__*/function () {
|
|
14872
14834
|
}]);
|
14873
14835
|
}();
|
14874
14836
|
|
14875
|
-
var StoryAPIClient = /*#__PURE__*/function () {
|
14876
|
-
function StoryAPIClient() {
|
14877
|
-
_classCallCheck(this, StoryAPIClient);
|
14878
|
-
this.httpClient = axios__default["default"].create({
|
14879
|
-
baseURL: "https://api.storyprotocol.net",
|
14880
|
-
timeout: 60000,
|
14881
|
-
headers: {
|
14882
|
-
"x-api-key": "U3RvcnlQcm90b2NvbFRlc3RBUElLRVk="
|
14883
|
-
}
|
14884
|
-
});
|
14885
|
-
}
|
14886
|
-
return _createClass(StoryAPIClient, [{
|
14887
|
-
key: "getRoyaltyPolicy",
|
14888
|
-
value: function () {
|
14889
|
-
var _getRoyaltyPolicy = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(ipId) {
|
14890
|
-
var royaltyPolicyResp;
|
14891
|
-
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
14892
|
-
while (1) switch (_context.prev = _context.next) {
|
14893
|
-
case 0:
|
14894
|
-
_context.next = 2;
|
14895
|
-
return this.httpClient.get("/api/v1/royalties/policies/".concat(ipId));
|
14896
|
-
case 2:
|
14897
|
-
royaltyPolicyResp = _context.sent;
|
14898
|
-
return _context.abrupt("return", royaltyPolicyResp.data.data);
|
14899
|
-
case 4:
|
14900
|
-
case "end":
|
14901
|
-
return _context.stop();
|
14902
|
-
}
|
14903
|
-
}, _callee, this);
|
14904
|
-
}));
|
14905
|
-
function getRoyaltyPolicy(_x) {
|
14906
|
-
return _getRoyaltyPolicy.apply(this, arguments);
|
14907
|
-
}
|
14908
|
-
return getRoyaltyPolicy;
|
14909
|
-
}()
|
14910
|
-
}, {
|
14911
|
-
key: "getLicense",
|
14912
|
-
value: function () {
|
14913
|
-
var _getLicense = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(licenseId) {
|
14914
|
-
var licenseResp;
|
14915
|
-
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
14916
|
-
while (1) switch (_context2.prev = _context2.next) {
|
14917
|
-
case 0:
|
14918
|
-
_context2.next = 2;
|
14919
|
-
return this.httpClient.get("/api/v1/licenses/".concat(licenseId));
|
14920
|
-
case 2:
|
14921
|
-
licenseResp = _context2.sent;
|
14922
|
-
return _context2.abrupt("return", licenseResp.data.data);
|
14923
|
-
case 4:
|
14924
|
-
case "end":
|
14925
|
-
return _context2.stop();
|
14926
|
-
}
|
14927
|
-
}, _callee2, this);
|
14928
|
-
}));
|
14929
|
-
function getLicense(_x2) {
|
14930
|
-
return _getLicense.apply(this, arguments);
|
14931
|
-
}
|
14932
|
-
return getLicense;
|
14933
|
-
}()
|
14934
|
-
}]);
|
14935
|
-
}();
|
14936
|
-
|
14937
14837
|
var RoyaltyClient = /*#__PURE__*/function () {
|
14938
14838
|
function RoyaltyClient(rpcClient, wallet) {
|
14939
14839
|
_classCallCheck(this, RoyaltyClient);
|
@@ -14947,7 +14847,7 @@ var RoyaltyClient = /*#__PURE__*/function () {
|
|
14947
14847
|
|
14948
14848
|
/**
|
14949
14849
|
* Allows ancestors to claim the royalty tokens and any accrued revenue tokens
|
14950
|
-
* @param request -
|
14850
|
+
* @param request - The request object that contains all data needed to collect royalty tokens.
|
14951
14851
|
* @param request.parentIpId The ip id of the ancestor to whom the royalty tokens belong to.
|
14952
14852
|
* @param request.royaltyVaultIpId The id of the royalty vault.
|
14953
14853
|
* @param request.txOptions [Optional] The transaction options.
|
@@ -15380,7 +15280,6 @@ var StoryClient = /*#__PURE__*/function () {
|
|
15380
15280
|
transport: this.config.transport
|
15381
15281
|
};
|
15382
15282
|
this.rpcClient = viem.createPublicClient(clientConfig);
|
15383
|
-
this.storyClient = new StoryAPIClient();
|
15384
15283
|
if (this.config.wallet) {
|
15385
15284
|
this.wallet = this.config.wallet;
|
15386
15285
|
} else if (this.config.account) {
|