@sparkdreamnft/sparkdreamjs 0.0.34 → 0.0.36

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 (74) hide show
  1. package/akash/bundle.d.ts +134 -134
  2. package/akash/bundle.js +150 -150
  3. package/cosmos/bundle.d.ts +160 -160
  4. package/cosmos/bundle.js +182 -182
  5. package/esm/akash/bundle.js +150 -150
  6. package/esm/cosmos/bundle.js +182 -182
  7. package/esm/ibc/bundle.js +116 -116
  8. package/esm/sparkdream/bundle.js +305 -301
  9. package/esm/sparkdream/rep/v1/{interim_template.js → acceptance_criteria.js} +13 -123
  10. package/esm/sparkdream/rep/v1/accountability.js +11 -0
  11. package/esm/sparkdream/rep/v1/bonded_role.js +13 -0
  12. package/esm/sparkdream/rep/v1/challenge.js +21 -9
  13. package/esm/sparkdream/rep/v1/genesis.js +198 -59
  14. package/esm/sparkdream/rep/v1/initiative.js +170 -47
  15. package/esm/sparkdream/rep/v1/initiative_review.js +179 -0
  16. package/esm/sparkdream/rep/v1/jury_participation.js +39 -9
  17. package/esm/sparkdream/rep/v1/jury_review.js +40 -1
  18. package/esm/sparkdream/rep/v1/member_report.js +8 -8
  19. package/esm/sparkdream/rep/v1/member_warning.js +2 -2
  20. package/esm/sparkdream/rep/v1/params.js +614 -2
  21. package/esm/sparkdream/rep/v1/query.js +4900 -3425
  22. package/esm/sparkdream/rep/v1/query.lcd.js +77 -16
  23. package/esm/sparkdream/rep/v1/query.rpc.Query.js +85 -21
  24. package/esm/sparkdream/rep/v1/review_bounty.js +215 -0
  25. package/esm/sparkdream/rep/v1/tag_report.js +2 -2
  26. package/esm/sparkdream/rep/v1/tx.js +2610 -1442
  27. package/esm/sparkdream/rep/v1/tx.registry.js +128 -2
  28. package/esm/sparkdream/rep/v1/tx.rpc.msg.js +43 -1
  29. package/esm/tendermint/bundle.js +18 -18
  30. package/ibc/bundle.d.ts +99 -99
  31. package/ibc/bundle.js +116 -116
  32. package/package.json +1 -1
  33. package/sparkdream/bundle.d.ts +9671 -9159
  34. package/sparkdream/bundle.js +305 -301
  35. package/sparkdream/rep/v1/{interim_template.d.ts → acceptance_criteria.d.ts} +39 -52
  36. package/sparkdream/rep/v1/{interim_template.js → acceptance_criteria.js} +14 -124
  37. package/sparkdream/rep/v1/accountability.d.ts +6 -0
  38. package/sparkdream/rep/v1/accountability.js +11 -0
  39. package/sparkdream/rep/v1/bonded_role.d.ts +8 -0
  40. package/sparkdream/rep/v1/bonded_role.js +13 -0
  41. package/sparkdream/rep/v1/challenge.d.ts +14 -0
  42. package/sparkdream/rep/v1/challenge.js +21 -9
  43. package/sparkdream/rep/v1/genesis.d.ts +100 -3
  44. package/sparkdream/rep/v1/genesis.js +199 -60
  45. package/sparkdream/rep/v1/initiative.d.ts +120 -2
  46. package/sparkdream/rep/v1/initiative.js +173 -48
  47. package/sparkdream/rep/v1/initiative_review.d.ts +121 -0
  48. package/sparkdream/rep/v1/initiative_review.js +182 -0
  49. package/sparkdream/rep/v1/jury_participation.d.ts +89 -5
  50. package/sparkdream/rep/v1/jury_participation.js +39 -9
  51. package/sparkdream/rep/v1/jury_review.d.ts +38 -0
  52. package/sparkdream/rep/v1/jury_review.js +40 -1
  53. package/sparkdream/rep/v1/member_report.js +8 -8
  54. package/sparkdream/rep/v1/member_warning.js +2 -2
  55. package/sparkdream/rep/v1/params.d.ts +668 -16
  56. package/sparkdream/rep/v1/params.js +614 -2
  57. package/sparkdream/rep/v1/query.d.ts +1214 -264
  58. package/sparkdream/rep/v1/query.js +4904 -3429
  59. package/sparkdream/rep/v1/query.lcd.d.ts +9 -3
  60. package/sparkdream/rep/v1/query.lcd.js +77 -16
  61. package/sparkdream/rep/v1/query.rpc.Query.d.ts +55 -9
  62. package/sparkdream/rep/v1/query.rpc.Query.js +84 -20
  63. package/sparkdream/rep/v1/review_bounty.d.ts +168 -0
  64. package/sparkdream/rep/v1/review_bounty.js +218 -0
  65. package/sparkdream/rep/v1/tag_report.js +2 -2
  66. package/sparkdream/rep/v1/tx.d.ts +816 -9
  67. package/sparkdream/rep/v1/tx.js +2612 -1443
  68. package/sparkdream/rep/v1/tx.registry.d.ts +85 -1
  69. package/sparkdream/rep/v1/tx.registry.js +127 -1
  70. package/sparkdream/rep/v1/tx.rpc.msg.d.ts +20 -1
  71. package/sparkdream/rep/v1/tx.rpc.msg.js +42 -0
  72. package/sparkdream/rpc.query.d.ts +8 -2
  73. package/tendermint/bundle.d.ts +844 -844
  74. package/tendermint/bundle.js +18 -18
