Skip to content

Commit e69e71c

Browse files
committed
add proto files
1 parent c9e6665 commit e69e71c

File tree

2 files changed

+46
-0
lines changed

2 files changed

+46
-0
lines changed

lazer/sdk/proto/lazer.proto

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
syntax = "proto3";
2+
3+
import "publisher_update.proto";
4+
5+
enum TransactionSignatureType {
6+
ed25519 = 0;
7+
}
8+
9+
message SignedLazerTransaction {
10+
TransactionSignatureType signature_type = 1;
11+
bytes signature = 2;
12+
bytes transaction = 3;
13+
}
14+
15+
message LazerTransaction {
16+
oneof transaction {
17+
PublisherUpdatePayload publisher_updates = 1;
18+
}
19+
}
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
syntax = "proto3";
2+
3+
message PublisherUpdatePayload {
4+
repeated PublisherUpdate updates = 1;
5+
uint64 batch_timestamp_us = 2;
6+
}
7+
8+
message PublisherUpdate {
9+
uint32 price_feed_id = 1;
10+
uint64 source_timestamp_us = 2;
11+
uint64 publisher_timestamp_us = 3;
12+
oneof update {
13+
PriceUpdateV1 price_update_v1 = 4;
14+
FundingRateUpdateV1 funding_rate_update_v1 = 5;
15+
}
16+
}
17+
18+
message PriceUpdateV1 {
19+
optional int64 price = 1;
20+
optional int64 best_bid_price = 2;
21+
optional int64 best_ask_price = 3;
22+
}
23+
24+
message FundingRateUpdateV1 {
25+
optional int64 price = 1;
26+
optional int64 rate = 2;
27+
}

0 commit comments

Comments
 (0)