Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
import app from "../../trengo.app.mjs";
import constants from "../../common/constants.mjs";

export default {
key: "trengo-list-all-quick-replies",
name: "List All Quick Replies",
description: "List all quick replies. [See the documentation](https://developers.trengo.com/reference/list-all-quick-replies)",
version: "0.0.1",
type: "action",
annotations: {
destructiveHint: false,
openWorldHint: true,
readOnlyHint: true,
},
props: {
app,
filterType: {
type: "string",
label: "Type",
description: "Filter by type of quick reply",
optional: true,
options: constants.FILTER_TYPES,
},
},
async run({ $ }) {
const response = await this.app.listQuickReplies({
params: {
type: this.filterType,
},
});
$.export("$summary", "Successfully listed quick replies");
return response;
},
};

6 changes: 6 additions & 0 deletions components/trengo/common/constants.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
export default {
FILTER_TYPES: [
"MESSAGING",
"EMAIL",
],
};
2 changes: 1 addition & 1 deletion components/trengo/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@pipedream/trengo",
"version": "0.7.0",
"version": "0.8.0",
"description": "Pipedream Trengo Components",
"main": "trengo.app.mjs",
"keywords": [
Expand Down
Loading