@@ -0,0 +1,168 @@
1
+ import { BinaryReader, BinaryWriter } from "../../../binary";
2
+ import { DeepPartial } from "../../../helpers";
3
+ /**
4
+ * ReviewBounty is DREAM escrowed against one initiative to attract reviewer
5
+ * attention to it.
6
+ *
7
+ * The DREAM review fee pays for the act of reviewing at a rate fixed by the
8
+ * budget. A bounty is how the people who actually want a particular initiative
9
+ * looked at — its creator, its stakers, anyone — bid that attention up. Review
10
+ * is the scarcest input in the system once the completion gate is mandatory,
11
+ * and a flat fee cannot express "this one matters more".
12
+ *
13
+ * Paid out per verdict filed and split across the round's reviewers, exactly
14
+ * like the fee: outcome-blind. A bounty released on successful completion would
15
+ * be a straightforward bribe to approve, which is the bias the reviewer role
16
+ * exists to remove.
17
+ * @name ReviewBounty
18
+ * @package sparkdream.rep.v1
19
+ * @see proto type: sparkdream.rep.v1.ReviewBounty
20
+ */
21
+ export interface ReviewBounty {
22
+ initiativeId: bigint;
23
+ /**
24
+ * Total DREAM currently escrowed and unpaid.
25
+ */
26
+ amount: string;
27
+ /**
28
+ * Per-funder contributions, so a reclaim or an end-without-verdict refund
29
+ * returns each funder's own DREAM rather than a pro-rata approximation.
30
+ */
31
+ contributions: ReviewBountyContribution[];
32
+ /**
33
+ * True once any verdict has been filed against this initiative. Reclaim is
34
+ * barred from that point: reviewers commit bond and do the reading on the
35
+ * strength of the advertised bounty, so allowing a withdrawal afterwards
36
+ * would make funding a bait-and-switch.
37
+ */
38
+ committed: boolean;
39
+ }
40
+ export interface ReviewBountyProtoMsg {
41
+ typeUrl: "/sparkdream.rep.v1.ReviewBounty";
42
+ value: Uint8Array;
43
+ }
44
+ /**
45
+ * ReviewBounty is DREAM escrowed against one initiative to attract reviewer
46
+ * attention to it.
47
+ *
48
+ * The DREAM review fee pays for the act of reviewing at a rate fixed by the
49
+ * budget. A bounty is how the people who actually want a particular initiative
50
+ * looked at — its creator, its stakers, anyone — bid that attention up. Review
51
+ * is the scarcest input in the system once the completion gate is mandatory,
52
+ * and a flat fee cannot express "this one matters more".
53
+ *
54
+ * Paid out per verdict filed and split across the round's reviewers, exactly
55
+ * like the fee: outcome-blind. A bounty released on successful completion would
56
+ * be a straightforward bribe to approve, which is the bias the reviewer role
57
+ * exists to remove.
58
+ * @name ReviewBountyAmino
59
+ * @package sparkdream.rep.v1
60
+ * @see proto type: sparkdream.rep.v1.ReviewBounty
61
+ */
62
+ export interface ReviewBountyAmino {
63
+ initiative_id?: string;
64
+ /**
65
+ * Total DREAM currently escrowed and unpaid.
66
+ */
67
+ amount?: string;
68
+ /**
69
+ * Per-funder contributions, so a reclaim or an end-without-verdict refund
70
+ * returns each funder's own DREAM rather than a pro-rata approximation.
71
+ */
72
+ contributions?: ReviewBountyContributionAmino[];
73
+ /**
74
+ * True once any verdict has been filed against this initiative. Reclaim is
75
+ * barred from that point: reviewers commit bond and do the reading on the
76
+ * strength of the advertised bounty, so allowing a withdrawal afterwards
77
+ * would make funding a bait-and-switch.
78
+ */
79
+ committed?: boolean;
80
+ }
81
+ export interface ReviewBountyAminoMsg {
82
+ type: "/sparkdream.rep.v1.ReviewBounty";
83
+ value: ReviewBountyAmino;
84
+ }
85
+ /**
86
+ * ReviewBountyContribution is one funder's stake in a bounty.
87
+ * @name ReviewBountyContribution
88
+ * @package sparkdream.rep.v1
89
+ * @see proto type: sparkdream.rep.v1.ReviewBountyContribution
90
+ */
91
+ export interface ReviewBountyContribution {
92
+ funder: string;
93
+ amount: string;
94
+ /**
95
+ * Block height the contribution was made, for the reclaim delay.
96
+ */
97
+ fundedAt: bigint;
98
+ }
99
+ export interface ReviewBountyContributionProtoMsg {
100
+ typeUrl: "/sparkdream.rep.v1.ReviewBountyContribution";
101
+ value: Uint8Array;
102
+ }
103
+ /**
104
+ * ReviewBountyContribution is one funder's stake in a bounty.
105
+ * @name ReviewBountyContributionAmino
106
+ * @package sparkdream.rep.v1
107
+ * @see proto type: sparkdream.rep.v1.ReviewBountyContribution
108
+ */
109
+ export interface ReviewBountyContributionAmino {
110
+ funder?: string;
111
+ amount?: string;
112
+ /**
113
+ * Block height the contribution was made, for the reclaim delay.
114
+ */
115
+ funded_at?: string;
116
+ }
117
+ export interface ReviewBountyContributionAminoMsg {
118
+ type: "/sparkdream.rep.v1.ReviewBountyContribution";
119
+ value: ReviewBountyContributionAmino;
120
+ }
121
+ /**
122
+ * ReviewBounty is DREAM escrowed against one initiative to attract reviewer
123
+ * attention to it.
124
+ *
125
+ * The DREAM review fee pays for the act of reviewing at a rate fixed by the
126
+ * budget. A bounty is how the people who actually want a particular initiative
127
+ * looked at — its creator, its stakers, anyone — bid that attention up. Review
128
+ * is the scarcest input in the system once the completion gate is mandatory,
129
+ * and a flat fee cannot express "this one matters more".
130
+ *
131
+ * Paid out per verdict filed and split across the round's reviewers, exactly
132
+ * like the fee: outcome-blind. A bounty released on successful completion would
133
+ * be a straightforward bribe to approve, which is the bias the reviewer role
134
+ * exists to remove.
135
+ * @name ReviewBounty
136
+ * @package sparkdream.rep.v1
137
+ * @see proto type: sparkdream.rep.v1.ReviewBounty
138
+ */
139
+ export declare const ReviewBounty: {
140
+ typeUrl: string;
141
+ encode(message: ReviewBounty, writer?: BinaryWriter): BinaryWriter;
142
+ decode(input: BinaryReader | Uint8Array, length?: number): ReviewBounty;
143
+ fromPartial(object: DeepPartial<ReviewBounty>): ReviewBounty;
144
+ fromAmino(object: ReviewBountyAmino): ReviewBounty;
145
+ toAmino(message: ReviewBounty): ReviewBountyAmino;
146
+ fromAminoMsg(object: ReviewBountyAminoMsg): ReviewBounty;
147
+ fromProtoMsg(message: ReviewBountyProtoMsg): ReviewBounty;
148
+ toProto(message: ReviewBounty): Uint8Array;
149
+ toProtoMsg(message: ReviewBounty): ReviewBountyProtoMsg;
150
+ };
151
+ /**
152
+ * ReviewBountyContribution is one funder's stake in a bounty.
153
+ * @name ReviewBountyContribution
154
+ * @package sparkdream.rep.v1
155
+ * @see proto type: sparkdream.rep.v1.ReviewBountyContribution
156
+ */
157
+ export declare const ReviewBountyContribution: {
158
+ typeUrl: string;
159
+ encode(message: ReviewBountyContribution, writer?: BinaryWriter): BinaryWriter;
160
+ decode(input: BinaryReader | Uint8Array, length?: number): ReviewBountyContribution;
161
+ fromPartial(object: DeepPartial<ReviewBountyContribution>): ReviewBountyContribution;
162
+ fromAmino(object: ReviewBountyContributionAmino): ReviewBountyContribution;
163
+ toAmino(message: ReviewBountyContribution): ReviewBountyContributionAmino;
164
+ fromAminoMsg(object: ReviewBountyContributionAminoMsg): ReviewBountyContribution;
165
+ fromProtoMsg(message: ReviewBountyContributionProtoMsg): ReviewBountyContribution;
166
+ toProto(message: ReviewBountyContribution): Uint8Array;
167
+ toProtoMsg(message: ReviewBountyContribution): ReviewBountyContributionProtoMsg;
168
+ };
@@ -0,0 +1,218 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ReviewBountyContribution = exports.ReviewBounty = void 0;
4
+ //@ts-nocheck
5
+ const binary_1 = require("../../../binary");
6
+ function createBaseReviewBounty() {
7
+ return {
8
+ initiativeId: BigInt(0),
9
+ amount: "",
10
+ contributions: [],
11
+ committed: false
12
+ };
13
+ }
14
+ /**
15
+ * ReviewBounty is DREAM escrowed against one initiative to attract reviewer
16
+ * attention to it.
17
+ *
18
+ * The DREAM review fee pays for the act of reviewing at a rate fixed by the
19
+ * budget. A bounty is how the people who actually want a particular initiative
20
+ * looked at — its creator, its stakers, anyone — bid that attention up. Review
21
+ * is the scarcest input in the system once the completion gate is mandatory,
22
+ * and a flat fee cannot express "this one matters more".
23
+ *
24
+ * Paid out per verdict filed and split across the round's reviewers, exactly
25
+ * like the fee: outcome-blind. A bounty released on successful completion would
26
+ * be a straightforward bribe to approve, which is the bias the reviewer role
27
+ * exists to remove.
28
+ * @name ReviewBounty
29
+ * @package sparkdream.rep.v1
30
+ * @see proto type: sparkdream.rep.v1.ReviewBounty
31
+ */
32
+ exports.ReviewBounty = {
33
+ typeUrl: "/sparkdream.rep.v1.ReviewBounty",
34
+ encode(message, writer = binary_1.BinaryWriter.create()) {
35
+ if (message.initiativeId !== BigInt(0)) {
36
+ writer.uint32(8).uint64(message.initiativeId);
37
+ }
38
+ if (message.amount !== "") {
39
+ writer.uint32(18).string(message.amount);
40
+ }
41
+ for (const v of message.contributions) {
42
+ exports.ReviewBountyContribution.encode(v, writer.uint32(26).fork()).ldelim();
43
+ }
44
+ if (message.committed === true) {
45
+ writer.uint32(32).bool(message.committed);
46
+ }
47
+ return writer;
48
+ },
49
+ decode(input, length) {
50
+ const reader = input instanceof binary_1.BinaryReader ? input : new binary_1.BinaryReader(input);
51
+ let end = length === undefined ? reader.len : reader.pos + length;
52
+ const message = createBaseReviewBounty();
53
+ while (reader.pos < end) {
54
+ const tag = reader.uint32();
55
+ switch (tag >>> 3) {
56
+ case 1:
57
+ message.initiativeId = reader.uint64();
58
+ break;
59
+ case 2:
60
+ message.amount = reader.string();
61
+ break;
62
+ case 3:
63
+ message.contributions.push(exports.ReviewBountyContribution.decode(reader, reader.uint32()));
64
+ break;
65
+ case 4:
66
+ message.committed = reader.bool();
67
+ break;
68
+ default:
69
+ reader.skipType(tag & 7);
70
+ break;
71
+ }
72
+ }
73
+ return message;
74
+ },
75
+ fromPartial(object) {
76
+ const message = createBaseReviewBounty();
77
+ message.initiativeId = object.initiativeId !== undefined && object.initiativeId !== null ? BigInt(object.initiativeId.toString()) : BigInt(0);
78
+ message.amount = object.amount ?? "";
79
+ message.contributions = object.contributions?.map(e => exports.ReviewBountyContribution.fromPartial(e)) || [];
80
+ message.committed = object.committed ?? false;
81
+ return message;
82
+ },
83
+ fromAmino(object) {
84
+ const message = createBaseReviewBounty();
85
+ if (object.initiative_id !== undefined && object.initiative_id !== null) {
86
+ message.initiativeId = BigInt(object.initiative_id);
87
+ }
88
+ if (object.amount !== undefined && object.amount !== null) {
89
+ message.amount = object.amount;
90
+ }
91
+ message.contributions = object.contributions?.map(e => exports.ReviewBountyContribution.fromAmino(e)) || [];
92
+ if (object.committed !== undefined && object.committed !== null) {
93
+ message.committed = object.committed;
94
+ }
95
+ return message;
96
+ },
97
+ toAmino(message) {
98
+ const obj = {};
99
+ obj.initiative_id = message.initiativeId !== BigInt(0) ? message.initiativeId?.toString() : undefined;
100
+ obj.amount = message.amount === "" ? undefined : message.amount;
101
+ if (message.contributions) {
102
+ obj.contributions = message.contributions.map(e => e ? exports.ReviewBountyContribution.toAmino(e) : undefined);
103
+ }
104
+ else {
105
+ obj.contributions = message.contributions;
106
+ }
107
+ obj.committed = message.committed === false ? undefined : message.committed;
108
+ return obj;
109
+ },
110
+ fromAminoMsg(object) {
111
+ return exports.ReviewBounty.fromAmino(object.value);
112
+ },
113
+ fromProtoMsg(message) {
114
+ return exports.ReviewBounty.decode(message.value);
115
+ },
116
+ toProto(message) {
117
+ return exports.ReviewBounty.encode(message).finish();
118
+ },
119
+ toProtoMsg(message) {
120
+ return {
121
+ typeUrl: "/sparkdream.rep.v1.ReviewBounty",
122
+ value: exports.ReviewBounty.encode(message).finish()
123
+ };
124
+ }
125
+ };
126
+ function createBaseReviewBountyContribution() {
127
+ return {
128
+ funder: "",
129
+ amount: "",
130
+ fundedAt: BigInt(0)
131
+ };
132
+ }
133
+ /**
134
+ * ReviewBountyContribution is one funder's stake in a bounty.
135
+ * @name ReviewBountyContribution
136
+ * @package sparkdream.rep.v1
137
+ * @see proto type: sparkdream.rep.v1.ReviewBountyContribution
138
+ */
139
+ exports.ReviewBountyContribution = {
140
+ typeUrl: "/sparkdream.rep.v1.ReviewBountyContribution",
141
+ encode(message, writer = binary_1.BinaryWriter.create()) {
142
+ if (message.funder !== "") {
143
+ writer.uint32(10).string(message.funder);
144
+ }
145
+ if (message.amount !== "") {
146
+ writer.uint32(18).string(message.amount);
147
+ }
148
+ if (message.fundedAt !== BigInt(0)) {
149
+ writer.uint32(24).int64(message.fundedAt);
150
+ }
151
+ return writer;
152
+ },
153
+ decode(input, length) {
154
+ const reader = input instanceof binary_1.BinaryReader ? input : new binary_1.BinaryReader(input);
155
+ let end = length === undefined ? reader.len : reader.pos + length;
156
+ const message = createBaseReviewBountyContribution();
157
+ while (reader.pos < end) {
158
+ const tag = reader.uint32();
159
+ switch (tag >>> 3) {
160
+ case 1:
161
+ message.funder = reader.string();
162
+ break;
163
+ case 2:
164
+ message.amount = reader.string();
165
+ break;
166
+ case 3:
167
+ message.fundedAt = reader.int64();
168
+ break;
169
+ default:
170
+ reader.skipType(tag & 7);
171
+ break;
172
+ }
173
+ }
174
+ return message;
175
+ },
176
+ fromPartial(object) {
177
+ const message = createBaseReviewBountyContribution();
178
+ message.funder = object.funder ?? "";
179
+ message.amount = object.amount ?? "";
180
+ message.fundedAt = object.fundedAt !== undefined && object.fundedAt !== null ? BigInt(object.fundedAt.toString()) : BigInt(0);
181
+ return message;
182
+ },
183
+ fromAmino(object) {
184
+ const message = createBaseReviewBountyContribution();
185
+ if (object.funder !== undefined && object.funder !== null) {
186
+ message.funder = object.funder;
187
+ }
188
+ if (object.amount !== undefined && object.amount !== null) {
189
+ message.amount = object.amount;
190
+ }
191
+ if (object.funded_at !== undefined && object.funded_at !== null) {
192
+ message.fundedAt = BigInt(object.funded_at);
193
+ }
194
+ return message;
195
+ },
196
+ toAmino(message) {
197
+ const obj = {};
198
+ obj.funder = message.funder === "" ? undefined : message.funder;
199
+ obj.amount = message.amount === "" ? undefined : message.amount;
200
+ obj.funded_at = message.fundedAt !== BigInt(0) ? message.fundedAt?.toString() : undefined;
201
+ return obj;
202
+ },
203
+ fromAminoMsg(object) {
204
+ return exports.ReviewBountyContribution.fromAmino(object.value);
205
+ },
206
+ fromProtoMsg(message) {
207
+ return exports.ReviewBountyContribution.decode(message.value);
208
+ },
209
+ toProto(message) {
210
+ return exports.ReviewBountyContribution.encode(message).finish();
211
+ },
212
+ toProtoMsg(message) {
213
+ return {
214
+ typeUrl: "/sparkdream.rep.v1.ReviewBountyContribution",
215
+ value: exports.ReviewBountyContribution.encode(message).finish()
216
+ };
217
+ }
218
+ };
@@ -34,7 +34,7 @@ exports.TagReport = {
34
34
  writer.uint32(32).bool(message.underReview);
35
35
  }
36
36
  for (const v of message.reporters) {
37
- writer.uint32(82).string(v);
37
+ writer.uint32(42).string(v);
38
38
  }
39
39
  return writer;
40
40
  },
@@ -57,7 +57,7 @@ exports.TagReport = {
57
57
  case 4:
58
58
  message.underReview = reader.bool();
59
59
  break;
60
- case 10:
60
+ case 5:
61
61
  message.reporters.push(reader.string());
62
62
  break;
63
63
  default: