Skip to content

Commit 80477f0

Browse files
committed
Working receive
1 parent 2baf6df commit 80477f0

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

lazer/sdk/js/examples/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
import { PythLazerClient } from "../src/index.js";
55

66
// Ignore debug messages
7-
console.debug = () => {};
7+
console.debug = () => { };
88

99
const client = await PythLazerClient.create(
1010
["wss://pyth-lazer.dourolabs.app/v1/stream"],
@@ -62,7 +62,7 @@ await client.subscribe({
6262
type: "subscribe",
6363
subscriptionId: 2,
6464
priceFeedIds: [1, 2, 3, 4, 5],
65-
properties: ["price"],
65+
properties: ["price", "exponent", "publisherCount"],
6666
chains: ["evm"],
6767
deliveryFormat: "json",
6868
channel: "fixed_rate@200ms",

lazer/sdk/js/src/protocol.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
export type Chain = "evm" | "solana";
22
export type DeliveryFormat = "json" | "binary";
33
export type JsonBinaryEncoding = "base64" | "hex";
4-
export type PriceFeedProperty = "price" | "bestBidPrice" | "bestAskPrice";
4+
export type PriceFeedProperty = "price" | "bestBidPrice" | "bestAskPrice" | "exponent" | "publisherCount";
55
export type Channel = "real_time" | "fixed_rate@50ms" | "fixed_rate@200ms";
66

77
export type Request =
@@ -26,7 +26,7 @@ export type ParsedFeedPayload = {
2626
price?: string | undefined;
2727
bestBidPrice?: string | undefined;
2828
bestAskPrice?: string | undefined;
29-
publisher_count?: number | undefined;
29+
publisherCount?: number | undefined;
3030
exponent?: number | undefined;
3131
};
3232

0 commit comments

Comments
 (0)