-
Notifications
You must be signed in to change notification settings - Fork 5.5k
18952 action expand messaging functionality for dixa #18975
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
Merged
GTFalcao
merged 12 commits into
master
from
18952-action-expand-messaging-functionality-for-dixa
Nov 12, 2025
Merged
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
5bdc8e5
Enhance Dixa component with new actions and version updates
luancazarine 9decfc4
pnpm update
luancazarine 3f89456
Merge branch '18953-action-add-knowledge-functionality-for-dixa' into…
luancazarine ab6f35c
Enhance Dixa component with new messaging functionalities and version…
luancazarine 7bbe9d0
pnpm update
luancazarine 6bfb17b
Merge branch 'master' into 18952-action-expand-messaging-functionalit…
luancazarine 7627a41
Add close conversation action for Dixa
luancazarine bbca0b2
Update components/dixa/actions/claim-conversation/claim-conversation.mjs
luancazarine 1b824a9
Update components/dixa/actions/get-conversation/get-conversation.mjs
luancazarine 88f1405
Update components/dixa/actions/list-messages/list-messages.mjs
luancazarine bb5619e
Update components/dixa/actions/list-notes/list-notes.mjs
luancazarine 31c6677
Merge branch 'master' into 18952-action-expand-messaging-functionalit…
luancazarine 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
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or 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
58 changes: 58 additions & 0 deletions
58
components/dixa/actions/claim-conversation/claim-conversation.mjs
This file contains hidden or 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,58 @@ | ||
| import dixa from "../../dixa.app.mjs"; | ||
|
|
||
| export default { | ||
| key: "dixa-claim-conversation", | ||
| name: "Claim Conversation", | ||
| description: "Claims a conversation for a given agent. To avoid taking over assigned conversations, set the force parameter to false. [See the documentation](https://docs.dixa.io/openapi/dixa-api/v1/tag/Conversations/#tag/Conversations/operation/putConversationsConversationidClaim)", | ||
| version: "0.0.1", | ||
| annotations: { | ||
| destructiveHint: false, | ||
| openWorldHint: true, | ||
| readOnlyHint: false, | ||
| }, | ||
| type: "action", | ||
| props: { | ||
| dixa, | ||
| endUserId: { | ||
| propDefinition: [ | ||
| dixa, | ||
| "endUserId", | ||
| ], | ||
| }, | ||
| conversationId: { | ||
| propDefinition: [ | ||
| dixa, | ||
| "conversationId", | ||
| ({ endUserId }) => ({ | ||
| endUserId, | ||
| }), | ||
| ], | ||
| }, | ||
| agentId: { | ||
| propDefinition: [ | ||
| dixa, | ||
| "agentId", | ||
| ], | ||
| hidden: false, | ||
| description: "The ID of the agent who is claiming the conversation.", | ||
| }, | ||
| force: { | ||
| type: "boolean", | ||
| label: "Force", | ||
| description: "Set as false to avoid taking over the conversation if it is already assigned to an agent.", | ||
| default: false, | ||
| }, | ||
| }, | ||
| async run({ $ }) { | ||
| const response = await this.dixa.claimConversation({ | ||
| $, | ||
| conversationId: this.conversationId, | ||
| data: { | ||
| agentId: this.agentId, | ||
| force: this.force, | ||
| }, | ||
| }); | ||
| $.export("$summary", `Successfully claimed conversation ${this.conversationId} for agent ${this.agentId}`); | ||
| return response; | ||
| }, | ||
| }; |
52 changes: 52 additions & 0 deletions
52
components/dixa/actions/close-conversation/close-conversation.mjs
This file contains hidden or 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,52 @@ | ||
| import dixa from "../../dixa.app.mjs"; | ||
|
|
||
| export default { | ||
| key: "dixa-close-conversation", | ||
| name: "Close Conversation", | ||
| description: "Mark a conversation as closed by providing its id. [See the documentation](https://docs.dixa.io/openapi/dixa-api/v1/tag/Conversations/#tag/Conversations/operation/putConversationsConversationidClose)", | ||
| version: "0.0.1", | ||
| annotations: { | ||
| destructiveHint: false, | ||
| openWorldHint: true, | ||
| readOnlyHint: false, | ||
| }, | ||
| type: "action", | ||
| props: { | ||
| dixa, | ||
| endUserId: { | ||
| propDefinition: [ | ||
| dixa, | ||
| "endUserId", | ||
| ], | ||
| }, | ||
| conversationId: { | ||
| propDefinition: [ | ||
| dixa, | ||
| "conversationId", | ||
| ({ endUserId }) => ({ | ||
| endUserId, | ||
| }), | ||
| ], | ||
| }, | ||
| agentId: { | ||
| propDefinition: [ | ||
| dixa, | ||
| "agentId", | ||
| ], | ||
| hidden: false, | ||
| description: "An optional agent/admin to close the conversation.", | ||
| optional: true, | ||
| }, | ||
| }, | ||
| async run({ $ }) { | ||
| const response = await this.dixa.closeConversation({ | ||
| $, | ||
| conversationId: this.conversationId, | ||
| data: { | ||
| agentId: this.agentId, | ||
| }, | ||
| }); | ||
| $.export("$summary", `Successfully closed conversation ${this.conversationId}`); | ||
| return response; | ||
| }, | ||
| }; | ||
This file contains hidden or 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 hidden or 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,48 @@ | ||
| import dixa from "../../dixa.app.mjs"; | ||
|
|
||
| export default { | ||
| key: "dixa-create-note", | ||
| name: "Create Note", | ||
| description: "Creates an internal note for a conversation. [See the documentation](https://docs.dixa.io/openapi/dixa-api/v1/tag/Conversations/#tag/Conversations/operation/postConversationsConversationidNotes).", | ||
| version: "0.0.1", | ||
| annotations: { | ||
| destructiveHint: false, | ||
| openWorldHint: true, | ||
| readOnlyHint: false, | ||
| }, | ||
| type: "action", | ||
| props: { | ||
| dixa, | ||
| endUserId: { | ||
| propDefinition: [ | ||
| dixa, | ||
| "endUserId", | ||
| ], | ||
| }, | ||
| conversationId: { | ||
| propDefinition: [ | ||
| dixa, | ||
| "conversationId", | ||
| ({ endUserId }) => ({ | ||
| endUserId, | ||
| }), | ||
| ], | ||
| }, | ||
| message: { | ||
| type: "string", | ||
| label: "Message", | ||
| description: "The message to create the note for.", | ||
| }, | ||
| }, | ||
| async run({ $ }) { | ||
| const response = await this.dixa.createNote({ | ||
| $, | ||
| conversationId: this.conversationId, | ||
| data: { | ||
| message: this.message, | ||
| }, | ||
| }); | ||
| $.export("$summary", `Successfully created note with ID ${response.data.id}`); | ||
| return response; | ||
| }, | ||
| }; |
This file contains hidden or 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 hidden or 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
40 changes: 40 additions & 0 deletions
40
components/dixa/actions/get-conversation/get-conversation.mjs
This file contains hidden or 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,40 @@ | ||
| import dixa from "../../dixa.app.mjs"; | ||
|
|
||
| export default { | ||
| key: "dixa-get-conversation", | ||
| name: "Get Conversation", | ||
| description: "Gets a conversation. [See the documentation](https://docs.dixa.io/openapi/dixa-api/v1/tag/Conversations/#tag/Conversations/operation/getConversationsConversationid)", | ||
| version: "0.0.1", | ||
| annotations: { | ||
| destructiveHint: false, | ||
| openWorldHint: true, | ||
| readOnlyHint: true, | ||
| }, | ||
| type: "action", | ||
| props: { | ||
| dixa, | ||
| endUserId: { | ||
| propDefinition: [ | ||
| dixa, | ||
| "endUserId", | ||
| ], | ||
| }, | ||
| conversationId: { | ||
| propDefinition: [ | ||
| dixa, | ||
| "conversationId", | ||
| ({ endUserId }) => ({ | ||
| endUserId, | ||
| }), | ||
| ], | ||
| }, | ||
| }, | ||
| async run({ $ }) { | ||
| const response = await this.dixa.getConversation({ | ||
| $, | ||
| conversationId: this.conversationId, | ||
| }); | ||
| $.export("$summary", `Successfully retrieved conversation ${this.conversationId}`); | ||
| return response; | ||
| }, | ||
| }; |
This file contains hidden or 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,40 @@ | ||
| import dixa from "../../dixa.app.mjs"; | ||
|
|
||
| export default { | ||
| key: "dixa-list-messages", | ||
| name: "List Messages", | ||
| description: "Lists messages from a conversation. [See the documentation](https://docs.dixa.io/openapi/dixa-api/v1/tag/Conversations/#tag/Conversations/operation/getConversationsConversationidMessages).", | ||
| version: "0.0.1", | ||
| annotations: { | ||
| destructiveHint: false, | ||
| openWorldHint: true, | ||
| readOnlyHint: true, | ||
| }, | ||
| type: "action", | ||
| props: { | ||
| dixa, | ||
| endUserId: { | ||
| propDefinition: [ | ||
| dixa, | ||
| "endUserId", | ||
| ], | ||
| }, | ||
| conversationId: { | ||
| propDefinition: [ | ||
| dixa, | ||
| "conversationId", | ||
| ({ endUserId }) => ({ | ||
| endUserId, | ||
| }), | ||
| ], | ||
| }, | ||
| }, | ||
| async run({ $ }) { | ||
| const response = await this.dixa.listMessages({ | ||
| $, | ||
| conversationId: this.conversationId, | ||
| }); | ||
| $.export("$summary", `Successfully retrieved ${response.data.length} message(s) from conversation ${this.conversationId}`); | ||
| return response; | ||
| }, | ||
| }; |
This file contains hidden or 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,40 @@ | ||
| import dixa from "../../dixa.app.mjs"; | ||
|
|
||
| export default { | ||
| key: "dixa-list-notes", | ||
| name: "List Notes", | ||
| description: "Lists internal notes from a conversation. [See the documentation](https://docs.dixa.io/openapi/dixa-api/v1/tag/Conversations/#tag/Conversations/operation/getConversationsConversationidNotes).", | ||
| version: "0.0.1", | ||
| annotations: { | ||
| destructiveHint: false, | ||
| openWorldHint: true, | ||
| readOnlyHint: true, | ||
| }, | ||
| type: "action", | ||
| props: { | ||
| dixa, | ||
| endUserId: { | ||
| propDefinition: [ | ||
| dixa, | ||
| "endUserId", | ||
| ], | ||
| }, | ||
| conversationId: { | ||
| propDefinition: [ | ||
| dixa, | ||
| "conversationId", | ||
| ({ endUserId }) => ({ | ||
| endUserId, | ||
| }), | ||
| ], | ||
| }, | ||
| }, | ||
| async run({ $ }) { | ||
| const response = await this.dixa.listNotes({ | ||
| $, | ||
| conversationId: this.conversationId, | ||
| }); | ||
| $.export("$summary", `Successfully retrieved ${response.data.length} note(s) from conversation ${this.conversationId}`); | ||
| return response; | ||
| }, | ||
| }; |
This file contains hidden or 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 hidden or 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 hidden or 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
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.