-
Notifications
You must be signed in to change notification settings - Fork 1
/
MailInterface.php
2086 lines (1924 loc) · 76.5 KB
/
MailInterface.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<?php
/**
* This file is part of the Zimbra API in PHP library.
*
* © Nguyen Van Nguyen <[email protected]>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Zimbra\Mail;
use Zimbra\Account\AccountInterface;
use Zimbra\Enum\Action;
use Zimbra\Enum\BrowseBy;
use Zimbra\Enum\GalSearchType;
use Zimbra\Enum\InterestType;
use Zimbra\Enum\ParticipationStatus;
use Zimbra\Enum\SortBy;
use Zimbra\Mail\Struct\ActivityFilter;
use Zimbra\Mail\Struct\AddedComment;
use Zimbra\Mail\Struct\AddMsgSpec;
use Zimbra\Mail\Struct\AttributeName;
use Zimbra\Mail\Struct\BounceMsgSpec;
use Zimbra\Mail\Struct\CalTZInfo;
use Zimbra\Mail\Struct\ContactActionSelector;
use Zimbra\Mail\Struct\ContactSpec;
use Zimbra\Mail\Struct\Content;
use Zimbra\Mail\Struct\ContentSpec;
use Zimbra\Mail\Struct\ConvActionSelector;
use Zimbra\Mail\Struct\ConversationSpec;
use Zimbra\Mail\Struct\DiffDocumentVersionSpec;
use Zimbra\Mail\Struct\DismissAppointmentAlarm;
use Zimbra\Mail\Struct\DismissTaskAlarm;
use Zimbra\Mail\Struct\DocumentActionSelector;
use Zimbra\Mail\Struct\DocumentSpec;
use Zimbra\Mail\Struct\DtTimeInfo;
use Zimbra\Mail\Struct\ExpandedRecurrenceCancel;
use Zimbra\Mail\Struct\ExpandedRecurrenceException;
use Zimbra\Mail\Struct\ExpandedRecurrenceInvite;
use Zimbra\Mail\Struct\FilterRules;
use Zimbra\Mail\Struct\FreeBusyUserSpec;
use Zimbra\Mail\Struct\FolderActionSelector;
use Zimbra\Mail\Struct\FolderSpec;
use Zimbra\Mail\Struct\GetFolderSpec;
use Zimbra\Mail\Struct\IdsAttr;
use Zimbra\Mail\Struct\IdStatus;
use Zimbra\Mail\Struct\InstanceRecurIdInfo;
use Zimbra\Mail\Struct\ItemActionSelector;
use Zimbra\Mail\Struct\ItemSpec;
use Zimbra\Mail\Struct\ListDocumentRevisionsSpec;
use Zimbra\Mail\Struct\MailCustomMetadata;
use Zimbra\Mail\Struct\ModifyContactSpec;
use Zimbra\Mail\Struct\ModifySearchFolderSpec;
use Zimbra\Mail\Struct\Msg;
use Zimbra\Mail\Struct\MsgActionSelector;
use Zimbra\Mail\Struct\MsgPartIds;
use Zimbra\Mail\Struct\MsgSpec;
use Zimbra\Mail\Struct\MsgToSend;
use Zimbra\Mail\Struct\NamedFilterRules;
use Zimbra\Mail\Struct\NewFolderSpec;
use Zimbra\Mail\Struct\NewMountpointSpec;
use Zimbra\Mail\Struct\NewNoteSpec;
use Zimbra\Mail\Struct\NewSearchFolderSpec;
use Zimbra\Mail\Struct\NoteActionSelector;
use Zimbra\Mail\Struct\ParentId;
use Zimbra\Mail\Struct\PurgeRevisionSpec;
use Zimbra\Mail\Struct\RankingActionSpec;
use Zimbra\Mail\Struct\Replies;
use Zimbra\Mail\Struct\SaveDraftMsg;
use Zimbra\Mail\Struct\SectionAttr;
use Zimbra\Mail\Struct\SetCalendarItemInfo;
use Zimbra\Mail\Struct\SharedReminderMount;
use Zimbra\Mail\Struct\SnoozeAppointmentAlarm;
use Zimbra\Mail\Struct\SnoozeTaskAlarm;
use Zimbra\Mail\Struct\TagSpec;
use Zimbra\Mail\Struct\TagActionSelector;
use Zimbra\Mail\Struct\TargetSpec;
use Zimbra\Mail\Struct\MailDataSource;
use Zimbra\Mail\Struct\MailImapDataSource;
use Zimbra\Mail\Struct\MailPop3DataSource;
use Zimbra\Mail\Struct\MailCaldavDataSource;
use Zimbra\Mail\Struct\MailYabDataSource;
use Zimbra\Mail\Struct\MailRssDataSource;
use Zimbra\Mail\Struct\MailGalDataSource;
use Zimbra\Mail\Struct\MailCalDataSource;
use Zimbra\Mail\Struct\MailUnknownDataSource;
use Zimbra\Mail\Struct\ImapDataSourceNameOrId;
use Zimbra\Mail\Struct\Pop3DataSourceNameOrId;
use Zimbra\Mail\Struct\CaldavDataSourceNameOrId;
use Zimbra\Mail\Struct\YabDataSourceNameOrId;
use Zimbra\Mail\Struct\RssDataSourceNameOrId;
use Zimbra\Mail\Struct\GalDataSourceNameOrId;
use Zimbra\Mail\Struct\CalDataSourceNameOrId;
use Zimbra\Mail\Struct\UnknownDataSourceNameOrId;
use Zimbra\Struct\CursorInfo;
use Zimbra\Struct\Id;
use Zimbra\Struct\NamedElement;
use Zimbra\Struct\WaitSetAdd;
use Zimbra\Struct\WaitSetSpec;
use Zimbra\Struct\WaitSetId;
/**
* MailInterface is a interface which allows to connect Zimbra API mail functions via SOAP
*
* @package Zimbra
* @category Mail
* @author Nguyen Van Nguyen - [email protected]
* @copyright Copyright © 2013 by Nguyen Van Nguyen.
*/
interface MailInterface extends AccountInterface
{
/**
* Add an invite to an appointment.
* The invite corresponds to a VEVENT component.
* Based on the UID specified (required),
* a new appointment is created in the default calendar if necessary.
* If an appointment with the same UID exists,
* the appointment is updated with the new invite only if the invite is not outdated,
* according to the iCalendar sequencing rule (based on SEQUENCE, RECURRENCE-ID and DTSTAMP).
*
* @param Msg $message Message.
* @param ParticipationStatus $ptst iCalendar PTST (Participation status). Valid values: NE|AC|TE|DE|DG|CO|IN|WE|DF. Meanings: "NE"eds-action, "TE"ntative, "AC"cept, "DE"clined, "DG" (delegated), "CO"mpleted (todo), "IN"-process (todo), "WA"iting (custom value only for todo), "DF" (deferred; custom value only for todo)
* @return mix
*/
function addAppointmentInvite(Msg $m = null, ParticipationStatus $ptst = null);
/**
* Add a comment to the specified item. Currently comments can only be added to documents.
*
* @param AddedComment $comment Added comment.
* @return mix
*/
function addComment(AddedComment $comment);
/**
* Add a message.
*
* @param AddMsgSpec $m Specification of the message to add.
* @param bool $filterSent If set, then do outgoing message filtering if the msg is being added to the Sent folder and has been flagged as sent. Default is unset.
* @return mix
*/
function addMsg(AddMsgSpec $m, $filterSent = null);
/**
* Add a task invite.
*
* @param Msg $m Message.
* @param ParticipationStatus $ptst iCalendar PTST (Participation status). Valid values: NE|AC|TE|DE|DG|CO|IN|WE|DF. Meanings: "NE"eds-action, "TE"ntative, "AC"cept, "DE"clined, "DG" (delegated), "CO"mpleted (todo), "IN"-process (todo), "WA"iting (custom value only for todo), "DF" (deferred; custom value only for todo)
* @return mix
*/
function addTaskInvite(Msg $m = null, ParticipationStatus $ptst = null);
/**
* Announce change of organizer.
*
* @param string $id ID.
* @return mix
*/
function announceOrganizerChange($id);
/**
* Applies one or more filter rules to messages specified by a comma-separated ID list, or returned by a search query.
* One or the other can be specified, but not both.
* Returns the list of ids of existing messages that were affected.
* Note that redirect actions are ignored when applying filter rules to existing messages.
*
* @param NamedFilterRules $filterRules Filter rules.
* @param IdsAttr $m Comma-separated list of message IDs.
* @param string $query Query string.
* @return mix
*/
function applyFilterRules(
NamedFilterRules $filterRules,
IdsAttr $m = null,
$query = null
);
/**
* Applies one or more filter rules to messages specified by a comma-separated ID list, or returned by a search query.
* One or the other can be specified, but not both.
* Returns the list of ids of existing messages that were affected.
*
* @param NamedFilterRules $filterRules Filter rules.
* @param IdsAttr $m Comma-separated list of message IDs.
* @param string $query Query string.
* @return mix
*/
function applyOutgoingFilterRules(
NamedFilterRules $filterRules,
IdsAttr $m = null,
$query = null
);
/**
* AutoComplete.
*
* @param string $name Name.
* @param GalSearchType $t GAL Search type - default value is "account". Valid values: all|account|resource|group
* @param bool $needExp Set if the "exp" flag is needed in the response for group entries. Default is unset..
* @param string $folders Comma separated list of folder IDs.
* @param bool $includeGal Flag whether to include Global Address Book (GAL).
* @return mix
*/
function autoComplete(
$name,
GalSearchType $t = null,
$needExp = null,
$folders = null,
$includeGal = null
);
/**
* Resend a message.
* Supports (f)rom, (t)o, (c)c, (b)cc, (s)ender "type" on <e> elements
* (these get mapped to Resent-From, Resent-To, Resent-CC, Resent-Bcc, Resent-Sender headers,
* which are prepended to copy of existing message)
* Aside from these prepended headers, message is reinjected verbatim
*
* @param BounceMsgSpec $m Specification of message to be resent.
* @return mix
*/
function bounceMsg(BounceMsgSpec $m);
/**
* Browse.
*
* @param BrowseBy $browseBy Browse by setting - domains|attachments|objects.
* @param string $regex Regex string. Return only those results which match the specified regular expression.
* @param int $maxToReturn Return only a maximum number of entries as requested. If more than {max-entries} results exist, the server will return the first {max-entries}, sorted by frequency.
* @return mix
*/
function browse(BrowseBy $browseBy, $regex = null, $maxToReturn = null);
/**
* Cancel appointment.
* NOTE: If canceling an exception, the original instance (ie the one the exception was "excepting") WILL NOT be restored when you cancel this exception.
* If <inst> is set, then this cancels just the specified instance or range of instances, otherwise it cancels the entire appointment. If <inst> is not set, then id MUST refer to the default invite for the appointment.
*
* @param InstanceRecurIdInfo $inst Instance recurrence ID information
* @param CalTZInfo $tz Definition for TZID referenced by DATETIME in <inst>
* @param Msg $m Message
* @param string $id ID of default invite
* @param int $comp Component number of default invite
* @param int $ms Modified sequence
* @param int $rev Revision
* @return mix
*/
function cancelAppointment(
InstanceRecurIdInfo $inst = null,
CalTZInfo $tz = null,
Msg $m = null,
$id = null,
$comp = null,
$ms = null,
$rev = null
);
/**
* Cancel task.
*
* @param InstanceRecurIdInfo $inst Instance recurrence ID information
* @param CalTZInfo $tz Definition for TZID referenced by DATETIME in <inst>
* @param Msg $m Message
* @param string $id ID of default invite
* @param int $comp Component number of default invite
* @param int $ms Modified sequence
* @param int $rev Revision
* @return mix
*/
function cancelTask(
InstanceRecurIdInfo $inst = null,
CalTZInfo $tz = null,
Msg $m = null,
$id = null,
$comp = null,
$ms = null,
$rev = null
);
/**
* Check device status.
*
* @param Id $id Device ID.
* @return mix
*/
function checkDeviceStatus(Id $device);
/**
* Check if the authed user has the specified right(s) on a target.
* If the specified target cannot be found:
* 1. if by is "id", throw NO_SUCH_ACCOUNT/NO_SUCH_CALENDAR_RESOURCE
* 2. if by is "name", return the default permission for the right.
*
* @param TargetSpec $target Target specification
* @param array $rights Rights to check.
* @return mix
*/
function checkPermission(TargetSpec $target = null, array $right = []);
/**
* Check conflicts in recurrence against list of users.
* Set all attribute to get all instances, even those without conflicts.
* By default only instances that have conflicts are returned.
*
* @param array $tz Timezones
* @param int $s Start time in millis. If not specified, defaults to current time
* @param int $e End time in millis. If not specified, unlimited
* @param bool $all Set this to get all instances, even those without conflicts. By default only instances that have conflicts are returned.
* @param string $excludeUid UID of appointment to exclude from free/busy search
* @param array $timezones Timezones
* @param array $component Expanded recurrences
* @param array $users Freebusy user specifications
* @return mix
*/
function checkRecurConflicts(
$s = null,
$e = null,
$all = null,
$excludeUid = null,
array $timezones = [],
array $component = [],
array $users = []
);
/**
* Check spelling.
* Suggested words are listed in decreasing order of their match score.
* The "available" attribute specifies whether the server-side spell checking interface is available or not.
*
* @param string $value Text to spell check
* @param string $dictionary The optional name of the aspell dictionary that will be used to check spelling.
* @param string $ignore Comma-separated list of words to ignore just for this request.
* @return mix
*/
function checkSpelling($value = null, $dictionary = null, $ignore = null);
/**
* Complete a task instance.
*
* @param string $id ID
* @param DtTimeInfo $exceptId Exception ID
* @param CalTZInfo $tz Timezone information
* @return mix
*/
function completeTaskInstance(
$id,
DtTimeInfo $exceptId,
CalTZInfo $tz = null
);
/**
* Contact Action.
*
* @param ContactActionSelector $action Contact action selector
* @return mix
*/
function contactAction(ContactActionSelector $action);
/**
* Conv Action.
*
* @param ConvActionSelector $action Action selector.
* @return mix
*/
function convAction(ConvActionSelector $action);
/**
* Propose a new time/location. Sent by meeting attendee to organizer.
* The syntax is very similar to CreateAppointmentRequest.
*
* @param Msg $m Details of counter proposal.
* @param string $id Invite ID of default invite
* @param int $comp Component number of default component
* @param int $ms Changed sequence of fetched version.
* @param int $rev Revision
* @return mix
*/
function counterAppointment(
Msg $m = null,
$id = null,
$comp = null,
$ms = null,
$rev = null
);
/**
* This is the API to create a new Appointment, optionally sending out meeting Invitations to other people.
*
* @param Msg $m Message
* @param bool $echo If specified, the created appointment is echoed back in the response as if a GetMsgRequest was made
* @param int $max Maximum inlined length
* @param bool $html Set if want HTML included in echoing
* @param bool $neuter Set if want "neuter" set for echoed response
* @param bool $forcesend If set, ignore smtp 550 errors when sending the notification to attendees.
* @return mix
*/
function createAppointment(
Msg $m = null,
$echo = null,
$max = null,
$html = null,
$neuter = null,
$forcesend = null
);
/**
* Create Appointment Exception.
*
* @param Msg $m Message
* @param string $id ID of default invite
* @param int $comp Component of default invite
* @param int $ms Change sequence of fetched series
* @param int $rev Revision of fetched series
* @param bool $echo If specified, the created appointment is echoed back in the response as if a GetMsgRequest was made
* @param int $max Maximum inlined length
* @param bool $html Set if want HTML included in echoing
* @param bool $neuter Set if want "neuter" set for echoed response
* @param bool $forcesend If set, ignore smtp 550 errors when sending the notification to attendees.
* @return mix
*/
function createAppointmentException(
Msg $m = null,
$id = null,
$comp = null,
$ms = null,
$rev = null,
$echo = null,
$max = null,
$html = null,
$neuter = null,
$forcesend = null
);
/**
* Create a contact.
*
* @param ContactSpec $cn Contact specification
* @param bool $verbose If set (defaults to unset) The returned <cn> is just a placeholder containing the new contact ID (i.e. <cn id="{id}"/>)
* @return mix
*/
function createContact(ContactSpec $cn, $verbose = null);
/**
* Creates a data source that imports mail items into the specified folder,
* for example via the POP3 or IMAP protocols.
* Only one data source is allowed per request.
*
* @param MailDataSource $ds Data source
* @return mix
*/
function createDataSource(MailDataSource $ds);
/**
* Creates a imap data source that imports mail items into the specified folder.
*
* @param MailImapDataSource $imap Imap data source
* @return mix
*/
function createImapDataSource(MailImapDataSource $imap);
/**
* Creates a pop3 data source that imports mail items into the specified folder.
*
* @param MailPop3DataSource $pop3 Pop3 data source
* @return mix
*/
function createPop3DataSource(MailPop3DataSource $pop3);
/**
* Creates a caldav data source that imports mail items into the specified folder.
*
* @param MailCaldavDataSource $caldav Caldav data source
* @return mix
*/
function createCaldavDataSource(MailCaldavDataSource $caldav);
/**
* Creates a yab data source that imports mail items into the specified folder.
*
* @param MailYabDataSource $yab Caldav data source
* @return mix
*/
function createYabDataSource(MailYabDataSource $yab);
/**
* Creates a rss data source that imports mail items into the specified folder.
*
* @param MailRssDataSource $rss Rss data source
* @return mix
*/
function createRssDataSource(MailRssDataSource $rss);
/**
* Creates a gal data source that imports mail items into the specified folder.
*
* @param MailGalDataSource $gal Gal data source
* @return mix
*/
function createGalDataSource(MailGalDataSource $gal);
/**
* Creates a cal data source that imports mail items into the specified folder.
*
* @param MailCalDataSource $cal Cal data source
* @return mix
*/
function createCalDataSource(MailCalDataSource $cal);
/**
* Creates a unknown data source that imports mail items into the specified folder.
*
* @param MailUnknownDataSource $unknown Unknown data source
* @return mix
*/
function createUnknownDataSource(MailUnknownDataSource $unknown);
/**
* Create folder.
*
* @param NewFolderSpec $folder New folder specification.
* @return mix
*/
function createFolder(NewFolderSpec $folder);
/**
* Create mountpoint.
*
* @param NewMountpointSpec $link New mountpoint specification.
* @return mix
*/
function createMountpoint(NewMountpointSpec $link);
/**
* Create a note.
*
* @param NewNoteSpec $note New note specification.
* @return mix
*/
function createNote(NewNoteSpec $note);
/**
* Create a search folder.
*
* @param NewSearchFolderSpec $search New search folder specification.
* @return mix
*/
function createSearchFolder(NewSearchFolderSpec $search);
/**
* Create a tag.
*
* @param TagSpec $tag Tag specification.
* @return mix
*/
function createTag(TagSpec $tag);
/**
* This is the API to create a new Task.
*
* @param Msg $m Message
* @param bool $echo If specified, the created appointment is echoed back in the response as if a GetMsgRequest was made
* @param int $max Maximum inlined length
* @param bool $html Set if want HTML included in echoing
* @param bool $neuter Set if want "neuter" set for echoed response
* @param bool $forcesend If set, ignore smtp 550 errors when sending the notification to attendees.
* @return mix
*/
function createTask(
Msg $m = null,
$echo = null,
$max = null,
$html = null,
$neuter = null,
$forcesend = null
);
/**
* Create Task Exception.
*
* @param Msg $m Message
* @param string $id ID of default invite
* @param int $comp Component of default invite
* @param int $ms Change sequence of fetched series
* @param int $rev Revision of fetched series
* @param bool $echo If specified, the created appointment is echoed back in the response as if a GetMsgRequest was made
* @param int $max Maximum inlined length
* @param bool $html Set if want HTML included in echoing
* @param bool $neuter Set if want "neuter" set for echoed response
* @param bool $forcesend If set, ignore smtp 550 errors when sending the notification to attendees.
* @return mix
*/
function createTaskException(
Msg $m = null,
$id = null,
$comp = null,
$ms = null,
$rev = null,
$echo = null,
$max = null,
$html = null,
$neuter = null,
$forcesend = null
);
/**
* Create a waitset to listen for changes on one or more accounts.
* Called once to initialize a WaitSet and to set its "default interest types"
* WaitSet: scalable mechanism for listening for changes to one or more accounts
*
* @param WaitSetSpec $add WaitSet add specification.
* @param array $defTypes Default interest types: comma-separated list.
* @param bool $allAccounts If {all-accounts} is set, then all mailboxes on the system will be listened to, including any mailboxes which are created on the system while the WaitSet is in existence.
* @return mix
*/
function createWaitSet(
WaitSetSpec $add = null,
array $defTypes = [],
$allAccounts = null
);
/**
* Decline a change proposal from an attendee.
* Sent by organizer to an attendee who has previously sent a COUNTER message.
* The syntax of the request is very similar to CreateAppointmentRequest.
*
* @param Msg $message Details of the Decline Counter.
* @return mix
*/
function declineCounterAppointment(Msg $m = null);
/**
* Deletes the given data sources.
* The name or id of each data source must be specified.
*
* @param ImapDataSourceNameOrId $imap
* @param Pop3DataSourceNameOrId $pop3
* @param CaldavDataSourceNameOrId $caldav
* @param YabDataSourceNameOrId $yab
* @param RssDataSourceNameOrId $rss
* @param GalDataSourceNameOrId $gal
* @param CalDataSourceNameOrId $cal
* @param UnknownDataSourceNameOrId $unknown
* @return mix
*/
function deleteDataSource(
ImapDataSourceNameOrId $imap = null,
Pop3DataSourceNameOrId $pop3 = null,
CaldavDataSourceNameOrId $caldav = null,
YabDataSourceNameOrId $yab = null,
RssDataSourceNameOrId $rss = null,
GalDataSourceNameOrId $gal = null,
CalDataSourceNameOrId $cal = null,
UnknownDataSourceNameOrId $unknown = null
);
/**
* Permanently deletes mapping for indicated device.
*
* @param Id $id Device ID.
* @return mix
*/
function deleteDevice(Id $device);
/**
* Use this to close out the waitset.
* Note that the server will automatically time out a wait set if there is no reference to it for (default of) 20 minutes.
* WaitSet: scalable mechanism for listening for changes to one or more accounts.
*
* @param string $waitSet Waitset ID.
* @return mix
*/
function destroyWaitSet($waitSet);
/**
* Performs line by line diff of two revisions of a Document then returns a list of <chunk/> containing the result.
* Sections of text that are identical to both versions are indicated with disp="common".
* For each conflict the chunk will show disp="first", disp="second" or both.
*
* @param DiffDocumentVersionSpec $doc Diff document version specification.
* @return mix
*/
function diffDocument(DiffDocumentVersionSpec $doc);
/**
* Dismiss calendar item alarm.
*
* @param array $alarms Details of alarms to dismiss.
* @return mix
*/
function dismissCalendarItemAlarm(array $alarms);
/**
* Document action.
*
* @param DocumentActionSelector $action Document action selector.
* @return mix
*/
function documentAction(DocumentActionSelector $action);
/**
* Empty dumpster.
*
* @return mix
*/
function emptyDumpster();
/**
* Enable/disable reminders for shared appointments/tasks on a mountpoint.
*
* @param SharedReminderMount $link Specification for mountpoint.
* @return mix
*/
function enableSharedReminder(SharedReminderMount $link);
/**
* Expand recurrences.
*
* @param int $startTime Start time in milliseconds
* @param int $endTime End time in milliseconds
* @param array $timezones Timezone definitions
* @param array $components Specifications for series, modified instances and canceled instances
* @return mix
*/
function expandRecur(
$startTime,
$endTime,
array $timezones = [],
array $components = []
);
/**
* Export contacts.
*
* @param string $ct Content type. Currently, the only supported content type is "csv" (comma-separated values).
* @param string $l Optional folder id to export contacts from.
* @param string $csvfmt Optional csv format for exported contacts. the supported formats are defined in $ZIMBRA_HOME/conf/zimbra-contact-fields.xml.
* @param string $csvlocale The locale to use when there are multiple {csv-format} locales defined. When it is not specified, the {csv-format} with no locale specification is used.
* @param string $csvsep Optional delimiter character to use in the resulting csv file - usually "," or ";".
* @return mix
*/
function exportContacts(
$ct,
$l = null,
$csvfmt = null,
$csvlocale = null,
$csvsep = null
);
/**
* Perform an action on a folder.
*
* @param FolderActionSelector $action Select action to perform on folder.
* @return mix
*/
function folderAction(FolderActionSelector $action);
/**
* Used by an attendee to forward an instance or entire appointment to another user who is not already an attendee.
*
* @param string $id Appointment item ID
* @param DtTimeInfo $exceptId RECURRENCE-ID information if forwarding a single instance of a recurring appointment
* @param CalTZInfo $tz Definition for TZID referenced by DATETIME in <exceptId>
* @param Msg $m Details of the appointment.
* @return mix
*/
function forwardAppointment(
$id = null,
DtTimeInfo $exceptId = null,
CalTZInfo $tz = null,
Msg $m = null
);
/**
* Used by an attendee to forward an appointment invite email to another user who is not already an attendee.
* To forward an appointment item, use ForwardAppointmentRequest instead.
*
* @param string $id Appointment item ID
* @param Msg $m Details of the appointment.
* @return mix
*/
function forwardAppointmentInvite($id = null, Msg $m = null);
/**
* Ajax client can use this request to ask the server for help in generating a proper,
* globally unique UUID.
*
* @return mix
*/
function generateUUID();
/**
* Get activity stream.
*
* @param string $id Item ID. If the id is for a Document, the response will include the activities for the requested Document. if it is for a Folder, the response will include the activities for all the Documents in the folder and subfolders.
* @param int $limit Limit - maximum number of activities to be returned
* @param int $offset Offset - for getting the next page worth of activities.
* @param ActivityFilter $filter Optionally <filter> can be used to filter the response based on the user that performed the activity, operation, or both. the server will cache previously established filter search results, and return the identifier in session attribute. The client is expected to reuse the session identifier in the subsequent filter search to improve the performance.
* @return mix
*/
function getActivityStream(
$id,
$offset = null,
$limit = null,
ActivityFilter $filter = null
);
/**
* Get all devices.
*
* @return mix
*/
function getAllDevices();
/**
* Get appointment.
* Returns the metadata info for each Invite that makes up this appointment.
*
* @param bool $sync Set this to return the modified date (md) on the appointment.
* @param bool $includeContent If true, MIME parts for body content are returned; default false.
* @param bool $includeInvites If set, information for each invite is included.
* @param string $uid iCalendar UID Either id or uid should be specified, but not both.
* @param string $id Appointment ID. Either id or uid should be specified, but not both.
* @return mix
*/
function getAppointment(
$sync = null,
$includeContent = null,
$includeInvites = null,
$uid = null,
$id = null
);
/**
* Get appointment summaries.
*
* @param int $s Range start in milliseconds since the epoch GMT.
* @param int $e Range end in milliseconds since the epoch GMT.
* @param string $l Folder Id. Optional folder to constrain requests to; otherwise, searches all folders but trash and spam.
* @return mix
*/
function getApptSummaries($s, $e, $l = null);
/**
* Get Calendar item summaries.
*
* @param int $s Range start in milliseconds since the epoch GMT.
* @param int $e Range end in milliseconds since the epoch GMT.
* @param string $l Folder Id.
* @return mix
*/
function getCalendarItemSummaries($s, $e, $l = null);
/**
* Get comments.
*
* @param ParentId $parentId Select parent for comments.
* @return mix
*/
function getComments(ParentId $comment);
/**
* Get contacts.
* Contact group members are returned as <m> elements.
* If derefGroupMember is not set, group members are returned in the order they were inserted in the group.
* If derefGroupMember is set, group members are returned ordered by the "key" of member.
* Key is:
* 1. for contact ref (type="C"): the fileAs field of the Contact
* 2. for GAL ref (type="G"): email address of the GAL entry
* 3. for inlined member (type="I"): the value
*
* @param bool $sync If set, return modified date (md) on contacts.
* @param string $l If is present, return only contacts in the specified folder.
* @param string $sortBy Sort by.
* @param bool $derefGroupMember If set, deref contact group members.
* @param bool $returnHiddenAttrs Whether to return contact hidden attrs defined in zimbraContactHiddenAttributes ignored if <a> is present..
* @param int $maxMembers Max members.
* @param array $a Attributes - if present, return only the specified attribute(s).
* @param array $ma If present, return only the specified attribute(s) for derefed members, applicable only when derefGroupMember is set.
* @param array $cn If present, only get the specified contact(s)..
* @return mix
*/
function getContacts(
$sync = null,
$l = null,
$sortBy = null,
$derefGroupMember = null,
$returnHiddenAttrs = null,
$maxMembers = null,
array $a = [],
array $ma = [],
array $cn = []
);
/**
* Get conversation.
* GetConvRequest gets information about the 1 conversation named by id's value.
* It will return exactly 1 conversation element.
* If fetch="1|all" is included,
* the full expanded message structure is inlined for the first (or for all) messages in the conversation.
* If fetch="{item-id}", only the message with the given {item-id} is expanded inline
*
* @param ConversationSpec $c Conversation specification.
* @return mix
*/
function getConv(ConversationSpec $c);
/**
* Get custom metadata.
*
* @param string $id Item ID.
* @param SectionAttr $section Metadata section selector.
* @return mix
*/
function getCustomMetadata($id, SectionAttr $meta = null);
/**
* Returns all data sources defined for the given mailbox.
* For each data source, every attribute value is returned except password.
*
* @return mix
*/
function getDataSources();
/**
* Get the download URL of shared document.
*
* @param ItemSpec $item Folder specification.
* @return mix
*/
function getDocumentShareURL(ItemSpec $item);
/**
* Returns the effective permissions of the specified folder.
*
* @param FolderSpec $folder Folder ID.
* @return mix
*/
function getEffectiveFolderPerms(FolderSpec $folder);
/**
* Get filter rules.
*
* @return mix
*/
function getFilterRules();
/**
* Get folder.
* A {base-folder-id}, a {base-folder-uuid} or a {fully-qualified-path} can optionally be specified in the folder element; if none is present, the descent of the folder hierarchy begins at the mailbox's root folder (id 1).
* If {fully-qualified-path} is present and {base-folder-id} or {base-folder-uuid} is also present, the path is treated as relative to the folder that was specified by id/uuid. {base-folder-id} is ignored if {base-folder-uuid} is present.
*
* @param bool $visible If set we include all visible subfolders of the specified folder.
* @param bool $needGranteeName If set then grantee names are supplied in the d attribute in <grant>.
* @param string $view If "view" is set then only the folders with matching view will be returned.
* @param int $depth If "depth" is set to a non-negative number, we include that many levels of subfolders in the response.
* @param bool $tr If true, one level of mountpoints are traversed and the target folder's counts are applied to the local mountpoint.
* @param GetFolderSpec $folder Folder specification
* @return mix
*/
function getFolder(
$visible = null,
$needGranteeName = null,
$view = null,
$depth = null,
$tr = null,
GetFolderSpec $folder = null
);
/**
* Get Free/Busy information.
* For accounts listed using uid,id or name attributes, f/b search will be done for all calendar folders.
* To view free/busy for a single folder in a particular account, use <usr>.
*
* @param int $s Range start in milliseconds
* @param int $e Range end in milliseconds
* @param string $uid Comma-separated list of Zimbra IDs or emails. Each value can be a Ziimbra ID or an email. DEPRECATED.
* @param string $id Comma separated list of Zimbra IDs
* @param string $name Comma separated list of Emails
* @param string $excludeUid UID of appointment to exclude from free/busy search
* @param array $usr To view free/busy for a single folders in particular accounts, use these.
* @return mix
*/
function getFreeBusy(
$s,
$e,
$uid = null,
$id = null,
$name = null,
$excludeUid = null,
array $usr = []
);
/**
* Retrieve the unparsed (but XML-encoded (")) iCalendar data for an Invite.