@forge/notification 0.3.8-next.0-experimental-2e302e1 → 0.3.9-experimental-04cc2b9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +26 -2
- package/out/fetch.d.ts.map +1 -1
- package/out/types.d.ts +16 -16
- package/out/types.d.ts.map +1 -1
- package/out/types.js +2 -2
- package/out/util.d.ts.map +1 -1
- package/out/validators.d.ts.map +1 -1
- package/package.json +12 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,10 +1,34 @@
|
|
|
1
1
|
# @forge/notification
|
|
2
2
|
|
|
3
|
-
## 0.3.
|
|
3
|
+
## 0.3.9-experimental-04cc2b9
|
|
4
|
+
|
|
5
|
+
### Major Changes
|
|
6
|
+
|
|
7
|
+
- d9ef926: Adds support for TypeScript 5
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- Updated dependencies [561f8f4]
|
|
12
|
+
- Updated dependencies [d9ef926]
|
|
13
|
+
- @forge/api@7.2.2-experimental-04cc2b9
|
|
14
|
+
|
|
15
|
+
## 0.3.9
|
|
16
|
+
|
|
17
|
+
### Patch Changes
|
|
18
|
+
|
|
19
|
+
- @forge/api@7.2.2
|
|
20
|
+
|
|
21
|
+
## 0.3.9-next.0
|
|
22
|
+
|
|
23
|
+
### Patch Changes
|
|
24
|
+
|
|
25
|
+
- @forge/api@7.2.2-next.0
|
|
26
|
+
|
|
27
|
+
## 0.3.8
|
|
4
28
|
|
|
5
29
|
### Patch Changes
|
|
6
30
|
|
|
7
|
-
- @forge/api@7.2.1
|
|
31
|
+
- @forge/api@7.2.1
|
|
8
32
|
|
|
9
33
|
## 0.3.8-next.0
|
|
10
34
|
|
package/out/fetch.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fetch.d.ts","sourceRoot":"","sources":["../src/fetch.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAEtD,eAAO,MAAM,mCAAmC,0FACyC,CAAC;AAE1F,eAAO,MAAM,IAAI,
|
|
1
|
+
{"version":3,"file":"fetch.d.ts","sourceRoot":"","sources":["../src/fetch.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAEtD,eAAO,MAAM,mCAAmC,0FACyC,CAAC;AAE1F,eAAO,MAAM,IAAI,GAAU,UAAU,MAAM,EAAE,MAAM,OAAO,EAAE,WAAW,WAAW,KAAG,OAAO,CAAC,WAAW,CAUvG,CAAC"}
|
package/out/types.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ interface Ari {
|
|
|
2
2
|
toString: () => string;
|
|
3
3
|
toJSON?: () => string;
|
|
4
4
|
}
|
|
5
|
-
export
|
|
5
|
+
export type IdentityUserAri = Ari & {
|
|
6
6
|
userId: string;
|
|
7
7
|
};
|
|
8
8
|
export declare enum DeliveryChannel {
|
|
@@ -12,16 +12,16 @@ export declare enum RecipientType {
|
|
|
12
12
|
EMAIL_ADDRESS = "EmailAddress",
|
|
13
13
|
ACCOUNT_ID = "AccountId"
|
|
14
14
|
}
|
|
15
|
-
export
|
|
15
|
+
export type NotificationPayload = {
|
|
16
16
|
deliveryChannel?: DeliveryChannel;
|
|
17
17
|
recipientsUserIds?: string[];
|
|
18
18
|
recipientEmails?: EmailRecipient[];
|
|
19
19
|
} & MessageTemplateData;
|
|
20
|
-
export
|
|
20
|
+
export type EmailRecipient = {
|
|
21
21
|
emailAddress: string;
|
|
22
22
|
locale?: string;
|
|
23
23
|
};
|
|
24
|
-
export
|
|
24
|
+
export type RecipientsToProcess = {
|
|
25
25
|
users?: {
|
|
26
26
|
userAri: string[];
|
|
27
27
|
};
|
|
@@ -29,12 +29,12 @@ export declare type RecipientsToProcess = {
|
|
|
29
29
|
emailAddresses: EmailRecipient[];
|
|
30
30
|
};
|
|
31
31
|
};
|
|
32
|
-
export
|
|
33
|
-
export
|
|
32
|
+
export type MessageTemplateData = Basic | Action | Confirmation | Custom;
|
|
33
|
+
export type InternalMessageTemplateData = {
|
|
34
34
|
id: string;
|
|
35
35
|
context: BasicContext | ActionContext | ConfirmationContext | CustomContext;
|
|
36
36
|
};
|
|
37
|
-
export
|
|
37
|
+
export type NotificationPORequest = {
|
|
38
38
|
triggerId: string;
|
|
39
39
|
messageTemplateData: InternalMessageTemplateData;
|
|
40
40
|
recipientsToProcess: RecipientsToProcess;
|
|
@@ -48,23 +48,23 @@ export interface NotificationResponse {
|
|
|
48
48
|
triggerId?: string;
|
|
49
49
|
errors?: string[];
|
|
50
50
|
}
|
|
51
|
-
|
|
51
|
+
type Basic = {
|
|
52
52
|
id: 'basic';
|
|
53
53
|
context: BasicContext;
|
|
54
54
|
};
|
|
55
|
-
|
|
55
|
+
type Action = {
|
|
56
56
|
id: 'action';
|
|
57
57
|
context: ActionContext;
|
|
58
58
|
};
|
|
59
|
-
|
|
59
|
+
type Confirmation = {
|
|
60
60
|
id: 'confirmation';
|
|
61
61
|
context: ConfirmationContext;
|
|
62
62
|
};
|
|
63
|
-
|
|
63
|
+
type Custom = {
|
|
64
64
|
id: 'custom';
|
|
65
65
|
context: CustomContext;
|
|
66
66
|
};
|
|
67
|
-
|
|
67
|
+
type BasicContext = {
|
|
68
68
|
subject: string;
|
|
69
69
|
headline: string;
|
|
70
70
|
copy: string;
|
|
@@ -72,7 +72,7 @@ declare type BasicContext = {
|
|
|
72
72
|
footerLinkItems: LinkItem[];
|
|
73
73
|
disclaimer: string;
|
|
74
74
|
};
|
|
75
|
-
|
|
75
|
+
type ActionContext = {
|
|
76
76
|
subject: string;
|
|
77
77
|
headline: string;
|
|
78
78
|
copy: string;
|
|
@@ -81,7 +81,7 @@ declare type ActionContext = {
|
|
|
81
81
|
footerLinkItems: LinkItem[];
|
|
82
82
|
disclaimer: string;
|
|
83
83
|
};
|
|
84
|
-
|
|
84
|
+
type ConfirmationContext = {
|
|
85
85
|
subject: string;
|
|
86
86
|
headline: string;
|
|
87
87
|
copy: string;
|
|
@@ -90,11 +90,11 @@ declare type ConfirmationContext = {
|
|
|
90
90
|
footerLinkItems: LinkItem[];
|
|
91
91
|
disclaimer: string;
|
|
92
92
|
};
|
|
93
|
-
|
|
93
|
+
type CustomContext = {
|
|
94
94
|
subject: string;
|
|
95
95
|
htmlBody: string;
|
|
96
96
|
};
|
|
97
|
-
|
|
97
|
+
type LinkItem = {
|
|
98
98
|
text: string;
|
|
99
99
|
link: string;
|
|
100
100
|
};
|
package/out/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,UAAU,GAAG;IACX,QAAQ,EAAE,MAAM,MAAM,CAAC;IACvB,MAAM,CAAC,EAAE,MAAM,MAAM,CAAC;CACvB;AAED,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,UAAU,GAAG;IACX,QAAQ,EAAE,MAAM,MAAM,CAAC;IACvB,MAAM,CAAC,EAAE,MAAM,MAAM,CAAC;CACvB;AAED,MAAM,MAAM,eAAe,GAAG,GAAG,GAAG;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE,CAAC;AAEvD,oBAAY,eAAe;IACzB,KAAK,UAAU;CAChB;AAED,oBAAY,aAAa;IACvB,aAAa,iBAAiB;IAC9B,UAAU,cAAc;CACzB;AAED,MAAM,MAAM,mBAAmB,GAAG;IAChC,eAAe,CAAC,EAAE,eAAe,CAAC;IAClC,iBAAiB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC7B,eAAe,CAAC,EAAE,cAAc,EAAE,CAAC;CACpC,GAAG,mBAAmB,CAAC;AAExB,MAAM,MAAM,cAAc,GAAG;IAC3B,YAAY,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,MAAM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aAAa,CAAC;CACxB,CAAC;AAEF,KAAK,YAAY,GAAG;IAClB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,EAAE,MAAM,CAAC;IACnB,eAAe,EAAE,QAAQ,EAAE,CAAC;IAC5B,UAAU,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF,KAAK,aAAa,GAAG;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,QAAQ,CAAC;IACtB,UAAU,EAAE,MAAM,CAAC;IACnB,eAAe,EAAE,QAAQ,EAAE,CAAC;IAC5B,UAAU,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF,KAAK,mBAAmB,GAAG;IACzB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,QAAQ,CAAC;IACtB,UAAU,EAAE,MAAM,CAAC;IACnB,eAAe,EAAE,QAAQ,EAAE,CAAC;IAC5B,UAAU,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF,KAAK,aAAa,GAAG;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF,KAAK,QAAQ,GAAG;IACd,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;CACd,CAAC"}
|
package/out/types.js
CHANGED
|
@@ -4,9 +4,9 @@ exports.RecipientType = exports.DeliveryChannel = void 0;
|
|
|
4
4
|
var DeliveryChannel;
|
|
5
5
|
(function (DeliveryChannel) {
|
|
6
6
|
DeliveryChannel["EMAIL"] = "email";
|
|
7
|
-
})(DeliveryChannel
|
|
7
|
+
})(DeliveryChannel || (exports.DeliveryChannel = DeliveryChannel = {}));
|
|
8
8
|
var RecipientType;
|
|
9
9
|
(function (RecipientType) {
|
|
10
10
|
RecipientType["EMAIL_ADDRESS"] = "EmailAddress";
|
|
11
11
|
RecipientType["ACCOUNT_ID"] = "AccountId";
|
|
12
|
-
})(RecipientType
|
|
12
|
+
})(RecipientType || (exports.RecipientType = RecipientType = {}));
|
package/out/util.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../src/util.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,mBAAmB,EAAE,qBAAqB,EAAuB,MAAM,SAAS,CAAC;AAI3G,eAAO,MAAM,mBAAmB,
|
|
1
|
+
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../src/util.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,mBAAmB,EAAE,qBAAqB,EAAuB,MAAM,SAAS,CAAC;AAI3G,eAAO,MAAM,mBAAmB,GAAI,QAAQ,MAAM,KAAG,eAGnD,CAAC;AAEH,eAAO,MAAM,2BAA2B,GAAI,OAAO,mBAAmB,EAAE,WAAW,MAAM,KAAG,qBA4B3F,CAAC"}
|
package/out/validators.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validators.d.ts","sourceRoot":"","sources":["../src/validators.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AAC9C,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAGzC,eAAO,MAAM,2BAA2B,
|
|
1
|
+
{"version":3,"file":"validators.d.ts","sourceRoot":"","sources":["../src/validators.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AAC9C,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAGzC,eAAO,MAAM,2BAA2B,GAAI,SAAS,mBAAmB,YA8GvE,CAAC;AAEF,eAAO,MAAM,mBAAmB,GAAU,UAAU,WAAW,kBAe9D,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@forge/notification",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.9-experimental-04cc2b9",
|
|
4
4
|
"description": "Forge Notification SDK",
|
|
5
5
|
"main": "out/index.js",
|
|
6
6
|
"types": "out/index.d.ts",
|
|
@@ -10,16 +10,25 @@
|
|
|
10
10
|
"compile": "tsc -b -v"
|
|
11
11
|
},
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@forge/api": "^7.2.
|
|
13
|
+
"@forge/api": "^7.2.2-experimental-04cc2b9"
|
|
14
14
|
},
|
|
15
15
|
"devDependencies": {
|
|
16
16
|
"@types/node": "20.19.1",
|
|
17
17
|
"expect-type": "^0.17.3",
|
|
18
|
-
"jest-when": "^3.6.0"
|
|
18
|
+
"jest-when": "^3.6.0",
|
|
19
|
+
"typescript": "5.9.2"
|
|
19
20
|
},
|
|
20
21
|
"author": "Atlassian",
|
|
21
22
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
22
23
|
"publishConfig": {
|
|
23
24
|
"registry": "https://packages.atlassian.com/api/npm/npm-public/"
|
|
25
|
+
},
|
|
26
|
+
"peerDependencies": {
|
|
27
|
+
"typescript": ">=5.0.0"
|
|
28
|
+
},
|
|
29
|
+
"peerDependenciesMeta": {
|
|
30
|
+
"typescript": {
|
|
31
|
+
"optional": true
|
|
32
|
+
}
|
|
24
33
|
}
|
|
25
34
|
}
|