Skip to content

Commit c1c6707

Browse files
committed
chore: generate injective protobufs
1 parent 0d1cba7 commit c1c6707

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

69 files changed

+38007
-0
lines changed

scripts/gen-protobufs.mjs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,10 @@ const REPOS = [
4646
repo: "osmosis-labs/osmosis#main",
4747
paths: ["proto"],
4848
},
49+
{
50+
repo: "InjectiveLabs/sdk-go#master",
51+
paths: ["proto"],
52+
},
4953
];
5054

5155
const __dirname = dirname(fileURLToPath(import.meta.url));

src/protobufs/index.ts

Lines changed: 1007 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 265 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,265 @@
1+
// @generated by protoc-gen-es v1.2.0 with parameter "target=ts"
2+
// @generated from file injective/auction/v1beta1/auction.proto (package injective.auction.v1beta1, syntax proto3)
3+
/* eslint-disable */
4+
// @ts-nocheck
5+
6+
import type { BinaryReadOptions, FieldList, JsonReadOptions, JsonValue, PartialMessage, PlainMessage } from "@bufbuild/protobuf";
7+
import { Message, proto3, protoInt64 } from "@bufbuild/protobuf";
8+
import { Coin } from "../../../cosmos/base/v1beta1/coin_pb.js";
9+
10+
/**
11+
* @generated from message injective.auction.v1beta1.Params
12+
*/
13+
export class Params extends Message<Params> {
14+
/**
15+
* auction_period_duration defines the auction period duration
16+
*
17+
* @generated from field: int64 auction_period = 1;
18+
*/
19+
auctionPeriod = protoInt64.zero;
20+
21+
/**
22+
* min_next_bid_increment_rate defines the minimum increment rate for new bids
23+
*
24+
* @generated from field: string min_next_bid_increment_rate = 2;
25+
*/
26+
minNextBidIncrementRate = "";
27+
28+
constructor(data?: PartialMessage<Params>) {
29+
super();
30+
proto3.util.initPartial(data, this);
31+
}
32+
33+
static readonly runtime: typeof proto3 = proto3;
34+
static readonly typeName = "injective.auction.v1beta1.Params";
35+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
36+
{ no: 1, name: "auction_period", kind: "scalar", T: 3 /* ScalarType.INT64 */ },
37+
{ no: 2, name: "min_next_bid_increment_rate", kind: "scalar", T: 9 /* ScalarType.STRING */ },
38+
]);
39+
40+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Params {
41+
return new Params().fromBinary(bytes, options);
42+
}
43+
44+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Params {
45+
return new Params().fromJson(jsonValue, options);
46+
}
47+
48+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Params {
49+
return new Params().fromJsonString(jsonString, options);
50+
}
51+
52+
static equals(a: Params | PlainMessage<Params> | undefined, b: Params | PlainMessage<Params> | undefined): boolean {
53+
return proto3.util.equals(Params, a, b);
54+
}
55+
}
56+
57+
/**
58+
* @generated from message injective.auction.v1beta1.Bid
59+
*/
60+
export class Bid extends Message<Bid> {
61+
/**
62+
* @generated from field: string bidder = 1;
63+
*/
64+
bidder = "";
65+
66+
/**
67+
* @generated from field: string amount = 2;
68+
*/
69+
amount = "";
70+
71+
constructor(data?: PartialMessage<Bid>) {
72+
super();
73+
proto3.util.initPartial(data, this);
74+
}
75+
76+
static readonly runtime: typeof proto3 = proto3;
77+
static readonly typeName = "injective.auction.v1beta1.Bid";
78+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
79+
{ no: 1, name: "bidder", kind: "scalar", T: 9 /* ScalarType.STRING */ },
80+
{ no: 2, name: "amount", kind: "scalar", T: 9 /* ScalarType.STRING */ },
81+
]);
82+
83+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Bid {
84+
return new Bid().fromBinary(bytes, options);
85+
}
86+
87+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Bid {
88+
return new Bid().fromJson(jsonValue, options);
89+
}
90+
91+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Bid {
92+
return new Bid().fromJsonString(jsonString, options);
93+
}
94+
95+
static equals(a: Bid | PlainMessage<Bid> | undefined, b: Bid | PlainMessage<Bid> | undefined): boolean {
96+
return proto3.util.equals(Bid, a, b);
97+
}
98+
}
99+
100+
/**
101+
* @generated from message injective.auction.v1beta1.EventBid
102+
*/
103+
export class EventBid extends Message<EventBid> {
104+
/**
105+
* bidder describes the address of bidder
106+
*
107+
* @generated from field: string bidder = 1;
108+
*/
109+
bidder = "";
110+
111+
/**
112+
* amount describes the amount the bidder put on the auction
113+
*
114+
* @generated from field: string amount = 2;
115+
*/
116+
amount = "";
117+
118+
/**
119+
* round defines the round number of auction
120+
*
121+
* @generated from field: uint64 round = 3;
122+
*/
123+
round = protoInt64.zero;
124+
125+
constructor(data?: PartialMessage<EventBid>) {
126+
super();
127+
proto3.util.initPartial(data, this);
128+
}
129+
130+
static readonly runtime: typeof proto3 = proto3;
131+
static readonly typeName = "injective.auction.v1beta1.EventBid";
132+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
133+
{ no: 1, name: "bidder", kind: "scalar", T: 9 /* ScalarType.STRING */ },
134+
{ no: 2, name: "amount", kind: "scalar", T: 9 /* ScalarType.STRING */ },
135+
{ no: 3, name: "round", kind: "scalar", T: 4 /* ScalarType.UINT64 */ },
136+
]);
137+
138+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): EventBid {
139+
return new EventBid().fromBinary(bytes, options);
140+
}
141+
142+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): EventBid {
143+
return new EventBid().fromJson(jsonValue, options);
144+
}
145+
146+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): EventBid {
147+
return new EventBid().fromJsonString(jsonString, options);
148+
}
149+
150+
static equals(a: EventBid | PlainMessage<EventBid> | undefined, b: EventBid | PlainMessage<EventBid> | undefined): boolean {
151+
return proto3.util.equals(EventBid, a, b);
152+
}
153+
}
154+
155+
/**
156+
* @generated from message injective.auction.v1beta1.EventAuctionResult
157+
*/
158+
export class EventAuctionResult extends Message<EventAuctionResult> {
159+
/**
160+
* winner describes the address of the winner
161+
*
162+
* @generated from field: string winner = 1;
163+
*/
164+
winner = "";
165+
166+
/**
167+
* amount describes the amount the winner get from the auction
168+
*
169+
* @generated from field: string amount = 2;
170+
*/
171+
amount = "";
172+
173+
/**
174+
* round defines the round number of auction
175+
*
176+
* @generated from field: uint64 round = 3;
177+
*/
178+
round = protoInt64.zero;
179+
180+
constructor(data?: PartialMessage<EventAuctionResult>) {
181+
super();
182+
proto3.util.initPartial(data, this);
183+
}
184+
185+
static readonly runtime: typeof proto3 = proto3;
186+
static readonly typeName = "injective.auction.v1beta1.EventAuctionResult";
187+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
188+
{ no: 1, name: "winner", kind: "scalar", T: 9 /* ScalarType.STRING */ },
189+
{ no: 2, name: "amount", kind: "scalar", T: 9 /* ScalarType.STRING */ },
190+
{ no: 3, name: "round", kind: "scalar", T: 4 /* ScalarType.UINT64 */ },
191+
]);
192+
193+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): EventAuctionResult {
194+
return new EventAuctionResult().fromBinary(bytes, options);
195+
}
196+
197+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): EventAuctionResult {
198+
return new EventAuctionResult().fromJson(jsonValue, options);
199+
}
200+
201+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): EventAuctionResult {
202+
return new EventAuctionResult().fromJsonString(jsonString, options);
203+
}
204+
205+
static equals(a: EventAuctionResult | PlainMessage<EventAuctionResult> | undefined, b: EventAuctionResult | PlainMessage<EventAuctionResult> | undefined): boolean {
206+
return proto3.util.equals(EventAuctionResult, a, b);
207+
}
208+
}
209+
210+
/**
211+
* @generated from message injective.auction.v1beta1.EventAuctionStart
212+
*/
213+
export class EventAuctionStart extends Message<EventAuctionStart> {
214+
/**
215+
* round defines the round number of auction
216+
*
217+
* @generated from field: uint64 round = 1;
218+
*/
219+
round = protoInt64.zero;
220+
221+
/**
222+
* ending_timestamp describes auction end time
223+
*
224+
* @generated from field: int64 ending_timestamp = 2;
225+
*/
226+
endingTimestamp = protoInt64.zero;
227+
228+
/**
229+
* new_basket describes auction module balance at the time of new auction
230+
* start
231+
*
232+
* @generated from field: repeated cosmos.base.v1beta1.Coin new_basket = 3;
233+
*/
234+
newBasket: Coin[] = [];
235+
236+
constructor(data?: PartialMessage<EventAuctionStart>) {
237+
super();
238+
proto3.util.initPartial(data, this);
239+
}
240+
241+
static readonly runtime: typeof proto3 = proto3;
242+
static readonly typeName = "injective.auction.v1beta1.EventAuctionStart";
243+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
244+
{ no: 1, name: "round", kind: "scalar", T: 4 /* ScalarType.UINT64 */ },
245+
{ no: 2, name: "ending_timestamp", kind: "scalar", T: 3 /* ScalarType.INT64 */ },
246+
{ no: 3, name: "new_basket", kind: "message", T: Coin, repeated: true },
247+
]);
248+
249+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): EventAuctionStart {
250+
return new EventAuctionStart().fromBinary(bytes, options);
251+
}
252+
253+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): EventAuctionStart {
254+
return new EventAuctionStart().fromJson(jsonValue, options);
255+
}
256+
257+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): EventAuctionStart {
258+
return new EventAuctionStart().fromJsonString(jsonString, options);
259+
}
260+
261+
static equals(a: EventAuctionStart | PlainMessage<EventAuctionStart> | undefined, b: EventAuctionStart | PlainMessage<EventAuctionStart> | undefined): boolean {
262+
return proto3.util.equals(EventAuctionStart, a, b);
263+
}
264+
}
265+
Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
// @generated by protoc-gen-es v1.2.0 with parameter "target=ts"
2+
// @generated from file injective/auction/v1beta1/genesis.proto (package injective.auction.v1beta1, syntax proto3)
3+
/* eslint-disable */
4+
// @ts-nocheck
5+
6+
import type { BinaryReadOptions, FieldList, JsonReadOptions, JsonValue, PartialMessage, PlainMessage } from "@bufbuild/protobuf";
7+
import { Message, proto3, protoInt64 } from "@bufbuild/protobuf";
8+
import { Bid, Params } from "./auction_pb.js";
9+
10+
/**
11+
* GenesisState defines the auction module's genesis state.
12+
*
13+
* @generated from message injective.auction.v1beta1.GenesisState
14+
*/
15+
export class GenesisState extends Message<GenesisState> {
16+
/**
17+
* params defines all the parameters of related to auction.
18+
*
19+
* @generated from field: injective.auction.v1beta1.Params params = 1;
20+
*/
21+
params?: Params;
22+
23+
/**
24+
* current auction round
25+
*
26+
* @generated from field: uint64 auction_round = 2;
27+
*/
28+
auctionRound = protoInt64.zero;
29+
30+
/**
31+
* current highest bid
32+
*
33+
* @generated from field: injective.auction.v1beta1.Bid highest_bid = 3;
34+
*/
35+
highestBid?: Bid;
36+
37+
/**
38+
* auction ending timestamp
39+
*
40+
* @generated from field: int64 auction_ending_timestamp = 4;
41+
*/
42+
auctionEndingTimestamp = protoInt64.zero;
43+
44+
constructor(data?: PartialMessage<GenesisState>) {
45+
super();
46+
proto3.util.initPartial(data, this);
47+
}
48+
49+
static readonly runtime: typeof proto3 = proto3;
50+
static readonly typeName = "injective.auction.v1beta1.GenesisState";
51+
static readonly fields: FieldList = proto3.util.newFieldList(() => [
52+
{ no: 1, name: "params", kind: "message", T: Params },
53+
{ no: 2, name: "auction_round", kind: "scalar", T: 4 /* ScalarType.UINT64 */ },
54+
{ no: 3, name: "highest_bid", kind: "message", T: Bid },
55+
{ no: 4, name: "auction_ending_timestamp", kind: "scalar", T: 3 /* ScalarType.INT64 */ },
56+
]);
57+
58+
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): GenesisState {
59+
return new GenesisState().fromBinary(bytes, options);
60+
}
61+
62+
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): GenesisState {
63+
return new GenesisState().fromJson(jsonValue, options);
64+
}
65+
66+
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): GenesisState {
67+
return new GenesisState().fromJsonString(jsonString, options);
68+
}
69+
70+
static equals(a: GenesisState | PlainMessage<GenesisState> | undefined, b: GenesisState | PlainMessage<GenesisState> | undefined): boolean {
71+
return proto3.util.equals(GenesisState, a, b);
72+
}
73+
}
74+
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
// @generated by protoc-gen-cosmes v0.0.1 with parameter "target=ts"
2+
// @generated from file injective/auction/v1beta1/query.proto (package injective.auction.v1beta1, syntax proto3)
3+
/* eslint-disable */
4+
// @ts-nocheck
5+
6+
import { QueryAuctionParamsRequest, QueryAuctionParamsResponse, QueryCurrentAuctionBasketRequest, QueryCurrentAuctionBasketResponse, QueryModuleStateRequest, QueryModuleStateResponse } from "./query_pb.js";
7+
8+
const TYPE_NAME = "injective.auction.v1beta1.Query";
9+
10+
/**
11+
* Retrieves auction params
12+
*
13+
* @generated from rpc injective.auction.v1beta1.Query.AuctionParams
14+
*/
15+
export const QueryAuctionParamsService = {
16+
typeName: TYPE_NAME,
17+
method: "AuctionParams",
18+
Request: QueryAuctionParamsRequest,
19+
Response: QueryAuctionParamsResponse,
20+
} as const;
21+
22+
/**
23+
* Retrieves current auction basket with current highest bid and bidder
24+
*
25+
* @generated from rpc injective.auction.v1beta1.Query.CurrentAuctionBasket
26+
*/
27+
export const QueryCurrentAuctionBasketService = {
28+
typeName: TYPE_NAME,
29+
method: "CurrentAuctionBasket",
30+
Request: QueryCurrentAuctionBasketRequest,
31+
Response: QueryCurrentAuctionBasketResponse,
32+
} as const;
33+
34+
/**
35+
* Retrieves the entire auction module's state
36+
*
37+
* @generated from rpc injective.auction.v1beta1.Query.AuctionModuleState
38+
*/
39+
export const QueryAuctionModuleStateService = {
40+
typeName: TYPE_NAME,
41+
method: "AuctionModuleState",
42+
Request: QueryModuleStateRequest,
43+
Response: QueryModuleStateResponse,
44+
} as const;
45+

0 commit comments

Comments
 (0)