@sparkdreamnft/sparkdreamjs 0.0.16 → 0.0.18

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.
Files changed (264) hide show
  1. package/cosmos/bundle.d.ts +160 -160
  2. package/cosmos/bundle.js +182 -182
  3. package/esm/cosmos/bundle.js +182 -182
  4. package/esm/ibc/bundle.js +106 -106
  5. package/esm/sparkdream/blog/v1/params.js +51 -50
  6. package/esm/sparkdream/blog/v1/tx.amino.js +53 -20
  7. package/esm/sparkdream/bundle.js +448 -346
  8. package/esm/sparkdream/client.js +7 -1
  9. package/esm/sparkdream/collect/v1/params.js +13 -1
  10. package/esm/sparkdream/collect/v1/tx.amino.js +138 -36
  11. package/esm/sparkdream/collect/v1/types.js +13 -1
  12. package/esm/sparkdream/commons/v1/genesis.js +29 -1
  13. package/esm/sparkdream/commons/v1/query.js +317 -0
  14. package/esm/sparkdream/commons/v1/query.lcd.js +23 -0
  15. package/esm/sparkdream/commons/v1/query.rpc.Query.js +20 -1
  16. package/esm/sparkdream/commons/v1/recurring_spend.js +296 -0
  17. package/esm/sparkdream/commons/v1/tx.amino.js +76 -6
  18. package/esm/sparkdream/commons/v1/tx.js +693 -0
  19. package/esm/sparkdream/commons/v1/tx.registry.js +74 -2
  20. package/esm/sparkdream/commons/v1/tx.rpc.msg.js +33 -1
  21. package/esm/sparkdream/ecosystem/v1/tx.amino.js +18 -4
  22. package/esm/sparkdream/federation/v1/genesis.js +10 -10
  23. package/esm/sparkdream/federation/v1/params.js +29 -54
  24. package/esm/sparkdream/federation/v1/query.js +216 -71
  25. package/esm/sparkdream/federation/v1/query.lcd.js +11 -6
  26. package/esm/sparkdream/federation/v1/query.rpc.Query.js +24 -15
  27. package/esm/sparkdream/federation/v1/tx.amino.js +21 -21
  28. package/esm/sparkdream/federation/v1/tx.js +1146 -1105
  29. package/esm/sparkdream/federation/v1/tx.registry.js +74 -74
  30. package/esm/sparkdream/federation/v1/tx.rpc.msg.js +32 -26
  31. package/esm/sparkdream/federation/v1/types.js +355 -99
  32. package/esm/sparkdream/federation/v1/verifier_activity.js +13 -1
  33. package/esm/sparkdream/forum/v1/params.js +173 -148
  34. package/esm/sparkdream/forum/v1/tx.amino.js +69 -40
  35. package/esm/sparkdream/guardian/module/v1/module.js +68 -0
  36. package/esm/sparkdream/guardian/v1/query.js +128 -0
  37. package/esm/sparkdream/guardian/v1/query.lcd.js +13 -0
  38. package/esm/sparkdream/guardian/v1/query.rpc.Query.js +26 -0
  39. package/esm/sparkdream/guardian/v1/tx.amino.js +9 -0
  40. package/esm/sparkdream/guardian/v1/tx.js +175 -0
  41. package/esm/sparkdream/guardian/v1/tx.registry.js +33 -0
  42. package/esm/sparkdream/guardian/v1/tx.rpc.msg.js +24 -0
  43. package/esm/sparkdream/identity/module/v1/module.js +71 -0
  44. package/esm/sparkdream/identity/v1/chain_identity.js +199 -0
  45. package/esm/sparkdream/identity/v1/genesis.js +84 -0
  46. package/esm/sparkdream/identity/v1/query.js +372 -0
  47. package/esm/sparkdream/identity/v1/query.lcd.js +21 -0
  48. package/esm/sparkdream/identity/v1/query.rpc.Query.js +42 -0
  49. package/esm/sparkdream/lcd.js +15 -0
  50. package/esm/sparkdream/name/v1/params.js +19 -18
  51. package/esm/sparkdream/rep/v1/bonded_role.js +48 -2
  52. package/esm/sparkdream/rep/v1/tag.js +6 -13
  53. package/esm/sparkdream/rep/v1/tx.amino.js +177 -58
  54. package/esm/sparkdream/reveal/v1/tx.amino.js +34 -13
  55. package/esm/sparkdream/rpc.query.js +9 -0
  56. package/esm/sparkdream/rpc.tx.js +6 -0
  57. package/esm/sparkdream/service/module/v1/module.js +71 -0
  58. package/esm/sparkdream/service/v1/controller_transfer_case.js +155 -0
  59. package/esm/sparkdream/service/v1/genesis.js +240 -0
  60. package/esm/sparkdream/service/v1/operator.js +250 -0
  61. package/esm/sparkdream/service/v1/params.js +355 -0
  62. package/esm/sparkdream/service/v1/query.js +1582 -0
  63. package/esm/sparkdream/service/v1/query.lcd.js +107 -0
  64. package/esm/sparkdream/service/v1/query.rpc.Query.js +109 -0
  65. package/esm/sparkdream/service/v1/refile_cooldown.js +121 -0
  66. package/esm/sparkdream/service/v1/report.js +212 -0
  67. package/esm/sparkdream/service/v1/reporter_rate_limit.js +137 -0
  68. package/esm/sparkdream/service/v1/service_type_config.js +264 -0
  69. package/esm/sparkdream/service/v1/system_report_rate_limit.js +115 -0
  70. package/esm/sparkdream/service/v1/tier1_escrow_entry.js +145 -0
  71. package/esm/sparkdream/service/v1/tier1_last_slash.js +121 -0
  72. package/esm/sparkdream/service/v1/tx.amino.js +69 -0
  73. package/esm/sparkdream/service/v1/tx.js +2124 -0
  74. package/esm/sparkdream/service/v1/tx.registry.js +249 -0
  75. package/esm/sparkdream/service/v1/tx.rpc.msg.js +100 -0
  76. package/esm/sparkdream/service/v1/types.js +353 -0
  77. package/esm/sparkdream/session/v1/genesis.js +136 -10
  78. package/esm/sparkdream/session/v1/grant.js +1020 -0
  79. package/esm/sparkdream/session/v1/params.js +543 -19
  80. package/esm/sparkdream/session/v1/query.js +487 -0
  81. package/esm/sparkdream/session/v1/query.lcd.js +41 -3
  82. package/esm/sparkdream/session/v1/query.rpc.Query.js +36 -4
  83. package/esm/sparkdream/session/v1/session.js +6 -0
  84. package/esm/sparkdream/session/v1/tx.amino.js +17 -1
  85. package/esm/sparkdream/session/v1/tx.js +1066 -0
  86. package/esm/sparkdream/session/v1/tx.registry.js +110 -2
  87. package/esm/sparkdream/session/v1/tx.rpc.msg.js +65 -3
  88. package/esm/sparkdream/shield/v1/tx.amino.js +61 -8
  89. package/esm/tendermint/bundle.js +20 -20
  90. package/ibc/bundle.d.ts +90 -90
  91. package/ibc/bundle.js +106 -106
  92. package/package.json +1 -1
  93. package/sparkdream/blog/v1/params.d.ts +37 -28
  94. package/sparkdream/blog/v1/params.js +51 -50
  95. package/sparkdream/blog/v1/post.d.ts +2 -2
  96. package/sparkdream/blog/v1/tx.amino.d.ts +2 -2
  97. package/sparkdream/blog/v1/tx.amino.js +53 -20
  98. package/sparkdream/blog/v1/tx.d.ts +4 -4
  99. package/sparkdream/bundle.d.ts +14945 -12924
  100. package/sparkdream/bundle.js +448 -346
  101. package/sparkdream/client.d.ts +125 -50
  102. package/sparkdream/client.js +7 -1
  103. package/sparkdream/collect/v1/params.d.ts +16 -0
  104. package/sparkdream/collect/v1/params.js +13 -1
  105. package/sparkdream/collect/v1/tx.amino.d.ts +7 -7
  106. package/sparkdream/collect/v1/tx.amino.js +138 -36
  107. package/sparkdream/collect/v1/types.d.ts +2 -0
  108. package/sparkdream/collect/v1/types.js +13 -1
  109. package/sparkdream/commons/v1/genesis.d.ts +17 -0
  110. package/sparkdream/commons/v1/genesis.js +29 -1
  111. package/sparkdream/commons/v1/query.d.ts +186 -0
  112. package/sparkdream/commons/v1/query.js +318 -1
  113. package/sparkdream/commons/v1/query.lcd.d.ts +3 -1
  114. package/sparkdream/commons/v1/query.lcd.js +23 -0
  115. package/sparkdream/commons/v1/query.rpc.Query.d.ts +12 -1
  116. package/sparkdream/commons/v1/query.rpc.Query.js +19 -0
  117. package/sparkdream/commons/v1/recurring_spend.d.ts +234 -0
  118. package/sparkdream/commons/v1/recurring_spend.js +301 -0
  119. package/sparkdream/commons/v1/tx.amino.d.ts +11 -6
  120. package/sparkdream/commons/v1/tx.amino.js +75 -5
  121. package/sparkdream/commons/v1/tx.d.ts +472 -0
  122. package/sparkdream/commons/v1/tx.js +694 -1
  123. package/sparkdream/commons/v1/tx.registry.d.ts +49 -1
  124. package/sparkdream/commons/v1/tx.registry.js +73 -1
  125. package/sparkdream/commons/v1/tx.rpc.msg.d.ts +29 -1
  126. package/sparkdream/commons/v1/tx.rpc.msg.js +32 -0
  127. package/sparkdream/ecosystem/v1/tx.amino.d.ts +1 -1
  128. package/sparkdream/ecosystem/v1/tx.amino.js +19 -5
  129. package/sparkdream/federation/v1/genesis.d.ts +3 -3
  130. package/sparkdream/federation/v1/genesis.js +9 -9
  131. package/sparkdream/federation/v1/params.d.ts +64 -13
  132. package/sparkdream/federation/v1/params.js +29 -54
  133. package/sparkdream/federation/v1/query.d.ts +209 -100
  134. package/sparkdream/federation/v1/query.js +216 -71
  135. package/sparkdream/federation/v1/query.lcd.d.ts +4 -3
  136. package/sparkdream/federation/v1/query.lcd.js +11 -6
  137. package/sparkdream/federation/v1/query.rpc.Query.d.ts +10 -7
  138. package/sparkdream/federation/v1/query.rpc.Query.js +24 -15
  139. package/sparkdream/federation/v1/tx.amino.d.ts +21 -21
  140. package/sparkdream/federation/v1/tx.amino.js +20 -20
  141. package/sparkdream/federation/v1/tx.d.ts +479 -352
  142. package/sparkdream/federation/v1/tx.js +1147 -1106
  143. package/sparkdream/federation/v1/tx.registry.d.ts +49 -49
  144. package/sparkdream/federation/v1/tx.registry.js +73 -73
  145. package/sparkdream/federation/v1/tx.rpc.msg.d.ts +18 -9
  146. package/sparkdream/federation/v1/tx.rpc.msg.js +31 -25
  147. package/sparkdream/federation/v1/types.d.ts +307 -41
  148. package/sparkdream/federation/v1/types.js +360 -100
  149. package/sparkdream/federation/v1/verifier_activity.d.ts +18 -0
  150. package/sparkdream/federation/v1/verifier_activity.js +13 -1
  151. package/sparkdream/forum/v1/params.d.ts +99 -62
  152. package/sparkdream/forum/v1/params.js +173 -148
  153. package/sparkdream/forum/v1/tx.amino.d.ts +2 -2
  154. package/sparkdream/forum/v1/tx.amino.js +69 -40
  155. package/sparkdream/guardian/module/v1/module.d.ts +74 -0
  156. package/sparkdream/guardian/module/v1/module.js +71 -0
  157. package/sparkdream/guardian/v1/query.d.ts +88 -0
  158. package/sparkdream/guardian/v1/query.js +131 -0
  159. package/sparkdream/guardian/v1/query.lcd.d.ts +9 -0
  160. package/sparkdream/guardian/v1/query.lcd.js +17 -0
  161. package/sparkdream/guardian/v1/query.rpc.Query.d.ts +20 -0
  162. package/sparkdream/guardian/v1/query.rpc.Query.js +31 -0
  163. package/sparkdream/guardian/v1/tx.amino.d.ts +8 -0
  164. package/sparkdream/guardian/v1/tx.amino.js +12 -0
  165. package/sparkdream/guardian/v1/tx.d.ts +138 -0
  166. package/sparkdream/guardian/v1/tx.js +181 -0
  167. package/sparkdream/guardian/v1/tx.registry.d.ts +25 -0
  168. package/sparkdream/guardian/v1/tx.registry.js +37 -0
  169. package/sparkdream/guardian/v1/tx.rpc.msg.d.ts +22 -0
  170. package/sparkdream/guardian/v1/tx.rpc.msg.js +29 -0
  171. package/sparkdream/identity/module/v1/module.d.ts +54 -0
  172. package/sparkdream/identity/module/v1/module.js +74 -0
  173. package/sparkdream/identity/v1/chain_identity.d.ts +131 -0
  174. package/sparkdream/identity/v1/chain_identity.js +202 -0
  175. package/sparkdream/identity/v1/genesis.d.ts +65 -0
  176. package/sparkdream/identity/v1/genesis.js +87 -0
  177. package/sparkdream/identity/v1/query.d.ts +243 -0
  178. package/sparkdream/identity/v1/query.js +375 -0
  179. package/sparkdream/identity/v1/query.lcd.d.ts +11 -0
  180. package/sparkdream/identity/v1/query.lcd.js +25 -0
  181. package/sparkdream/identity/v1/query.rpc.Query.d.ts +26 -0
  182. package/sparkdream/identity/v1/query.rpc.Query.js +47 -0
  183. package/sparkdream/lcd.d.ts +9 -0
  184. package/sparkdream/lcd.js +15 -0
  185. package/sparkdream/name/v1/params.d.ts +25 -8
  186. package/sparkdream/name/v1/params.js +19 -18
  187. package/sparkdream/rep/v1/bonded_role.d.ts +51 -0
  188. package/sparkdream/rep/v1/bonded_role.js +48 -2
  189. package/sparkdream/rep/v1/tag.d.ts +15 -2
  190. package/sparkdream/rep/v1/tag.js +6 -13
  191. package/sparkdream/rep/v1/tx.amino.d.ts +9 -9
  192. package/sparkdream/rep/v1/tx.amino.js +177 -58
  193. package/sparkdream/reveal/v1/tx.amino.d.ts +1 -1
  194. package/sparkdream/reveal/v1/tx.amino.js +34 -13
  195. package/sparkdream/rpc.query.d.ts +34 -2
  196. package/sparkdream/rpc.query.js +9 -0
  197. package/sparkdream/rpc.tx.d.ts +6 -0
  198. package/sparkdream/rpc.tx.js +6 -0
  199. package/sparkdream/service/module/v1/module.d.ts +54 -0
  200. package/sparkdream/service/module/v1/module.js +74 -0
  201. package/sparkdream/service/v1/controller_transfer_case.d.ts +125 -0
  202. package/sparkdream/service/v1/controller_transfer_case.js +158 -0
  203. package/sparkdream/service/v1/genesis.d.ts +172 -0
  204. package/sparkdream/service/v1/genesis.js +243 -0
  205. package/sparkdream/service/v1/operator.d.ts +215 -0
  206. package/sparkdream/service/v1/operator.js +253 -0
  207. package/sparkdream/service/v1/params.d.ts +346 -0
  208. package/sparkdream/service/v1/params.js +358 -0
  209. package/sparkdream/service/v1/query.d.ts +964 -0
  210. package/sparkdream/service/v1/query.js +1585 -0
  211. package/sparkdream/service/v1/query.lcd.d.ts +18 -0
  212. package/sparkdream/service/v1/query.lcd.js +111 -0
  213. package/sparkdream/service/v1/query.rpc.Query.d.ts +63 -0
  214. package/sparkdream/service/v1/query.rpc.Query.js +114 -0
  215. package/sparkdream/service/v1/refile_cooldown.d.ts +105 -0
  216. package/sparkdream/service/v1/refile_cooldown.js +124 -0
  217. package/sparkdream/service/v1/report.d.ts +174 -0
  218. package/sparkdream/service/v1/report.js +215 -0
  219. package/sparkdream/service/v1/reporter_rate_limit.d.ts +112 -0
  220. package/sparkdream/service/v1/reporter_rate_limit.js +140 -0
  221. package/sparkdream/service/v1/service_type_config.d.ts +222 -0
  222. package/sparkdream/service/v1/service_type_config.js +269 -0
  223. package/sparkdream/service/v1/system_report_rate_limit.d.ts +106 -0
  224. package/sparkdream/service/v1/system_report_rate_limit.js +118 -0
  225. package/sparkdream/service/v1/tier1_escrow_entry.d.ts +125 -0
  226. package/sparkdream/service/v1/tier1_escrow_entry.js +148 -0
  227. package/sparkdream/service/v1/tier1_last_slash.d.ts +101 -0
  228. package/sparkdream/service/v1/tier1_last_slash.js +124 -0
  229. package/sparkdream/service/v1/tx.amino.d.ts +68 -0
  230. package/sparkdream/service/v1/tx.amino.js +72 -0
  231. package/sparkdream/service/v1/tx.d.ts +1264 -0
  232. package/sparkdream/service/v1/tx.js +2127 -0
  233. package/sparkdream/service/v1/tx.registry.d.ts +169 -0
  234. package/sparkdream/service/v1/tx.registry.js +253 -0
  235. package/sparkdream/service/v1/tx.rpc.msg.d.ts +80 -0
  236. package/sparkdream/service/v1/tx.rpc.msg.js +105 -0
  237. package/sparkdream/service/v1/types.d.ts +94 -0
  238. package/sparkdream/service/v1/types.js +370 -0
  239. package/sparkdream/session/v1/genesis.d.ts +93 -9
  240. package/sparkdream/session/v1/genesis.js +137 -11
  241. package/sparkdream/session/v1/grant.d.ts +517 -0
  242. package/sparkdream/session/v1/grant.js +1027 -0
  243. package/sparkdream/session/v1/params.d.ts +338 -7
  244. package/sparkdream/session/v1/params.js +543 -19
  245. package/sparkdream/session/v1/query.d.ts +265 -0
  246. package/sparkdream/session/v1/query.js +488 -1
  247. package/sparkdream/session/v1/query.lcd.d.ts +4 -1
  248. package/sparkdream/session/v1/query.lcd.js +41 -3
  249. package/sparkdream/session/v1/query.rpc.Query.d.ts +27 -4
  250. package/sparkdream/session/v1/query.rpc.Query.js +35 -3
  251. package/sparkdream/session/v1/session.d.ts +18 -0
  252. package/sparkdream/session/v1/session.js +6 -0
  253. package/sparkdream/session/v1/tx.amino.d.ts +1 -1
  254. package/sparkdream/session/v1/tx.amino.js +17 -1
  255. package/sparkdream/session/v1/tx.d.ts +660 -0
  256. package/sparkdream/session/v1/tx.js +1067 -1
  257. package/sparkdream/session/v1/tx.registry.d.ts +73 -1
  258. package/sparkdream/session/v1/tx.registry.js +109 -1
  259. package/sparkdream/session/v1/tx.rpc.msg.d.ts +63 -3
  260. package/sparkdream/session/v1/tx.rpc.msg.js +64 -2
  261. package/sparkdream/shield/v1/tx.amino.d.ts +3 -3
  262. package/sparkdream/shield/v1/tx.amino.js +61 -8
  263. package/tendermint/bundle.d.ts +844 -844
  264. package/tendermint/bundle.js +20 -20
