-
Notifications
You must be signed in to change notification settings - Fork 117
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Symphony PRs in FDC3 2.1 candidates #882
Merged
mistryvinay
merged 59 commits into
finos:context-data-and-intents-consolidated-update-branch-2.1
from
symphony-jean-michael:Symphony_2.1-candidates
Mar 27, 2023
Merged
Changes from all commits
Commits
Show all changes
59 commits
Select commit
Hold shift + click to select a range
56479cc
feat: Add message type
ZimmySymphony df75169
Add ChatRoom
symphony-jean-michael 75141ff
review: make intent type free, rename intent+context to action
Yannick-Malins 4501ef2
Add SendChatMessage Intent
symphony-jean-michael d30e3e9
Add ChatMessage context
symphony-jean-michael 44c2d61
Add ChatRoom and ChatMessage to the documentation
symphony-jean-michael 81699a9
added Action, set Types on Message and Action, did doc
Yannick-Malins 37712ce
merge master
Yannick-Malins 864ad77
typo
Yannick-Malins bc31906
Add ChatRoom and SendChatMessage in Typescript
symphony-jean-michael 100f416
Add SearchCriteria Context
symphony-jean-michael 3afbfec
Link ChatRoom and ChatMessage schemas in main schema
symphony-jean-michael f98866c
typos
Yannick-Malins f2c89da
Update ChatMessage.md
mistryvinay 59fbd9f
rename chat.message to message to make space for PR765
Yannick-Malins 2eb75d8
Lint file
symphony-jean-michael a57e625
Remove the html entitites
symphony-jean-michael 6e1c104
Add SeachCriteria link
symphony-jean-michael f236082
Merge remote-tracking branch 'upstream/master' into feature/ViewMessages
symphony-jean-michael d31fb7b
Hugh review
Yannick-Malins 864f756
Update the description to be more generic
symphony-jean-michael 56ddcd7
kris review
Yannick-Malins 5f9b52c
Reorder links
symphony-jean-michael 1a344df
more kris review
Yannick-Malins b517682
Update descriptions
symphony-jean-michael 6ab7ece
Restore the HTML entities
symphony-jean-michael 1d7f05b
Flip the order of the example
symphony-jean-michael 81dfc54
Update links
symphony-jean-michael 24ecdfe
Replace URI with URL
symphony-jean-michael 91f9a67
Update description
symphony-jean-michael ca41bfe
Merge remote-tracking branch 'upstream/master' into feature/SendChatM…
symphony-jean-michael 82229d9
Update description
symphony-jean-michael a54ae60
Rename contexts in criteria
symphony-jean-michael 2b9931a
Rename fdc3.searchCriteria into fdc3.chat.searchCriteria
symphony-jean-michael 342173f
#644 | Add Order and OrderLeg Context Types
nemery-flextrade e1bb738
Empty criteria
symphony-jean-michael 58ab363
Update StartChat description
symphony-jean-michael 86aa01b
Add ViewChat Intent
symphony-jean-michael cbc349b
Add ViewChat entry in the unreleased section of the changelog.md
symphony-jean-michael 0172785
Rename SearchCriteria in ChatSearchCriteria
symphony-jean-michael 89d2fec
Rename searchCriteria in chatSearchCriteria
symphony-jean-michael 41b3384
Add ViewMessages entry in the unreleased section of the changelog.md
symphony-jean-michael bfc8c03
Remove unnecessary 'type' because it's already required by context sc…
symphony-jean-michael 6a62c40
Add SendChatMessage, ChatRoom and ChatMessage in the Changelog
symphony-jean-michael 9d6df85
kris review
Yannick-Malins 7586c45
Merge branch 'master' into message_container
Yannick-Malins c7ad6ab
Merge feature/SendChatMessage
symphony-jean-michael a729cf7
Merge feature/ViewChat
symphony-jean-michael 6564051
Merge feature/ViewMessages
symphony-jean-michael f887601
Merge Yannick-Symphony:message_container
symphony-jean-michael 6f92481
Update ChatRoom examples
symphony-jean-michael 6799b31
Add missing Github PR links
symphony-jean-michael ddef7d9
Fix syntax by closing the example section
symphony-jean-michael 86310a3
Update ChatRoom examples
symphony-jean-michael aab2b9e
Merge branch '644-context-type-order' of https://github.com/nemery-fl…
mistryvinay 06ff641
Merge branch 'nemery-flextrade-644-context-type-order' into context-d…
mistryvinay d9661d1
Merge branch 'context-data-and-intents-consolidated-update-branch-2.1…
symphony-jean-michael 7df7aab
Fix invalid syntax
symphony-jean-michael b4c2dc2
Use the same syntax for bullets
symphony-jean-michael File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
--- | ||
id: Action | ||
sidebar_label: Action | ||
title: Action | ||
hide_title: true | ||
--- | ||
# `Action` | ||
|
||
A representation of an FDC3 Action (specified via a Context or Context & Intent) that can be inserted inside another object, | ||
for example a chat message. | ||
|
||
The action may be completed by calling `fdc3.raiseIntent()` with the specified Intent and Context, or, if only a context is specified, by calling `fdc3.raiseIntentForContext()` (which the Desktop Agent will resolve by presenting the user with a list of available Intents for the Context). | ||
|
||
Accepts an optional `app` parameter in order to specify a certain app. | ||
|
||
## Type | ||
|
||
`fdc3.action` | ||
|
||
## Schema | ||
|
||
https://fdc3.finos.org/schemas/next/action.schema.json | ||
|
||
## Details | ||
|
||
| Property | Type | Required | Example Value | | ||
|-------------------|-------------------------------------------|----------|-------------------------| | ||
| `type` | string | Yes | `'fdc3.action'` | | ||
| `title` | string | Yes | `'Click to view Chart'` | | ||
| `intent` | string | No | `'ViewChart'` | | ||
| `context` | string | Yes | See Below | | ||
| `app` | object | No | `'myApp'` | | ||
| `app.appId` | string | Yes | `'app1'` | | ||
| `app.instanceId` | string | No | `'instance1'` | | ||
|
||
|
||
|
||
## Example | ||
|
||
```js | ||
const action = { | ||
type: 'fdc3.action', | ||
title: 'Click to view Chart', | ||
intent: 'ViewChart', | ||
context { | ||
type: 'fdc3.chart', | ||
instruments: [ | ||
{ | ||
type: 'fdc3.instrument', | ||
id: { | ||
ticker: 'EURUSD' | ||
} | ||
} | ||
], | ||
range: { | ||
type: 'fdc3.dateRange', | ||
starttime: '2020-09-01T08:00:00.000Z', | ||
endtime: '2020-10-31T08:00:00.000Z' | ||
}, | ||
style: 'candle' | ||
}, | ||
app { | ||
appId: 'MyChartViewingApp', | ||
instanceId: 'instance1' | ||
} | ||
} | ||
|
||
## See Also | ||
|
||
Other Types | ||
* [Message](Message) | ||
|
||
Intents | ||
* [StartChat](../../intents/ref/StartChat) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
--- | ||
id: ChatMessage | ||
sidebar_label: ChatMessage | ||
title: ChatMessage | ||
hide_title: true | ||
--- | ||
# `ChatMessage` | ||
|
||
A context representing a chat message. Typically used to send the message or to pre-populate a message for sending. | ||
|
||
## Type | ||
|
||
`fdc3.chat.message` | ||
|
||
## Schema | ||
|
||
- https://fdc3.finos.org/schemas/next/chatMessage.schema.json | ||
|
||
## Details | ||
|
||
| Property | Type | Required | Example Value | | ||
|-------------|---------|----------|-------------------| | ||
| `type` | string | Yes | `'fdc3.chat.message'` | | ||
| `chatRoom` | ChatRoom | Yes | `{ type: 'fdc3.chat.room', providerName: 'Symphony', id:{ streamId: 'j75xqXy25NBOdacUI3FNBH'} }` | | ||
| `message` | [Message](https://fdc3.finos.org/schemas/next/message.schema.json) | Yes | `'A message to send'` | | ||
|
||
## Example | ||
|
||
```js | ||
const chatMessage = { | ||
type: "fdc3.chat.message", | ||
chatRoom: { | ||
type: 'fdc3.chat.room', | ||
providerName: "Symphony", | ||
id: { | ||
streamId: "j75xqXy25NBOdacUI3FNBH" | ||
} | ||
}, | ||
message: "A message to send" | ||
} | ||
``` | ||
|
||
## See Also | ||
|
||
Intents | ||
- [StartChat](../../intents/ref/StartChat) | ||
- [StartCall](../../intents/ref/StartCall) | ||
- [SendChatMessage](../../intents/ref/SendChatMessage) | ||
|
||
FINOS Financial Objects | ||
- [Contact](https://fo.finos.org/docs/objects/contact) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
--- | ||
id: ChatRoom | ||
sidebar_label: ChatRoom | ||
title: Contact | ||
hide_title: true | ||
--- | ||
# `ChatRoom` | ||
|
||
Reference to the chat room(s) (which could be used later to send a message to the room(s)). | ||
|
||
## Type | ||
|
||
`fdc3.chat.room` | ||
|
||
## Schema | ||
|
||
https://fdc3.finos.org/schemas/next/chatRoom.schema.json | ||
|
||
## Details | ||
|
||
| Property | Type | Required | Example Value | | ||
|-------------|---------|----------|-------------------| | ||
| `type` | string | Yes | `'fdc3.chat.room'` | | ||
| `providerName` | string | Yes | `'Symphony'` | | ||
| `id` | object | Yes | `{ streamId: 'j75xqXy25NBOdacUI3FNBH', anyOtherKey: 'abcdef'}` | | ||
| `url` | string | No | `'http://symphony.com/ref/room/j75xqXy25NBOdacUI3FNBH___pqSsuJRdA'` | | ||
| `name` | string | No | `'My new room'` | | ||
|
||
The `url` is an universal url to access to the room. It could be opened from a browser, a mobile app, etc... | ||
|
||
## Example | ||
|
||
```js | ||
const chatRoom = { | ||
type: "fdc3.chat.room", | ||
providerName: "Symphony", | ||
id: { | ||
streamId: "j75xqXy25NBOdacUI3FNBH" | ||
} | ||
url: "http://symphony.com/ref/room/j75xqXy25NBOdacUI3FNBH___pqSsuJRdA", | ||
name: 'My new room' | ||
}; | ||
|
||
//Chat rooms are returned by the StartChat intent as a result | ||
const intentResolution = await fdc3.raiseIntent("StartChat", context); | ||
|
||
try { | ||
const chatRooms = await intentResolution.getResult(): | ||
} catch (error) { | ||
//chat room were not created... | ||
} | ||
``` | ||
|
||
## See Also | ||
|
||
Other Types | ||
* [ChatInitSettings](ChatInitSettings) | ||
|
||
Intents | ||
- [StartChat](../../intents/ref/StartChat) | ||
- [SendChatMessage](../../intents/ref/SendChatMessage) | ||
|
||
FINOS Financial Objects | ||
- [Contact](https://fo.finos.org/docs/objects/contact) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
--- | ||
id: Message | ||
sidebar_label: Message | ||
title: Message | ||
hide_title: true | ||
--- | ||
# `Message` | ||
|
||
A chat message to be sent through an instant messaging application. Can contain one or several text bodies (organised by mime-type, plaintext or markdown), | ||
as well as attached entities (either arbitrary file attachments or FDC3 actions to be embedded in the message). To be put inside a ChatInitSettings object. | ||
|
||
## Type | ||
|
||
`fdc3.message` | ||
|
||
## Schema | ||
|
||
https://fdc3.finos.org/schemas/next/message.schema.json | ||
|
||
## Details | ||
|
||
| Property | Type | Required | Example Value | | ||
|-------------------|-------------------------------------------|----------|-------------------------| | ||
| `type` | string | Yes | `'fdc3.message'` | | ||
| `text` | map of string mime-type to string content | No | { text/plain: 'Hello' } | | ||
| `entities` | map of json entity to string id | No | See Below | | ||
|
||
## Example | ||
|
||
```js | ||
const message = { | ||
type: 'fdc3.message', | ||
text: { | ||
'text/plain': 'Hey all, can we discuss the issue together? I attached a screenshot and a link to the current exchange rate' | ||
}, | ||
entities: { | ||
'picture1': { | ||
type: 'fdc3.fileAttachment', | ||
data: { | ||
name: 'myImage.png', | ||
dataUri: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAIAQMAAAD+wSzIAAAABlBMVEX///+/v7+jQ3Y5AAAADklEQVQI12P4AIX8EAgALgAD/aNpbtEAAAAASUVORK5CYII' | ||
} | ||
}, | ||
'eurusd_action': { | ||
type: 'fdc3.action', | ||
title: 'Click to view Chart', | ||
intent: 'ViewChart', | ||
context: { | ||
type: 'fdc3.chart', | ||
instruments: [ | ||
{ | ||
type: 'fdc3.instrument', | ||
id: { | ||
ticker: 'EURUSD' | ||
} | ||
} | ||
], | ||
range: { | ||
type: 'fdc3.dateRange', | ||
starttime: '2020-09-01T08:00:00.000Z', | ||
endtime: '2020-10-31T08:00:00.000Z' | ||
}, | ||
style: 'candle' | ||
} | ||
} | ||
} | ||
} | ||
``` | ||
|
||
## See Also | ||
|
||
Other Types | ||
* [ChatInitSettings](ChatInitSettings) | ||
* [Action](Action) | ||
|
||
Intents | ||
* [StartChat](../../intents/ref/StartChat) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
--- | ||
id: Order | ||
sidebar_label: Order | ||
title: Order | ||
hide_title: true | ||
--- | ||
# `Order` | ||
|
||
:::caution Experimental | ||
|
||
**Note:** This feature has been designated as experimental to indicate that its design may change in the future. To read more about the FDC3 experimental policy pleae visit our [Experimental Features](https://fdc3.finos.org/docs/fdc3-compliance#experimental-features) page. | ||
|
||
::: | ||
|
||
A context type representing the details of an order, which may be used to transmit a new order to a third party or share details of an existing order. | ||
|
||
When the intent is to create an Order in a downstream system at least one OrderLeg MUST be populated. | ||
|
||
When the intent is to lookup an Order in a downstream system at least one entry MUST be populated in the id field and other fields are not required. | ||
|
||
## Type | ||
|
||
`fdc3.order` | ||
|
||
## Schema | ||
|
||
https://fdc3.finos.org/scehmas/next/order.schema.json | ||
|
||
## Details | ||
|
||
| Property| Type| Required| Example | ||
| -| -| -| - | ||
| `id` | object | Yes | `{'OMS': '123456789'}` | ||
| `id.OMS` | string | No | `'123456789'` | ||
| `id.EMS` | string | No | `'EMSID1234'` | ||
| `id.PMS` | string | No | `'PMS12345'` | ||
| `sendingTime` | string | Yes | `'2022-03-30T15:44:44+00:00'` | ||
| `timeInForce` | fdc3.timeRange| No | `{type: "fdc3.timeRange", startTime: "2020-09-01T08:00:00.000Z", endTime: "2020-10-31T08:00:00.000Z"}` | ||
| `orderLegs` | fdc3.orderLeg[] | Yes | | ||
| `notes` | String | No | ||
|
||
|
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This block of text is also included in the example section. Needs to be moved outside of the example.