@zimbra/api-client 89.0.0 → 91.0.0
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/dist/schema.graphql +164 -9
- package/dist/src/apollo/types.d.ts +8 -0
- package/dist/src/batch-client/index.d.ts +8 -4
- package/dist/src/normalize/entities.d.ts +2 -0
- package/dist/src/schema/generated-schema-types.d.ts +160 -1
- package/dist/src/utils/normalize-attrs-custommetadata.d.ts +1 -0
- package/dist/zm-api-js-client.esm.js +742 -487
- package/dist/zm-api-js-client.esm.js.map +1 -1
- package/dist/zm-api-js-client.js +5 -10
- package/dist/zm-api-js-client.js.map +1 -1
- package/dist/zm-api-js-client.umd.js +6 -11
- package/dist/zm-api-js-client.umd.js.map +1 -1
- package/package-lock.json +268 -158
- package/package.json +2 -2
- package/src/apollo/types.ts +9 -0
- package/src/apollo/zimbra-in-memory-cache.ts +6 -4
- package/src/batch-client/index.ts +116 -20
- package/src/normalize/entities.ts +12 -0
- package/src/schema/generated-schema-types.ts +191 -1
- package/src/schema/schema.graphql +164 -9
- package/src/schema/schema.ts +12 -3
- package/src/utils/normalize-attrs-custommetadata.ts +9 -0
|
@@ -328,6 +328,10 @@ type AuthResponse {
|
|
|
328
328
|
authToken: [AuthToken]
|
|
329
329
|
twoFactorAuthRequired: TwoFactorAuthRequired
|
|
330
330
|
trustedDevicesEnabled: TrustedDevicesEnabled
|
|
331
|
+
zimbraPrefPasswordRecoveryAddress: StringContent
|
|
332
|
+
zimbraPrefPrimaryTwoFactorAuthMethod: StringContent
|
|
333
|
+
zimbraTwoFactorAuthMethodAllowed: [String]
|
|
334
|
+
zimbraTwoFactorAuthMethodEnabled: [String]
|
|
331
335
|
lifetime: Float
|
|
332
336
|
session: Session
|
|
333
337
|
skin: [Skin]
|
|
@@ -353,6 +357,10 @@ type EnableTwoFactorAuthResponse {
|
|
|
353
357
|
csrfToken: [CsrfToken]
|
|
354
358
|
}
|
|
355
359
|
|
|
360
|
+
type SendTwoFactorAuthCodeResponse {
|
|
361
|
+
status: [StringContent]
|
|
362
|
+
}
|
|
363
|
+
|
|
356
364
|
type ProfileImageChangeResponse {
|
|
357
365
|
itemId: ID
|
|
358
366
|
}
|
|
@@ -464,6 +472,10 @@ type ShareNotification {
|
|
|
464
472
|
content: String
|
|
465
473
|
}
|
|
466
474
|
|
|
475
|
+
type DLSubscribe {
|
|
476
|
+
content: String
|
|
477
|
+
}
|
|
478
|
+
|
|
467
479
|
type MessageAttributes {
|
|
468
480
|
isEncrypted: Boolean
|
|
469
481
|
isSigned: Boolean
|
|
@@ -488,6 +500,7 @@ interface MailItem {
|
|
|
488
500
|
invitations: [InviteInfo] # inv
|
|
489
501
|
sortField: String # sf, Sort field used for cursor-based pagination
|
|
490
502
|
share: [ShareNotification] # shr
|
|
503
|
+
subscribe: [DLSubscribe] # dlSub
|
|
491
504
|
replyType: String #rt
|
|
492
505
|
}
|
|
493
506
|
|
|
@@ -497,6 +510,7 @@ type ClientInfoAttributes {
|
|
|
497
510
|
zimbraWebClientSkipLogoff: Boolean
|
|
498
511
|
zimbraFeatureResetPasswordStatus: ResetPasswordStatus
|
|
499
512
|
zimbraHelpModernURL: String
|
|
513
|
+
zimbraClassicWebClientDisabled: Boolean
|
|
500
514
|
}
|
|
501
515
|
|
|
502
516
|
type ClientInfoType {
|
|
@@ -538,6 +552,7 @@ type MessageInfo implements MailItem {
|
|
|
538
552
|
attachments: [MimePart]
|
|
539
553
|
inlineAttachments: [MimePart]
|
|
540
554
|
share: [ShareNotification] # shr
|
|
555
|
+
subscribe: [DLSubscribe] # dlSub
|
|
541
556
|
replyType: String #rt
|
|
542
557
|
attributes: MessageAttributes
|
|
543
558
|
isEncrypted: Boolean
|
|
@@ -546,6 +561,7 @@ type MessageInfo implements MailItem {
|
|
|
546
561
|
local: Boolean
|
|
547
562
|
part: String
|
|
548
563
|
meta: [CustomMetadataMeta]
|
|
564
|
+
_attrs: [CustomHeader]
|
|
549
565
|
}
|
|
550
566
|
|
|
551
567
|
type Conversation implements MailItem {
|
|
@@ -571,8 +587,10 @@ type Conversation implements MailItem {
|
|
|
571
587
|
numMessages: Float # n, Number of messages in this conversation
|
|
572
588
|
unread: Float # u
|
|
573
589
|
share: [ShareNotification] # shr
|
|
590
|
+
subscribe: [DLSubscribe] # dlSub
|
|
574
591
|
replyType: String #rt
|
|
575
592
|
meta: [CustomMetadataMeta]
|
|
593
|
+
_attrs: [CustomHeader]
|
|
576
594
|
}
|
|
577
595
|
|
|
578
596
|
type MsgWithGroupInfo implements MailItem {
|
|
@@ -589,6 +607,7 @@ type MsgWithGroupInfo implements MailItem {
|
|
|
589
607
|
folderId: ID # l
|
|
590
608
|
subject: String # su
|
|
591
609
|
emailAddresses: [EmailAddress]
|
|
610
|
+
_attrs: [CustomHeader]
|
|
592
611
|
excerpt: String # fr
|
|
593
612
|
conversationId: ID # cid
|
|
594
613
|
flags: String # f
|
|
@@ -600,6 +619,7 @@ type MsgWithGroupInfo implements MailItem {
|
|
|
600
619
|
invitations: [InviteInfo] # inv
|
|
601
620
|
sortField: String # sf, Sort field used for cursor-based pagination
|
|
602
621
|
share: [ShareNotification] # shr
|
|
622
|
+
subscribe: [DLSubscribe] # dlSub
|
|
603
623
|
replyType: String #rt
|
|
604
624
|
}
|
|
605
625
|
|
|
@@ -1192,7 +1212,7 @@ type DLSAttrs {
|
|
|
1192
1212
|
zimbraHideInGal: String
|
|
1193
1213
|
}
|
|
1194
1214
|
|
|
1195
|
-
|
|
1215
|
+
type DLS {
|
|
1196
1216
|
d: String
|
|
1197
1217
|
dynamic: Boolean
|
|
1198
1218
|
id: String
|
|
@@ -1201,18 +1221,74 @@ type DLSAttrs {
|
|
|
1201
1221
|
name: String
|
|
1202
1222
|
ref: String
|
|
1203
1223
|
_attrs: DLSAttrs
|
|
1204
|
-
|
|
1224
|
+
}
|
|
1205
1225
|
|
|
1206
|
-
|
|
1226
|
+
type DLSDetails {
|
|
1207
1227
|
dls: [DLS]
|
|
1208
|
-
|
|
1228
|
+
}
|
|
1229
|
+
|
|
1230
|
+
type DLOwner {
|
|
1231
|
+
id: String
|
|
1232
|
+
name: String
|
|
1233
|
+
type: String
|
|
1234
|
+
}
|
|
1235
|
+
|
|
1236
|
+
type DLOwners {
|
|
1237
|
+
owner: [DLOwner]
|
|
1238
|
+
}
|
|
1239
|
+
|
|
1240
|
+
type DLAttributes {
|
|
1241
|
+
description: String
|
|
1242
|
+
displayName: String
|
|
1243
|
+
mail: String
|
|
1244
|
+
zimbraDistributionListSubscriptionPolicy: String
|
|
1245
|
+
zimbraDistributionListUnsubscriptionPolicy: String
|
|
1246
|
+
zimbraHideInGal: String
|
|
1247
|
+
zimbraMailAlias: String
|
|
1248
|
+
zimbraMailStatus: String
|
|
1249
|
+
zimbraNotes: String
|
|
1250
|
+
}
|
|
1251
|
+
|
|
1252
|
+
type SubscribeDistributionList {
|
|
1253
|
+
status: String
|
|
1254
|
+
}
|
|
1255
|
+
|
|
1256
|
+
type DLGrantee {
|
|
1257
|
+
id: ID
|
|
1258
|
+
type: String
|
|
1259
|
+
name: String
|
|
1260
|
+
}
|
|
1261
|
+
|
|
1262
|
+
type DLRight {
|
|
1263
|
+
right: String
|
|
1264
|
+
grantee: [DLGrantee]
|
|
1265
|
+
}
|
|
1266
|
+
|
|
1267
|
+
type DLRights {
|
|
1268
|
+
right: [DLRight]
|
|
1269
|
+
}
|
|
1270
|
+
|
|
1271
|
+
type DLDetails {
|
|
1272
|
+
dynamic: Boolean
|
|
1273
|
+
id: String
|
|
1274
|
+
isMember: Boolean
|
|
1275
|
+
isOwner: Boolean
|
|
1276
|
+
name: String
|
|
1277
|
+
owners: [DLOwners]
|
|
1278
|
+
rights: [DLRights]
|
|
1279
|
+
_attrs: DLAttributes
|
|
1280
|
+
}
|
|
1281
|
+
|
|
1282
|
+
type DL {
|
|
1283
|
+
dl: [DLDetails]
|
|
1284
|
+
}
|
|
1209
1285
|
|
|
1210
|
-
|
|
1286
|
+
type DLMembersDetails {
|
|
1211
1287
|
dlm: [Dlm]
|
|
1212
1288
|
dlGroupMember: [DlGroupMember]
|
|
1213
1289
|
more: Boolean,
|
|
1214
1290
|
total: Int
|
|
1215
|
-
|
|
1291
|
+
}
|
|
1216
1292
|
|
|
1217
1293
|
type HabGroup {
|
|
1218
1294
|
name: String
|
|
@@ -1406,6 +1482,7 @@ type AccountInfoAttrs {
|
|
|
1406
1482
|
zimbraFeatureFiltersEnabled: Boolean
|
|
1407
1483
|
zimbraFeatureReadReceiptsEnabled: Boolean
|
|
1408
1484
|
zimbraFeatureSharingEnabled: Boolean
|
|
1485
|
+
zimbraFeatureSharedFolderMobileSyncEnabled: Boolean
|
|
1409
1486
|
zimbraFeatureManageZimlets: Boolean
|
|
1410
1487
|
zimbraFeatureTwoFactorAuthAvailable: Boolean
|
|
1411
1488
|
zimbraFeatureTwoFactorAuthRequired: Boolean
|
|
@@ -1413,6 +1490,8 @@ type AccountInfoAttrs {
|
|
|
1413
1490
|
zimbraFeatureZulipChatEnabled: Boolean
|
|
1414
1491
|
zimbraFeatureDocumentEditingEnabled: Boolean
|
|
1415
1492
|
zimbraTwoFactorAuthEnabled: Boolean
|
|
1493
|
+
zimbraTwoFactorAuthMethodAllowed: [String]
|
|
1494
|
+
zimbraTwoFactorAuthMethodEnabled: [String]
|
|
1416
1495
|
zimbraFeatureTrustedDevicesEnabled: Boolean
|
|
1417
1496
|
zimbraFeatureAntispamEnabled: Boolean
|
|
1418
1497
|
zimbraFeatureAppSpecificPasswordsEnabled: Boolean
|
|
@@ -1547,6 +1626,7 @@ type Preferences {
|
|
|
1547
1626
|
zimbraPrefCalendarAlwaysShowMiniCal: Boolean
|
|
1548
1627
|
zimbraPrefComposeDirection: String
|
|
1549
1628
|
zimbraPrefComposeFormat: Mode
|
|
1629
|
+
zimbraPrefForwardReplyInOriginalFormat: Boolean
|
|
1550
1630
|
zimbraPrefHtmlEditorDefaultFontColor: String
|
|
1551
1631
|
zimbraPrefHtmlEditorDefaultFontFamily: String
|
|
1552
1632
|
zimbraPrefHtmlEditorDefaultFontSize: String
|
|
@@ -1595,6 +1675,7 @@ type Preferences {
|
|
|
1595
1675
|
zimbraPrefTagTreeOpen: Boolean
|
|
1596
1676
|
zimbraPrefPowerPasteEnabled: Boolean
|
|
1597
1677
|
zimbraPrefDisplayTimeInMailList: Boolean
|
|
1678
|
+
zimbraPrefPrimaryTwoFactorAuthMethod: String
|
|
1598
1679
|
}
|
|
1599
1680
|
|
|
1600
1681
|
type GetAppointmentResponse {
|
|
@@ -1706,6 +1787,11 @@ type SaveDraftResponse {
|
|
|
1706
1787
|
message: [MessageInfo]
|
|
1707
1788
|
}
|
|
1708
1789
|
|
|
1790
|
+
type CustomHeader {
|
|
1791
|
+
key: String
|
|
1792
|
+
value: String
|
|
1793
|
+
}
|
|
1794
|
+
|
|
1709
1795
|
type CustomMetadataAttrs {
|
|
1710
1796
|
key: String
|
|
1711
1797
|
value: String
|
|
@@ -1733,6 +1819,7 @@ type Contact {
|
|
|
1733
1819
|
attributes: ContactAttributes
|
|
1734
1820
|
members: [ContactListMember]
|
|
1735
1821
|
certificate: [SmimeCert]
|
|
1822
|
+
isOwner: Boolean
|
|
1736
1823
|
}
|
|
1737
1824
|
|
|
1738
1825
|
type OtherContactAttribute {
|
|
@@ -1995,6 +2082,7 @@ type ShareInfo {
|
|
|
1995
2082
|
rights: String
|
|
1996
2083
|
view: FolderView
|
|
1997
2084
|
mid: ID
|
|
2085
|
+
activeSyncDisabled: Boolean
|
|
1998
2086
|
}
|
|
1999
2087
|
|
|
2000
2088
|
type MailboxMetadataAttrs {
|
|
@@ -2228,6 +2316,12 @@ input SendMessageInput {
|
|
|
2228
2316
|
emailAddresses: [MailItemEmailAddressInput] #e
|
|
2229
2317
|
attachments: [AttachmentInput] #attach
|
|
2230
2318
|
inlineAttachments: [MimePartInput] #attach
|
|
2319
|
+
header: [HeaderInput] #header
|
|
2320
|
+
}
|
|
2321
|
+
|
|
2322
|
+
input HeaderInput {
|
|
2323
|
+
name: String #name
|
|
2324
|
+
_content: String #value
|
|
2231
2325
|
}
|
|
2232
2326
|
|
|
2233
2327
|
input SaveSMimeCertInputUpload {
|
|
@@ -2604,6 +2698,7 @@ input PreferencesInput {
|
|
|
2604
2698
|
zimbraPrefCalendarAlwaysShowMiniCal: Boolean
|
|
2605
2699
|
zimbraPrefComposeDirection: String
|
|
2606
2700
|
zimbraPrefComposeFormat: Mode
|
|
2701
|
+
zimbraPrefForwardReplyInOriginalFormat: Boolean
|
|
2607
2702
|
zimbraPrefExternalSendersType: ExternalSendersType
|
|
2608
2703
|
zimbraPrefHtmlEditorDefaultFontColor: String
|
|
2609
2704
|
zimbraPrefHtmlEditorDefaultFontFamily: String
|
|
@@ -2648,6 +2743,7 @@ input PreferencesInput {
|
|
|
2648
2743
|
zimbraPrefTagTreeOpen: Boolean
|
|
2649
2744
|
zimbraPrefPowerPasteEnabled: Boolean
|
|
2650
2745
|
zimbraPrefDisplayTimeInMailList: Boolean
|
|
2746
|
+
zimbraPrefPrimaryTwoFactorAuthMethod: String
|
|
2651
2747
|
}
|
|
2652
2748
|
|
|
2653
2749
|
input ModifyIdentityInput {
|
|
@@ -2973,6 +3069,8 @@ input ExternalAccountModifyAttrsInput {
|
|
|
2973
3069
|
|
|
2974
3070
|
input EnableTwoFactorAuthInput {
|
|
2975
3071
|
name: String!
|
|
3072
|
+
method: String!
|
|
3073
|
+
email: String
|
|
2976
3074
|
password: String
|
|
2977
3075
|
twoFactorCode: String
|
|
2978
3076
|
authToken: String
|
|
@@ -2980,6 +3078,11 @@ input EnableTwoFactorAuthInput {
|
|
|
2980
3078
|
ignoreSameSite: Boolean
|
|
2981
3079
|
}
|
|
2982
3080
|
|
|
3081
|
+
input SendTwoFactorAuthCodeInput {
|
|
3082
|
+
action: String!
|
|
3083
|
+
authToken: String!
|
|
3084
|
+
}
|
|
3085
|
+
|
|
2983
3086
|
input ExternalAccountImportInput {
|
|
2984
3087
|
accountType: AccountType
|
|
2985
3088
|
id: ID!
|
|
@@ -3113,6 +3216,46 @@ input SaveDocumentInput {
|
|
|
3113
3216
|
document: SaveDocumentInput
|
|
3114
3217
|
}
|
|
3115
3218
|
|
|
3219
|
+
input DLActionAttrInput {
|
|
3220
|
+
attributeName: String
|
|
3221
|
+
content: String
|
|
3222
|
+
}
|
|
3223
|
+
|
|
3224
|
+
input DLActionGranteeInput {
|
|
3225
|
+
by: String
|
|
3226
|
+
type: String
|
|
3227
|
+
_content: String
|
|
3228
|
+
}
|
|
3229
|
+
|
|
3230
|
+
input DLActionRightInput {
|
|
3231
|
+
right: String
|
|
3232
|
+
grantee: [DLActionGranteeInput]
|
|
3233
|
+
}
|
|
3234
|
+
|
|
3235
|
+
input SubRequestInput {
|
|
3236
|
+
op: String
|
|
3237
|
+
_content: String
|
|
3238
|
+
}
|
|
3239
|
+
|
|
3240
|
+
input DLActionInput {
|
|
3241
|
+
operation: String
|
|
3242
|
+
attributes: [DLActionAttrInput]
|
|
3243
|
+
right: DLActionRightInput
|
|
3244
|
+
owner: [DLActionGranteeInput]
|
|
3245
|
+
subsReq: SubRequestInput
|
|
3246
|
+
distributionListMembers: [MethodInput]
|
|
3247
|
+
}
|
|
3248
|
+
|
|
3249
|
+
input DLSelectorInput {
|
|
3250
|
+
by: String
|
|
3251
|
+
_content: String
|
|
3252
|
+
}
|
|
3253
|
+
|
|
3254
|
+
input DistributionListActionInput {
|
|
3255
|
+
action: DLActionInput
|
|
3256
|
+
dl: DLSelectorInput
|
|
3257
|
+
}
|
|
3258
|
+
|
|
3116
3259
|
type SaveDocument {
|
|
3117
3260
|
id: ID
|
|
3118
3261
|
version: Int
|
|
@@ -3393,11 +3536,17 @@ type Query {
|
|
|
3393
3536
|
attrs: String
|
|
3394
3537
|
ownerOf: Int
|
|
3395
3538
|
): DLSDetails
|
|
3539
|
+
getDistributionList(
|
|
3540
|
+
needOwners: Boolean
|
|
3541
|
+
needRights: String
|
|
3542
|
+
dl: String
|
|
3543
|
+
by: String
|
|
3544
|
+
): DL
|
|
3396
3545
|
getDistributionListMembers(
|
|
3397
3546
|
limit: Int
|
|
3398
3547
|
offset: Int
|
|
3399
3548
|
dl: String
|
|
3400
|
-
):
|
|
3549
|
+
): DLMembersDetails
|
|
3401
3550
|
getCustomMetadata(id: ID!, section: String): CustomMetadata
|
|
3402
3551
|
getMailboxMetadata(section: String): MailboxMetadata
|
|
3403
3552
|
getMessage(
|
|
@@ -3462,7 +3611,8 @@ type Query {
|
|
|
3462
3611
|
sortBy: SortBy
|
|
3463
3612
|
types: SearchType
|
|
3464
3613
|
resultMode: String
|
|
3465
|
-
inDumpster: Boolean
|
|
3614
|
+
inDumpster: Boolean,
|
|
3615
|
+
header: [MailItemHeaderInput]
|
|
3466
3616
|
): SearchResponse
|
|
3467
3617
|
|
|
3468
3618
|
searchCalendarResources(
|
|
@@ -3612,7 +3762,7 @@ type Mutation {
|
|
|
3612
3762
|
enableTwoFactorAuth(
|
|
3613
3763
|
options: EnableTwoFactorAuthInput!
|
|
3614
3764
|
): EnableTwoFactorAuthResponse
|
|
3615
|
-
disableTwoFactorAuth: Boolean
|
|
3765
|
+
disableTwoFactorAuth(method: String!): Boolean
|
|
3616
3766
|
messageAction(ids: [ID!]!, op: String!): Boolean
|
|
3617
3767
|
modifyExternalAccount(
|
|
3618
3768
|
id: ID!
|
|
@@ -3667,6 +3817,9 @@ type Mutation {
|
|
|
3667
3817
|
sendDeliveryReport(messageId: ID!): Boolean
|
|
3668
3818
|
sendInviteReply(inviteReply: InviteReplyInput!): InviteReplyResponse
|
|
3669
3819
|
sendShareNotification(shareNotification: ShareNotificationInput!): Boolean
|
|
3820
|
+
sendTwoFactorAuthCode(
|
|
3821
|
+
options: SendTwoFactorAuthCodeInput!
|
|
3822
|
+
): SendTwoFactorAuthCodeResponse
|
|
3670
3823
|
setCustomMetadata(customMetaData: CustomMetadataInput!): Boolean
|
|
3671
3824
|
setMailboxMetadata(
|
|
3672
3825
|
section: String
|
|
@@ -3691,6 +3844,8 @@ type Mutation {
|
|
|
3691
3844
|
cancelPendingAccountOnlyRemoteWipeSync(deviceId: String): Device
|
|
3692
3845
|
remoteWipeSync(deviceId: String): Device
|
|
3693
3846
|
cancelPendingRemoteWipeSync(deviceId: String): Device
|
|
3847
|
+
subscribeDistributionList(op: String!, by: String, dl: String!): String
|
|
3848
|
+
distributionListAction(dlActions: DistributionListActionInput!): Boolean
|
|
3694
3849
|
}
|
|
3695
3850
|
|
|
3696
3851
|
schema {
|
package/src/schema/schema.ts
CHANGED
|
@@ -12,6 +12,7 @@ import {
|
|
|
12
12
|
CustomMetadataInput,
|
|
13
13
|
DeleteAppointmentInput,
|
|
14
14
|
DeleteIdentityInput,
|
|
15
|
+
DistributionListActionInput,
|
|
15
16
|
EnableTwoFactorAuthInput,
|
|
16
17
|
ExternalAccountAddInput,
|
|
17
18
|
ExternalAccountImportInput,
|
|
@@ -34,6 +35,7 @@ import {
|
|
|
34
35
|
SaveSMimeCertInputUpload,
|
|
35
36
|
SearchFolderInput,
|
|
36
37
|
SendMessageInput,
|
|
38
|
+
SendTwoFactorAuthCodeInput,
|
|
37
39
|
ShareNotificationInput,
|
|
38
40
|
SignatureInput,
|
|
39
41
|
WhiteBlackListInput,
|
|
@@ -144,6 +146,8 @@ export function createZimbraSchema(options: ZimbraSchemaOptions): {
|
|
|
144
146
|
getHAB: (_, { habRootGroupId }) => client.getHAB(habRootGroupId),
|
|
145
147
|
getAccountDistributionLists: (_, { attrs, ownerOf }) =>
|
|
146
148
|
client.getAccountDistributionLists(attrs, ownerOf),
|
|
149
|
+
getDistributionList: (_, { dl, needOwners, needRights, by }) =>
|
|
150
|
+
client.getDistributionList(dl, needOwners, needRights, by),
|
|
147
151
|
getDistributionListMembers: (_, { limit, offset, dl }) =>
|
|
148
152
|
client.getDistributionListMembers(limit, offset, dl),
|
|
149
153
|
getAppointment: (_: any, variables) =>
|
|
@@ -236,7 +240,7 @@ export function createZimbraSchema(options: ZimbraSchemaOptions): {
|
|
|
236
240
|
itemAction: (_, variables) => client.itemAction(variables as ActionOptions),
|
|
237
241
|
login: (_, variables) => client.login(variables as LoginOptions),
|
|
238
242
|
logout: client.logout,
|
|
239
|
-
disableTwoFactorAuth: client.disableTwoFactorAuth,
|
|
243
|
+
disableTwoFactorAuth: (_, { method }) => client.disableTwoFactorAuth(method),
|
|
240
244
|
enableTwoFactorAuth: (_, { options }) =>
|
|
241
245
|
client.enableTwoFactorAuth(options as EnableTwoFactorAuthInput),
|
|
242
246
|
messageAction: (_, variables) => client.messageAction(variables as ActionOptions),
|
|
@@ -315,7 +319,8 @@ export function createZimbraSchema(options: ZimbraSchemaOptions): {
|
|
|
315
319
|
grantRights: (_, variables) => client.grantRights(variables.input as GrantRightsInput),
|
|
316
320
|
sendShareNotification: (_, { shareNotification }) =>
|
|
317
321
|
client.sendShareNotification(shareNotification as ShareNotificationInput),
|
|
318
|
-
|
|
322
|
+
sendTwoFactorAuthCode: (_, { options }) =>
|
|
323
|
+
client.sendTwoFactorAuthCode(options as SendTwoFactorAuthCodeInput),
|
|
319
324
|
testExternalAccount: (_, { externalAccount }) =>
|
|
320
325
|
client.testExternalAccount(externalAccount as ExternalAccountTestInput),
|
|
321
326
|
addExternalAccount: (_, { externalAccount }) =>
|
|
@@ -442,7 +447,11 @@ export function createZimbraSchema(options: ZimbraSchemaOptions): {
|
|
|
442
447
|
},
|
|
443
448
|
cancelPendingRemoteWipeSync: (_, { deviceId }) => {
|
|
444
449
|
client.cancelPendingRemoteWipeSync(deviceId);
|
|
445
|
-
}
|
|
450
|
+
},
|
|
451
|
+
subscribeDistributionList: (_, { op, by, dl }) =>
|
|
452
|
+
client.subscribeDistributionList(op, by, dl),
|
|
453
|
+
distributionListAction: (_, { dlActions }) =>
|
|
454
|
+
client.distributionListAction(dlActions as DistributionListActionInput)
|
|
446
455
|
}
|
|
447
456
|
}
|
|
448
457
|
});
|
|
@@ -29,3 +29,12 @@ export function normalizeCustomMetaDataAttrs(data: any) {
|
|
|
29
29
|
_attrs: attrs
|
|
30
30
|
};
|
|
31
31
|
}
|
|
32
|
+
|
|
33
|
+
export function normalizeHeaderAttrs(data: any) {
|
|
34
|
+
let attrs: any = [];
|
|
35
|
+
|
|
36
|
+
Object.keys(data).forEach(
|
|
37
|
+
key => typeof data[key] === 'string' && attrs.push({ key, value: data[key] })
|
|
38
|
+
);
|
|
39
|
+
return attrs;
|
|
40
|
+
}
|