@@ -0,0 +1,47 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.createRpcQueryExtension = exports.QueryClientImpl = void 0;
4
+ const binary_1 = require("../../../binary");
5
+ const stargate_1 = require("@cosmjs/stargate");
6
+ const query_1 = require("./query");
7
+ class QueryClientImpl {
8
+ rpc;
9
+ constructor(rpc) {
10
+ this.rpc = rpc;
11
+ }
12
+ /* ChainIdentity returns the chain's immutable identity record. */
13
+ chainIdentity = async (request = {}) => {
14
+ const data = query_1.QueryChainIdentityRequest.encode(request).finish();
15
+ const promise = this.rpc.request("sparkdream.identity.v1.Query", "ChainIdentity", data);
16
+ return promise.then(data => query_1.QueryChainIdentityResponse.decode(new binary_1.BinaryReader(data)));
17
+ };
18
+ /* BondDenom is a convenience wrapper returning the native gas/staking denom. */
19
+ bondDenom = async (request = {}) => {
20
+ const data = query_1.QueryBondDenomRequest.encode(request).finish();
21
+ const promise = this.rpc.request("sparkdream.identity.v1.Query", "BondDenom", data);
22
+ return promise.then(data => query_1.QueryBondDenomResponse.decode(new binary_1.BinaryReader(data)));
23
+ };
24
+ /* DreamDenom is a convenience wrapper returning the native DREAM denom. */
25
+ dreamDenom = async (request = {}) => {
26
+ const data = query_1.QueryDreamDenomRequest.encode(request).finish();
27
+ const promise = this.rpc.request("sparkdream.identity.v1.Query", "DreamDenom", data);
28
+ return promise.then(data => query_1.QueryDreamDenomResponse.decode(new binary_1.BinaryReader(data)));
29
+ };
30
+ }
31
+ exports.QueryClientImpl = QueryClientImpl;
32
+ const createRpcQueryExtension = (base) => {
33
+ const rpc = (0, stargate_1.createProtobufRpcClient)(base);
34
+ const queryService = new QueryClientImpl(rpc);
35
+ return {
36
+ chainIdentity(request) {
37
+ return queryService.chainIdentity(request);
38
+ },
39
+ bondDenom(request) {
40
+ return queryService.bondDenom(request);
41
+ },
42
+ dreamDenom(request) {
43
+ return queryService.dreamDenom(request);
44
+ }
45
+ };
46
+ };
47
+ exports.createRpcQueryExtension = createRpcQueryExtension;
@@ -79,6 +79,12 @@ export declare const createLCDClient: ({ restEndpoint }: {
79
79
  futarchy: {
80
80
  v1: import("./futarchy/v1/query.lcd").LCDQueryClient;
81
81
  };
82
+ guardian: {
83
+ v1: import("./guardian/v1/query.lcd").LCDQueryClient;
84
+ };
85
+ identity: {
86
+ v1: import("./identity/v1/query.lcd").LCDQueryClient;
87
+ };
82
88
  name: {
83
89
  v1: import("./name/v1/query.lcd").LCDQueryClient;
84
90
  };
@@ -91,6 +97,9 @@ export declare const createLCDClient: ({ restEndpoint }: {
91
97
  season: {
92
98
  v1: import("./season/v1/query.lcd").LCDQueryClient;
93
99
  };
100
+ service: {
101
+ v1: import("./service/v1/query.lcd").LCDQueryClient;
102
+ };
94
103
  session: {
95
104
  v1: import("./session/v1/query.lcd").LCDQueryClient;
96
105
  };
package/sparkdream/lcd.js CHANGED
@@ -169,6 +169,16 @@ const createLCDClient = async ({ restEndpoint }) => {
169
169
  requestClient
170
170
  })
171
171
  },
172
+ guardian: {
173
+ v1: new (await Promise.resolve().then(() => __importStar(require("./guardian/v1/query.lcd")))).LCDQueryClient({
174
+ requestClient
175
+ })
176
+ },
177
+ identity: {
178
+ v1: new (await Promise.resolve().then(() => __importStar(require("./identity/v1/query.lcd")))).LCDQueryClient({
179
+ requestClient
180
+ })
181
+ },
172
182
  name: {
173
183
  v1: new (await Promise.resolve().then(() => __importStar(require("./name/v1/query.lcd")))).LCDQueryClient({
174
184
  requestClient
@@ -189,6 +199,11 @@ const createLCDClient = async ({ restEndpoint }) => {
189
199
  requestClient
190
200
  })
191
201
  },
202
+ service: {
203
+ v1: new (await Promise.resolve().then(() => __importStar(require("./service/v1/query.lcd")))).LCDQueryClient({
204
+ requestClient
205
+ })
206
+ },
192
207
  session: {
193
208
  v1: new (await Promise.resolve().then(() => __importStar(require("./session/v1/query.lcd")))).LCDQueryClient({
194
209
  requestClient
@@ -1,9 +1,10 @@
1
1
  import { Duration, DurationAmino } from "../../../google/protobuf/duration";
2
- import { Coin, CoinAmino } from "../../../cosmos/base/v1beta1/coin";
3
2
  import { BinaryReader, BinaryWriter } from "../../../binary";
4
3
  import { DeepPartial } from "../../../helpers";
5
4
  /**
6
- * Params defines the parameters for the module.
5
+ * Params defines the parameters for the module. Fee amounts are bare
6
+ * math.Int values in the chain's bond/dream denom — wrapped into sdk.Coin
7
+ * at the point of use via the identity keeper.
7
8
  * @name Params
8
9
  * @package sparkdream.name.v1
9
10
  * @see proto type: sparkdream.name.v1.Params
@@ -14,7 +15,10 @@ export interface Params {
14
15
  maxNameLength: bigint;
15
16
  maxNamesPerAddress: bigint;
16
17
  expirationDuration: Duration;
17
- registrationFee: Coin;
18
+ /**
19
+ * Registration fee amount in bond-denom micro-units.
20
+ */
21
+ registrationFeeAmount: string;
18
22
  /**
19
23
  * DREAM tokens staked by claimant when filing a dispute (default 50)
20
24
  */
@@ -33,7 +37,9 @@ export interface ParamsProtoMsg {
33
37
  value: Uint8Array;
34
38
  }
35
39
  /**
36
- * Params defines the parameters for the module.
40
+ * Params defines the parameters for the module. Fee amounts are bare
41
+ * math.Int values in the chain's bond/dream denom — wrapped into sdk.Coin
42
+ * at the point of use via the identity keeper.
37
43
  * @name ParamsAmino
38
44
  * @package sparkdream.name.v1
39
45
  * @see proto type: sparkdream.name.v1.Params
@@ -44,7 +50,10 @@ export interface ParamsAmino {
44
50
  max_name_length?: string;
45
51
  max_names_per_address?: string;
46
52
  expiration_duration?: DurationAmino;
47
- registration_fee: CoinAmino;
53
+ /**
54
+ * Registration fee amount in bond-denom micro-units.
55
+ */
56
+ registration_fee_amount?: string;
48
57
  /**
49
58
  * DREAM tokens staked by claimant when filing a dispute (default 50)
50
59
  */
@@ -73,7 +82,10 @@ export interface ParamsAminoMsg {
73
82
  */
74
83
  export interface NameOperationalParams {
75
84
  expirationDuration: Duration;
76
- registrationFee: Coin;
85
+ /**
86
+ * Registration fee amount in bond-denom micro-units.
87
+ */
88
+ registrationFeeAmount: string;
77
89
  /**
78
90
  * DREAM tokens staked by claimant when filing a dispute (default 50)
79
91
  */
@@ -102,7 +114,10 @@ export interface NameOperationalParamsProtoMsg {
102
114
  */
103
115
  export interface NameOperationalParamsAmino {
104
116
  expiration_duration?: DurationAmino;
105
- registration_fee: CoinAmino;
117
+ /**
118
+ * Registration fee amount in bond-denom micro-units.
119
+ */
120
+ registration_fee_amount?: string;
106
121
  /**
107
122
  * DREAM tokens staked by claimant when filing a dispute (default 50)
108
123
  */
@@ -121,7 +136,9 @@ export interface NameOperationalParamsAminoMsg {
121
136
  value: NameOperationalParamsAmino;
122
137
  }
123
138
  /**
124
- * Params defines the parameters for the module.
139
+ * Params defines the parameters for the module. Fee amounts are bare
140
+ * math.Int values in the chain's bond/dream denom — wrapped into sdk.Coin
141
+ * at the point of use via the identity keeper.
125
142
  * @name Params
126
143
  * @package sparkdream.name.v1
127
144
  * @see proto type: sparkdream.name.v1.Params
@@ -3,7 +3,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.NameOperationalParams = exports.Params = void 0;
4
4
  //@ts-nocheck
5
5
  const duration_1 = require("../../../google/protobuf/duration");
6
- const coin_1 = require("../../../cosmos/base/v1beta1/coin");
7
6
  const binary_1 = require("../../../binary");
8
7
  function createBaseParams() {
9
8
  return {
@@ -12,14 +11,16 @@ function createBaseParams() {
12
11
  maxNameLength: BigInt(0),
13
12
  maxNamesPerAddress: BigInt(0),
14
13
  expirationDuration: duration_1.Duration.fromPartial({}),
15
- registrationFee: coin_1.Coin.fromPartial({}),
14
+ registrationFeeAmount: "",
16
15
  disputeStakeDream: "",
17
16
  disputeTimeoutBlocks: BigInt(0),
18
17
  contestStakeDream: ""
19
18
  };
20
19
  }
21
20
  /**
22
- * Params defines the parameters for the module.
21
+ * Params defines the parameters for the module. Fee amounts are bare
22
+ * math.Int values in the chain's bond/dream denom — wrapped into sdk.Coin
23
+ * at the point of use via the identity keeper.
23
24
  * @name Params
24
25
  * @package sparkdream.name.v1
25
26
  * @see proto type: sparkdream.name.v1.Params
@@ -43,8 +44,8 @@ exports.Params = {
43
44
  if (message.expirationDuration !== undefined) {
44
45
  duration_1.Duration.encode(message.expirationDuration, writer.uint32(42).fork()).ldelim();
45
46
  }
46
- if (message.registrationFee !== undefined) {
47
- coin_1.Coin.encode(message.registrationFee, writer.uint32(50).fork()).ldelim();
47
+ if (message.registrationFeeAmount !== "") {
48
+ writer.uint32(50).string(message.registrationFeeAmount);
48
49
  }
49
50
  if (message.disputeStakeDream !== "") {
50
51
  writer.uint32(58).string(message.disputeStakeDream);
@@ -80,7 +81,7 @@ exports.Params = {
80
81
  message.expirationDuration = duration_1.Duration.decode(reader, reader.uint32());
81
82
  break;
82
83
  case 6:
83
- message.registrationFee = coin_1.Coin.decode(reader, reader.uint32());
84
+ message.registrationFeeAmount = reader.string();
84
85
  break;
85
86
  case 7:
86
87
  message.disputeStakeDream = reader.string();
@@ -105,7 +106,7 @@ exports.Params = {
105
106
  message.maxNameLength = object.maxNameLength !== undefined && object.maxNameLength !== null ? BigInt(object.maxNameLength.toString()) : BigInt(0);
106
107
  message.maxNamesPerAddress = object.maxNamesPerAddress !== undefined && object.maxNamesPerAddress !== null ? BigInt(object.maxNamesPerAddress.toString()) : BigInt(0);
107
108
  message.expirationDuration = object.expirationDuration !== undefined && object.expirationDuration !== null ? duration_1.Duration.fromPartial(object.expirationDuration) : undefined;
108
- message.registrationFee = object.registrationFee !== undefined && object.registrationFee !== null ? coin_1.Coin.fromPartial(object.registrationFee) : undefined;
109
+ message.registrationFeeAmount = object.registrationFeeAmount ?? "";
109
110
  message.disputeStakeDream = object.disputeStakeDream ?? "";
110
111
  message.disputeTimeoutBlocks = object.disputeTimeoutBlocks !== undefined && object.disputeTimeoutBlocks !== null ? BigInt(object.disputeTimeoutBlocks.toString()) : BigInt(0);
111
112
  message.contestStakeDream = object.contestStakeDream ?? "";
@@ -126,8 +127,8 @@ exports.Params = {
126
127
  if (object.expiration_duration !== undefined && object.expiration_duration !== null) {
127
128
  message.expirationDuration = duration_1.Duration.fromAmino(object.expiration_duration);
128
129
  }
129
- if (object.registration_fee !== undefined && object.registration_fee !== null) {
130
- message.registrationFee = coin_1.Coin.fromAmino(object.registration_fee);
130
+ if (object.registration_fee_amount !== undefined && object.registration_fee_amount !== null) {
131
+ message.registrationFeeAmount = object.registration_fee_amount;
131
132
  }
132
133
  if (object.dispute_stake_dream !== undefined && object.dispute_stake_dream !== null) {
133
134
  message.disputeStakeDream = object.dispute_stake_dream;
@@ -152,7 +153,7 @@ exports.Params = {
152
153
  obj.max_name_length = message.maxNameLength !== BigInt(0) ? message.maxNameLength?.toString() : undefined;
153
154
  obj.max_names_per_address = message.maxNamesPerAddress !== BigInt(0) ? message.maxNamesPerAddress?.toString() : undefined;
154
155
  obj.expiration_duration = message.expirationDuration ? duration_1.Duration.toAmino(message.expirationDuration) : undefined;
155
- obj.registration_fee = message.registrationFee ? coin_1.Coin.toAmino(message.registrationFee) : coin_1.Coin.toAmino(coin_1.Coin.fromPartial({}));
156
+ obj.registration_fee_amount = message.registrationFeeAmount === "" ? undefined : message.registrationFeeAmount;
156
157
  obj.dispute_stake_dream = message.disputeStakeDream === "" ? undefined : message.disputeStakeDream;
157
158
  obj.dispute_timeout_blocks = message.disputeTimeoutBlocks !== BigInt(0) ? message.disputeTimeoutBlocks?.toString() : undefined;
158
159
  obj.contest_stake_dream = message.contestStakeDream === "" ? undefined : message.contestStakeDream;
@@ -183,7 +184,7 @@ exports.Params = {
183
184
  function createBaseNameOperationalParams() {
184
185
  return {
185
186
  expirationDuration: duration_1.Duration.fromPartial({}),
186
- registrationFee: coin_1.Coin.fromPartial({}),
187
+ registrationFeeAmount: "",
187
188
  disputeStakeDream: "",
188
189
  disputeTimeoutBlocks: BigInt(0),
189
190
  contestStakeDream: ""
@@ -205,8 +206,8 @@ exports.NameOperationalParams = {
205
206
  if (message.expirationDuration !== undefined) {
206
207
  duration_1.Duration.encode(message.expirationDuration, writer.uint32(10).fork()).ldelim();
207
208
  }
208
- if (message.registrationFee !== undefined) {
209
- coin_1.Coin.encode(message.registrationFee, writer.uint32(18).fork()).ldelim();
209
+ if (message.registrationFeeAmount !== "") {
210
+ writer.uint32(18).string(message.registrationFeeAmount);
210
211
  }
211
212
  if (message.disputeStakeDream !== "") {
212
213
  writer.uint32(26).string(message.disputeStakeDream);
@@ -230,7 +231,7 @@ exports.NameOperationalParams = {
230
231
  message.expirationDuration = duration_1.Duration.decode(reader, reader.uint32());
231
232
  break;
232
233
  case 2:
233
- message.registrationFee = coin_1.Coin.decode(reader, reader.uint32());
234
+ message.registrationFeeAmount = reader.string();
234
235
  break;
235
236
  case 3:
236
237
  message.disputeStakeDream = reader.string();
@@ -251,7 +252,7 @@ exports.NameOperationalParams = {
251
252
  fromPartial(object) {
252
253
  const message = createBaseNameOperationalParams();
253
254
  message.expirationDuration = object.expirationDuration !== undefined && object.expirationDuration !== null ? duration_1.Duration.fromPartial(object.expirationDuration) : undefined;
254
- message.registrationFee = object.registrationFee !== undefined && object.registrationFee !== null ? coin_1.Coin.fromPartial(object.registrationFee) : undefined;
255
+ message.registrationFeeAmount = object.registrationFeeAmount ?? "";
255
256
  message.disputeStakeDream = object.disputeStakeDream ?? "";
256
257
  message.disputeTimeoutBlocks = object.disputeTimeoutBlocks !== undefined && object.disputeTimeoutBlocks !== null ? BigInt(object.disputeTimeoutBlocks.toString()) : BigInt(0);
257
258
  message.contestStakeDream = object.contestStakeDream ?? "";
@@ -262,8 +263,8 @@ exports.NameOperationalParams = {
262
263
  if (object.expiration_duration !== undefined && object.expiration_duration !== null) {
263
264
  message.expirationDuration = duration_1.Duration.fromAmino(object.expiration_duration);
264
265
  }
265
- if (object.registration_fee !== undefined && object.registration_fee !== null) {
266
- message.registrationFee = coin_1.Coin.fromAmino(object.registration_fee);
266
+ if (object.registration_fee_amount !== undefined && object.registration_fee_amount !== null) {
267
+ message.registrationFeeAmount = object.registration_fee_amount;
267
268
  }
268
269
  if (object.dispute_stake_dream !== undefined && object.dispute_stake_dream !== null) {
269
270
  message.disputeStakeDream = object.dispute_stake_dream;
@@ -279,7 +280,7 @@ exports.NameOperationalParams = {
279
280
  toAmino(message) {
280
281
  const obj = {};
281
282
  obj.expiration_duration = message.expirationDuration ? duration_1.Duration.toAmino(message.expirationDuration) : undefined;
282
- obj.registration_fee = message.registrationFee ? coin_1.Coin.toAmino(message.registrationFee) : coin_1.Coin.toAmino(coin_1.Coin.fromPartial({}));
283
+ obj.registration_fee_amount = message.registrationFeeAmount === "" ? undefined : message.registrationFeeAmount;
283
284
  obj.dispute_stake_dream = message.disputeStakeDream === "" ? undefined : message.disputeStakeDream;
284
285
  obj.dispute_timeout_blocks = message.disputeTimeoutBlocks !== BigInt(0) ? message.disputeTimeoutBlocks?.toString() : undefined;
285
286
  obj.contest_stake_dream = message.contestStakeDream === "" ? undefined : message.contestStakeDream;
@@ -25,12 +25,17 @@ export declare function roleTypeToJSON(object: RoleType): string;
25
25
  * reduced privileges depending on role, rewards may auto-bond.
26
26
  * DEMOTED: bond below demotion_threshold; privileges revoked; cooldown
27
27
  * enforced before re-bonding.
28
+ * UNBONDING: role-holder called MsgUnbondRole. DREAM remains locked and the
29
+ * bond remains slashable until unbond_completion_time. Action-time gates in
30
+ * owning modules must refuse on this status to contain new liability while
31
+ * the bond drains.
28
32
  */
29
33
  export declare enum BondedRoleStatus {
30
34
  BONDED_ROLE_STATUS_UNSPECIFIED = 0,
31
35
  BONDED_ROLE_STATUS_NORMAL = 1,
32
36
  BONDED_ROLE_STATUS_RECOVERY = 2,
33
37
  BONDED_ROLE_STATUS_DEMOTED = 3,
38
+ BONDED_ROLE_STATUS_UNBONDING = 4,
34
39
  UNRECOGNIZED = -1
35
40
  }
36
41
  export declare const BondedRoleStatusAmino: typeof BondedRoleStatus;
@@ -98,6 +103,21 @@ export interface BondedRole {
98
103
  * this role.
99
104
  */
100
105
  lastRewardEpoch: bigint;
106
+ /**
107
+ * pending_unbond_amount is DREAM queued for withdrawal via MsgUnbondRole and
108
+ * not yet released to the holder's available balance (math.Int string).
109
+ * Counts toward current_bond — i.e., slashes consume current_bond as a
110
+ * whole and the pending amount is reduced symmetrically on slash. Zero when
111
+ * no unbond is in flight.
112
+ */
113
+ pendingUnbondAmount: string;
114
+ /**
115
+ * unbond_completion_time is the unix timestamp at which an in-flight unbond
116
+ * matures: the EndBlocker unlocks pending_unbond_amount, resets the field,
117
+ * and flips bond_status (typically to DEMOTED, starting demotion_cooldown).
118
+ * Zero when no unbond is in flight.
119
+ */
120
+ unbondCompletionTime: bigint;
101
121
  }
102
122
  export interface BondedRoleProtoMsg {
103
123
  typeUrl: "/sparkdream.rep.v1.BondedRole";
@@ -165,6 +185,21 @@ export interface BondedRoleAmino {
165
185
  * this role.
166
186
  */
167
187
  last_reward_epoch?: string;
188
+ /**
189
+ * pending_unbond_amount is DREAM queued for withdrawal via MsgUnbondRole and
190
+ * not yet released to the holder's available balance (math.Int string).
191
+ * Counts toward current_bond — i.e., slashes consume current_bond as a
192
+ * whole and the pending amount is reduced symmetrically on slash. Zero when
193
+ * no unbond is in flight.
194
+ */
195
+ pending_unbond_amount?: string;
196
+ /**
197
+ * unbond_completion_time is the unix timestamp at which an in-flight unbond
198
+ * matures: the EndBlocker unlocks pending_unbond_amount, resets the field,
199
+ * and flips bond_status (typically to DEMOTED, starting demotion_cooldown).
200
+ * Zero when no unbond is in flight.
201
+ */
202
+ unbond_completion_time?: string;
168
203
  }
169
204
  export interface BondedRoleAminoMsg {
170
205
  type: "/sparkdream.rep.v1.BondedRole";
@@ -221,6 +256,14 @@ export interface BondedRoleConfig {
221
256
  * from RECOVERY to DEMOTED (math.Int string).
222
257
  */
223
258
  demotionThreshold: string;
259
+ /**
260
+ * unbond_cooldown is the number of seconds DREAM stays locked and slashable
261
+ * after MsgUnbondRole is called. While the cooldown is pending, the role's
262
+ * bond_status is UNBONDING and the owning module refuses authority. Zero =
263
+ * no cooldown (immediate withdrawal, legacy behavior). Source of truth is
264
+ * the owning module's operational params.
265
+ */
266
+ unbondCooldown: bigint;
224
267
  }
225
268
  export interface BondedRoleConfigProtoMsg {
226
269
  typeUrl: "/sparkdream.rep.v1.BondedRoleConfig";
@@ -277,6 +320,14 @@ export interface BondedRoleConfigAmino {
277
320
  * from RECOVERY to DEMOTED (math.Int string).
278
321
  */
279
322
  demotion_threshold?: string;
323
+ /**
324
+ * unbond_cooldown is the number of seconds DREAM stays locked and slashable
325
+ * after MsgUnbondRole is called. While the cooldown is pending, the role's
326
+ * bond_status is UNBONDING and the owning module refuses authority. Zero =
327
+ * no cooldown (immediate withdrawal, legacy behavior). Source of truth is
328
+ * the owning module's operational params.
329
+ */
330
+ unbond_cooldown?: string;
280
331
  }
281
332
  export interface BondedRoleConfigAminoMsg {
282
333
  type: "/sparkdream.rep.v1.BondedRoleConfig";
@@ -66,6 +66,10 @@ function roleTypeToJSON(object) {
66
66
  * reduced privileges depending on role, rewards may auto-bond.
67
67
  * DEMOTED: bond below demotion_threshold; privileges revoked; cooldown
68
68
  * enforced before re-bonding.
69
+ * UNBONDING: role-holder called MsgUnbondRole. DREAM remains locked and the
70
+ * bond remains slashable until unbond_completion_time. Action-time gates in
71
+ * owning modules must refuse on this status to contain new liability while
72
+ * the bond drains.
69
73
  */
70
74
  var BondedRoleStatus;
71
75
  (function (BondedRoleStatus) {
@@ -73,6 +77,7 @@ var BondedRoleStatus;
73
77
  BondedRoleStatus[BondedRoleStatus["BONDED_ROLE_STATUS_NORMAL"] = 1] = "BONDED_ROLE_STATUS_NORMAL";
74
78
  BondedRoleStatus[BondedRoleStatus["BONDED_ROLE_STATUS_RECOVERY"] = 2] = "BONDED_ROLE_STATUS_RECOVERY";
75
79
  BondedRoleStatus[BondedRoleStatus["BONDED_ROLE_STATUS_DEMOTED"] = 3] = "BONDED_ROLE_STATUS_DEMOTED";
80
+ BondedRoleStatus[BondedRoleStatus["BONDED_ROLE_STATUS_UNBONDING"] = 4] = "BONDED_ROLE_STATUS_UNBONDING";
76
81
  BondedRoleStatus[BondedRoleStatus["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
77
82
  })(BondedRoleStatus || (exports.BondedRoleStatus = BondedRoleStatus = {}));
78
83
  exports.BondedRoleStatusAmino = BondedRoleStatus;
@@ -90,6 +95,9 @@ function bondedRoleStatusFromJSON(object) {
90
95
  case 3:
91
96
  case "BONDED_ROLE_STATUS_DEMOTED":
92
97
  return BondedRoleStatus.BONDED_ROLE_STATUS_DEMOTED;
98
+ case 4:
99
+ case "BONDED_ROLE_STATUS_UNBONDING":
100
+ return BondedRoleStatus.BONDED_ROLE_STATUS_UNBONDING;
93
101
  case -1:
94
102
  case "UNRECOGNIZED":
95
103
  default:
@@ -106,6 +114,8 @@ function bondedRoleStatusToJSON(object) {
106
114
  return "BONDED_ROLE_STATUS_RECOVERY";
107
115
  case BondedRoleStatus.BONDED_ROLE_STATUS_DEMOTED:
108
116
  return "BONDED_ROLE_STATUS_DEMOTED";
117
+ case BondedRoleStatus.BONDED_ROLE_STATUS_UNBONDING:
118
+ return "BONDED_ROLE_STATUS_UNBONDING";
109
119
  case BondedRoleStatus.UNRECOGNIZED:
110
120
  default:
111
121
  return "UNRECOGNIZED";
@@ -123,7 +133,9 @@ function createBaseBondedRole() {
123
133
  consecutiveInactiveEpochs: BigInt(0),
124
134
  demotionCooldownUntil: BigInt(0),
125
135
  cumulativeRewards: "",
126
- lastRewardEpoch: BigInt(0)
136
+ lastRewardEpoch: BigInt(0),
137
+ pendingUnbondAmount: "",
138
+ unbondCompletionTime: BigInt(0)
127
139
  };
128
140
  }
129
141
  /**
@@ -171,6 +183,12 @@ exports.BondedRole = {
171
183
  if (message.lastRewardEpoch !== BigInt(0)) {
172
184
  writer.uint32(88).int64(message.lastRewardEpoch);
173
185
  }
186
+ if (message.pendingUnbondAmount !== "") {
187
+ writer.uint32(98).string(message.pendingUnbondAmount);
188
+ }
189
+ if (message.unbondCompletionTime !== BigInt(0)) {
190
+ writer.uint32(104).int64(message.unbondCompletionTime);
191
+ }
174
192
  return writer;
175
193
  },
176
194
  decode(input, length) {
@@ -213,6 +231,12 @@ exports.BondedRole = {
213
231
  case 11:
214
232
  message.lastRewardEpoch = reader.int64();
215
233
  break;
234
+ case 12:
235
+ message.pendingUnbondAmount = reader.string();
236
+ break;
237
+ case 13:
238
+ message.unbondCompletionTime = reader.int64();
239
+ break;
216
240
  default:
217
241
  reader.skipType(tag & 7);
218
242
  break;
@@ -233,6 +257,8 @@ exports.BondedRole = {
233
257
  message.demotionCooldownUntil = object.demotionCooldownUntil !== undefined && object.demotionCooldownUntil !== null ? BigInt(object.demotionCooldownUntil.toString()) : BigInt(0);
234
258
  message.cumulativeRewards = object.cumulativeRewards ?? "";
235
259
  message.lastRewardEpoch = object.lastRewardEpoch !== undefined && object.lastRewardEpoch !== null ? BigInt(object.lastRewardEpoch.toString()) : BigInt(0);
260
+ message.pendingUnbondAmount = object.pendingUnbondAmount ?? "";
261
+ message.unbondCompletionTime = object.unbondCompletionTime !== undefined && object.unbondCompletionTime !== null ? BigInt(object.unbondCompletionTime.toString()) : BigInt(0);
236
262
  return message;
237
263
  },
238
264
  fromAmino(object) {
@@ -270,6 +296,12 @@ exports.BondedRole = {
270
296
  if (object.last_reward_epoch !== undefined && object.last_reward_epoch !== null) {
271
297
  message.lastRewardEpoch = BigInt(object.last_reward_epoch);
272
298
  }
299
+ if (object.pending_unbond_amount !== undefined && object.pending_unbond_amount !== null) {
300
+ message.pendingUnbondAmount = object.pending_unbond_amount;
301
+ }
302
+ if (object.unbond_completion_time !== undefined && object.unbond_completion_time !== null) {
303
+ message.unbondCompletionTime = BigInt(object.unbond_completion_time);
304
+ }
273
305
  return message;
274
306
  },
275
307
  toAmino(message) {
@@ -285,6 +317,8 @@ exports.BondedRole = {
285
317
  obj.demotion_cooldown_until = message.demotionCooldownUntil !== BigInt(0) ? message.demotionCooldownUntil?.toString() : undefined;
286
318
  obj.cumulative_rewards = message.cumulativeRewards === "" ? undefined : message.cumulativeRewards;
287
319
  obj.last_reward_epoch = message.lastRewardEpoch !== BigInt(0) ? message.lastRewardEpoch?.toString() : undefined;
320
+ obj.pending_unbond_amount = message.pendingUnbondAmount === "" ? undefined : message.pendingUnbondAmount;
321
+ obj.unbond_completion_time = message.unbondCompletionTime !== BigInt(0) ? message.unbondCompletionTime?.toString() : undefined;
288
322
  return obj;
289
323
  },
290
324
  fromAminoMsg(object) {
@@ -311,7 +345,8 @@ function createBaseBondedRoleConfig() {
311
345
  minTrustLevel: "",
312
346
  minAgeBlocks: BigInt(0),
313
347
  demotionCooldown: BigInt(0),
314
- demotionThreshold: ""
348
+ demotionThreshold: "",
349
+ unbondCooldown: BigInt(0)
315
350
  };
316
351
  }
317
352
  /**
@@ -351,6 +386,9 @@ exports.BondedRoleConfig = {
351
386
  if (message.demotionThreshold !== "") {
352
387
  writer.uint32(58).string(message.demotionThreshold);
353
388
  }
389
+ if (message.unbondCooldown !== BigInt(0)) {
390
+ writer.uint32(64).int64(message.unbondCooldown);
391
+ }
354
392
  return writer;
355
393
  },
356
394
  decode(input, length) {
@@ -381,6 +419,9 @@ exports.BondedRoleConfig = {
381
419
  case 7:
382
420
  message.demotionThreshold = reader.string();
383
421
  break;
422
+ case 8:
423
+ message.unbondCooldown = reader.int64();
424
+ break;
384
425
  default:
385
426
  reader.skipType(tag & 7);
386
427
  break;
@@ -397,6 +438,7 @@ exports.BondedRoleConfig = {
397
438
  message.minAgeBlocks = object.minAgeBlocks !== undefined && object.minAgeBlocks !== null ? BigInt(object.minAgeBlocks.toString()) : BigInt(0);
398
439
  message.demotionCooldown = object.demotionCooldown !== undefined && object.demotionCooldown !== null ? BigInt(object.demotionCooldown.toString()) : BigInt(0);
399
440
  message.demotionThreshold = object.demotionThreshold ?? "";
441
+ message.unbondCooldown = object.unbondCooldown !== undefined && object.unbondCooldown !== null ? BigInt(object.unbondCooldown.toString()) : BigInt(0);
400
442
  return message;
401
443
  },
402
444
  fromAmino(object) {
@@ -422,6 +464,9 @@ exports.BondedRoleConfig = {
422
464
  if (object.demotion_threshold !== undefined && object.demotion_threshold !== null) {
423
465
  message.demotionThreshold = object.demotion_threshold;
424
466
  }
467
+ if (object.unbond_cooldown !== undefined && object.unbond_cooldown !== null) {
468
+ message.unbondCooldown = BigInt(object.unbond_cooldown);
469
+ }
425
470
  return message;
426
471
  },
427
472
  toAmino(message) {
@@ -433,6 +478,7 @@ exports.BondedRoleConfig = {
433
478
  obj.min_age_blocks = message.minAgeBlocks !== BigInt(0) ? message.minAgeBlocks?.toString() : undefined;
434
479
  obj.demotion_cooldown = message.demotionCooldown !== BigInt(0) ? message.demotionCooldown?.toString() : undefined;
435
480
  obj.demotion_threshold = message.demotionThreshold === "" ? undefined : message.demotionThreshold;
481
+ obj.unbond_cooldown = message.unbondCooldown !== BigInt(0) ? message.unbondCooldown?.toString() : undefined;
436
482
  return obj;
437
483
  },
438
484
  fromAminoMsg(object) {
@@ -3,6 +3,11 @@ import { DeepPartial } from "../../../helpers";
3
3
  /**
4
4
  * Tag defines a content-tagging label. Owned by x/rep.
5
5
  * Consumed by x/forum, x/collect, and x/rep's own initiative/reputation systems.
6
+ *
7
+ * GC is driven by `last_used_at + DefaultTagExpiration` (see x/rep ExpireTags
8
+ * in abci.go). IncrementTagUsage refreshes last_used_at on every reference,
9
+ * so actively used tags roll their deadline forward; stale tags hit their
10
+ * deadline and get reclaimed. Tags with last_used_at == 0 are permanent.
6
11
  * @name Tag
7
12
  * @package sparkdream.rep.v1
8
13
  * @see proto type: sparkdream.rep.v1.Tag
@@ -12,7 +17,6 @@ export interface Tag {
12
17
  usageCount: bigint;
13
18
  createdAt: bigint;
14
19
  lastUsedAt: bigint;
15
- expirationIndex: bigint;
16
20
  }
17
21
  export interface TagProtoMsg {
18
22
  typeUrl: "/sparkdream.rep.v1.Tag";
@@ -21,6 +25,11 @@ export interface TagProtoMsg {
21
25
  /**
22
26
  * Tag defines a content-tagging label. Owned by x/rep.
23
27
  * Consumed by x/forum, x/collect, and x/rep's own initiative/reputation systems.
28
+ *
29
+ * GC is driven by `last_used_at + DefaultTagExpiration` (see x/rep ExpireTags
30
+ * in abci.go). IncrementTagUsage refreshes last_used_at on every reference,
31
+ * so actively used tags roll their deadline forward; stale tags hit their
32
+ * deadline and get reclaimed. Tags with last_used_at == 0 are permanent.
24
33
  * @name TagAmino
25
34
  * @package sparkdream.rep.v1
26
35
  * @see proto type: sparkdream.rep.v1.Tag
@@ -30,7 +39,6 @@ export interface TagAmino {
30
39
  usage_count?: string;
31
40
  created_at?: string;
32
41
  last_used_at?: string;
33
- expiration_index?: string;
34
42
  }
35
43
  export interface TagAminoMsg {
36
44
  type: "/sparkdream.rep.v1.Tag";
@@ -39,6 +47,11 @@ export interface TagAminoMsg {
39
47
  /**
40
48
  * Tag defines a content-tagging label. Owned by x/rep.
41
49
  * Consumed by x/forum, x/collect, and x/rep's own initiative/reputation systems.
50
+ *
51
+ * GC is driven by `last_used_at + DefaultTagExpiration` (see x/rep ExpireTags
52
+ * in abci.go). IncrementTagUsage refreshes last_used_at on every reference,
53
+ * so actively used tags roll their deadline forward; stale tags hit their
54
+ * deadline and get reclaimed. Tags with last_used_at == 0 are permanent.
42
55
  * @name Tag
43
56
  * @package sparkdream.rep.v1
44
57
  * @see proto type: sparkdream.rep.v1.Tag