diff --git a/CHANGELOG.md b/CHANGELOG.md index a59b9a6ac..8b08ed442 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -29,6 +29,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). * Added missing `desktopAgent` field to ImplementationMetadata objects returned for all agents connect to a DesktopAgent bridge in Connection Step 6 connectAgentsUpdate messages and refined the schema used to collect this info in step 3 handshake. ([#1177](https://github.com/finos/FDC3/pull/1177)) * Removed the `version` field from `IntentResolution` as there are no version fields for intents in the FDC3 API definitions and hence the field has no purpose. ([#1170](https://github.com/finos/FDC3/pull/1170)) +* Fixed error in the Client-side example from `PrivateChannel` and `addIntentListener` by correcting `id.symbol` to `id.ticker` to align with the `fdc3.instrument` context. ([#1314](https://github.com/finos/FDC3/pull/1314)) + ## [npm v2.1.1] - 2024-06-28 ### Fixed diff --git a/docs/api/ref/DesktopAgent.md b/docs/api/ref/DesktopAgent.md index 4388c8055..5ee865db5 100644 --- a/docs/api/ref/DesktopAgent.md +++ b/docs/api/ref/DesktopAgent.md @@ -293,7 +293,7 @@ fdc3.addIntentListener("CreateOrder", (context) => { //Handle a raised intent and return a PrivateChannel over which response will be sent fdc3.addIntentListener("QuoteStream", async (context) => { const channel: PrivateChannel = await fdc3.createPrivateChannel(); - const symbol = context.id.symbol; + const symbol = context.id.ticker; // Called when the remote side adds a context listener const addContextListener = channel.onAddContextListener((contextType) => { diff --git a/docs/api/ref/PrivateChannel.md b/docs/api/ref/PrivateChannel.md index 300ff0439..d232cddda 100644 --- a/docs/api/ref/PrivateChannel.md +++ b/docs/api/ref/PrivateChannel.md @@ -151,7 +151,7 @@ Although this interaction occurs entirely in frontend code, we refer to it as th ```ts try { - const resolution3 = await fdc3.raiseIntent("QuoteStream", { type: "fdc3.instrument", id : { symbol: "AAPL" } }); + const resolution3 = await fdc3.raiseIntent("QuoteStream", { type: "fdc3.instrument", id : { ticker: "AAPL" } }); try { const result = await resolution3.getResult(); //check that we got a result and that it's a channel diff --git a/website/versioned_docs/version-2.0/api/ref/DesktopAgent.md b/website/versioned_docs/version-2.0/api/ref/DesktopAgent.md index b8ba998f5..8876c1c7e 100644 --- a/website/versioned_docs/version-2.0/api/ref/DesktopAgent.md +++ b/website/versioned_docs/version-2.0/api/ref/DesktopAgent.md @@ -132,7 +132,7 @@ fdc3.addIntentListener("CreateOrder", (context) => { //Handle a raised intent and return a PrivateChannel over which response will be sent fdc3.addIntentListener("QuoteStream", async (context) => { const channel: PrivateChannel = await fdc3.createPrivateChannel(); - const symbol = context.id.symbol; + const symbol = context.id.ticker; // Called when the remote side adds a context listener const addContextListener = channel.onAddContextListener((contextType) => { diff --git a/website/versioned_docs/version-2.0/api/ref/PrivateChannel.md b/website/versioned_docs/version-2.0/api/ref/PrivateChannel.md index 40248f8df..c495152c7 100644 --- a/website/versioned_docs/version-2.0/api/ref/PrivateChannel.md +++ b/website/versioned_docs/version-2.0/api/ref/PrivateChannel.md @@ -72,7 +72,7 @@ Although this interaction occurs entirely in frontend code, we refer to it as th ```javascript try { - const resolution3 = await fdc3.raiseIntent("QuoteStream", { type: "fdc3.instrument", id : { symbol: "AAPL" } }); + const resolution3 = await fdc3.raiseIntent("QuoteStream", { type: "fdc3.instrument", id : { ticker: "AAPL" } }); try { const result = await resolution3.getResult(); //check that we got a result and that it's a channel diff --git a/website/versioned_docs/version-2.1/api/ref/DesktopAgent.md b/website/versioned_docs/version-2.1/api/ref/DesktopAgent.md index 310cd54ca..7ab8d692e 100644 --- a/website/versioned_docs/version-2.1/api/ref/DesktopAgent.md +++ b/website/versioned_docs/version-2.1/api/ref/DesktopAgent.md @@ -137,7 +137,7 @@ fdc3.addIntentListener("CreateOrder", (context) => { //Handle a raised intent and return a PrivateChannel over which response will be sent fdc3.addIntentListener("QuoteStream", async (context) => { const channel: PrivateChannel = await fdc3.createPrivateChannel(); - const symbol = context.id.symbol; + const symbol = context.id.ticker; // Called when the remote side adds a context listener const addContextListener = channel.onAddContextListener((contextType) => { diff --git a/website/versioned_docs/version-2.1/api/ref/PrivateChannel.md b/website/versioned_docs/version-2.1/api/ref/PrivateChannel.md index 5fc8e9c55..112f279ea 100644 --- a/website/versioned_docs/version-2.1/api/ref/PrivateChannel.md +++ b/website/versioned_docs/version-2.1/api/ref/PrivateChannel.md @@ -77,7 +77,7 @@ Although this interaction occurs entirely in frontend code, we refer to it as th ```javascript try { - const resolution3 = await fdc3.raiseIntent("QuoteStream", { type: "fdc3.instrument", id : { symbol: "AAPL" } }); + const resolution3 = await fdc3.raiseIntent("QuoteStream", { type: "fdc3.instrument", id : { ticker: "AAPL" } }); try { const result = await resolution3.getResult(); //check that we got a result and that it's a channel