Skip to content

Commit d86c53a

Browse files
committed
remove subscription actions
1 parent 7a1e3d6 commit d86c53a

File tree

7 files changed

+1
-359
lines changed

7 files changed

+1
-359
lines changed

components/dhl/actions/create-subscription/create-subscription.mjs

Lines changed: 0 additions & 107 deletions
This file was deleted.

components/dhl/actions/get-subscription-details/get-subscription-details.mjs

Lines changed: 0 additions & 26 deletions
This file was deleted.

components/dhl/actions/list-subscriptions/list-subscriptions.mjs

Lines changed: 0 additions & 19 deletions
This file was deleted.

components/dhl/actions/update-subscription-filters/update-subscription-filters.mjs

Lines changed: 0 additions & 88 deletions
This file was deleted.

components/dhl/actions/update-subscription-status/update-subscription-status.mjs

Lines changed: 0 additions & 35 deletions
This file was deleted.

components/dhl/common/constants.mjs

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -18,27 +18,6 @@ const SHIPPING_SERVICES = [
1818
"svb",
1919
];
2020

21-
const STATUS_OPTIONS = [
22-
"ACTIVE",
23-
"INACTIVE",
24-
];
25-
26-
const SUBSCRIPTION_TYPES = [
27-
"timestamp-notification",
28-
"tracking-notification",
29-
"tracking-notification-v2",
30-
];
31-
32-
const MODE_OF_TRANSPORT = [
33-
"Air",
34-
"Ocean",
35-
"Road",
36-
"Rail",
37-
];
38-
3921
export default {
4022
SHIPPING_SERVICES,
41-
STATUS_OPTIONS,
42-
SUBSCRIPTION_TYPES,
43-
MODE_OF_TRANSPORT,
4423
};

components/dhl/dhl.app.mjs

Lines changed: 1 addition & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,9 @@
11
import { axios } from "@pipedream/platform";
2-
import constants from "./common/constants.mjs";
32

43
export default {
54
type: "app",
65
app: "dhl",
7-
propDefinitions: {
8-
subscriptionId: {
9-
type: "string",
10-
label: "Subscription ID",
11-
description: "The ID of the subscription to get details for",
12-
async options() {
13-
const { subscriptions } = await this.listSubscriptions();
14-
return subscriptions?.map(({ subscriptionID }) => subscriptionID) || [];
15-
},
16-
},
17-
status: {
18-
type: "string",
19-
label: "Status",
20-
description: "Status of the subscription",
21-
options: constants.STATUS_OPTIONS,
22-
},
23-
callbackUrl: {
24-
type: "string",
25-
label: "Callback URL",
26-
description: "Your callback URL where DHL will post the timestamp notification to",
27-
optional: true,
28-
},
29-
},
6+
propDefinitions: {},
307
methods: {
318
_baseUrl() {
329
return this.$auth.api_url;
@@ -48,44 +25,5 @@ export default {
4825
...opts,
4926
});
5027
},
51-
listSubscriptions(opts = {}) {
52-
return this._makeRequest({
53-
path: "/dgff/push/subscriptions",
54-
...opts,
55-
});
56-
},
57-
getSubscriptionDetails({
58-
subscriberId, ...opts
59-
}) {
60-
return this._makeRequest({
61-
path: `/dgff/push/subscription/timestamp/${subscriberId}`,
62-
...opts,
63-
});
64-
},
65-
createSubscription(opts = {}) {
66-
return this._makeRequest({
67-
path: "/dgff/push/subscription/timestamp",
68-
method: "POST",
69-
...opts,
70-
});
71-
},
72-
updateSubscriptionStatus({
73-
subscriberId, ...opts
74-
}) {
75-
return this._makeRequest({
76-
path: `/dgff/push/subscription/timestamp/${subscriberId}`,
77-
method: "PATCH",
78-
...opts,
79-
});
80-
},
81-
updateSubscriptionFilters({
82-
subscriberId, ...opts
83-
}) {
84-
return this._makeRequest({
85-
path: `/dgff/push/subscription/timestamp/${subscriberId}`,
86-
method: "PUT",
87-
...opts,
88-
});
89-
},
9028
},
9129
};

0 commit comments

Comments
 (0)