@farcaster/hub-web 0.5.0 → 0.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +1295 -618
- package/dist/index.js +726 -345
- package/dist/index.mjs +729 -349
- package/package.json +2 -2
package/dist/index.js
CHANGED
@@ -2646,8 +2646,7 @@ __export(src_exports, {
|
|
2646
2646
|
AdminServiceRebuildSyncTrieDesc: () => AdminServiceRebuildSyncTrieDesc,
|
2647
2647
|
AdminServiceSubmitIdRegistryEventDesc: () => AdminServiceSubmitIdRegistryEventDesc,
|
2648
2648
|
AdminServiceSubmitNameRegistryEventDesc: () => AdminServiceSubmitNameRegistryEventDesc,
|
2649
|
-
|
2650
|
-
AdminServiceSubmitStorageAdminRegistryEventDesc: () => AdminServiceSubmitStorageAdminRegistryEventDesc,
|
2649
|
+
AdminServiceSubmitOnChainEventDesc: () => AdminServiceSubmitOnChainEventDesc,
|
2651
2650
|
GrpcWebError: () => GrpcWebError,
|
2652
2651
|
GrpcWebImpl: () => GrpcWebImpl,
|
2653
2652
|
HubServiceClientImpl: () => HubServiceClientImpl,
|
@@ -2664,6 +2663,7 @@ __export(src_exports, {
|
|
2664
2663
|
HubServiceGetCastsByFidDesc: () => HubServiceGetCastsByFidDesc,
|
2665
2664
|
HubServiceGetCastsByMentionDesc: () => HubServiceGetCastsByMentionDesc,
|
2666
2665
|
HubServiceGetCastsByParentDesc: () => HubServiceGetCastsByParentDesc,
|
2666
|
+
HubServiceGetCurrentStorageLimitsByFidDesc: () => HubServiceGetCurrentStorageLimitsByFidDesc,
|
2667
2667
|
HubServiceGetEventDesc: () => HubServiceGetEventDesc,
|
2668
2668
|
HubServiceGetFidsDesc: () => HubServiceGetFidsDesc,
|
2669
2669
|
HubServiceGetIdRegistryEventByAddressDesc: () => HubServiceGetIdRegistryEventByAddressDesc,
|
@@ -2673,11 +2673,12 @@ __export(src_exports, {
|
|
2673
2673
|
HubServiceGetLinksByFidDesc: () => HubServiceGetLinksByFidDesc,
|
2674
2674
|
HubServiceGetLinksByTargetDesc: () => HubServiceGetLinksByTargetDesc,
|
2675
2675
|
HubServiceGetNameRegistryEventDesc: () => HubServiceGetNameRegistryEventDesc,
|
2676
|
+
HubServiceGetOnChainEventsDesc: () => HubServiceGetOnChainEventsDesc,
|
2677
|
+
HubServiceGetOnChainSignerDesc: () => HubServiceGetOnChainSignerDesc,
|
2676
2678
|
HubServiceGetReactionDesc: () => HubServiceGetReactionDesc,
|
2677
2679
|
HubServiceGetReactionsByCastDesc: () => HubServiceGetReactionsByCastDesc,
|
2678
2680
|
HubServiceGetReactionsByFidDesc: () => HubServiceGetReactionsByFidDesc,
|
2679
2681
|
HubServiceGetReactionsByTargetDesc: () => HubServiceGetReactionsByTargetDesc,
|
2680
|
-
HubServiceGetRentRegistryEventsDesc: () => HubServiceGetRentRegistryEventsDesc,
|
2681
2682
|
HubServiceGetSignerDesc: () => HubServiceGetSignerDesc,
|
2682
2683
|
HubServiceGetSignersByFidDesc: () => HubServiceGetSignersByFidDesc,
|
2683
2684
|
HubServiceGetSyncMetadataByPrefixDesc: () => HubServiceGetSyncMetadataByPrefixDesc,
|
@@ -2702,7 +2703,7 @@ __reExport(src_exports, require("@farcaster/core"), module.exports);
|
|
2702
2703
|
|
2703
2704
|
// src/generated/rpc.ts
|
2704
2705
|
init_cjs_shims();
|
2705
|
-
var import_grpc_web = require("@improbable-eng/grpc-web");
|
2706
|
+
var import_grpc_web = __toESM(require("@improbable-eng/grpc-web"));
|
2706
2707
|
var import_browser_headers = __toESM(require_browser_headers());
|
2707
2708
|
var import_rxjs = require("rxjs");
|
2708
2709
|
var import_operators = require("rxjs/operators");
|
@@ -4789,100 +4790,171 @@ function isSet4(value) {
|
|
4789
4790
|
return value !== null && value !== void 0;
|
4790
4791
|
}
|
4791
4792
|
|
4792
|
-
// src/generated/
|
4793
|
+
// src/generated/onchain_event.ts
|
4793
4794
|
init_cjs_shims();
|
4794
4795
|
var import_long4 = __toESM(require_long());
|
4795
4796
|
var import_minimal5 = __toESM(require_minimal2());
|
4796
|
-
function
|
4797
|
+
function onChainEventTypeFromJSON(object) {
|
4797
4798
|
switch (object) {
|
4798
4799
|
case 0:
|
4799
|
-
case "
|
4800
|
-
return 0 /*
|
4800
|
+
case "EVENT_TYPE_NONE":
|
4801
|
+
return 0 /* EVENT_TYPE_NONE */;
|
4801
4802
|
case 1:
|
4802
|
-
case "
|
4803
|
-
return 1 /*
|
4803
|
+
case "EVENT_TYPE_SIGNER":
|
4804
|
+
return 1 /* EVENT_TYPE_SIGNER */;
|
4804
4805
|
case 2:
|
4805
|
-
case "
|
4806
|
-
return 2 /*
|
4806
|
+
case "EVENT_TYPE_SIGNER_MIGRATED":
|
4807
|
+
return 2 /* EVENT_TYPE_SIGNER_MIGRATED */;
|
4807
4808
|
case 3:
|
4808
|
-
case "
|
4809
|
-
return 3 /*
|
4809
|
+
case "EVENT_TYPE_ID_REGISTER":
|
4810
|
+
return 3 /* EVENT_TYPE_ID_REGISTER */;
|
4810
4811
|
case 4:
|
4811
|
-
case "
|
4812
|
-
return 4 /*
|
4813
|
-
|
4814
|
-
|
4815
|
-
|
4812
|
+
case "EVENT_TYPE_STORAGE_RENT":
|
4813
|
+
return 4 /* EVENT_TYPE_STORAGE_RENT */;
|
4814
|
+
default:
|
4815
|
+
throw new tsProtoGlobalThis5.Error("Unrecognized enum value " + object + " for enum OnChainEventType");
|
4816
|
+
}
|
4817
|
+
}
|
4818
|
+
function onChainEventTypeToJSON(object) {
|
4819
|
+
switch (object) {
|
4820
|
+
case 0 /* EVENT_TYPE_NONE */:
|
4821
|
+
return "EVENT_TYPE_NONE";
|
4822
|
+
case 1 /* EVENT_TYPE_SIGNER */:
|
4823
|
+
return "EVENT_TYPE_SIGNER";
|
4824
|
+
case 2 /* EVENT_TYPE_SIGNER_MIGRATED */:
|
4825
|
+
return "EVENT_TYPE_SIGNER_MIGRATED";
|
4826
|
+
case 3 /* EVENT_TYPE_ID_REGISTER */:
|
4827
|
+
return "EVENT_TYPE_ID_REGISTER";
|
4828
|
+
case 4 /* EVENT_TYPE_STORAGE_RENT */:
|
4829
|
+
return "EVENT_TYPE_STORAGE_RENT";
|
4830
|
+
default:
|
4831
|
+
throw new tsProtoGlobalThis5.Error("Unrecognized enum value " + object + " for enum OnChainEventType");
|
4832
|
+
}
|
4833
|
+
}
|
4834
|
+
function signerEventTypeFromJSON(object) {
|
4835
|
+
switch (object) {
|
4836
|
+
case 0:
|
4837
|
+
case "SIGNER_EVENT_TYPE_NONE":
|
4838
|
+
return 0 /* NONE */;
|
4839
|
+
case 1:
|
4840
|
+
case "SIGNER_EVENT_TYPE_ADD":
|
4841
|
+
return 1 /* ADD */;
|
4842
|
+
case 2:
|
4843
|
+
case "SIGNER_EVENT_TYPE_REMOVE":
|
4844
|
+
return 2 /* REMOVE */;
|
4845
|
+
case 3:
|
4846
|
+
case "SIGNER_EVENT_TYPE_ADMIN_RESET":
|
4847
|
+
return 3 /* ADMIN_RESET */;
|
4848
|
+
default:
|
4849
|
+
throw new tsProtoGlobalThis5.Error("Unrecognized enum value " + object + " for enum SignerEventType");
|
4850
|
+
}
|
4851
|
+
}
|
4852
|
+
function signerEventTypeToJSON(object) {
|
4853
|
+
switch (object) {
|
4854
|
+
case 0 /* NONE */:
|
4855
|
+
return "SIGNER_EVENT_TYPE_NONE";
|
4856
|
+
case 1 /* ADD */:
|
4857
|
+
return "SIGNER_EVENT_TYPE_ADD";
|
4858
|
+
case 2 /* REMOVE */:
|
4859
|
+
return "SIGNER_EVENT_TYPE_REMOVE";
|
4860
|
+
case 3 /* ADMIN_RESET */:
|
4861
|
+
return "SIGNER_EVENT_TYPE_ADMIN_RESET";
|
4816
4862
|
default:
|
4817
|
-
throw new tsProtoGlobalThis5.Error("Unrecognized enum value " + object + " for enum
|
4863
|
+
throw new tsProtoGlobalThis5.Error("Unrecognized enum value " + object + " for enum SignerEventType");
|
4818
4864
|
}
|
4819
4865
|
}
|
4820
|
-
function
|
4866
|
+
function idRegisterEventTypeFromJSON(object) {
|
4867
|
+
switch (object) {
|
4868
|
+
case 0:
|
4869
|
+
case "ID_REGISTER_EVENT_TYPE_NONE":
|
4870
|
+
return 0 /* NONE */;
|
4871
|
+
case 1:
|
4872
|
+
case "ID_REGISTER_EVENT_TYPE_REGISTER":
|
4873
|
+
return 1 /* REGISTER */;
|
4874
|
+
case 2:
|
4875
|
+
case "ID_REGISTER_EVENT_TYPE_TRANSFER":
|
4876
|
+
return 2 /* TRANSFER */;
|
4877
|
+
case 3:
|
4878
|
+
case "ID_REGISTER_EVENT_TYPE_CHANGE_RECOVERY":
|
4879
|
+
return 3 /* CHANGE_RECOVERY */;
|
4880
|
+
default:
|
4881
|
+
throw new tsProtoGlobalThis5.Error("Unrecognized enum value " + object + " for enum IdRegisterEventType");
|
4882
|
+
}
|
4883
|
+
}
|
4884
|
+
function idRegisterEventTypeToJSON(object) {
|
4821
4885
|
switch (object) {
|
4822
4886
|
case 0 /* NONE */:
|
4823
|
-
return "
|
4824
|
-
case 1 /*
|
4825
|
-
return "
|
4826
|
-
case 2 /*
|
4827
|
-
return "
|
4828
|
-
case 3 /*
|
4829
|
-
return "
|
4830
|
-
case 4 /* SET_DEPRECATION_TIMESTAMP */:
|
4831
|
-
return "STORAGE_REGISTRY_EVENT_TYPE_SET_DEPRECATION_TIMESTAMP";
|
4832
|
-
case 5 /* SET_GRACE_PERIOD */:
|
4833
|
-
return "STORAGE_REGISTRY_EVENT_TYPE_SET_GRACE_PERIOD";
|
4887
|
+
return "ID_REGISTER_EVENT_TYPE_NONE";
|
4888
|
+
case 1 /* REGISTER */:
|
4889
|
+
return "ID_REGISTER_EVENT_TYPE_REGISTER";
|
4890
|
+
case 2 /* TRANSFER */:
|
4891
|
+
return "ID_REGISTER_EVENT_TYPE_TRANSFER";
|
4892
|
+
case 3 /* CHANGE_RECOVERY */:
|
4893
|
+
return "ID_REGISTER_EVENT_TYPE_CHANGE_RECOVERY";
|
4834
4894
|
default:
|
4835
|
-
throw new tsProtoGlobalThis5.Error("Unrecognized enum value " + object + " for enum
|
4895
|
+
throw new tsProtoGlobalThis5.Error("Unrecognized enum value " + object + " for enum IdRegisterEventType");
|
4836
4896
|
}
|
4837
4897
|
}
|
4838
|
-
function
|
4898
|
+
function createBaseOnChainEvent() {
|
4839
4899
|
return {
|
4900
|
+
type: 0,
|
4901
|
+
chainId: 0,
|
4840
4902
|
blockNumber: 0,
|
4841
4903
|
blockHash: new Uint8Array(),
|
4904
|
+
blockTimestamp: 0,
|
4842
4905
|
transactionHash: new Uint8Array(),
|
4843
4906
|
logIndex: 0,
|
4844
|
-
payer: new Uint8Array(),
|
4845
4907
|
fid: 0,
|
4846
|
-
|
4847
|
-
|
4848
|
-
|
4908
|
+
signerEventBody: void 0,
|
4909
|
+
signerMigratedEventBody: void 0,
|
4910
|
+
idRegisterEventBody: void 0,
|
4911
|
+
storageRentEventBody: void 0
|
4849
4912
|
};
|
4850
4913
|
}
|
4851
|
-
var
|
4914
|
+
var OnChainEvent = {
|
4852
4915
|
encode(message, writer = import_minimal5.default.Writer.create()) {
|
4916
|
+
if (message.type !== 0) {
|
4917
|
+
writer.uint32(8).int32(message.type);
|
4918
|
+
}
|
4919
|
+
if (message.chainId !== 0) {
|
4920
|
+
writer.uint32(16).uint32(message.chainId);
|
4921
|
+
}
|
4853
4922
|
if (message.blockNumber !== 0) {
|
4854
|
-
writer.uint32(
|
4923
|
+
writer.uint32(24).uint32(message.blockNumber);
|
4855
4924
|
}
|
4856
4925
|
if (message.blockHash.length !== 0) {
|
4857
|
-
writer.uint32(
|
4926
|
+
writer.uint32(34).bytes(message.blockHash);
|
4927
|
+
}
|
4928
|
+
if (message.blockTimestamp !== 0) {
|
4929
|
+
writer.uint32(40).uint64(message.blockTimestamp);
|
4858
4930
|
}
|
4859
4931
|
if (message.transactionHash.length !== 0) {
|
4860
|
-
writer.uint32(
|
4932
|
+
writer.uint32(50).bytes(message.transactionHash);
|
4861
4933
|
}
|
4862
4934
|
if (message.logIndex !== 0) {
|
4863
|
-
writer.uint32(
|
4864
|
-
}
|
4865
|
-
if (message.payer.length !== 0) {
|
4866
|
-
writer.uint32(42).bytes(message.payer);
|
4935
|
+
writer.uint32(56).uint32(message.logIndex);
|
4867
4936
|
}
|
4868
4937
|
if (message.fid !== 0) {
|
4869
|
-
writer.uint32(
|
4938
|
+
writer.uint32(64).uint64(message.fid);
|
4870
4939
|
}
|
4871
|
-
if (message.
|
4872
|
-
writer.uint32(
|
4940
|
+
if (message.signerEventBody !== void 0) {
|
4941
|
+
SignerEventBody.encode(message.signerEventBody, writer.uint32(74).fork()).ldelim();
|
4873
4942
|
}
|
4874
|
-
if (message.
|
4875
|
-
writer.uint32(
|
4943
|
+
if (message.signerMigratedEventBody !== void 0) {
|
4944
|
+
SignerMigratedEventBody.encode(message.signerMigratedEventBody, writer.uint32(82).fork()).ldelim();
|
4876
4945
|
}
|
4877
|
-
if (message.
|
4878
|
-
writer.uint32(
|
4946
|
+
if (message.idRegisterEventBody !== void 0) {
|
4947
|
+
IdRegisterEventBody.encode(message.idRegisterEventBody, writer.uint32(90).fork()).ldelim();
|
4948
|
+
}
|
4949
|
+
if (message.storageRentEventBody !== void 0) {
|
4950
|
+
StorageRentEventBody.encode(message.storageRentEventBody, writer.uint32(98).fork()).ldelim();
|
4879
4951
|
}
|
4880
4952
|
return writer;
|
4881
4953
|
},
|
4882
4954
|
decode(input, length) {
|
4883
4955
|
const reader = input instanceof import_minimal5.default.Reader ? input : import_minimal5.default.Reader.create(input);
|
4884
4956
|
let end = length === void 0 ? reader.len : reader.pos + length;
|
4885
|
-
const message =
|
4957
|
+
const message = createBaseOnChainEvent();
|
4886
4958
|
while (reader.pos < end) {
|
4887
4959
|
const tag = reader.uint32();
|
4888
4960
|
switch (tag >>> 3) {
|
@@ -4890,55 +4962,73 @@ var RentRegistryEvent = {
|
|
4890
4962
|
if (tag != 8) {
|
4891
4963
|
break;
|
4892
4964
|
}
|
4893
|
-
message.
|
4965
|
+
message.type = reader.int32();
|
4894
4966
|
continue;
|
4895
4967
|
case 2:
|
4896
|
-
if (tag !=
|
4968
|
+
if (tag != 16) {
|
4897
4969
|
break;
|
4898
4970
|
}
|
4899
|
-
message.
|
4971
|
+
message.chainId = reader.uint32();
|
4900
4972
|
continue;
|
4901
4973
|
case 3:
|
4902
|
-
if (tag !=
|
4974
|
+
if (tag != 24) {
|
4903
4975
|
break;
|
4904
4976
|
}
|
4905
|
-
message.
|
4977
|
+
message.blockNumber = reader.uint32();
|
4906
4978
|
continue;
|
4907
4979
|
case 4:
|
4908
|
-
if (tag !=
|
4980
|
+
if (tag != 34) {
|
4909
4981
|
break;
|
4910
4982
|
}
|
4911
|
-
message.
|
4983
|
+
message.blockHash = reader.bytes();
|
4912
4984
|
continue;
|
4913
4985
|
case 5:
|
4914
|
-
if (tag !=
|
4986
|
+
if (tag != 40) {
|
4915
4987
|
break;
|
4916
4988
|
}
|
4917
|
-
message.
|
4989
|
+
message.blockTimestamp = longToNumber4(reader.uint64());
|
4918
4990
|
continue;
|
4919
4991
|
case 6:
|
4920
|
-
if (tag !=
|
4992
|
+
if (tag != 50) {
|
4921
4993
|
break;
|
4922
4994
|
}
|
4923
|
-
message.
|
4995
|
+
message.transactionHash = reader.bytes();
|
4924
4996
|
continue;
|
4925
4997
|
case 7:
|
4926
4998
|
if (tag != 56) {
|
4927
4999
|
break;
|
4928
5000
|
}
|
4929
|
-
message.
|
5001
|
+
message.logIndex = reader.uint32();
|
4930
5002
|
continue;
|
4931
5003
|
case 8:
|
4932
5004
|
if (tag != 64) {
|
4933
5005
|
break;
|
4934
5006
|
}
|
4935
|
-
message.
|
5007
|
+
message.fid = longToNumber4(reader.uint64());
|
4936
5008
|
continue;
|
4937
5009
|
case 9:
|
4938
|
-
if (tag !=
|
5010
|
+
if (tag != 74) {
|
4939
5011
|
break;
|
4940
5012
|
}
|
4941
|
-
message.
|
5013
|
+
message.signerEventBody = SignerEventBody.decode(reader, reader.uint32());
|
5014
|
+
continue;
|
5015
|
+
case 10:
|
5016
|
+
if (tag != 82) {
|
5017
|
+
break;
|
5018
|
+
}
|
5019
|
+
message.signerMigratedEventBody = SignerMigratedEventBody.decode(reader, reader.uint32());
|
5020
|
+
continue;
|
5021
|
+
case 11:
|
5022
|
+
if (tag != 90) {
|
5023
|
+
break;
|
5024
|
+
}
|
5025
|
+
message.idRegisterEventBody = IdRegisterEventBody.decode(reader, reader.uint32());
|
5026
|
+
continue;
|
5027
|
+
case 12:
|
5028
|
+
if (tag != 98) {
|
5029
|
+
break;
|
5030
|
+
}
|
5031
|
+
message.storageRentEventBody = StorageRentEventBody.decode(reader, reader.uint32());
|
4942
5032
|
continue;
|
4943
5033
|
}
|
4944
5034
|
if ((tag & 7) == 4 || tag == 0) {
|
@@ -4950,144 +5040,244 @@ var RentRegistryEvent = {
|
|
4950
5040
|
},
|
4951
5041
|
fromJSON(object) {
|
4952
5042
|
return {
|
5043
|
+
type: isSet5(object.type) ? onChainEventTypeFromJSON(object.type) : 0,
|
5044
|
+
chainId: isSet5(object.chainId) ? Number(object.chainId) : 0,
|
4953
5045
|
blockNumber: isSet5(object.blockNumber) ? Number(object.blockNumber) : 0,
|
4954
5046
|
blockHash: isSet5(object.blockHash) ? bytesFromBase645(object.blockHash) : new Uint8Array(),
|
5047
|
+
blockTimestamp: isSet5(object.blockTimestamp) ? Number(object.blockTimestamp) : 0,
|
4955
5048
|
transactionHash: isSet5(object.transactionHash) ? bytesFromBase645(object.transactionHash) : new Uint8Array(),
|
4956
5049
|
logIndex: isSet5(object.logIndex) ? Number(object.logIndex) : 0,
|
4957
|
-
payer: isSet5(object.payer) ? bytesFromBase645(object.payer) : new Uint8Array(),
|
4958
5050
|
fid: isSet5(object.fid) ? Number(object.fid) : 0,
|
4959
|
-
|
4960
|
-
|
4961
|
-
|
5051
|
+
signerEventBody: isSet5(object.signerEventBody) ? SignerEventBody.fromJSON(object.signerEventBody) : void 0,
|
5052
|
+
signerMigratedEventBody: isSet5(object.signerMigratedEventBody) ? SignerMigratedEventBody.fromJSON(object.signerMigratedEventBody) : void 0,
|
5053
|
+
idRegisterEventBody: isSet5(object.idRegisterEventBody) ? IdRegisterEventBody.fromJSON(object.idRegisterEventBody) : void 0,
|
5054
|
+
storageRentEventBody: isSet5(object.storageRentEventBody) ? StorageRentEventBody.fromJSON(object.storageRentEventBody) : void 0
|
4962
5055
|
};
|
4963
5056
|
},
|
4964
5057
|
toJSON(message) {
|
4965
5058
|
const obj = {};
|
5059
|
+
message.type !== void 0 && (obj.type = onChainEventTypeToJSON(message.type));
|
5060
|
+
message.chainId !== void 0 && (obj.chainId = Math.round(message.chainId));
|
4966
5061
|
message.blockNumber !== void 0 && (obj.blockNumber = Math.round(message.blockNumber));
|
4967
5062
|
message.blockHash !== void 0 && (obj.blockHash = base64FromBytes5(message.blockHash !== void 0 ? message.blockHash : new Uint8Array()));
|
5063
|
+
message.blockTimestamp !== void 0 && (obj.blockTimestamp = Math.round(message.blockTimestamp));
|
4968
5064
|
message.transactionHash !== void 0 && (obj.transactionHash = base64FromBytes5(
|
4969
5065
|
message.transactionHash !== void 0 ? message.transactionHash : new Uint8Array()
|
4970
5066
|
));
|
4971
5067
|
message.logIndex !== void 0 && (obj.logIndex = Math.round(message.logIndex));
|
4972
|
-
message.payer !== void 0 && (obj.payer = base64FromBytes5(message.payer !== void 0 ? message.payer : new Uint8Array()));
|
4973
5068
|
message.fid !== void 0 && (obj.fid = Math.round(message.fid));
|
4974
|
-
message.
|
4975
|
-
message.
|
4976
|
-
message.
|
5069
|
+
message.signerEventBody !== void 0 && (obj.signerEventBody = message.signerEventBody ? SignerEventBody.toJSON(message.signerEventBody) : void 0);
|
5070
|
+
message.signerMigratedEventBody !== void 0 && (obj.signerMigratedEventBody = message.signerMigratedEventBody ? SignerMigratedEventBody.toJSON(message.signerMigratedEventBody) : void 0);
|
5071
|
+
message.idRegisterEventBody !== void 0 && (obj.idRegisterEventBody = message.idRegisterEventBody ? IdRegisterEventBody.toJSON(message.idRegisterEventBody) : void 0);
|
5072
|
+
message.storageRentEventBody !== void 0 && (obj.storageRentEventBody = message.storageRentEventBody ? StorageRentEventBody.toJSON(message.storageRentEventBody) : void 0);
|
4977
5073
|
return obj;
|
4978
5074
|
},
|
4979
5075
|
create(base) {
|
4980
|
-
return
|
5076
|
+
return OnChainEvent.fromPartial(base != null ? base : {});
|
4981
5077
|
},
|
4982
5078
|
fromPartial(object) {
|
4983
|
-
var _a, _b, _c, _d, _e, _f, _g, _h
|
4984
|
-
const message =
|
4985
|
-
message.
|
4986
|
-
message.
|
4987
|
-
message.
|
4988
|
-
message.
|
4989
|
-
message.
|
4990
|
-
message.
|
4991
|
-
message.
|
4992
|
-
message.
|
4993
|
-
message.
|
5079
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
5080
|
+
const message = createBaseOnChainEvent();
|
5081
|
+
message.type = (_a = object.type) != null ? _a : 0;
|
5082
|
+
message.chainId = (_b = object.chainId) != null ? _b : 0;
|
5083
|
+
message.blockNumber = (_c = object.blockNumber) != null ? _c : 0;
|
5084
|
+
message.blockHash = (_d = object.blockHash) != null ? _d : new Uint8Array();
|
5085
|
+
message.blockTimestamp = (_e = object.blockTimestamp) != null ? _e : 0;
|
5086
|
+
message.transactionHash = (_f = object.transactionHash) != null ? _f : new Uint8Array();
|
5087
|
+
message.logIndex = (_g = object.logIndex) != null ? _g : 0;
|
5088
|
+
message.fid = (_h = object.fid) != null ? _h : 0;
|
5089
|
+
message.signerEventBody = object.signerEventBody !== void 0 && object.signerEventBody !== null ? SignerEventBody.fromPartial(object.signerEventBody) : void 0;
|
5090
|
+
message.signerMigratedEventBody = object.signerMigratedEventBody !== void 0 && object.signerMigratedEventBody !== null ? SignerMigratedEventBody.fromPartial(object.signerMigratedEventBody) : void 0;
|
5091
|
+
message.idRegisterEventBody = object.idRegisterEventBody !== void 0 && object.idRegisterEventBody !== null ? IdRegisterEventBody.fromPartial(object.idRegisterEventBody) : void 0;
|
5092
|
+
message.storageRentEventBody = object.storageRentEventBody !== void 0 && object.storageRentEventBody !== null ? StorageRentEventBody.fromPartial(object.storageRentEventBody) : void 0;
|
4994
5093
|
return message;
|
4995
5094
|
}
|
4996
5095
|
};
|
4997
|
-
function
|
4998
|
-
return {
|
4999
|
-
blockNumber: 0,
|
5000
|
-
blockHash: new Uint8Array(),
|
5001
|
-
transactionHash: new Uint8Array(),
|
5002
|
-
logIndex: 0,
|
5003
|
-
timestamp: 0,
|
5004
|
-
from: new Uint8Array(),
|
5005
|
-
type: 0,
|
5006
|
-
value: new Uint8Array()
|
5007
|
-
};
|
5096
|
+
function createBaseSignerEventBody() {
|
5097
|
+
return { key: new Uint8Array(), scheme: 0, eventType: 0, metadata: new Uint8Array() };
|
5008
5098
|
}
|
5009
|
-
var
|
5099
|
+
var SignerEventBody = {
|
5010
5100
|
encode(message, writer = import_minimal5.default.Writer.create()) {
|
5011
|
-
if (message.
|
5012
|
-
writer.uint32(
|
5013
|
-
}
|
5014
|
-
if (message.blockHash.length !== 0) {
|
5015
|
-
writer.uint32(18).bytes(message.blockHash);
|
5016
|
-
}
|
5017
|
-
if (message.transactionHash.length !== 0) {
|
5018
|
-
writer.uint32(26).bytes(message.transactionHash);
|
5019
|
-
}
|
5020
|
-
if (message.logIndex !== 0) {
|
5021
|
-
writer.uint32(32).uint32(message.logIndex);
|
5101
|
+
if (message.key.length !== 0) {
|
5102
|
+
writer.uint32(10).bytes(message.key);
|
5022
5103
|
}
|
5023
|
-
if (message.
|
5024
|
-
writer.uint32(
|
5025
|
-
}
|
5026
|
-
if (message.from.length !== 0) {
|
5027
|
-
writer.uint32(50).bytes(message.from);
|
5104
|
+
if (message.scheme !== 0) {
|
5105
|
+
writer.uint32(16).uint32(message.scheme);
|
5028
5106
|
}
|
5029
|
-
if (message.
|
5030
|
-
writer.uint32(
|
5107
|
+
if (message.eventType !== 0) {
|
5108
|
+
writer.uint32(24).int32(message.eventType);
|
5031
5109
|
}
|
5032
|
-
if (message.
|
5033
|
-
writer.uint32(
|
5110
|
+
if (message.metadata.length !== 0) {
|
5111
|
+
writer.uint32(34).bytes(message.metadata);
|
5034
5112
|
}
|
5035
5113
|
return writer;
|
5036
5114
|
},
|
5037
5115
|
decode(input, length) {
|
5038
5116
|
const reader = input instanceof import_minimal5.default.Reader ? input : import_minimal5.default.Reader.create(input);
|
5039
5117
|
let end = length === void 0 ? reader.len : reader.pos + length;
|
5040
|
-
const message =
|
5118
|
+
const message = createBaseSignerEventBody();
|
5041
5119
|
while (reader.pos < end) {
|
5042
5120
|
const tag = reader.uint32();
|
5043
5121
|
switch (tag >>> 3) {
|
5044
5122
|
case 1:
|
5045
|
-
if (tag !=
|
5123
|
+
if (tag != 10) {
|
5046
5124
|
break;
|
5047
5125
|
}
|
5048
|
-
message.
|
5126
|
+
message.key = reader.bytes();
|
5049
5127
|
continue;
|
5050
5128
|
case 2:
|
5051
|
-
if (tag !=
|
5129
|
+
if (tag != 16) {
|
5052
5130
|
break;
|
5053
5131
|
}
|
5054
|
-
message.
|
5132
|
+
message.scheme = reader.uint32();
|
5055
5133
|
continue;
|
5056
5134
|
case 3:
|
5057
|
-
if (tag !=
|
5135
|
+
if (tag != 24) {
|
5058
5136
|
break;
|
5059
5137
|
}
|
5060
|
-
message.
|
5138
|
+
message.eventType = reader.int32();
|
5061
5139
|
continue;
|
5062
5140
|
case 4:
|
5063
|
-
if (tag !=
|
5141
|
+
if (tag != 34) {
|
5064
5142
|
break;
|
5065
5143
|
}
|
5066
|
-
message.
|
5144
|
+
message.metadata = reader.bytes();
|
5067
5145
|
continue;
|
5068
|
-
|
5069
|
-
|
5146
|
+
}
|
5147
|
+
if ((tag & 7) == 4 || tag == 0) {
|
5148
|
+
break;
|
5149
|
+
}
|
5150
|
+
reader.skipType(tag & 7);
|
5151
|
+
}
|
5152
|
+
return message;
|
5153
|
+
},
|
5154
|
+
fromJSON(object) {
|
5155
|
+
return {
|
5156
|
+
key: isSet5(object.key) ? bytesFromBase645(object.key) : new Uint8Array(),
|
5157
|
+
scheme: isSet5(object.scheme) ? Number(object.scheme) : 0,
|
5158
|
+
eventType: isSet5(object.eventType) ? signerEventTypeFromJSON(object.eventType) : 0,
|
5159
|
+
metadata: isSet5(object.metadata) ? bytesFromBase645(object.metadata) : new Uint8Array()
|
5160
|
+
};
|
5161
|
+
},
|
5162
|
+
toJSON(message) {
|
5163
|
+
const obj = {};
|
5164
|
+
message.key !== void 0 && (obj.key = base64FromBytes5(message.key !== void 0 ? message.key : new Uint8Array()));
|
5165
|
+
message.scheme !== void 0 && (obj.scheme = Math.round(message.scheme));
|
5166
|
+
message.eventType !== void 0 && (obj.eventType = signerEventTypeToJSON(message.eventType));
|
5167
|
+
message.metadata !== void 0 && (obj.metadata = base64FromBytes5(message.metadata !== void 0 ? message.metadata : new Uint8Array()));
|
5168
|
+
return obj;
|
5169
|
+
},
|
5170
|
+
create(base) {
|
5171
|
+
return SignerEventBody.fromPartial(base != null ? base : {});
|
5172
|
+
},
|
5173
|
+
fromPartial(object) {
|
5174
|
+
var _a, _b, _c, _d;
|
5175
|
+
const message = createBaseSignerEventBody();
|
5176
|
+
message.key = (_a = object.key) != null ? _a : new Uint8Array();
|
5177
|
+
message.scheme = (_b = object.scheme) != null ? _b : 0;
|
5178
|
+
message.eventType = (_c = object.eventType) != null ? _c : 0;
|
5179
|
+
message.metadata = (_d = object.metadata) != null ? _d : new Uint8Array();
|
5180
|
+
return message;
|
5181
|
+
}
|
5182
|
+
};
|
5183
|
+
function createBaseSignerMigratedEventBody() {
|
5184
|
+
return { migratedAt: 0 };
|
5185
|
+
}
|
5186
|
+
var SignerMigratedEventBody = {
|
5187
|
+
encode(message, writer = import_minimal5.default.Writer.create()) {
|
5188
|
+
if (message.migratedAt !== 0) {
|
5189
|
+
writer.uint32(8).uint32(message.migratedAt);
|
5190
|
+
}
|
5191
|
+
return writer;
|
5192
|
+
},
|
5193
|
+
decode(input, length) {
|
5194
|
+
const reader = input instanceof import_minimal5.default.Reader ? input : import_minimal5.default.Reader.create(input);
|
5195
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
5196
|
+
const message = createBaseSignerMigratedEventBody();
|
5197
|
+
while (reader.pos < end) {
|
5198
|
+
const tag = reader.uint32();
|
5199
|
+
switch (tag >>> 3) {
|
5200
|
+
case 1:
|
5201
|
+
if (tag != 8) {
|
5070
5202
|
break;
|
5071
5203
|
}
|
5072
|
-
message.
|
5204
|
+
message.migratedAt = reader.uint32();
|
5073
5205
|
continue;
|
5074
|
-
|
5075
|
-
|
5206
|
+
}
|
5207
|
+
if ((tag & 7) == 4 || tag == 0) {
|
5208
|
+
break;
|
5209
|
+
}
|
5210
|
+
reader.skipType(tag & 7);
|
5211
|
+
}
|
5212
|
+
return message;
|
5213
|
+
},
|
5214
|
+
fromJSON(object) {
|
5215
|
+
return { migratedAt: isSet5(object.migratedAt) ? Number(object.migratedAt) : 0 };
|
5216
|
+
},
|
5217
|
+
toJSON(message) {
|
5218
|
+
const obj = {};
|
5219
|
+
message.migratedAt !== void 0 && (obj.migratedAt = Math.round(message.migratedAt));
|
5220
|
+
return obj;
|
5221
|
+
},
|
5222
|
+
create(base) {
|
5223
|
+
return SignerMigratedEventBody.fromPartial(base != null ? base : {});
|
5224
|
+
},
|
5225
|
+
fromPartial(object) {
|
5226
|
+
var _a;
|
5227
|
+
const message = createBaseSignerMigratedEventBody();
|
5228
|
+
message.migratedAt = (_a = object.migratedAt) != null ? _a : 0;
|
5229
|
+
return message;
|
5230
|
+
}
|
5231
|
+
};
|
5232
|
+
function createBaseIdRegisterEventBody() {
|
5233
|
+
return { to: new Uint8Array(), eventType: 0, from: new Uint8Array(), recoveryAddress: new Uint8Array() };
|
5234
|
+
}
|
5235
|
+
var IdRegisterEventBody = {
|
5236
|
+
encode(message, writer = import_minimal5.default.Writer.create()) {
|
5237
|
+
if (message.to.length !== 0) {
|
5238
|
+
writer.uint32(10).bytes(message.to);
|
5239
|
+
}
|
5240
|
+
if (message.eventType !== 0) {
|
5241
|
+
writer.uint32(16).int32(message.eventType);
|
5242
|
+
}
|
5243
|
+
if (message.from.length !== 0) {
|
5244
|
+
writer.uint32(26).bytes(message.from);
|
5245
|
+
}
|
5246
|
+
if (message.recoveryAddress.length !== 0) {
|
5247
|
+
writer.uint32(34).bytes(message.recoveryAddress);
|
5248
|
+
}
|
5249
|
+
return writer;
|
5250
|
+
},
|
5251
|
+
decode(input, length) {
|
5252
|
+
const reader = input instanceof import_minimal5.default.Reader ? input : import_minimal5.default.Reader.create(input);
|
5253
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
5254
|
+
const message = createBaseIdRegisterEventBody();
|
5255
|
+
while (reader.pos < end) {
|
5256
|
+
const tag = reader.uint32();
|
5257
|
+
switch (tag >>> 3) {
|
5258
|
+
case 1:
|
5259
|
+
if (tag != 10) {
|
5076
5260
|
break;
|
5077
5261
|
}
|
5078
|
-
message.
|
5262
|
+
message.to = reader.bytes();
|
5079
5263
|
continue;
|
5080
|
-
case
|
5081
|
-
if (tag !=
|
5264
|
+
case 2:
|
5265
|
+
if (tag != 16) {
|
5082
5266
|
break;
|
5083
5267
|
}
|
5084
|
-
message.
|
5268
|
+
message.eventType = reader.int32();
|
5085
5269
|
continue;
|
5086
|
-
case
|
5087
|
-
if (tag !=
|
5270
|
+
case 3:
|
5271
|
+
if (tag != 26) {
|
5272
|
+
break;
|
5273
|
+
}
|
5274
|
+
message.from = reader.bytes();
|
5275
|
+
continue;
|
5276
|
+
case 4:
|
5277
|
+
if (tag != 34) {
|
5088
5278
|
break;
|
5089
5279
|
}
|
5090
|
-
message.
|
5280
|
+
message.recoveryAddress = reader.bytes();
|
5091
5281
|
continue;
|
5092
5282
|
}
|
5093
5283
|
if ((tag & 7) == 4 || tag == 0) {
|
@@ -5099,44 +5289,107 @@ var StorageAdminRegistryEvent = {
|
|
5099
5289
|
},
|
5100
5290
|
fromJSON(object) {
|
5101
5291
|
return {
|
5102
|
-
|
5103
|
-
|
5104
|
-
transactionHash: isSet5(object.transactionHash) ? bytesFromBase645(object.transactionHash) : new Uint8Array(),
|
5105
|
-
logIndex: isSet5(object.logIndex) ? Number(object.logIndex) : 0,
|
5106
|
-
timestamp: isSet5(object.timestamp) ? Number(object.timestamp) : 0,
|
5292
|
+
to: isSet5(object.to) ? bytesFromBase645(object.to) : new Uint8Array(),
|
5293
|
+
eventType: isSet5(object.eventType) ? idRegisterEventTypeFromJSON(object.eventType) : 0,
|
5107
5294
|
from: isSet5(object.from) ? bytesFromBase645(object.from) : new Uint8Array(),
|
5108
|
-
|
5109
|
-
value: isSet5(object.value) ? bytesFromBase645(object.value) : new Uint8Array()
|
5295
|
+
recoveryAddress: isSet5(object.recoveryAddress) ? bytesFromBase645(object.recoveryAddress) : new Uint8Array()
|
5110
5296
|
};
|
5111
5297
|
},
|
5112
5298
|
toJSON(message) {
|
5113
5299
|
const obj = {};
|
5114
|
-
message.
|
5115
|
-
message.
|
5116
|
-
message.transactionHash !== void 0 && (obj.transactionHash = base64FromBytes5(
|
5117
|
-
message.transactionHash !== void 0 ? message.transactionHash : new Uint8Array()
|
5118
|
-
));
|
5119
|
-
message.logIndex !== void 0 && (obj.logIndex = Math.round(message.logIndex));
|
5120
|
-
message.timestamp !== void 0 && (obj.timestamp = Math.round(message.timestamp));
|
5300
|
+
message.to !== void 0 && (obj.to = base64FromBytes5(message.to !== void 0 ? message.to : new Uint8Array()));
|
5301
|
+
message.eventType !== void 0 && (obj.eventType = idRegisterEventTypeToJSON(message.eventType));
|
5121
5302
|
message.from !== void 0 && (obj.from = base64FromBytes5(message.from !== void 0 ? message.from : new Uint8Array()));
|
5122
|
-
message.
|
5123
|
-
|
5303
|
+
message.recoveryAddress !== void 0 && (obj.recoveryAddress = base64FromBytes5(
|
5304
|
+
message.recoveryAddress !== void 0 ? message.recoveryAddress : new Uint8Array()
|
5305
|
+
));
|
5306
|
+
return obj;
|
5307
|
+
},
|
5308
|
+
create(base) {
|
5309
|
+
return IdRegisterEventBody.fromPartial(base != null ? base : {});
|
5310
|
+
},
|
5311
|
+
fromPartial(object) {
|
5312
|
+
var _a, _b, _c, _d;
|
5313
|
+
const message = createBaseIdRegisterEventBody();
|
5314
|
+
message.to = (_a = object.to) != null ? _a : new Uint8Array();
|
5315
|
+
message.eventType = (_b = object.eventType) != null ? _b : 0;
|
5316
|
+
message.from = (_c = object.from) != null ? _c : new Uint8Array();
|
5317
|
+
message.recoveryAddress = (_d = object.recoveryAddress) != null ? _d : new Uint8Array();
|
5318
|
+
return message;
|
5319
|
+
}
|
5320
|
+
};
|
5321
|
+
function createBaseStorageRentEventBody() {
|
5322
|
+
return { payer: new Uint8Array(), units: 0, expiry: 0 };
|
5323
|
+
}
|
5324
|
+
var StorageRentEventBody = {
|
5325
|
+
encode(message, writer = import_minimal5.default.Writer.create()) {
|
5326
|
+
if (message.payer.length !== 0) {
|
5327
|
+
writer.uint32(10).bytes(message.payer);
|
5328
|
+
}
|
5329
|
+
if (message.units !== 0) {
|
5330
|
+
writer.uint32(16).uint32(message.units);
|
5331
|
+
}
|
5332
|
+
if (message.expiry !== 0) {
|
5333
|
+
writer.uint32(24).uint32(message.expiry);
|
5334
|
+
}
|
5335
|
+
return writer;
|
5336
|
+
},
|
5337
|
+
decode(input, length) {
|
5338
|
+
const reader = input instanceof import_minimal5.default.Reader ? input : import_minimal5.default.Reader.create(input);
|
5339
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
5340
|
+
const message = createBaseStorageRentEventBody();
|
5341
|
+
while (reader.pos < end) {
|
5342
|
+
const tag = reader.uint32();
|
5343
|
+
switch (tag >>> 3) {
|
5344
|
+
case 1:
|
5345
|
+
if (tag != 10) {
|
5346
|
+
break;
|
5347
|
+
}
|
5348
|
+
message.payer = reader.bytes();
|
5349
|
+
continue;
|
5350
|
+
case 2:
|
5351
|
+
if (tag != 16) {
|
5352
|
+
break;
|
5353
|
+
}
|
5354
|
+
message.units = reader.uint32();
|
5355
|
+
continue;
|
5356
|
+
case 3:
|
5357
|
+
if (tag != 24) {
|
5358
|
+
break;
|
5359
|
+
}
|
5360
|
+
message.expiry = reader.uint32();
|
5361
|
+
continue;
|
5362
|
+
}
|
5363
|
+
if ((tag & 7) == 4 || tag == 0) {
|
5364
|
+
break;
|
5365
|
+
}
|
5366
|
+
reader.skipType(tag & 7);
|
5367
|
+
}
|
5368
|
+
return message;
|
5369
|
+
},
|
5370
|
+
fromJSON(object) {
|
5371
|
+
return {
|
5372
|
+
payer: isSet5(object.payer) ? bytesFromBase645(object.payer) : new Uint8Array(),
|
5373
|
+
units: isSet5(object.units) ? Number(object.units) : 0,
|
5374
|
+
expiry: isSet5(object.expiry) ? Number(object.expiry) : 0
|
5375
|
+
};
|
5376
|
+
},
|
5377
|
+
toJSON(message) {
|
5378
|
+
const obj = {};
|
5379
|
+
message.payer !== void 0 && (obj.payer = base64FromBytes5(message.payer !== void 0 ? message.payer : new Uint8Array()));
|
5380
|
+
message.units !== void 0 && (obj.units = Math.round(message.units));
|
5381
|
+
message.expiry !== void 0 && (obj.expiry = Math.round(message.expiry));
|
5124
5382
|
return obj;
|
5125
5383
|
},
|
5126
5384
|
create(base) {
|
5127
|
-
return
|
5385
|
+
return StorageRentEventBody.fromPartial(base != null ? base : {});
|
5128
5386
|
},
|
5129
5387
|
fromPartial(object) {
|
5130
|
-
var _a, _b, _c
|
5131
|
-
const message =
|
5132
|
-
message.
|
5133
|
-
message.
|
5134
|
-
message.
|
5135
|
-
message.logIndex = (_d = object.logIndex) != null ? _d : 0;
|
5136
|
-
message.timestamp = (_e = object.timestamp) != null ? _e : 0;
|
5137
|
-
message.from = (_f = object.from) != null ? _f : new Uint8Array();
|
5138
|
-
message.type = (_g = object.type) != null ? _g : 0;
|
5139
|
-
message.value = (_h = object.value) != null ? _h : new Uint8Array();
|
5388
|
+
var _a, _b, _c;
|
5389
|
+
const message = createBaseStorageRentEventBody();
|
5390
|
+
message.payer = (_a = object.payer) != null ? _a : new Uint8Array();
|
5391
|
+
message.units = (_b = object.units) != null ? _b : 0;
|
5392
|
+
message.expiry = (_c = object.expiry) != null ? _c : 0;
|
5140
5393
|
return message;
|
5141
5394
|
}
|
5142
5395
|
};
|
@@ -5216,12 +5469,9 @@ function hubEventTypeFromJSON(object) {
|
|
5216
5469
|
case 6:
|
5217
5470
|
case "HUB_EVENT_TYPE_MERGE_USERNAME_PROOF":
|
5218
5471
|
return 6 /* MERGE_USERNAME_PROOF */;
|
5219
|
-
case
|
5220
|
-
case "
|
5221
|
-
return
|
5222
|
-
case 8:
|
5223
|
-
case "HUB_EVENT_TYPE_MERGE_STORAGE_ADMIN_REGISTRY_EVENT":
|
5224
|
-
return 8 /* MERGE_STORAGE_ADMIN_REGISTRY_EVENT */;
|
5472
|
+
case 9:
|
5473
|
+
case "HUB_EVENT_TYPE_MERGE_ON_CHAIN_EVENT":
|
5474
|
+
return 9 /* MERGE_ON_CHAIN_EVENT */;
|
5225
5475
|
default:
|
5226
5476
|
throw new tsProtoGlobalThis6.Error("Unrecognized enum value " + object + " for enum HubEventType");
|
5227
5477
|
}
|
@@ -5242,10 +5492,8 @@ function hubEventTypeToJSON(object) {
|
|
5242
5492
|
return "HUB_EVENT_TYPE_MERGE_NAME_REGISTRY_EVENT";
|
5243
5493
|
case 6 /* MERGE_USERNAME_PROOF */:
|
5244
5494
|
return "HUB_EVENT_TYPE_MERGE_USERNAME_PROOF";
|
5245
|
-
case
|
5246
|
-
return "
|
5247
|
-
case 8 /* MERGE_STORAGE_ADMIN_REGISTRY_EVENT */:
|
5248
|
-
return "HUB_EVENT_TYPE_MERGE_STORAGE_ADMIN_REGISTRY_EVENT";
|
5495
|
+
case 9 /* MERGE_ON_CHAIN_EVENT */:
|
5496
|
+
return "HUB_EVENT_TYPE_MERGE_ON_CHAIN_EVENT";
|
5249
5497
|
default:
|
5250
5498
|
throw new tsProtoGlobalThis6.Error("Unrecognized enum value " + object + " for enum HubEventType");
|
5251
5499
|
}
|
@@ -5513,70 +5761,20 @@ var MergeNameRegistryEventBody = {
|
|
5513
5761
|
return message;
|
5514
5762
|
}
|
5515
5763
|
};
|
5516
|
-
function
|
5517
|
-
return {
|
5518
|
-
}
|
5519
|
-
var MergeRentRegistryEventBody = {
|
5520
|
-
encode(message, writer = import_minimal6.default.Writer.create()) {
|
5521
|
-
if (message.rentRegistryEvent !== void 0) {
|
5522
|
-
RentRegistryEvent.encode(message.rentRegistryEvent, writer.uint32(10).fork()).ldelim();
|
5523
|
-
}
|
5524
|
-
return writer;
|
5525
|
-
},
|
5526
|
-
decode(input, length) {
|
5527
|
-
const reader = input instanceof import_minimal6.default.Reader ? input : import_minimal6.default.Reader.create(input);
|
5528
|
-
let end = length === void 0 ? reader.len : reader.pos + length;
|
5529
|
-
const message = createBaseMergeRentRegistryEventBody();
|
5530
|
-
while (reader.pos < end) {
|
5531
|
-
const tag = reader.uint32();
|
5532
|
-
switch (tag >>> 3) {
|
5533
|
-
case 1:
|
5534
|
-
if (tag != 10) {
|
5535
|
-
break;
|
5536
|
-
}
|
5537
|
-
message.rentRegistryEvent = RentRegistryEvent.decode(reader, reader.uint32());
|
5538
|
-
continue;
|
5539
|
-
}
|
5540
|
-
if ((tag & 7) == 4 || tag == 0) {
|
5541
|
-
break;
|
5542
|
-
}
|
5543
|
-
reader.skipType(tag & 7);
|
5544
|
-
}
|
5545
|
-
return message;
|
5546
|
-
},
|
5547
|
-
fromJSON(object) {
|
5548
|
-
return {
|
5549
|
-
rentRegistryEvent: isSet6(object.rentRegistryEvent) ? RentRegistryEvent.fromJSON(object.rentRegistryEvent) : void 0
|
5550
|
-
};
|
5551
|
-
},
|
5552
|
-
toJSON(message) {
|
5553
|
-
const obj = {};
|
5554
|
-
message.rentRegistryEvent !== void 0 && (obj.rentRegistryEvent = message.rentRegistryEvent ? RentRegistryEvent.toJSON(message.rentRegistryEvent) : void 0);
|
5555
|
-
return obj;
|
5556
|
-
},
|
5557
|
-
create(base) {
|
5558
|
-
return MergeRentRegistryEventBody.fromPartial(base != null ? base : {});
|
5559
|
-
},
|
5560
|
-
fromPartial(object) {
|
5561
|
-
const message = createBaseMergeRentRegistryEventBody();
|
5562
|
-
message.rentRegistryEvent = object.rentRegistryEvent !== void 0 && object.rentRegistryEvent !== null ? RentRegistryEvent.fromPartial(object.rentRegistryEvent) : void 0;
|
5563
|
-
return message;
|
5564
|
-
}
|
5565
|
-
};
|
5566
|
-
function createBaseMergeStorageAdminRegistryEventBody() {
|
5567
|
-
return { storageAdminRegistryEvent: void 0 };
|
5764
|
+
function createBaseMergeOnChainEventBody() {
|
5765
|
+
return { onChainEvent: void 0 };
|
5568
5766
|
}
|
5569
|
-
var
|
5767
|
+
var MergeOnChainEventBody = {
|
5570
5768
|
encode(message, writer = import_minimal6.default.Writer.create()) {
|
5571
|
-
if (message.
|
5572
|
-
|
5769
|
+
if (message.onChainEvent !== void 0) {
|
5770
|
+
OnChainEvent.encode(message.onChainEvent, writer.uint32(10).fork()).ldelim();
|
5573
5771
|
}
|
5574
5772
|
return writer;
|
5575
5773
|
},
|
5576
5774
|
decode(input, length) {
|
5577
5775
|
const reader = input instanceof import_minimal6.default.Reader ? input : import_minimal6.default.Reader.create(input);
|
5578
5776
|
let end = length === void 0 ? reader.len : reader.pos + length;
|
5579
|
-
const message =
|
5777
|
+
const message = createBaseMergeOnChainEventBody();
|
5580
5778
|
while (reader.pos < end) {
|
5581
5779
|
const tag = reader.uint32();
|
5582
5780
|
switch (tag >>> 3) {
|
@@ -5584,7 +5782,7 @@ var MergeStorageAdminRegistryEventBody = {
|
|
5584
5782
|
if (tag != 10) {
|
5585
5783
|
break;
|
5586
5784
|
}
|
5587
|
-
message.
|
5785
|
+
message.onChainEvent = OnChainEvent.decode(reader, reader.uint32());
|
5588
5786
|
continue;
|
5589
5787
|
}
|
5590
5788
|
if ((tag & 7) == 4 || tag == 0) {
|
@@ -5595,21 +5793,19 @@ var MergeStorageAdminRegistryEventBody = {
|
|
5595
5793
|
return message;
|
5596
5794
|
},
|
5597
5795
|
fromJSON(object) {
|
5598
|
-
return {
|
5599
|
-
storageAdminRegistryEvent: isSet6(object.storageAdminRegistryEvent) ? StorageAdminRegistryEvent.fromJSON(object.storageAdminRegistryEvent) : void 0
|
5600
|
-
};
|
5796
|
+
return { onChainEvent: isSet6(object.onChainEvent) ? OnChainEvent.fromJSON(object.onChainEvent) : void 0 };
|
5601
5797
|
},
|
5602
5798
|
toJSON(message) {
|
5603
5799
|
const obj = {};
|
5604
|
-
message.
|
5800
|
+
message.onChainEvent !== void 0 && (obj.onChainEvent = message.onChainEvent ? OnChainEvent.toJSON(message.onChainEvent) : void 0);
|
5605
5801
|
return obj;
|
5606
5802
|
},
|
5607
5803
|
create(base) {
|
5608
|
-
return
|
5804
|
+
return MergeOnChainEventBody.fromPartial(base != null ? base : {});
|
5609
5805
|
},
|
5610
5806
|
fromPartial(object) {
|
5611
|
-
const message =
|
5612
|
-
message.
|
5807
|
+
const message = createBaseMergeOnChainEventBody();
|
5808
|
+
message.onChainEvent = object.onChainEvent !== void 0 && object.onChainEvent !== null ? OnChainEvent.fromPartial(object.onChainEvent) : void 0;
|
5613
5809
|
return message;
|
5614
5810
|
}
|
5615
5811
|
};
|
@@ -5714,8 +5910,7 @@ function createBaseHubEvent() {
|
|
5714
5910
|
mergeIdRegistryEventBody: void 0,
|
5715
5911
|
mergeNameRegistryEventBody: void 0,
|
5716
5912
|
mergeUsernameProofBody: void 0,
|
5717
|
-
|
5718
|
-
mergeStorageAdminRegistryEventBody: void 0
|
5913
|
+
mergeOnChainEventBody: void 0
|
5719
5914
|
};
|
5720
5915
|
}
|
5721
5916
|
var HubEvent = {
|
@@ -5744,11 +5939,8 @@ var HubEvent = {
|
|
5744
5939
|
if (message.mergeUsernameProofBody !== void 0) {
|
5745
5940
|
MergeUserNameProofBody.encode(message.mergeUsernameProofBody, writer.uint32(66).fork()).ldelim();
|
5746
5941
|
}
|
5747
|
-
if (message.
|
5748
|
-
|
5749
|
-
}
|
5750
|
-
if (message.mergeStorageAdminRegistryEventBody !== void 0) {
|
5751
|
-
MergeStorageAdminRegistryEventBody.encode(message.mergeStorageAdminRegistryEventBody, writer.uint32(82).fork()).ldelim();
|
5942
|
+
if (message.mergeOnChainEventBody !== void 0) {
|
5943
|
+
MergeOnChainEventBody.encode(message.mergeOnChainEventBody, writer.uint32(90).fork()).ldelim();
|
5752
5944
|
}
|
5753
5945
|
return writer;
|
5754
5946
|
},
|
@@ -5807,20 +5999,11 @@ var HubEvent = {
|
|
5807
5999
|
}
|
5808
6000
|
message.mergeUsernameProofBody = MergeUserNameProofBody.decode(reader, reader.uint32());
|
5809
6001
|
continue;
|
5810
|
-
case
|
5811
|
-
if (tag !=
|
5812
|
-
break;
|
5813
|
-
}
|
5814
|
-
message.mergeRentRegistryEventBody = MergeRentRegistryEventBody.decode(reader, reader.uint32());
|
5815
|
-
continue;
|
5816
|
-
case 10:
|
5817
|
-
if (tag != 82) {
|
6002
|
+
case 11:
|
6003
|
+
if (tag != 90) {
|
5818
6004
|
break;
|
5819
6005
|
}
|
5820
|
-
message.
|
5821
|
-
reader,
|
5822
|
-
reader.uint32()
|
5823
|
-
);
|
6006
|
+
message.mergeOnChainEventBody = MergeOnChainEventBody.decode(reader, reader.uint32());
|
5824
6007
|
continue;
|
5825
6008
|
}
|
5826
6009
|
if ((tag & 7) == 4 || tag == 0) {
|
@@ -5840,8 +6023,7 @@ var HubEvent = {
|
|
5840
6023
|
mergeIdRegistryEventBody: isSet6(object.mergeIdRegistryEventBody) ? MergeIdRegistryEventBody.fromJSON(object.mergeIdRegistryEventBody) : void 0,
|
5841
6024
|
mergeNameRegistryEventBody: isSet6(object.mergeNameRegistryEventBody) ? MergeNameRegistryEventBody.fromJSON(object.mergeNameRegistryEventBody) : void 0,
|
5842
6025
|
mergeUsernameProofBody: isSet6(object.mergeUsernameProofBody) ? MergeUserNameProofBody.fromJSON(object.mergeUsernameProofBody) : void 0,
|
5843
|
-
|
5844
|
-
mergeStorageAdminRegistryEventBody: isSet6(object.mergeStorageAdminRegistryEventBody) ? MergeStorageAdminRegistryEventBody.fromJSON(object.mergeStorageAdminRegistryEventBody) : void 0
|
6026
|
+
mergeOnChainEventBody: isSet6(object.mergeOnChainEventBody) ? MergeOnChainEventBody.fromJSON(object.mergeOnChainEventBody) : void 0
|
5845
6027
|
};
|
5846
6028
|
},
|
5847
6029
|
toJSON(message) {
|
@@ -5854,8 +6036,7 @@ var HubEvent = {
|
|
5854
6036
|
message.mergeIdRegistryEventBody !== void 0 && (obj.mergeIdRegistryEventBody = message.mergeIdRegistryEventBody ? MergeIdRegistryEventBody.toJSON(message.mergeIdRegistryEventBody) : void 0);
|
5855
6037
|
message.mergeNameRegistryEventBody !== void 0 && (obj.mergeNameRegistryEventBody = message.mergeNameRegistryEventBody ? MergeNameRegistryEventBody.toJSON(message.mergeNameRegistryEventBody) : void 0);
|
5856
6038
|
message.mergeUsernameProofBody !== void 0 && (obj.mergeUsernameProofBody = message.mergeUsernameProofBody ? MergeUserNameProofBody.toJSON(message.mergeUsernameProofBody) : void 0);
|
5857
|
-
message.
|
5858
|
-
message.mergeStorageAdminRegistryEventBody !== void 0 && (obj.mergeStorageAdminRegistryEventBody = message.mergeStorageAdminRegistryEventBody ? MergeStorageAdminRegistryEventBody.toJSON(message.mergeStorageAdminRegistryEventBody) : void 0);
|
6039
|
+
message.mergeOnChainEventBody !== void 0 && (obj.mergeOnChainEventBody = message.mergeOnChainEventBody ? MergeOnChainEventBody.toJSON(message.mergeOnChainEventBody) : void 0);
|
5859
6040
|
return obj;
|
5860
6041
|
},
|
5861
6042
|
create(base) {
|
@@ -5872,8 +6053,7 @@ var HubEvent = {
|
|
5872
6053
|
message.mergeIdRegistryEventBody = object.mergeIdRegistryEventBody !== void 0 && object.mergeIdRegistryEventBody !== null ? MergeIdRegistryEventBody.fromPartial(object.mergeIdRegistryEventBody) : void 0;
|
5873
6054
|
message.mergeNameRegistryEventBody = object.mergeNameRegistryEventBody !== void 0 && object.mergeNameRegistryEventBody !== null ? MergeNameRegistryEventBody.fromPartial(object.mergeNameRegistryEventBody) : void 0;
|
5874
6055
|
message.mergeUsernameProofBody = object.mergeUsernameProofBody !== void 0 && object.mergeUsernameProofBody !== null ? MergeUserNameProofBody.fromPartial(object.mergeUsernameProofBody) : void 0;
|
5875
|
-
message.
|
5876
|
-
message.mergeStorageAdminRegistryEventBody = object.mergeStorageAdminRegistryEventBody !== void 0 && object.mergeStorageAdminRegistryEventBody !== null ? MergeStorageAdminRegistryEventBody.fromPartial(object.mergeStorageAdminRegistryEventBody) : void 0;
|
6056
|
+
message.mergeOnChainEventBody = object.mergeOnChainEventBody !== void 0 && object.mergeOnChainEventBody !== null ? MergeOnChainEventBody.fromPartial(object.mergeOnChainEventBody) : void 0;
|
5877
6057
|
return message;
|
5878
6058
|
}
|
5879
6059
|
};
|
@@ -5910,6 +6090,48 @@ function isSet6(value) {
|
|
5910
6090
|
init_cjs_shims();
|
5911
6091
|
var import_long6 = __toESM(require_long());
|
5912
6092
|
var import_minimal7 = __toESM(require_minimal2());
|
6093
|
+
function storeTypeFromJSON(object) {
|
6094
|
+
switch (object) {
|
6095
|
+
case 0:
|
6096
|
+
case "STORE_TYPE_NONE":
|
6097
|
+
return 0 /* NONE */;
|
6098
|
+
case 1:
|
6099
|
+
case "STORE_TYPE_CASTS":
|
6100
|
+
return 1 /* CASTS */;
|
6101
|
+
case 2:
|
6102
|
+
case "STORE_TYPE_LINKS":
|
6103
|
+
return 2 /* LINKS */;
|
6104
|
+
case 3:
|
6105
|
+
case "STORE_TYPE_REACTIONS":
|
6106
|
+
return 3 /* REACTIONS */;
|
6107
|
+
case 4:
|
6108
|
+
case "STORE_TYPE_USER_DATA":
|
6109
|
+
return 4 /* USER_DATA */;
|
6110
|
+
case 5:
|
6111
|
+
case "STORE_TYPE_VERIFICATIONS":
|
6112
|
+
return 5 /* VERIFICATIONS */;
|
6113
|
+
default:
|
6114
|
+
throw new tsProtoGlobalThis7.Error("Unrecognized enum value " + object + " for enum StoreType");
|
6115
|
+
}
|
6116
|
+
}
|
6117
|
+
function storeTypeToJSON(object) {
|
6118
|
+
switch (object) {
|
6119
|
+
case 0 /* NONE */:
|
6120
|
+
return "STORE_TYPE_NONE";
|
6121
|
+
case 1 /* CASTS */:
|
6122
|
+
return "STORE_TYPE_CASTS";
|
6123
|
+
case 2 /* LINKS */:
|
6124
|
+
return "STORE_TYPE_LINKS";
|
6125
|
+
case 3 /* REACTIONS */:
|
6126
|
+
return "STORE_TYPE_REACTIONS";
|
6127
|
+
case 4 /* USER_DATA */:
|
6128
|
+
return "STORE_TYPE_USER_DATA";
|
6129
|
+
case 5 /* VERIFICATIONS */:
|
6130
|
+
return "STORE_TYPE_VERIFICATIONS";
|
6131
|
+
default:
|
6132
|
+
throw new tsProtoGlobalThis7.Error("Unrecognized enum value " + object + " for enum StoreType");
|
6133
|
+
}
|
6134
|
+
}
|
5913
6135
|
function createBaseEmpty() {
|
5914
6136
|
return {};
|
5915
6137
|
}
|
@@ -6345,7 +6567,7 @@ var SyncStatusRequest = {
|
|
6345
6567
|
}
|
6346
6568
|
};
|
6347
6569
|
function createBaseSyncStatusResponse() {
|
6348
|
-
return { isSyncing: false, syncStatus: [] };
|
6570
|
+
return { isSyncing: false, syncStatus: [], engineStarted: false };
|
6349
6571
|
}
|
6350
6572
|
var SyncStatusResponse = {
|
6351
6573
|
encode(message, writer = import_minimal7.default.Writer.create()) {
|
@@ -6355,6 +6577,9 @@ var SyncStatusResponse = {
|
|
6355
6577
|
for (const v of message.syncStatus) {
|
6356
6578
|
SyncStatus.encode(v, writer.uint32(18).fork()).ldelim();
|
6357
6579
|
}
|
6580
|
+
if (message.engineStarted === true) {
|
6581
|
+
writer.uint32(24).bool(message.engineStarted);
|
6582
|
+
}
|
6358
6583
|
return writer;
|
6359
6584
|
},
|
6360
6585
|
decode(input, length) {
|
@@ -6376,6 +6601,12 @@ var SyncStatusResponse = {
|
|
6376
6601
|
}
|
6377
6602
|
message.syncStatus.push(SyncStatus.decode(reader, reader.uint32()));
|
6378
6603
|
continue;
|
6604
|
+
case 3:
|
6605
|
+
if (tag != 24) {
|
6606
|
+
break;
|
6607
|
+
}
|
6608
|
+
message.engineStarted = reader.bool();
|
6609
|
+
continue;
|
6379
6610
|
}
|
6380
6611
|
if ((tag & 7) == 4 || tag == 0) {
|
6381
6612
|
break;
|
@@ -6387,7 +6618,8 @@ var SyncStatusResponse = {
|
|
6387
6618
|
fromJSON(object) {
|
6388
6619
|
return {
|
6389
6620
|
isSyncing: isSet7(object.isSyncing) ? Boolean(object.isSyncing) : false,
|
6390
|
-
syncStatus: Array.isArray(object == null ? void 0 : object.syncStatus) ? object.syncStatus.map((e) => SyncStatus.fromJSON(e)) : []
|
6621
|
+
syncStatus: Array.isArray(object == null ? void 0 : object.syncStatus) ? object.syncStatus.map((e) => SyncStatus.fromJSON(e)) : [],
|
6622
|
+
engineStarted: isSet7(object.engineStarted) ? Boolean(object.engineStarted) : false
|
6391
6623
|
};
|
6392
6624
|
},
|
6393
6625
|
toJSON(message) {
|
@@ -6398,16 +6630,18 @@ var SyncStatusResponse = {
|
|
6398
6630
|
} else {
|
6399
6631
|
obj.syncStatus = [];
|
6400
6632
|
}
|
6633
|
+
message.engineStarted !== void 0 && (obj.engineStarted = message.engineStarted);
|
6401
6634
|
return obj;
|
6402
6635
|
},
|
6403
6636
|
create(base) {
|
6404
6637
|
return SyncStatusResponse.fromPartial(base != null ? base : {});
|
6405
6638
|
},
|
6406
6639
|
fromPartial(object) {
|
6407
|
-
var _a, _b;
|
6640
|
+
var _a, _b, _c;
|
6408
6641
|
const message = createBaseSyncStatusResponse();
|
6409
6642
|
message.isSyncing = (_a = object.isSyncing) != null ? _a : false;
|
6410
6643
|
message.syncStatus = ((_b = object.syncStatus) == null ? void 0 : _b.map((e) => SyncStatus.fromPartial(e))) || [];
|
6644
|
+
message.engineStarted = (_c = object.engineStarted) != null ? _c : false;
|
6411
6645
|
return message;
|
6412
6646
|
}
|
6413
6647
|
};
|
@@ -7665,20 +7899,23 @@ var NameRegistryEventRequest = {
|
|
7665
7899
|
return message;
|
7666
7900
|
}
|
7667
7901
|
};
|
7668
|
-
function
|
7669
|
-
return { fid: 0 };
|
7902
|
+
function createBaseOnChainEventRequest() {
|
7903
|
+
return { fid: 0, eventType: 0 };
|
7670
7904
|
}
|
7671
|
-
var
|
7905
|
+
var OnChainEventRequest = {
|
7672
7906
|
encode(message, writer = import_minimal7.default.Writer.create()) {
|
7673
7907
|
if (message.fid !== 0) {
|
7674
7908
|
writer.uint32(8).uint64(message.fid);
|
7675
7909
|
}
|
7910
|
+
if (message.eventType !== 0) {
|
7911
|
+
writer.uint32(16).int32(message.eventType);
|
7912
|
+
}
|
7676
7913
|
return writer;
|
7677
7914
|
},
|
7678
7915
|
decode(input, length) {
|
7679
7916
|
const reader = input instanceof import_minimal7.default.Reader ? input : import_minimal7.default.Reader.create(input);
|
7680
7917
|
let end = length === void 0 ? reader.len : reader.pos + length;
|
7681
|
-
const message =
|
7918
|
+
const message = createBaseOnChainEventRequest();
|
7682
7919
|
while (reader.pos < end) {
|
7683
7920
|
const tag = reader.uint32();
|
7684
7921
|
switch (tag >>> 3) {
|
@@ -7688,6 +7925,12 @@ var RentRegistryEventsRequest = {
|
|
7688
7925
|
}
|
7689
7926
|
message.fid = longToNumber6(reader.uint64());
|
7690
7927
|
continue;
|
7928
|
+
case 2:
|
7929
|
+
if (tag != 16) {
|
7930
|
+
break;
|
7931
|
+
}
|
7932
|
+
message.eventType = reader.int32();
|
7933
|
+
continue;
|
7691
7934
|
}
|
7692
7935
|
if ((tag & 7) == 4 || tag == 0) {
|
7693
7936
|
break;
|
@@ -7697,37 +7940,42 @@ var RentRegistryEventsRequest = {
|
|
7697
7940
|
return message;
|
7698
7941
|
},
|
7699
7942
|
fromJSON(object) {
|
7700
|
-
return {
|
7943
|
+
return {
|
7944
|
+
fid: isSet7(object.fid) ? Number(object.fid) : 0,
|
7945
|
+
eventType: isSet7(object.eventType) ? onChainEventTypeFromJSON(object.eventType) : 0
|
7946
|
+
};
|
7701
7947
|
},
|
7702
7948
|
toJSON(message) {
|
7703
7949
|
const obj = {};
|
7704
7950
|
message.fid !== void 0 && (obj.fid = Math.round(message.fid));
|
7951
|
+
message.eventType !== void 0 && (obj.eventType = onChainEventTypeToJSON(message.eventType));
|
7705
7952
|
return obj;
|
7706
7953
|
},
|
7707
7954
|
create(base) {
|
7708
|
-
return
|
7955
|
+
return OnChainEventRequest.fromPartial(base != null ? base : {});
|
7709
7956
|
},
|
7710
7957
|
fromPartial(object) {
|
7711
|
-
var _a;
|
7712
|
-
const message =
|
7958
|
+
var _a, _b;
|
7959
|
+
const message = createBaseOnChainEventRequest();
|
7713
7960
|
message.fid = (_a = object.fid) != null ? _a : 0;
|
7961
|
+
message.eventType = (_b = object.eventType) != null ? _b : 0;
|
7714
7962
|
return message;
|
7715
7963
|
}
|
7716
7964
|
};
|
7717
|
-
function
|
7965
|
+
function createBaseOnChainEventResponse() {
|
7718
7966
|
return { events: [] };
|
7719
7967
|
}
|
7720
|
-
var
|
7968
|
+
var OnChainEventResponse = {
|
7721
7969
|
encode(message, writer = import_minimal7.default.Writer.create()) {
|
7722
7970
|
for (const v of message.events) {
|
7723
|
-
|
7971
|
+
OnChainEvent.encode(v, writer.uint32(10).fork()).ldelim();
|
7724
7972
|
}
|
7725
7973
|
return writer;
|
7726
7974
|
},
|
7727
7975
|
decode(input, length) {
|
7728
7976
|
const reader = input instanceof import_minimal7.default.Reader ? input : import_minimal7.default.Reader.create(input);
|
7729
7977
|
let end = length === void 0 ? reader.len : reader.pos + length;
|
7730
|
-
const message =
|
7978
|
+
const message = createBaseOnChainEventResponse();
|
7731
7979
|
while (reader.pos < end) {
|
7732
7980
|
const tag = reader.uint32();
|
7733
7981
|
switch (tag >>> 3) {
|
@@ -7735,7 +7983,7 @@ var RentRegistryEventsResponse = {
|
|
7735
7983
|
if (tag != 10) {
|
7736
7984
|
break;
|
7737
7985
|
}
|
7738
|
-
message.events.push(
|
7986
|
+
message.events.push(OnChainEvent.decode(reader, reader.uint32()));
|
7739
7987
|
continue;
|
7740
7988
|
}
|
7741
7989
|
if ((tag & 7) == 4 || tag == 0) {
|
@@ -7746,26 +7994,140 @@ var RentRegistryEventsResponse = {
|
|
7746
7994
|
return message;
|
7747
7995
|
},
|
7748
7996
|
fromJSON(object) {
|
7749
|
-
return {
|
7750
|
-
events: Array.isArray(object == null ? void 0 : object.events) ? object.events.map((e) => RentRegistryEvent.fromJSON(e)) : []
|
7751
|
-
};
|
7997
|
+
return { events: Array.isArray(object == null ? void 0 : object.events) ? object.events.map((e) => OnChainEvent.fromJSON(e)) : [] };
|
7752
7998
|
},
|
7753
7999
|
toJSON(message) {
|
7754
8000
|
const obj = {};
|
7755
8001
|
if (message.events) {
|
7756
|
-
obj.events = message.events.map((e) => e ?
|
8002
|
+
obj.events = message.events.map((e) => e ? OnChainEvent.toJSON(e) : void 0);
|
7757
8003
|
} else {
|
7758
8004
|
obj.events = [];
|
7759
8005
|
}
|
7760
8006
|
return obj;
|
7761
8007
|
},
|
7762
8008
|
create(base) {
|
7763
|
-
return
|
8009
|
+
return OnChainEventResponse.fromPartial(base != null ? base : {});
|
8010
|
+
},
|
8011
|
+
fromPartial(object) {
|
8012
|
+
var _a;
|
8013
|
+
const message = createBaseOnChainEventResponse();
|
8014
|
+
message.events = ((_a = object.events) == null ? void 0 : _a.map((e) => OnChainEvent.fromPartial(e))) || [];
|
8015
|
+
return message;
|
8016
|
+
}
|
8017
|
+
};
|
8018
|
+
function createBaseStorageLimitsResponse() {
|
8019
|
+
return { limits: [] };
|
8020
|
+
}
|
8021
|
+
var StorageLimitsResponse = {
|
8022
|
+
encode(message, writer = import_minimal7.default.Writer.create()) {
|
8023
|
+
for (const v of message.limits) {
|
8024
|
+
StorageLimit.encode(v, writer.uint32(10).fork()).ldelim();
|
8025
|
+
}
|
8026
|
+
return writer;
|
8027
|
+
},
|
8028
|
+
decode(input, length) {
|
8029
|
+
const reader = input instanceof import_minimal7.default.Reader ? input : import_minimal7.default.Reader.create(input);
|
8030
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
8031
|
+
const message = createBaseStorageLimitsResponse();
|
8032
|
+
while (reader.pos < end) {
|
8033
|
+
const tag = reader.uint32();
|
8034
|
+
switch (tag >>> 3) {
|
8035
|
+
case 1:
|
8036
|
+
if (tag != 10) {
|
8037
|
+
break;
|
8038
|
+
}
|
8039
|
+
message.limits.push(StorageLimit.decode(reader, reader.uint32()));
|
8040
|
+
continue;
|
8041
|
+
}
|
8042
|
+
if ((tag & 7) == 4 || tag == 0) {
|
8043
|
+
break;
|
8044
|
+
}
|
8045
|
+
reader.skipType(tag & 7);
|
8046
|
+
}
|
8047
|
+
return message;
|
8048
|
+
},
|
8049
|
+
fromJSON(object) {
|
8050
|
+
return { limits: Array.isArray(object == null ? void 0 : object.limits) ? object.limits.map((e) => StorageLimit.fromJSON(e)) : [] };
|
8051
|
+
},
|
8052
|
+
toJSON(message) {
|
8053
|
+
const obj = {};
|
8054
|
+
if (message.limits) {
|
8055
|
+
obj.limits = message.limits.map((e) => e ? StorageLimit.toJSON(e) : void 0);
|
8056
|
+
} else {
|
8057
|
+
obj.limits = [];
|
8058
|
+
}
|
8059
|
+
return obj;
|
8060
|
+
},
|
8061
|
+
create(base) {
|
8062
|
+
return StorageLimitsResponse.fromPartial(base != null ? base : {});
|
7764
8063
|
},
|
7765
8064
|
fromPartial(object) {
|
7766
8065
|
var _a;
|
7767
|
-
const message =
|
7768
|
-
message.
|
8066
|
+
const message = createBaseStorageLimitsResponse();
|
8067
|
+
message.limits = ((_a = object.limits) == null ? void 0 : _a.map((e) => StorageLimit.fromPartial(e))) || [];
|
8068
|
+
return message;
|
8069
|
+
}
|
8070
|
+
};
|
8071
|
+
function createBaseStorageLimit() {
|
8072
|
+
return { storeType: 0, limit: 0 };
|
8073
|
+
}
|
8074
|
+
var StorageLimit = {
|
8075
|
+
encode(message, writer = import_minimal7.default.Writer.create()) {
|
8076
|
+
if (message.storeType !== 0) {
|
8077
|
+
writer.uint32(8).int32(message.storeType);
|
8078
|
+
}
|
8079
|
+
if (message.limit !== 0) {
|
8080
|
+
writer.uint32(16).uint64(message.limit);
|
8081
|
+
}
|
8082
|
+
return writer;
|
8083
|
+
},
|
8084
|
+
decode(input, length) {
|
8085
|
+
const reader = input instanceof import_minimal7.default.Reader ? input : import_minimal7.default.Reader.create(input);
|
8086
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
8087
|
+
const message = createBaseStorageLimit();
|
8088
|
+
while (reader.pos < end) {
|
8089
|
+
const tag = reader.uint32();
|
8090
|
+
switch (tag >>> 3) {
|
8091
|
+
case 1:
|
8092
|
+
if (tag != 8) {
|
8093
|
+
break;
|
8094
|
+
}
|
8095
|
+
message.storeType = reader.int32();
|
8096
|
+
continue;
|
8097
|
+
case 2:
|
8098
|
+
if (tag != 16) {
|
8099
|
+
break;
|
8100
|
+
}
|
8101
|
+
message.limit = longToNumber6(reader.uint64());
|
8102
|
+
continue;
|
8103
|
+
}
|
8104
|
+
if ((tag & 7) == 4 || tag == 0) {
|
8105
|
+
break;
|
8106
|
+
}
|
8107
|
+
reader.skipType(tag & 7);
|
8108
|
+
}
|
8109
|
+
return message;
|
8110
|
+
},
|
8111
|
+
fromJSON(object) {
|
8112
|
+
return {
|
8113
|
+
storeType: isSet7(object.storeType) ? storeTypeFromJSON(object.storeType) : 0,
|
8114
|
+
limit: isSet7(object.limit) ? Number(object.limit) : 0
|
8115
|
+
};
|
8116
|
+
},
|
8117
|
+
toJSON(message) {
|
8118
|
+
const obj = {};
|
8119
|
+
message.storeType !== void 0 && (obj.storeType = storeTypeToJSON(message.storeType));
|
8120
|
+
message.limit !== void 0 && (obj.limit = Math.round(message.limit));
|
8121
|
+
return obj;
|
8122
|
+
},
|
8123
|
+
create(base) {
|
8124
|
+
return StorageLimit.fromPartial(base != null ? base : {});
|
8125
|
+
},
|
8126
|
+
fromPartial(object) {
|
8127
|
+
var _a, _b;
|
8128
|
+
const message = createBaseStorageLimit();
|
8129
|
+
message.storeType = (_a = object.storeType) != null ? _a : 0;
|
8130
|
+
message.limit = (_b = object.limit) != null ? _b : 0;
|
7769
8131
|
return message;
|
7770
8132
|
}
|
7771
8133
|
};
|
@@ -8439,12 +8801,14 @@ var HubServiceClientImpl = class {
|
|
8439
8801
|
this.getUserData = this.getUserData.bind(this);
|
8440
8802
|
this.getUserDataByFid = this.getUserDataByFid.bind(this);
|
8441
8803
|
this.getNameRegistryEvent = this.getNameRegistryEvent.bind(this);
|
8442
|
-
this.
|
8804
|
+
this.getOnChainEvents = this.getOnChainEvents.bind(this);
|
8805
|
+
this.getCurrentStorageLimitsByFid = this.getCurrentStorageLimitsByFid.bind(this);
|
8443
8806
|
this.getUsernameProof = this.getUsernameProof.bind(this);
|
8444
8807
|
this.getUserNameProofsByFid = this.getUserNameProofsByFid.bind(this);
|
8445
8808
|
this.getVerification = this.getVerification.bind(this);
|
8446
8809
|
this.getVerificationsByFid = this.getVerificationsByFid.bind(this);
|
8447
8810
|
this.getSigner = this.getSigner.bind(this);
|
8811
|
+
this.getOnChainSigner = this.getOnChainSigner.bind(this);
|
8448
8812
|
this.getSignersByFid = this.getSignersByFid.bind(this);
|
8449
8813
|
this.getIdRegistryEvent = this.getIdRegistryEvent.bind(this);
|
8450
8814
|
this.getIdRegistryEventByAddress = this.getIdRegistryEventByAddress.bind(this);
|
@@ -8507,12 +8871,11 @@ var HubServiceClientImpl = class {
|
|
8507
8871
|
getNameRegistryEvent(request, metadata) {
|
8508
8872
|
return this.rpc.unary(HubServiceGetNameRegistryEventDesc, NameRegistryEventRequest.fromPartial(request), metadata);
|
8509
8873
|
}
|
8510
|
-
|
8511
|
-
return this.rpc.unary(
|
8512
|
-
|
8513
|
-
|
8514
|
-
|
8515
|
-
);
|
8874
|
+
getOnChainEvents(request, metadata) {
|
8875
|
+
return this.rpc.unary(HubServiceGetOnChainEventsDesc, OnChainEventRequest.fromPartial(request), metadata);
|
8876
|
+
}
|
8877
|
+
getCurrentStorageLimitsByFid(request, metadata) {
|
8878
|
+
return this.rpc.unary(HubServiceGetCurrentStorageLimitsByFidDesc, FidRequest.fromPartial(request), metadata);
|
8516
8879
|
}
|
8517
8880
|
getUsernameProof(request, metadata) {
|
8518
8881
|
return this.rpc.unary(HubServiceGetUsernameProofDesc, UsernameProofRequest.fromPartial(request), metadata);
|
@@ -8529,6 +8892,9 @@ var HubServiceClientImpl = class {
|
|
8529
8892
|
getSigner(request, metadata) {
|
8530
8893
|
return this.rpc.unary(HubServiceGetSignerDesc, SignerRequest.fromPartial(request), metadata);
|
8531
8894
|
}
|
8895
|
+
getOnChainSigner(request, metadata) {
|
8896
|
+
return this.rpc.unary(HubServiceGetOnChainSignerDesc, SignerRequest.fromPartial(request), metadata);
|
8897
|
+
}
|
8532
8898
|
getSignersByFid(request, metadata) {
|
8533
8899
|
return this.rpc.unary(HubServiceGetSignersByFidDesc, FidRequest.fromPartial(request), metadata);
|
8534
8900
|
}
|
@@ -8900,19 +9266,41 @@ var HubServiceGetNameRegistryEventDesc = {
|
|
8900
9266
|
}
|
8901
9267
|
}
|
8902
9268
|
};
|
8903
|
-
var
|
8904
|
-
methodName: "
|
9269
|
+
var HubServiceGetOnChainEventsDesc = {
|
9270
|
+
methodName: "GetOnChainEvents",
|
9271
|
+
service: HubServiceDesc,
|
9272
|
+
requestStream: false,
|
9273
|
+
responseStream: false,
|
9274
|
+
requestType: {
|
9275
|
+
serializeBinary() {
|
9276
|
+
return OnChainEventRequest.encode(this).finish();
|
9277
|
+
}
|
9278
|
+
},
|
9279
|
+
responseType: {
|
9280
|
+
deserializeBinary(data) {
|
9281
|
+
const value = OnChainEventResponse.decode(data);
|
9282
|
+
return {
|
9283
|
+
...value,
|
9284
|
+
toObject() {
|
9285
|
+
return value;
|
9286
|
+
}
|
9287
|
+
};
|
9288
|
+
}
|
9289
|
+
}
|
9290
|
+
};
|
9291
|
+
var HubServiceGetCurrentStorageLimitsByFidDesc = {
|
9292
|
+
methodName: "GetCurrentStorageLimitsByFid",
|
8905
9293
|
service: HubServiceDesc,
|
8906
9294
|
requestStream: false,
|
8907
9295
|
responseStream: false,
|
8908
9296
|
requestType: {
|
8909
9297
|
serializeBinary() {
|
8910
|
-
return
|
9298
|
+
return FidRequest.encode(this).finish();
|
8911
9299
|
}
|
8912
9300
|
},
|
8913
9301
|
responseType: {
|
8914
9302
|
deserializeBinary(data) {
|
8915
|
-
const value =
|
9303
|
+
const value = StorageLimitsResponse.decode(data);
|
8916
9304
|
return {
|
8917
9305
|
...value,
|
8918
9306
|
toObject() {
|
@@ -9032,6 +9420,28 @@ var HubServiceGetSignerDesc = {
|
|
9032
9420
|
}
|
9033
9421
|
}
|
9034
9422
|
};
|
9423
|
+
var HubServiceGetOnChainSignerDesc = {
|
9424
|
+
methodName: "GetOnChainSigner",
|
9425
|
+
service: HubServiceDesc,
|
9426
|
+
requestStream: false,
|
9427
|
+
responseStream: false,
|
9428
|
+
requestType: {
|
9429
|
+
serializeBinary() {
|
9430
|
+
return SignerRequest.encode(this).finish();
|
9431
|
+
}
|
9432
|
+
},
|
9433
|
+
responseType: {
|
9434
|
+
deserializeBinary(data) {
|
9435
|
+
const value = OnChainEvent.decode(data);
|
9436
|
+
return {
|
9437
|
+
...value,
|
9438
|
+
toObject() {
|
9439
|
+
return value;
|
9440
|
+
}
|
9441
|
+
};
|
9442
|
+
}
|
9443
|
+
}
|
9444
|
+
};
|
9035
9445
|
var HubServiceGetSignersByFidDesc = {
|
9036
9446
|
methodName: "GetSignersByFid",
|
9037
9447
|
service: HubServiceDesc,
|
@@ -9458,8 +9868,7 @@ var AdminServiceClientImpl = class {
|
|
9458
9868
|
this.deleteAllMessagesFromDb = this.deleteAllMessagesFromDb.bind(this);
|
9459
9869
|
this.submitIdRegistryEvent = this.submitIdRegistryEvent.bind(this);
|
9460
9870
|
this.submitNameRegistryEvent = this.submitNameRegistryEvent.bind(this);
|
9461
|
-
this.
|
9462
|
-
this.submitStorageAdminRegistryEvent = this.submitStorageAdminRegistryEvent.bind(this);
|
9871
|
+
this.submitOnChainEvent = this.submitOnChainEvent.bind(this);
|
9463
9872
|
}
|
9464
9873
|
rebuildSyncTrie(request, metadata) {
|
9465
9874
|
return this.rpc.unary(AdminServiceRebuildSyncTrieDesc, Empty.fromPartial(request), metadata);
|
@@ -9473,15 +9882,8 @@ var AdminServiceClientImpl = class {
|
|
9473
9882
|
submitNameRegistryEvent(request, metadata) {
|
9474
9883
|
return this.rpc.unary(AdminServiceSubmitNameRegistryEventDesc, NameRegistryEvent.fromPartial(request), metadata);
|
9475
9884
|
}
|
9476
|
-
|
9477
|
-
return this.rpc.unary(
|
9478
|
-
}
|
9479
|
-
submitStorageAdminRegistryEvent(request, metadata) {
|
9480
|
-
return this.rpc.unary(
|
9481
|
-
AdminServiceSubmitStorageAdminRegistryEventDesc,
|
9482
|
-
StorageAdminRegistryEvent.fromPartial(request),
|
9483
|
-
metadata
|
9484
|
-
);
|
9885
|
+
submitOnChainEvent(request, metadata) {
|
9886
|
+
return this.rpc.unary(AdminServiceSubmitOnChainEventDesc, OnChainEvent.fromPartial(request), metadata);
|
9485
9887
|
}
|
9486
9888
|
};
|
9487
9889
|
var AdminServiceDesc = { serviceName: "AdminService" };
|
@@ -9573,41 +9975,19 @@ var AdminServiceSubmitNameRegistryEventDesc = {
|
|
9573
9975
|
}
|
9574
9976
|
}
|
9575
9977
|
};
|
9576
|
-
var
|
9577
|
-
methodName: "
|
9578
|
-
service: AdminServiceDesc,
|
9579
|
-
requestStream: false,
|
9580
|
-
responseStream: false,
|
9581
|
-
requestType: {
|
9582
|
-
serializeBinary() {
|
9583
|
-
return RentRegistryEvent.encode(this).finish();
|
9584
|
-
}
|
9585
|
-
},
|
9586
|
-
responseType: {
|
9587
|
-
deserializeBinary(data) {
|
9588
|
-
const value = RentRegistryEvent.decode(data);
|
9589
|
-
return {
|
9590
|
-
...value,
|
9591
|
-
toObject() {
|
9592
|
-
return value;
|
9593
|
-
}
|
9594
|
-
};
|
9595
|
-
}
|
9596
|
-
}
|
9597
|
-
};
|
9598
|
-
var AdminServiceSubmitStorageAdminRegistryEventDesc = {
|
9599
|
-
methodName: "SubmitStorageAdminRegistryEvent",
|
9978
|
+
var AdminServiceSubmitOnChainEventDesc = {
|
9979
|
+
methodName: "SubmitOnChainEvent",
|
9600
9980
|
service: AdminServiceDesc,
|
9601
9981
|
requestStream: false,
|
9602
9982
|
responseStream: false,
|
9603
9983
|
requestType: {
|
9604
9984
|
serializeBinary() {
|
9605
|
-
return
|
9985
|
+
return OnChainEvent.encode(this).finish();
|
9606
9986
|
}
|
9607
9987
|
},
|
9608
9988
|
responseType: {
|
9609
9989
|
deserializeBinary(data) {
|
9610
|
-
const value =
|
9990
|
+
const value = OnChainEvent.decode(data);
|
9611
9991
|
return {
|
9612
9992
|
...value,
|
9613
9993
|
toObject() {
|
@@ -9629,14 +10009,14 @@ var GrpcWebImpl = class {
|
|
9629
10009
|
const request = { ..._request, ...methodDesc.requestType };
|
9630
10010
|
const maybeCombinedMetadata = metadata && this.options.metadata ? new import_browser_headers.BrowserHeaders({ ...(_a = this.options) == null ? void 0 : _a.metadata.headersMap, ...metadata == null ? void 0 : metadata.headersMap }) : metadata || this.options.metadata;
|
9631
10011
|
return new Promise((resolve, reject) => {
|
9632
|
-
import_grpc_web.grpc.unary(methodDesc, {
|
10012
|
+
import_grpc_web.default.grpc.unary(methodDesc, {
|
9633
10013
|
request,
|
9634
10014
|
host: this.host,
|
9635
10015
|
metadata: maybeCombinedMetadata,
|
9636
10016
|
transport: this.options.transport,
|
9637
10017
|
debug: this.options.debug,
|
9638
10018
|
onEnd: function(response) {
|
9639
|
-
if (response.status === import_grpc_web.grpc.Code.OK) {
|
10019
|
+
if (response.status === import_grpc_web.default.grpc.Code.OK) {
|
9640
10020
|
resolve(response.message.toObject());
|
9641
10021
|
} else {
|
9642
10022
|
const err2 = new GrpcWebError(response.statusMessage, response.status, response.trailers);
|
@@ -9654,7 +10034,7 @@ var GrpcWebImpl = class {
|
|
9654
10034
|
const maybeCombinedMetadata = metadata && this.options.metadata ? new import_browser_headers.BrowserHeaders({ ...(_a = this.options) == null ? void 0 : _a.metadata.headersMap, ...metadata == null ? void 0 : metadata.headersMap }) : metadata || this.options.metadata;
|
9655
10035
|
return new import_rxjs.Observable((observer) => {
|
9656
10036
|
const upStream = () => {
|
9657
|
-
const client = import_grpc_web.grpc.invoke(methodDesc, {
|
10037
|
+
const client = import_grpc_web.default.grpc.invoke(methodDesc, {
|
9658
10038
|
host: this.host,
|
9659
10039
|
request,
|
9660
10040
|
transport: this.options.streamingTransport || this.options.transport,
|
@@ -10194,8 +10574,7 @@ var getAuthMetadata = (username, password) => {
|
|
10194
10574
|
AdminServiceRebuildSyncTrieDesc,
|
10195
10575
|
AdminServiceSubmitIdRegistryEventDesc,
|
10196
10576
|
AdminServiceSubmitNameRegistryEventDesc,
|
10197
|
-
|
10198
|
-
AdminServiceSubmitStorageAdminRegistryEventDesc,
|
10577
|
+
AdminServiceSubmitOnChainEventDesc,
|
10199
10578
|
GrpcWebError,
|
10200
10579
|
GrpcWebImpl,
|
10201
10580
|
HubServiceClientImpl,
|
@@ -10212,6 +10591,7 @@ var getAuthMetadata = (username, password) => {
|
|
10212
10591
|
HubServiceGetCastsByFidDesc,
|
10213
10592
|
HubServiceGetCastsByMentionDesc,
|
10214
10593
|
HubServiceGetCastsByParentDesc,
|
10594
|
+
HubServiceGetCurrentStorageLimitsByFidDesc,
|
10215
10595
|
HubServiceGetEventDesc,
|
10216
10596
|
HubServiceGetFidsDesc,
|
10217
10597
|
HubServiceGetIdRegistryEventByAddressDesc,
|
@@ -10221,11 +10601,12 @@ var getAuthMetadata = (username, password) => {
|
|
10221
10601
|
HubServiceGetLinksByFidDesc,
|
10222
10602
|
HubServiceGetLinksByTargetDesc,
|
10223
10603
|
HubServiceGetNameRegistryEventDesc,
|
10604
|
+
HubServiceGetOnChainEventsDesc,
|
10605
|
+
HubServiceGetOnChainSignerDesc,
|
10224
10606
|
HubServiceGetReactionDesc,
|
10225
10607
|
HubServiceGetReactionsByCastDesc,
|
10226
10608
|
HubServiceGetReactionsByFidDesc,
|
10227
10609
|
HubServiceGetReactionsByTargetDesc,
|
10228
|
-
HubServiceGetRentRegistryEventsDesc,
|
10229
10610
|
HubServiceGetSignerDesc,
|
10230
10611
|
HubServiceGetSignersByFidDesc,
|
10231
10612
|
HubServiceGetSyncMetadataByPrefixDesc,
|