Skip to content

Commit 197eede

Browse files
committed
richpanel init
1 parent 22be9ab commit 197eede

File tree

8 files changed

+825
-4
lines changed

8 files changed

+825
-4
lines changed
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
import richpanel from "../../richpanel.app.mjs";
2+
import { axios } from "@pipedream/platform";
3+
4+
export default {
5+
key: "richpanel-add-ticket-message",
6+
name: "Add Ticket Message",
7+
description: "Adds a message to an existing ticket. [See the documentation]()",
8+
version: "0.0.{{ts}}",
9+
type: "action",
10+
props: {
11+
richpanel,
12+
addMessageId: {
13+
propDefinition: [
14+
richpanel,
15+
"addMessageId",
16+
],
17+
},
18+
addMessageBody: {
19+
propDefinition: [
20+
richpanel,
21+
"addMessageBody",
22+
],
23+
},
24+
addMessageSenderType: {
25+
propDefinition: [
26+
richpanel,
27+
"addMessageSenderType",
28+
],
29+
},
30+
},
31+
async run({ $ }) {
32+
const response = await this.richpanel.addMessageToTicket();
33+
$.export("$summary", `Added message to ticket ${this.addMessageId} successfully`);
34+
return response;
35+
},
36+
};
Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
import richpanel from "../../richpanel.app.mjs";
2+
import { axios } from "@pipedream/platform";
3+
4+
export default {
5+
key: "richpanel-create-ticket",
6+
name: "Create Ticket",
7+
description: "Creates a new support ticket in Richpanel. [See the documentation]().",
8+
version: "0.0.{{ts}}",
9+
type: "action",
10+
props: {
11+
richpanel,
12+
id: {
13+
propDefinition: [
14+
richpanel,
15+
"createId",
16+
],
17+
},
18+
status: {
19+
propDefinition: [
20+
richpanel,
21+
"createStatus",
22+
],
23+
},
24+
commentBody: {
25+
propDefinition: [
26+
richpanel,
27+
"createCommentBody",
28+
],
29+
},
30+
commentSenderType: {
31+
propDefinition: [
32+
richpanel,
33+
"createCommentSenderType",
34+
],
35+
},
36+
viaChannel: {
37+
propDefinition: [
38+
richpanel,
39+
"createViaChannel",
40+
],
41+
},
42+
viaSourceFrom: {
43+
propDefinition: [
44+
richpanel,
45+
"createViaSourceFrom",
46+
],
47+
},
48+
viaSourceTo: {
49+
propDefinition: [
50+
richpanel,
51+
"createViaSourceTo",
52+
],
53+
},
54+
tags: {
55+
propDefinition: [
56+
richpanel,
57+
"createTags",
58+
],
59+
},
60+
},
61+
async run({ $ }) {
62+
const response = await this.richpanel.createTicket();
63+
64+
$.export("$summary", `Created ticket ${response.id}`);
65+
return response;
66+
},
67+
};
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
import richpanel from "../../richpanel.app.mjs";
2+
import { axios } from "@pipedream/platform";
3+
4+
export default {
5+
key: "richpanel-update-ticket-status",
6+
name: "Update Ticket Status",
7+
description: "Updates the status of an existing ticket in Richpanel. [See the documentation]().",
8+
version: "0.0.{{ts}}",
9+
type: "action",
10+
props: {
11+
richpanel,
12+
updateTicketId: {
13+
propDefinition: [
14+
richpanel,
15+
"updateTicketId",
16+
],
17+
},
18+
updateStatus: {
19+
propDefinition: [
20+
richpanel,
21+
"updateStatus",
22+
],
23+
},
24+
},
25+
async run({ $ }) {
26+
const response = await this.richpanel.updateTicketStatus();
27+
$.export("$summary", `Updated ticket ${this.updateTicketId} to status ${this.updateStatus}`);
28+
return response;
29+
},
30+
};

components/richpanel/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,4 @@
1212
"publishConfig": {
1313
"access": "public"
1414
}
15-
}
15+
}

0 commit comments

Comments
 (0)