Skip to content

Commit f87954a

Browse files
committed
[ACTION] trengo - Helpcenter
1 parent 01875e4 commit f87954a

File tree

34 files changed

+433
-26
lines changed

34 files changed

+433
-26
lines changed

components/trengo/actions/attach-label/attach-label.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ export default {
44
key: "trengo-attach-label",
55
name: "Attach Label",
66
description: "Attach a label to a ticket. [See the documentation](https://developers.trengo.com/reference/apply-a-label)",
7-
version: "0.0.3",
7+
version: "0.0.4",
88
type: "action",
99
annotations: {
1010
destructiveHint: false,

components/trengo/actions/close-ticket/close-ticket.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ export default {
44
key: "trengo-close-ticket",
55
name: "Close Ticket",
66
description: "Close a ticket. [See the documentation](https://developers.trengo.com/reference/close-a-ticket)",
7-
version: "0.0.1",
7+
version: "0.0.2",
88
type: "action",
99
annotations: {
1010
destructiveHint: true,

components/trengo/actions/create-contact/create-contact.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import app from "../../trengo.app.mjs";
33
export default {
44
type: "action",
55
key: "trengo-create-contact",
6-
version: "0.0.8",
6+
version: "0.0.9",
77
annotations: {
88
destructiveHint: false,
99
openWorldHint: true,

components/trengo/actions/find-contacts/find-contacts.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import app from "../../trengo.app.mjs";
44
export default {
55
type: "action",
66
key: "trengo-find-contacts",
7-
version: "0.0.8",
7+
version: "0.0.9",
88
annotations: {
99
destructiveHint: false,
1010
openWorldHint: true,
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
import app from "../../trengo.app.mjs";
2+
3+
export default {
4+
key: "trengo-get-article",
5+
name: "Get Article",
6+
description: "Get a specific article. [See the documentation](https://developers.trengo.com/reference/get-an-article)",
7+
version: "0.0.1",
8+
type: "action",
9+
annotations: {
10+
destructiveHint: false,
11+
openWorldHint: true,
12+
readOnlyHint: true,
13+
},
14+
props: {
15+
app,
16+
helpCenterId: {
17+
propDefinition: [
18+
app,
19+
"helpCenterId",
20+
],
21+
},
22+
articleId: {
23+
propDefinition: [
24+
app,
25+
"articleId",
26+
({ helpCenterId }) => ({
27+
helpCenterId,
28+
}),
29+
],
30+
},
31+
},
32+
async run({ $ }) {
33+
const response = await this.app.getArticle({
34+
$,
35+
helpCenterId: this.helpCenterId,
36+
articleId: this.articleId,
37+
});
38+
$.export("$summary", "Successfully retrieved article");
39+
return response;
40+
},
41+
};
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
import app from "../../trengo.app.mjs";
2+
3+
export default {
4+
key: "trengo-get-block",
5+
name: "Get Block",
6+
description: "Get a specific block. [See the documentation](https://developers.trengo.com/reference/get-a-block)",
7+
version: "0.0.1",
8+
type: "action",
9+
annotations: {
10+
destructiveHint: false,
11+
openWorldHint: true,
12+
readOnlyHint: true,
13+
},
14+
props: {
15+
app,
16+
helpCenterId: {
17+
propDefinition: [
18+
app,
19+
"helpCenterId",
20+
],
21+
},
22+
blockId: {
23+
propDefinition: [
24+
app,
25+
"blockId",
26+
({ helpCenterId }) => ({
27+
helpCenterId,
28+
}),
29+
],
30+
},
31+
},
32+
async run({ $ }) {
33+
const response = await this.app.getBlock({
34+
$,
35+
helpCenterId: this.helpCenterId,
36+
blockId: this.blockId,
37+
});
38+
$.export("$summary", "Successfully retrieved block");
39+
return response;
40+
},
41+
};
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
import app from "../../trengo.app.mjs";
2+
3+
export default {
4+
key: "trengo-get-category",
5+
name: "Get Category",
6+
description: "Get a specific category. [See the documentation](https://developers.trengo.com/reference/get-a-category)",
7+
version: "0.0.1",
8+
type: "action",
9+
annotations: {
10+
destructiveHint: false,
11+
openWorldHint: true,
12+
readOnlyHint: true,
13+
},
14+
props: {
15+
app,
16+
helpCenterId: {
17+
propDefinition: [
18+
app,
19+
"helpCenterId",
20+
],
21+
},
22+
categoryId: {
23+
propDefinition: [
24+
app,
25+
"categoryId",
26+
({ helpCenterId }) => ({
27+
helpCenterId,
28+
}),
29+
],
30+
},
31+
},
32+
async run({ $ }) {
33+
const response = await this.app.getCategory({
34+
$,
35+
helpCenterId: this.helpCenterId,
36+
categoryId: this.categoryId,
37+
});
38+
$.export("$summary", "Successfully retrieved category");
39+
return response;
40+
},
41+
};
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
import app from "../../trengo.app.mjs";
2+
3+
export default {
4+
key: "trengo-get-help-center",
5+
name: "Get Help Center",
6+
description: "Get a specific help center. [See the documentation](https://developers.trengo.com/reference/get-a-help-center)",
7+
version: "0.0.1",
8+
type: "action",
9+
annotations: {
10+
destructiveHint: false,
11+
openWorldHint: true,
12+
readOnlyHint: true,
13+
},
14+
props: {
15+
app,
16+
helpCenterId: {
17+
propDefinition: [
18+
app,
19+
"helpCenterId",
20+
],
21+
},
22+
},
23+
async run({ $ }) {
24+
const response = await this.app.getHelpCenter({
25+
$,
26+
helpCenterId: this.helpCenterId,
27+
});
28+
$.export("$summary", "Successfully retrieved help center");
29+
return response;
30+
},
31+
};

components/trengo/actions/get-label/get-label.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ export default {
44
key: "trengo-get-label",
55
name: "Get Label",
66
description: "Get a label by ID. [See the documentation](https://developers.trengo.com/reference/get-a-label)",
7-
version: "0.0.3",
7+
version: "0.0.4",
88
type: "action",
99
annotations: {
1010
destructiveHint: false,

components/trengo/actions/get-message/get-message.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ export default {
44
key: "trengo-get-message",
55
name: "Get Message",
66
description: "Get a message by ID. [See the documentation](https://developers.trengo.com/reference/fetch-a-message)",
7-
version: "0.0.3",
7+
version: "0.0.4",
88
type: "action",
99
annotations: {
1010
destructiveHint: false,

0 commit comments

Comments
 (0)