This commit is contained in:
Tim Bendt
2025-11-25 00:16:35 -05:00
commit 6b9ef7ca55
6757 changed files with 1003748 additions and 0 deletions

View File

@@ -0,0 +1,203 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

View File

@@ -0,0 +1,7 @@
# Security Policy
To report a security issue, please use [g.co/vulnz](https://g.co/vulnz).
The Google Security Team will respond within 5 working days of your report on g.co/vulnz.
We use g.co/vulnz for our intake, and do coordination and disclosure here using GitHub Security Advisory to privately discuss and fix the issue.

View File

@@ -0,0 +1,36 @@
<?php
// For older (pre-2.7.2) verions of google/apiclient
if (
file_exists(__DIR__ . '/../apiclient/src/Google/Client.php')
&& !class_exists('Google_Client', false)
) {
require_once(__DIR__ . '/../apiclient/src/Google/Client.php');
if (
defined('Google_Client::LIBVER')
&& version_compare(Google_Client::LIBVER, '2.7.2', '<=')
) {
$servicesClassMap = [
'Google\\Client' => 'Google_Client',
'Google\\Service' => 'Google_Service',
'Google\\Service\\Resource' => 'Google_Service_Resource',
'Google\\Model' => 'Google_Model',
'Google\\Collection' => 'Google_Collection',
];
foreach ($servicesClassMap as $alias => $class) {
class_alias($class, $alias);
}
}
}
spl_autoload_register(function ($class) {
if (0 === strpos($class, 'Google_Service_')) {
// Autoload the new class, which will also create an alias for the
// old class by changing underscores to namespaces:
// Google_Service_Speech_Resource_Operations
// => Google\Service\Speech\Resource\Operations
$classExists = class_exists($newClass = str_replace('_', '\\', $class));
if ($classExists) {
return true;
}
}
}, true, true);

View File

@@ -0,0 +1,27 @@
{
"name": "google/apiclient-services",
"type": "library",
"description": "Client library for Google APIs",
"keywords": ["google"],
"homepage": "http://developers.google.com/api-client-library/php",
"license": "Apache-2.0",
"require": {
"php": "^7.4||^8.0"
},
"require-dev": {
"phpunit/phpunit": "^5.7||^8.5.13"
},
"autoload": {
"psr-4": {
"Google\\Service\\": "src"
},
"files": [
"autoload.php"
]
},
"autoload-dev": {
"psr-4": {
"Google\\": "tests/mocks"
}
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,80 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class AutoForwarding extends \Google\Model
{
/**
* @var string
*/
public $disposition;
/**
* @var string
*/
public $emailAddress;
/**
* @var bool
*/
public $enabled;
/**
* @param string
*/
public function setDisposition($disposition)
{
$this->disposition = $disposition;
}
/**
* @return string
*/
public function getDisposition()
{
return $this->disposition;
}
/**
* @param string
*/
public function setEmailAddress($emailAddress)
{
$this->emailAddress = $emailAddress;
}
/**
* @return string
*/
public function getEmailAddress()
{
return $this->emailAddress;
}
/**
* @param bool
*/
public function setEnabled($enabled)
{
$this->enabled = $enabled;
}
/**
* @return bool
*/
public function getEnabled()
{
return $this->enabled;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(AutoForwarding::class, 'Google_Service_Gmail_AutoForwarding');

View File

@@ -0,0 +1,45 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class BatchDeleteMessagesRequest extends \Google\Collection
{
protected $collection_key = 'ids';
/**
* @var string[]
*/
public $ids;
/**
* @param string[]
*/
public function setIds($ids)
{
$this->ids = $ids;
}
/**
* @return string[]
*/
public function getIds()
{
return $this->ids;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(BatchDeleteMessagesRequest::class, 'Google_Service_Gmail_BatchDeleteMessagesRequest');

View File

@@ -0,0 +1,81 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class BatchModifyMessagesRequest extends \Google\Collection
{
protected $collection_key = 'removeLabelIds';
/**
* @var string[]
*/
public $addLabelIds;
/**
* @var string[]
*/
public $ids;
/**
* @var string[]
*/
public $removeLabelIds;
/**
* @param string[]
*/
public function setAddLabelIds($addLabelIds)
{
$this->addLabelIds = $addLabelIds;
}
/**
* @return string[]
*/
public function getAddLabelIds()
{
return $this->addLabelIds;
}
/**
* @param string[]
*/
public function setIds($ids)
{
$this->ids = $ids;
}
/**
* @return string[]
*/
public function getIds()
{
return $this->ids;
}
/**
* @param string[]
*/
public function setRemoveLabelIds($removeLabelIds)
{
$this->removeLabelIds = $removeLabelIds;
}
/**
* @return string[]
*/
public function getRemoveLabelIds()
{
return $this->removeLabelIds;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(BatchModifyMessagesRequest::class, 'Google_Service_Gmail_BatchModifyMessagesRequest');

View File

@@ -0,0 +1,62 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class CseIdentity extends \Google\Model
{
/**
* @var string
*/
public $emailAddress;
/**
* @var string
*/
public $primaryKeyPairId;
/**
* @param string
*/
public function setEmailAddress($emailAddress)
{
$this->emailAddress = $emailAddress;
}
/**
* @return string
*/
public function getEmailAddress()
{
return $this->emailAddress;
}
/**
* @param string
*/
public function setPrimaryKeyPairId($primaryKeyPairId)
{
$this->primaryKeyPairId = $primaryKeyPairId;
}
/**
* @return string
*/
public function getPrimaryKeyPairId()
{
return $this->primaryKeyPairId;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(CseIdentity::class, 'Google_Service_Gmail_CseIdentity');

View File

@@ -0,0 +1,151 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class CseKeyPair extends \Google\Collection
{
protected $collection_key = 'subjectEmailAddresses';
/**
* @var string
*/
public $disableTime;
/**
* @var string
*/
public $enablementState;
/**
* @var string
*/
public $keyPairId;
/**
* @var string
*/
public $pem;
/**
* @var string
*/
public $pkcs7;
protected $privateKeyMetadataType = CsePrivateKeyMetadata::class;
protected $privateKeyMetadataDataType = 'array';
/**
* @var string[]
*/
public $subjectEmailAddresses;
/**
* @param string
*/
public function setDisableTime($disableTime)
{
$this->disableTime = $disableTime;
}
/**
* @return string
*/
public function getDisableTime()
{
return $this->disableTime;
}
/**
* @param string
*/
public function setEnablementState($enablementState)
{
$this->enablementState = $enablementState;
}
/**
* @return string
*/
public function getEnablementState()
{
return $this->enablementState;
}
/**
* @param string
*/
public function setKeyPairId($keyPairId)
{
$this->keyPairId = $keyPairId;
}
/**
* @return string
*/
public function getKeyPairId()
{
return $this->keyPairId;
}
/**
* @param string
*/
public function setPem($pem)
{
$this->pem = $pem;
}
/**
* @return string
*/
public function getPem()
{
return $this->pem;
}
/**
* @param string
*/
public function setPkcs7($pkcs7)
{
$this->pkcs7 = $pkcs7;
}
/**
* @return string
*/
public function getPkcs7()
{
return $this->pkcs7;
}
/**
* @param CsePrivateKeyMetadata[]
*/
public function setPrivateKeyMetadata($privateKeyMetadata)
{
$this->privateKeyMetadata = $privateKeyMetadata;
}
/**
* @return CsePrivateKeyMetadata[]
*/
public function getPrivateKeyMetadata()
{
return $this->privateKeyMetadata;
}
/**
* @param string[]
*/
public function setSubjectEmailAddresses($subjectEmailAddresses)
{
$this->subjectEmailAddresses = $subjectEmailAddresses;
}
/**
* @return string[]
*/
public function getSubjectEmailAddresses()
{
return $this->subjectEmailAddresses;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(CseKeyPair::class, 'Google_Service_Gmail_CseKeyPair');

View File

@@ -0,0 +1,60 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class CsePrivateKeyMetadata extends \Google\Model
{
protected $kaclsKeyMetadataType = KaclsKeyMetadata::class;
protected $kaclsKeyMetadataDataType = '';
/**
* @var string
*/
public $privateKeyMetadataId;
/**
* @param KaclsKeyMetadata
*/
public function setKaclsKeyMetadata(KaclsKeyMetadata $kaclsKeyMetadata)
{
$this->kaclsKeyMetadata = $kaclsKeyMetadata;
}
/**
* @return KaclsKeyMetadata
*/
public function getKaclsKeyMetadata()
{
return $this->kaclsKeyMetadata;
}
/**
* @param string
*/
public function setPrivateKeyMetadataId($privateKeyMetadataId)
{
$this->privateKeyMetadataId = $privateKeyMetadataId;
}
/**
* @return string
*/
public function getPrivateKeyMetadataId()
{
return $this->privateKeyMetadataId;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(CsePrivateKeyMetadata::class, 'Google_Service_Gmail_CsePrivateKeyMetadata');

View File

@@ -0,0 +1,62 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class Delegate extends \Google\Model
{
/**
* @var string
*/
public $delegateEmail;
/**
* @var string
*/
public $verificationStatus;
/**
* @param string
*/
public function setDelegateEmail($delegateEmail)
{
$this->delegateEmail = $delegateEmail;
}
/**
* @return string
*/
public function getDelegateEmail()
{
return $this->delegateEmail;
}
/**
* @param string
*/
public function setVerificationStatus($verificationStatus)
{
$this->verificationStatus = $verificationStatus;
}
/**
* @return string
*/
public function getVerificationStatus()
{
return $this->verificationStatus;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Delegate::class, 'Google_Service_Gmail_Delegate');

View File

@@ -0,0 +1,25 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class DisableCseKeyPairRequest extends \Google\Model
{
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(DisableCseKeyPairRequest::class, 'Google_Service_Gmail_DisableCseKeyPairRequest');

View File

@@ -0,0 +1,60 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class Draft extends \Google\Model
{
/**
* @var string
*/
public $id;
protected $messageType = Message::class;
protected $messageDataType = '';
/**
* @param string
*/
public function setId($id)
{
$this->id = $id;
}
/**
* @return string
*/
public function getId()
{
return $this->id;
}
/**
* @param Message
*/
public function setMessage(Message $message)
{
$this->message = $message;
}
/**
* @return Message
*/
public function getMessage()
{
return $this->message;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Draft::class, 'Google_Service_Gmail_Draft');

View File

@@ -0,0 +1,25 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class EnableCseKeyPairRequest extends \Google\Model
{
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(EnableCseKeyPairRequest::class, 'Google_Service_Gmail_EnableCseKeyPairRequest');

View File

@@ -0,0 +1,76 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class Filter extends \Google\Model
{
protected $actionType = FilterAction::class;
protected $actionDataType = '';
protected $criteriaType = FilterCriteria::class;
protected $criteriaDataType = '';
/**
* @var string
*/
public $id;
/**
* @param FilterAction
*/
public function setAction(FilterAction $action)
{
$this->action = $action;
}
/**
* @return FilterAction
*/
public function getAction()
{
return $this->action;
}
/**
* @param FilterCriteria
*/
public function setCriteria(FilterCriteria $criteria)
{
$this->criteria = $criteria;
}
/**
* @return FilterCriteria
*/
public function getCriteria()
{
return $this->criteria;
}
/**
* @param string
*/
public function setId($id)
{
$this->id = $id;
}
/**
* @return string
*/
public function getId()
{
return $this->id;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Filter::class, 'Google_Service_Gmail_Filter');

View File

@@ -0,0 +1,81 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class FilterAction extends \Google\Collection
{
protected $collection_key = 'removeLabelIds';
/**
* @var string[]
*/
public $addLabelIds;
/**
* @var string
*/
public $forward;
/**
* @var string[]
*/
public $removeLabelIds;
/**
* @param string[]
*/
public function setAddLabelIds($addLabelIds)
{
$this->addLabelIds = $addLabelIds;
}
/**
* @return string[]
*/
public function getAddLabelIds()
{
return $this->addLabelIds;
}
/**
* @param string
*/
public function setForward($forward)
{
$this->forward = $forward;
}
/**
* @return string
*/
public function getForward()
{
return $this->forward;
}
/**
* @param string[]
*/
public function setRemoveLabelIds($removeLabelIds)
{
$this->removeLabelIds = $removeLabelIds;
}
/**
* @return string[]
*/
public function getRemoveLabelIds()
{
return $this->removeLabelIds;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(FilterAction::class, 'Google_Service_Gmail_FilterAction');

View File

@@ -0,0 +1,188 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class FilterCriteria extends \Google\Model
{
/**
* @var bool
*/
public $excludeChats;
/**
* @var string
*/
public $from;
/**
* @var bool
*/
public $hasAttachment;
/**
* @var string
*/
public $negatedQuery;
/**
* @var string
*/
public $query;
/**
* @var int
*/
public $size;
/**
* @var string
*/
public $sizeComparison;
/**
* @var string
*/
public $subject;
/**
* @var string
*/
public $to;
/**
* @param bool
*/
public function setExcludeChats($excludeChats)
{
$this->excludeChats = $excludeChats;
}
/**
* @return bool
*/
public function getExcludeChats()
{
return $this->excludeChats;
}
/**
* @param string
*/
public function setFrom($from)
{
$this->from = $from;
}
/**
* @return string
*/
public function getFrom()
{
return $this->from;
}
/**
* @param bool
*/
public function setHasAttachment($hasAttachment)
{
$this->hasAttachment = $hasAttachment;
}
/**
* @return bool
*/
public function getHasAttachment()
{
return $this->hasAttachment;
}
/**
* @param string
*/
public function setNegatedQuery($negatedQuery)
{
$this->negatedQuery = $negatedQuery;
}
/**
* @return string
*/
public function getNegatedQuery()
{
return $this->negatedQuery;
}
/**
* @param string
*/
public function setQuery($query)
{
$this->query = $query;
}
/**
* @return string
*/
public function getQuery()
{
return $this->query;
}
/**
* @param int
*/
public function setSize($size)
{
$this->size = $size;
}
/**
* @return int
*/
public function getSize()
{
return $this->size;
}
/**
* @param string
*/
public function setSizeComparison($sizeComparison)
{
$this->sizeComparison = $sizeComparison;
}
/**
* @return string
*/
public function getSizeComparison()
{
return $this->sizeComparison;
}
/**
* @param string
*/
public function setSubject($subject)
{
$this->subject = $subject;
}
/**
* @return string
*/
public function getSubject()
{
return $this->subject;
}
/**
* @param string
*/
public function setTo($to)
{
$this->to = $to;
}
/**
* @return string
*/
public function getTo()
{
return $this->to;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(FilterCriteria::class, 'Google_Service_Gmail_FilterCriteria');

View File

@@ -0,0 +1,62 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ForwardingAddress extends \Google\Model
{
/**
* @var string
*/
public $forwardingEmail;
/**
* @var string
*/
public $verificationStatus;
/**
* @param string
*/
public function setForwardingEmail($forwardingEmail)
{
$this->forwardingEmail = $forwardingEmail;
}
/**
* @return string
*/
public function getForwardingEmail()
{
return $this->forwardingEmail;
}
/**
* @param string
*/
public function setVerificationStatus($verificationStatus)
{
$this->verificationStatus = $verificationStatus;
}
/**
* @return string
*/
public function getVerificationStatus()
{
return $this->verificationStatus;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ForwardingAddress::class, 'Google_Service_Gmail_ForwardingAddress');

View File

@@ -0,0 +1,125 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class History extends \Google\Collection
{
protected $collection_key = 'messagesDeleted';
/**
* @var string
*/
public $id;
protected $labelsAddedType = HistoryLabelAdded::class;
protected $labelsAddedDataType = 'array';
protected $labelsRemovedType = HistoryLabelRemoved::class;
protected $labelsRemovedDataType = 'array';
protected $messagesType = Message::class;
protected $messagesDataType = 'array';
protected $messagesAddedType = HistoryMessageAdded::class;
protected $messagesAddedDataType = 'array';
protected $messagesDeletedType = HistoryMessageDeleted::class;
protected $messagesDeletedDataType = 'array';
/**
* @param string
*/
public function setId($id)
{
$this->id = $id;
}
/**
* @return string
*/
public function getId()
{
return $this->id;
}
/**
* @param HistoryLabelAdded[]
*/
public function setLabelsAdded($labelsAdded)
{
$this->labelsAdded = $labelsAdded;
}
/**
* @return HistoryLabelAdded[]
*/
public function getLabelsAdded()
{
return $this->labelsAdded;
}
/**
* @param HistoryLabelRemoved[]
*/
public function setLabelsRemoved($labelsRemoved)
{
$this->labelsRemoved = $labelsRemoved;
}
/**
* @return HistoryLabelRemoved[]
*/
public function getLabelsRemoved()
{
return $this->labelsRemoved;
}
/**
* @param Message[]
*/
public function setMessages($messages)
{
$this->messages = $messages;
}
/**
* @return Message[]
*/
public function getMessages()
{
return $this->messages;
}
/**
* @param HistoryMessageAdded[]
*/
public function setMessagesAdded($messagesAdded)
{
$this->messagesAdded = $messagesAdded;
}
/**
* @return HistoryMessageAdded[]
*/
public function getMessagesAdded()
{
return $this->messagesAdded;
}
/**
* @param HistoryMessageDeleted[]
*/
public function setMessagesDeleted($messagesDeleted)
{
$this->messagesDeleted = $messagesDeleted;
}
/**
* @return HistoryMessageDeleted[]
*/
public function getMessagesDeleted()
{
return $this->messagesDeleted;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(History::class, 'Google_Service_Gmail_History');

View File

@@ -0,0 +1,61 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class HistoryLabelAdded extends \Google\Collection
{
protected $collection_key = 'labelIds';
/**
* @var string[]
*/
public $labelIds;
protected $messageType = Message::class;
protected $messageDataType = '';
/**
* @param string[]
*/
public function setLabelIds($labelIds)
{
$this->labelIds = $labelIds;
}
/**
* @return string[]
*/
public function getLabelIds()
{
return $this->labelIds;
}
/**
* @param Message
*/
public function setMessage(Message $message)
{
$this->message = $message;
}
/**
* @return Message
*/
public function getMessage()
{
return $this->message;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(HistoryLabelAdded::class, 'Google_Service_Gmail_HistoryLabelAdded');

View File

@@ -0,0 +1,61 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class HistoryLabelRemoved extends \Google\Collection
{
protected $collection_key = 'labelIds';
/**
* @var string[]
*/
public $labelIds;
protected $messageType = Message::class;
protected $messageDataType = '';
/**
* @param string[]
*/
public function setLabelIds($labelIds)
{
$this->labelIds = $labelIds;
}
/**
* @return string[]
*/
public function getLabelIds()
{
return $this->labelIds;
}
/**
* @param Message
*/
public function setMessage(Message $message)
{
$this->message = $message;
}
/**
* @return Message
*/
public function getMessage()
{
return $this->message;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(HistoryLabelRemoved::class, 'Google_Service_Gmail_HistoryLabelRemoved');

View File

@@ -0,0 +1,42 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class HistoryMessageAdded extends \Google\Model
{
protected $messageType = Message::class;
protected $messageDataType = '';
/**
* @param Message
*/
public function setMessage(Message $message)
{
$this->message = $message;
}
/**
* @return Message
*/
public function getMessage()
{
return $this->message;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(HistoryMessageAdded::class, 'Google_Service_Gmail_HistoryMessageAdded');

View File

@@ -0,0 +1,42 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class HistoryMessageDeleted extends \Google\Model
{
protected $messageType = Message::class;
protected $messageDataType = '';
/**
* @param Message
*/
public function setMessage(Message $message)
{
$this->message = $message;
}
/**
* @return Message
*/
public function getMessage()
{
return $this->message;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(HistoryMessageDeleted::class, 'Google_Service_Gmail_HistoryMessageDeleted');

View File

@@ -0,0 +1,98 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ImapSettings extends \Google\Model
{
/**
* @var bool
*/
public $autoExpunge;
/**
* @var bool
*/
public $enabled;
/**
* @var string
*/
public $expungeBehavior;
/**
* @var int
*/
public $maxFolderSize;
/**
* @param bool
*/
public function setAutoExpunge($autoExpunge)
{
$this->autoExpunge = $autoExpunge;
}
/**
* @return bool
*/
public function getAutoExpunge()
{
return $this->autoExpunge;
}
/**
* @param bool
*/
public function setEnabled($enabled)
{
$this->enabled = $enabled;
}
/**
* @return bool
*/
public function getEnabled()
{
return $this->enabled;
}
/**
* @param string
*/
public function setExpungeBehavior($expungeBehavior)
{
$this->expungeBehavior = $expungeBehavior;
}
/**
* @return string
*/
public function getExpungeBehavior()
{
return $this->expungeBehavior;
}
/**
* @param int
*/
public function setMaxFolderSize($maxFolderSize)
{
$this->maxFolderSize = $maxFolderSize;
}
/**
* @return int
*/
public function getMaxFolderSize()
{
return $this->maxFolderSize;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ImapSettings::class, 'Google_Service_Gmail_ImapSettings');

View File

@@ -0,0 +1,62 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class KaclsKeyMetadata extends \Google\Model
{
/**
* @var string
*/
public $kaclsData;
/**
* @var string
*/
public $kaclsUri;
/**
* @param string
*/
public function setKaclsData($kaclsData)
{
$this->kaclsData = $kaclsData;
}
/**
* @return string
*/
public function getKaclsData()
{
return $this->kaclsData;
}
/**
* @param string
*/
public function setKaclsUri($kaclsUri)
{
$this->kaclsUri = $kaclsUri;
}
/**
* @return string
*/
public function getKaclsUri()
{
return $this->kaclsUri;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(KaclsKeyMetadata::class, 'Google_Service_Gmail_KaclsKeyMetadata');

View File

@@ -0,0 +1,204 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class Label extends \Google\Model
{
protected $colorType = LabelColor::class;
protected $colorDataType = '';
/**
* @var string
*/
public $id;
/**
* @var string
*/
public $labelListVisibility;
/**
* @var string
*/
public $messageListVisibility;
/**
* @var int
*/
public $messagesTotal;
/**
* @var int
*/
public $messagesUnread;
/**
* @var string
*/
public $name;
/**
* @var int
*/
public $threadsTotal;
/**
* @var int
*/
public $threadsUnread;
/**
* @var string
*/
public $type;
/**
* @param LabelColor
*/
public function setColor(LabelColor $color)
{
$this->color = $color;
}
/**
* @return LabelColor
*/
public function getColor()
{
return $this->color;
}
/**
* @param string
*/
public function setId($id)
{
$this->id = $id;
}
/**
* @return string
*/
public function getId()
{
return $this->id;
}
/**
* @param string
*/
public function setLabelListVisibility($labelListVisibility)
{
$this->labelListVisibility = $labelListVisibility;
}
/**
* @return string
*/
public function getLabelListVisibility()
{
return $this->labelListVisibility;
}
/**
* @param string
*/
public function setMessageListVisibility($messageListVisibility)
{
$this->messageListVisibility = $messageListVisibility;
}
/**
* @return string
*/
public function getMessageListVisibility()
{
return $this->messageListVisibility;
}
/**
* @param int
*/
public function setMessagesTotal($messagesTotal)
{
$this->messagesTotal = $messagesTotal;
}
/**
* @return int
*/
public function getMessagesTotal()
{
return $this->messagesTotal;
}
/**
* @param int
*/
public function setMessagesUnread($messagesUnread)
{
$this->messagesUnread = $messagesUnread;
}
/**
* @return int
*/
public function getMessagesUnread()
{
return $this->messagesUnread;
}
/**
* @param string
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* @param int
*/
public function setThreadsTotal($threadsTotal)
{
$this->threadsTotal = $threadsTotal;
}
/**
* @return int
*/
public function getThreadsTotal()
{
return $this->threadsTotal;
}
/**
* @param int
*/
public function setThreadsUnread($threadsUnread)
{
$this->threadsUnread = $threadsUnread;
}
/**
* @return int
*/
public function getThreadsUnread()
{
return $this->threadsUnread;
}
/**
* @param string
*/
public function setType($type)
{
$this->type = $type;
}
/**
* @return string
*/
public function getType()
{
return $this->type;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Label::class, 'Google_Service_Gmail_Label');

View File

@@ -0,0 +1,62 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class LabelColor extends \Google\Model
{
/**
* @var string
*/
public $backgroundColor;
/**
* @var string
*/
public $textColor;
/**
* @param string
*/
public function setBackgroundColor($backgroundColor)
{
$this->backgroundColor = $backgroundColor;
}
/**
* @return string
*/
public function getBackgroundColor()
{
return $this->backgroundColor;
}
/**
* @param string
*/
public function setTextColor($textColor)
{
$this->textColor = $textColor;
}
/**
* @return string
*/
public function getTextColor()
{
return $this->textColor;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(LabelColor::class, 'Google_Service_Gmail_LabelColor');

View File

@@ -0,0 +1,44 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class LanguageSettings extends \Google\Model
{
/**
* @var string
*/
public $displayLanguage;
/**
* @param string
*/
public function setDisplayLanguage($displayLanguage)
{
$this->displayLanguage = $displayLanguage;
}
/**
* @return string
*/
public function getDisplayLanguage()
{
return $this->displayLanguage;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(LanguageSettings::class, 'Google_Service_Gmail_LanguageSettings');

View File

@@ -0,0 +1,61 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ListCseIdentitiesResponse extends \Google\Collection
{
protected $collection_key = 'cseIdentities';
protected $cseIdentitiesType = CseIdentity::class;
protected $cseIdentitiesDataType = 'array';
/**
* @var string
*/
public $nextPageToken;
/**
* @param CseIdentity[]
*/
public function setCseIdentities($cseIdentities)
{
$this->cseIdentities = $cseIdentities;
}
/**
* @return CseIdentity[]
*/
public function getCseIdentities()
{
return $this->cseIdentities;
}
/**
* @param string
*/
public function setNextPageToken($nextPageToken)
{
$this->nextPageToken = $nextPageToken;
}
/**
* @return string
*/
public function getNextPageToken()
{
return $this->nextPageToken;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListCseIdentitiesResponse::class, 'Google_Service_Gmail_ListCseIdentitiesResponse');

View File

@@ -0,0 +1,61 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ListCseKeyPairsResponse extends \Google\Collection
{
protected $collection_key = 'cseKeyPairs';
protected $cseKeyPairsType = CseKeyPair::class;
protected $cseKeyPairsDataType = 'array';
/**
* @var string
*/
public $nextPageToken;
/**
* @param CseKeyPair[]
*/
public function setCseKeyPairs($cseKeyPairs)
{
$this->cseKeyPairs = $cseKeyPairs;
}
/**
* @return CseKeyPair[]
*/
public function getCseKeyPairs()
{
return $this->cseKeyPairs;
}
/**
* @param string
*/
public function setNextPageToken($nextPageToken)
{
$this->nextPageToken = $nextPageToken;
}
/**
* @return string
*/
public function getNextPageToken()
{
return $this->nextPageToken;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListCseKeyPairsResponse::class, 'Google_Service_Gmail_ListCseKeyPairsResponse');

View File

@@ -0,0 +1,43 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ListDelegatesResponse extends \Google\Collection
{
protected $collection_key = 'delegates';
protected $delegatesType = Delegate::class;
protected $delegatesDataType = 'array';
/**
* @param Delegate[]
*/
public function setDelegates($delegates)
{
$this->delegates = $delegates;
}
/**
* @return Delegate[]
*/
public function getDelegates()
{
return $this->delegates;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListDelegatesResponse::class, 'Google_Service_Gmail_ListDelegatesResponse');

View File

@@ -0,0 +1,79 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ListDraftsResponse extends \Google\Collection
{
protected $collection_key = 'drafts';
protected $draftsType = Draft::class;
protected $draftsDataType = 'array';
/**
* @var string
*/
public $nextPageToken;
/**
* @var string
*/
public $resultSizeEstimate;
/**
* @param Draft[]
*/
public function setDrafts($drafts)
{
$this->drafts = $drafts;
}
/**
* @return Draft[]
*/
public function getDrafts()
{
return $this->drafts;
}
/**
* @param string
*/
public function setNextPageToken($nextPageToken)
{
$this->nextPageToken = $nextPageToken;
}
/**
* @return string
*/
public function getNextPageToken()
{
return $this->nextPageToken;
}
/**
* @param string
*/
public function setResultSizeEstimate($resultSizeEstimate)
{
$this->resultSizeEstimate = $resultSizeEstimate;
}
/**
* @return string
*/
public function getResultSizeEstimate()
{
return $this->resultSizeEstimate;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListDraftsResponse::class, 'Google_Service_Gmail_ListDraftsResponse');

View File

@@ -0,0 +1,43 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ListFiltersResponse extends \Google\Collection
{
protected $collection_key = 'filter';
protected $filterType = Filter::class;
protected $filterDataType = 'array';
/**
* @param Filter[]
*/
public function setFilter($filter)
{
$this->filter = $filter;
}
/**
* @return Filter[]
*/
public function getFilter()
{
return $this->filter;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListFiltersResponse::class, 'Google_Service_Gmail_ListFiltersResponse');

View File

@@ -0,0 +1,43 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ListForwardingAddressesResponse extends \Google\Collection
{
protected $collection_key = 'forwardingAddresses';
protected $forwardingAddressesType = ForwardingAddress::class;
protected $forwardingAddressesDataType = 'array';
/**
* @param ForwardingAddress[]
*/
public function setForwardingAddresses($forwardingAddresses)
{
$this->forwardingAddresses = $forwardingAddresses;
}
/**
* @return ForwardingAddress[]
*/
public function getForwardingAddresses()
{
return $this->forwardingAddresses;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListForwardingAddressesResponse::class, 'Google_Service_Gmail_ListForwardingAddressesResponse');

View File

@@ -0,0 +1,79 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ListHistoryResponse extends \Google\Collection
{
protected $collection_key = 'history';
protected $historyType = History::class;
protected $historyDataType = 'array';
/**
* @var string
*/
public $historyId;
/**
* @var string
*/
public $nextPageToken;
/**
* @param History[]
*/
public function setHistory($history)
{
$this->history = $history;
}
/**
* @return History[]
*/
public function getHistory()
{
return $this->history;
}
/**
* @param string
*/
public function setHistoryId($historyId)
{
$this->historyId = $historyId;
}
/**
* @return string
*/
public function getHistoryId()
{
return $this->historyId;
}
/**
* @param string
*/
public function setNextPageToken($nextPageToken)
{
$this->nextPageToken = $nextPageToken;
}
/**
* @return string
*/
public function getNextPageToken()
{
return $this->nextPageToken;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListHistoryResponse::class, 'Google_Service_Gmail_ListHistoryResponse');

View File

@@ -0,0 +1,43 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ListLabelsResponse extends \Google\Collection
{
protected $collection_key = 'labels';
protected $labelsType = Label::class;
protected $labelsDataType = 'array';
/**
* @param Label[]
*/
public function setLabels($labels)
{
$this->labels = $labels;
}
/**
* @return Label[]
*/
public function getLabels()
{
return $this->labels;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListLabelsResponse::class, 'Google_Service_Gmail_ListLabelsResponse');

View File

@@ -0,0 +1,79 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ListMessagesResponse extends \Google\Collection
{
protected $collection_key = 'messages';
protected $messagesType = Message::class;
protected $messagesDataType = 'array';
/**
* @var string
*/
public $nextPageToken;
/**
* @var string
*/
public $resultSizeEstimate;
/**
* @param Message[]
*/
public function setMessages($messages)
{
$this->messages = $messages;
}
/**
* @return Message[]
*/
public function getMessages()
{
return $this->messages;
}
/**
* @param string
*/
public function setNextPageToken($nextPageToken)
{
$this->nextPageToken = $nextPageToken;
}
/**
* @return string
*/
public function getNextPageToken()
{
return $this->nextPageToken;
}
/**
* @param string
*/
public function setResultSizeEstimate($resultSizeEstimate)
{
$this->resultSizeEstimate = $resultSizeEstimate;
}
/**
* @return string
*/
public function getResultSizeEstimate()
{
return $this->resultSizeEstimate;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListMessagesResponse::class, 'Google_Service_Gmail_ListMessagesResponse');

View File

@@ -0,0 +1,43 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ListSendAsResponse extends \Google\Collection
{
protected $collection_key = 'sendAs';
protected $sendAsType = SendAs::class;
protected $sendAsDataType = 'array';
/**
* @param SendAs[]
*/
public function setSendAs($sendAs)
{
$this->sendAs = $sendAs;
}
/**
* @return SendAs[]
*/
public function getSendAs()
{
return $this->sendAs;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListSendAsResponse::class, 'Google_Service_Gmail_ListSendAsResponse');

View File

@@ -0,0 +1,43 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ListSmimeInfoResponse extends \Google\Collection
{
protected $collection_key = 'smimeInfo';
protected $smimeInfoType = SmimeInfo::class;
protected $smimeInfoDataType = 'array';
/**
* @param SmimeInfo[]
*/
public function setSmimeInfo($smimeInfo)
{
$this->smimeInfo = $smimeInfo;
}
/**
* @return SmimeInfo[]
*/
public function getSmimeInfo()
{
return $this->smimeInfo;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListSmimeInfoResponse::class, 'Google_Service_Gmail_ListSmimeInfoResponse');

View File

@@ -0,0 +1,79 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ListThreadsResponse extends \Google\Collection
{
protected $collection_key = 'threads';
/**
* @var string
*/
public $nextPageToken;
/**
* @var string
*/
public $resultSizeEstimate;
protected $threadsType = Thread::class;
protected $threadsDataType = 'array';
/**
* @param string
*/
public function setNextPageToken($nextPageToken)
{
$this->nextPageToken = $nextPageToken;
}
/**
* @return string
*/
public function getNextPageToken()
{
return $this->nextPageToken;
}
/**
* @param string
*/
public function setResultSizeEstimate($resultSizeEstimate)
{
$this->resultSizeEstimate = $resultSizeEstimate;
}
/**
* @return string
*/
public function getResultSizeEstimate()
{
return $this->resultSizeEstimate;
}
/**
* @param Thread[]
*/
public function setThreads($threads)
{
$this->threads = $threads;
}
/**
* @return Thread[]
*/
public function getThreads()
{
return $this->threads;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListThreadsResponse::class, 'Google_Service_Gmail_ListThreadsResponse');

View File

@@ -0,0 +1,187 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class Message extends \Google\Collection
{
protected $collection_key = 'labelIds';
/**
* @var string
*/
public $historyId;
/**
* @var string
*/
public $id;
/**
* @var string
*/
public $internalDate;
/**
* @var string[]
*/
public $labelIds;
protected $payloadType = MessagePart::class;
protected $payloadDataType = '';
/**
* @var string
*/
public $raw;
/**
* @var int
*/
public $sizeEstimate;
/**
* @var string
*/
public $snippet;
/**
* @var string
*/
public $threadId;
/**
* @param string
*/
public function setHistoryId($historyId)
{
$this->historyId = $historyId;
}
/**
* @return string
*/
public function getHistoryId()
{
return $this->historyId;
}
/**
* @param string
*/
public function setId($id)
{
$this->id = $id;
}
/**
* @return string
*/
public function getId()
{
return $this->id;
}
/**
* @param string
*/
public function setInternalDate($internalDate)
{
$this->internalDate = $internalDate;
}
/**
* @return string
*/
public function getInternalDate()
{
return $this->internalDate;
}
/**
* @param string[]
*/
public function setLabelIds($labelIds)
{
$this->labelIds = $labelIds;
}
/**
* @return string[]
*/
public function getLabelIds()
{
return $this->labelIds;
}
/**
* @param MessagePart
*/
public function setPayload(MessagePart $payload)
{
$this->payload = $payload;
}
/**
* @return MessagePart
*/
public function getPayload()
{
return $this->payload;
}
/**
* @param string
*/
public function setRaw($raw)
{
$this->raw = $raw;
}
/**
* @return string
*/
public function getRaw()
{
return $this->raw;
}
/**
* @param int
*/
public function setSizeEstimate($sizeEstimate)
{
$this->sizeEstimate = $sizeEstimate;
}
/**
* @return int
*/
public function getSizeEstimate()
{
return $this->sizeEstimate;
}
/**
* @param string
*/
public function setSnippet($snippet)
{
$this->snippet = $snippet;
}
/**
* @return string
*/
public function getSnippet()
{
return $this->snippet;
}
/**
* @param string
*/
public function setThreadId($threadId)
{
$this->threadId = $threadId;
}
/**
* @return string
*/
public function getThreadId()
{
return $this->threadId;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Message::class, 'Google_Service_Gmail_Message');

View File

@@ -0,0 +1,129 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class MessagePart extends \Google\Collection
{
protected $collection_key = 'parts';
protected $bodyType = MessagePartBody::class;
protected $bodyDataType = '';
/**
* @var string
*/
public $filename;
protected $headersType = MessagePartHeader::class;
protected $headersDataType = 'array';
/**
* @var string
*/
public $mimeType;
/**
* @var string
*/
public $partId;
protected $partsType = MessagePart::class;
protected $partsDataType = 'array';
/**
* @param MessagePartBody
*/
public function setBody(MessagePartBody $body)
{
$this->body = $body;
}
/**
* @return MessagePartBody
*/
public function getBody()
{
return $this->body;
}
/**
* @param string
*/
public function setFilename($filename)
{
$this->filename = $filename;
}
/**
* @return string
*/
public function getFilename()
{
return $this->filename;
}
/**
* @param MessagePartHeader[]
*/
public function setHeaders($headers)
{
$this->headers = $headers;
}
/**
* @return MessagePartHeader[]
*/
public function getHeaders()
{
return $this->headers;
}
/**
* @param string
*/
public function setMimeType($mimeType)
{
$this->mimeType = $mimeType;
}
/**
* @return string
*/
public function getMimeType()
{
return $this->mimeType;
}
/**
* @param string
*/
public function setPartId($partId)
{
$this->partId = $partId;
}
/**
* @return string
*/
public function getPartId()
{
return $this->partId;
}
/**
* @param MessagePart[]
*/
public function setParts($parts)
{
$this->parts = $parts;
}
/**
* @return MessagePart[]
*/
public function getParts()
{
return $this->parts;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(MessagePart::class, 'Google_Service_Gmail_MessagePart');

View File

@@ -0,0 +1,80 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class MessagePartBody extends \Google\Model
{
/**
* @var string
*/
public $attachmentId;
/**
* @var string
*/
public $data;
/**
* @var int
*/
public $size;
/**
* @param string
*/
public function setAttachmentId($attachmentId)
{
$this->attachmentId = $attachmentId;
}
/**
* @return string
*/
public function getAttachmentId()
{
return $this->attachmentId;
}
/**
* @param string
*/
public function setData($data)
{
$this->data = $data;
}
/**
* @return string
*/
public function getData()
{
return $this->data;
}
/**
* @param int
*/
public function setSize($size)
{
$this->size = $size;
}
/**
* @return int
*/
public function getSize()
{
return $this->size;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(MessagePartBody::class, 'Google_Service_Gmail_MessagePartBody');

View File

@@ -0,0 +1,62 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class MessagePartHeader extends \Google\Model
{
/**
* @var string
*/
public $name;
/**
* @var string
*/
public $value;
/**
* @param string
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* @param string
*/
public function setValue($value)
{
$this->value = $value;
}
/**
* @return string
*/
public function getValue()
{
return $this->value;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(MessagePartHeader::class, 'Google_Service_Gmail_MessagePartHeader');

View File

@@ -0,0 +1,63 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ModifyMessageRequest extends \Google\Collection
{
protected $collection_key = 'removeLabelIds';
/**
* @var string[]
*/
public $addLabelIds;
/**
* @var string[]
*/
public $removeLabelIds;
/**
* @param string[]
*/
public function setAddLabelIds($addLabelIds)
{
$this->addLabelIds = $addLabelIds;
}
/**
* @return string[]
*/
public function getAddLabelIds()
{
return $this->addLabelIds;
}
/**
* @param string[]
*/
public function setRemoveLabelIds($removeLabelIds)
{
$this->removeLabelIds = $removeLabelIds;
}
/**
* @return string[]
*/
public function getRemoveLabelIds()
{
return $this->removeLabelIds;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ModifyMessageRequest::class, 'Google_Service_Gmail_ModifyMessageRequest');

View File

@@ -0,0 +1,63 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ModifyThreadRequest extends \Google\Collection
{
protected $collection_key = 'removeLabelIds';
/**
* @var string[]
*/
public $addLabelIds;
/**
* @var string[]
*/
public $removeLabelIds;
/**
* @param string[]
*/
public function setAddLabelIds($addLabelIds)
{
$this->addLabelIds = $addLabelIds;
}
/**
* @return string[]
*/
public function getAddLabelIds()
{
return $this->addLabelIds;
}
/**
* @param string[]
*/
public function setRemoveLabelIds($removeLabelIds)
{
$this->removeLabelIds = $removeLabelIds;
}
/**
* @return string[]
*/
public function getRemoveLabelIds()
{
return $this->removeLabelIds;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ModifyThreadRequest::class, 'Google_Service_Gmail_ModifyThreadRequest');

View File

@@ -0,0 +1,25 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class ObliterateCseKeyPairRequest extends \Google\Model
{
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ObliterateCseKeyPairRequest::class, 'Google_Service_Gmail_ObliterateCseKeyPairRequest');

View File

@@ -0,0 +1,62 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class PopSettings extends \Google\Model
{
/**
* @var string
*/
public $accessWindow;
/**
* @var string
*/
public $disposition;
/**
* @param string
*/
public function setAccessWindow($accessWindow)
{
$this->accessWindow = $accessWindow;
}
/**
* @return string
*/
public function getAccessWindow()
{
return $this->accessWindow;
}
/**
* @param string
*/
public function setDisposition($disposition)
{
$this->disposition = $disposition;
}
/**
* @return string
*/
public function getDisposition()
{
return $this->disposition;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(PopSettings::class, 'Google_Service_Gmail_PopSettings');

View File

@@ -0,0 +1,98 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class Profile extends \Google\Model
{
/**
* @var string
*/
public $emailAddress;
/**
* @var string
*/
public $historyId;
/**
* @var int
*/
public $messagesTotal;
/**
* @var int
*/
public $threadsTotal;
/**
* @param string
*/
public function setEmailAddress($emailAddress)
{
$this->emailAddress = $emailAddress;
}
/**
* @return string
*/
public function getEmailAddress()
{
return $this->emailAddress;
}
/**
* @param string
*/
public function setHistoryId($historyId)
{
$this->historyId = $historyId;
}
/**
* @return string
*/
public function getHistoryId()
{
return $this->historyId;
}
/**
* @param int
*/
public function setMessagesTotal($messagesTotal)
{
$this->messagesTotal = $messagesTotal;
}
/**
* @return int
*/
public function getMessagesTotal()
{
return $this->messagesTotal;
}
/**
* @param int
*/
public function setThreadsTotal($threadsTotal)
{
$this->threadsTotal = $threadsTotal;
}
/**
* @return int
*/
public function getThreadsTotal()
{
return $this->threadsTotal;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Profile::class, 'Google_Service_Gmail_Profile');

View File

@@ -0,0 +1,80 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
use Google\Service\Gmail\Profile;
use Google\Service\Gmail\WatchRequest;
use Google\Service\Gmail\WatchResponse;
/**
* The "users" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $users = $gmailService->users;
* </code>
*/
class Users extends \Google\Service\Resource
{
/**
* Gets the current user's Gmail profile. (users.getProfile)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
* @return Profile
*/
public function getProfile($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('getProfile', [$params], Profile::class);
}
/**
* Stop receiving push notifications for the given user mailbox. (users.stop)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
*/
public function stop($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('stop', [$params]);
}
/**
* Set up or update a push notification watch on the given user mailbox.
* (users.watch)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param WatchRequest $postBody
* @param array $optParams Optional parameters.
* @return WatchResponse
*/
public function watch($userId, WatchRequest $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('watch', [$params], WatchResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Users::class, 'Google_Service_Gmail_Resource_Users');

View File

@@ -0,0 +1,140 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
use Google\Service\Gmail\Draft;
use Google\Service\Gmail\ListDraftsResponse;
use Google\Service\Gmail\Message;
/**
* The "drafts" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $drafts = $gmailService->users_drafts;
* </code>
*/
class UsersDrafts extends \Google\Service\Resource
{
/**
* Creates a new draft with the `DRAFT` label. (drafts.create)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param Draft $postBody
* @param array $optParams Optional parameters.
* @return Draft
*/
public function create($userId, Draft $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], Draft::class);
}
/**
* Immediately and permanently deletes the specified draft. Does not simply
* trash it. (drafts.delete)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the draft to delete.
* @param array $optParams Optional parameters.
*/
public function delete($userId, $id, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params]);
}
/**
* Gets the specified draft. (drafts.get)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the draft to retrieve.
* @param array $optParams Optional parameters.
*
* @opt_param string format The format to return the draft in.
* @return Draft
*/
public function get($userId, $id, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Draft::class);
}
/**
* Lists the drafts in the user's mailbox. (drafts.listUsersDrafts)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
*
* @opt_param bool includeSpamTrash Include drafts from `SPAM` and `TRASH` in
* the results.
* @opt_param string maxResults Maximum number of drafts to return. This field
* defaults to 100. The maximum allowed value for this field is 500.
* @opt_param string pageToken Page token to retrieve a specific page of results
* in the list.
* @opt_param string q Only return draft messages matching the specified query.
* Supports the same query format as the Gmail search box. For example,
* `"from:someuser@example.com rfc822msgid: is:unread"`.
* @return ListDraftsResponse
*/
public function listUsersDrafts($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListDraftsResponse::class);
}
/**
* Sends the specified, existing draft to the recipients in the `To`, `Cc`, and
* `Bcc` headers. (drafts.send)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param Draft $postBody
* @param array $optParams Optional parameters.
* @return Message
*/
public function send($userId, Draft $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('send', [$params], Message::class);
}
/**
* Replaces a draft's content. (drafts.update)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the draft to update.
* @param Draft $postBody
* @param array $optParams Optional parameters.
* @return Draft
*/
public function update($userId, $id, Draft $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('update', [$params], Draft::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UsersDrafts::class, 'Google_Service_Gmail_Resource_UsersDrafts');

View File

@@ -0,0 +1,69 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
use Google\Service\Gmail\ListHistoryResponse;
/**
* The "history" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $history = $gmailService->users_history;
* </code>
*/
class UsersHistory extends \Google\Service\Resource
{
/**
* Lists the history of all changes to the given mailbox. History results are
* returned in chronological order (increasing `historyId`).
* (history.listUsersHistory)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
*
* @opt_param string historyTypes History types to be returned by the function
* @opt_param string labelId Only return messages with a label matching the ID.
* @opt_param string maxResults Maximum number of history records to return.
* This field defaults to 100. The maximum allowed value for this field is 500.
* @opt_param string pageToken Page token to retrieve a specific page of results
* in the list.
* @opt_param string startHistoryId Required. Returns history records after the
* specified `startHistoryId`. The supplied `startHistoryId` should be obtained
* from the `historyId` of a message, thread, or previous `list` response.
* History IDs increase chronologically but are not contiguous with random gaps
* in between valid IDs. Supplying an invalid or out of date `startHistoryId`
* typically returns an `HTTP 404` error code. A `historyId` is typically valid
* for at least a week, but in some rare circumstances may be valid for only a
* few hours. If you receive an `HTTP 404` error response, your application
* should perform a full sync. If you receive no `nextPageToken` in the
* response, there are no updates to retrieve and you can store the returned
* `historyId` for a future request.
* @return ListHistoryResponse
*/
public function listUsersHistory($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListHistoryResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UsersHistory::class, 'Google_Service_Gmail_Resource_UsersHistory');

View File

@@ -0,0 +1,127 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
use Google\Service\Gmail\Label;
use Google\Service\Gmail\ListLabelsResponse;
/**
* The "labels" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $labels = $gmailService->users_labels;
* </code>
*/
class UsersLabels extends \Google\Service\Resource
{
/**
* Creates a new label. (labels.create)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param Label $postBody
* @param array $optParams Optional parameters.
* @return Label
*/
public function create($userId, Label $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], Label::class);
}
/**
* Immediately and permanently deletes the specified label and removes it from
* any messages and threads that it is applied to. (labels.delete)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the label to delete.
* @param array $optParams Optional parameters.
*/
public function delete($userId, $id, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params]);
}
/**
* Gets the specified label. (labels.get)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the label to retrieve.
* @param array $optParams Optional parameters.
* @return Label
*/
public function get($userId, $id, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Label::class);
}
/**
* Lists all labels in the user's mailbox. (labels.listUsersLabels)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
* @return ListLabelsResponse
*/
public function listUsersLabels($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListLabelsResponse::class);
}
/**
* Patch the specified label. (labels.patch)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the label to update.
* @param Label $postBody
* @param array $optParams Optional parameters.
* @return Label
*/
public function patch($userId, $id, Label $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('patch', [$params], Label::class);
}
/**
* Updates the specified label. (labels.update)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the label to update.
* @param Label $postBody
* @param array $optParams Optional parameters.
* @return Label
*/
public function update($userId, $id, Label $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('update', [$params], Label::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UsersLabels::class, 'Google_Service_Gmail_Resource_UsersLabels');

View File

@@ -0,0 +1,250 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
use Google\Service\Gmail\BatchDeleteMessagesRequest;
use Google\Service\Gmail\BatchModifyMessagesRequest;
use Google\Service\Gmail\ListMessagesResponse;
use Google\Service\Gmail\Message;
use Google\Service\Gmail\ModifyMessageRequest;
/**
* The "messages" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $messages = $gmailService->users_messages;
* </code>
*/
class UsersMessages extends \Google\Service\Resource
{
/**
* Deletes many messages by message ID. Provides no guarantees that messages
* were not already deleted or even existed at all. (messages.batchDelete)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param BatchDeleteMessagesRequest $postBody
* @param array $optParams Optional parameters.
*/
public function batchDelete($userId, BatchDeleteMessagesRequest $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('batchDelete', [$params]);
}
/**
* Modifies the labels on the specified messages. (messages.batchModify)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param BatchModifyMessagesRequest $postBody
* @param array $optParams Optional parameters.
*/
public function batchModify($userId, BatchModifyMessagesRequest $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('batchModify', [$params]);
}
/**
* Immediately and permanently deletes the specified message. This operation
* cannot be undone. Prefer `messages.trash` instead. (messages.delete)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the message to delete.
* @param array $optParams Optional parameters.
*/
public function delete($userId, $id, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params]);
}
/**
* Gets the specified message. (messages.get)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the message to retrieve. This ID is usually
* retrieved using `messages.list`. The ID is also contained in the result when
* a message is inserted (`messages.insert`) or imported (`messages.import`).
* @param array $optParams Optional parameters.
*
* @opt_param string format The format to return the message in.
* @opt_param string metadataHeaders When given and format is `METADATA`, only
* include headers specified.
* @return Message
*/
public function get($userId, $id, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Message::class);
}
/**
* Imports a message into only this user's mailbox, with standard email delivery
* scanning and classification similar to receiving via SMTP. This method
* doesn't perform SPF checks, so it might not work for some spam messages, such
* as those attempting to perform domain spoofing. This method does not send a
* message. (messages.import)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param Message $postBody
* @param array $optParams Optional parameters.
*
* @opt_param bool deleted Mark the email as permanently deleted (not TRASH) and
* only visible in Google Vault to a Vault administrator. Only used for Google
* Workspace accounts.
* @opt_param string internalDateSource Source for Gmail's internal date of the
* message.
* @opt_param bool neverMarkSpam Ignore the Gmail spam classifier decision and
* never mark this email as SPAM in the mailbox.
* @opt_param bool processForCalendar Process calendar invites in the email and
* add any extracted meetings to the Google Calendar for this user.
* @return Message
*/
public function import($userId, Message $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('import', [$params], Message::class);
}
/**
* Directly inserts a message into only this user's mailbox similar to `IMAP
* APPEND`, bypassing most scanning and classification. Does not send a message.
* (messages.insert)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param Message $postBody
* @param array $optParams Optional parameters.
*
* @opt_param bool deleted Mark the email as permanently deleted (not TRASH) and
* only visible in Google Vault to a Vault administrator. Only used for Google
* Workspace accounts.
* @opt_param string internalDateSource Source for Gmail's internal date of the
* message.
* @return Message
*/
public function insert($userId, Message $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('insert', [$params], Message::class);
}
/**
* Lists the messages in the user's mailbox. (messages.listUsersMessages)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
*
* @opt_param bool includeSpamTrash Include messages from `SPAM` and `TRASH` in
* the results.
* @opt_param string labelIds Only return messages with labels that match all of
* the specified label IDs. Messages in a thread might have labels that other
* messages in the same thread don't have. To learn more, see [Manage labels on
* messages and threads](https://developers.google.com/gmail/api/guides/labels#m
* anage_labels_on_messages_threads).
* @opt_param string maxResults Maximum number of messages to return. This field
* defaults to 100. The maximum allowed value for this field is 500.
* @opt_param string pageToken Page token to retrieve a specific page of results
* in the list.
* @opt_param string q Only return messages matching the specified query.
* Supports the same query format as the Gmail search box. For example,
* `"from:someuser@example.com rfc822msgid: is:unread"`. Parameter cannot be
* used when accessing the api using the gmail.metadata scope.
* @return ListMessagesResponse
*/
public function listUsersMessages($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListMessagesResponse::class);
}
/**
* Modifies the labels on the specified message. (messages.modify)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the message to modify.
* @param ModifyMessageRequest $postBody
* @param array $optParams Optional parameters.
* @return Message
*/
public function modify($userId, $id, ModifyMessageRequest $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('modify', [$params], Message::class);
}
/**
* Sends the specified message to the recipients in the `To`, `Cc`, and `Bcc`
* headers. For example usage, see [Sending
* email](https://developers.google.com/gmail/api/guides/sending).
* (messages.send)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param Message $postBody
* @param array $optParams Optional parameters.
* @return Message
*/
public function send($userId, Message $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('send', [$params], Message::class);
}
/**
* Moves the specified message to the trash. (messages.trash)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the message to Trash.
* @param array $optParams Optional parameters.
* @return Message
*/
public function trash($userId, $id, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('trash', [$params], Message::class);
}
/**
* Removes the specified message from the trash. (messages.untrash)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the message to remove from Trash.
* @param array $optParams Optional parameters.
* @return Message
*/
public function untrash($userId, $id, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('untrash', [$params], Message::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UsersMessages::class, 'Google_Service_Gmail_Resource_UsersMessages');

View File

@@ -0,0 +1,51 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
use Google\Service\Gmail\MessagePartBody;
/**
* The "attachments" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $attachments = $gmailService->users_messages_attachments;
* </code>
*/
class UsersMessagesAttachments extends \Google\Service\Resource
{
/**
* Gets the specified message attachment. (attachments.get)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $messageId The ID of the message containing the attachment.
* @param string $id The ID of the attachment.
* @param array $optParams Optional parameters.
* @return MessagePartBody
*/
public function get($userId, $messageId, $id, $optParams = [])
{
$params = ['userId' => $userId, 'messageId' => $messageId, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], MessagePartBody::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UsersMessagesAttachments::class, 'Google_Service_Gmail_Resource_UsersMessagesAttachments');

View File

@@ -0,0 +1,193 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
use Google\Service\Gmail\AutoForwarding;
use Google\Service\Gmail\ImapSettings;
use Google\Service\Gmail\LanguageSettings;
use Google\Service\Gmail\PopSettings;
use Google\Service\Gmail\VacationSettings;
/**
* The "settings" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $settings = $gmailService->users_settings;
* </code>
*/
class UsersSettings extends \Google\Service\Resource
{
/**
* Gets the auto-forwarding setting for the specified account.
* (settings.getAutoForwarding)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
* @return AutoForwarding
*/
public function getAutoForwarding($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('getAutoForwarding', [$params], AutoForwarding::class);
}
/**
* Gets IMAP settings. (settings.getImap)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
* @return ImapSettings
*/
public function getImap($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('getImap', [$params], ImapSettings::class);
}
/**
* Gets language settings. (settings.getLanguage)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
* @return LanguageSettings
*/
public function getLanguage($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('getLanguage', [$params], LanguageSettings::class);
}
/**
* Gets POP settings. (settings.getPop)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
* @return PopSettings
*/
public function getPop($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('getPop', [$params], PopSettings::class);
}
/**
* Gets vacation responder settings. (settings.getVacation)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
* @return VacationSettings
*/
public function getVacation($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('getVacation', [$params], VacationSettings::class);
}
/**
* Updates the auto-forwarding setting for the specified account. A verified
* forwarding address must be specified when auto-forwarding is enabled. This
* method is only available to service account clients that have been delegated
* domain-wide authority. (settings.updateAutoForwarding)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param AutoForwarding $postBody
* @param array $optParams Optional parameters.
* @return AutoForwarding
*/
public function updateAutoForwarding($userId, AutoForwarding $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('updateAutoForwarding', [$params], AutoForwarding::class);
}
/**
* Updates IMAP settings. (settings.updateImap)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param ImapSettings $postBody
* @param array $optParams Optional parameters.
* @return ImapSettings
*/
public function updateImap($userId, ImapSettings $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('updateImap', [$params], ImapSettings::class);
}
/**
* Updates language settings. If successful, the return object contains the
* `displayLanguage` that was saved for the user, which may differ from the
* value passed into the request. This is because the requested
* `displayLanguage` may not be directly supported by Gmail but have a close
* variant that is, and so the variant may be chosen and saved instead.
* (settings.updateLanguage)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param LanguageSettings $postBody
* @param array $optParams Optional parameters.
* @return LanguageSettings
*/
public function updateLanguage($userId, LanguageSettings $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('updateLanguage', [$params], LanguageSettings::class);
}
/**
* Updates POP settings. (settings.updatePop)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param PopSettings $postBody
* @param array $optParams Optional parameters.
* @return PopSettings
*/
public function updatePop($userId, PopSettings $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('updatePop', [$params], PopSettings::class);
}
/**
* Updates vacation responder settings. (settings.updateVacation)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param VacationSettings $postBody
* @param array $optParams Optional parameters.
* @return VacationSettings
*/
public function updateVacation($userId, VacationSettings $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('updateVacation', [$params], VacationSettings::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UsersSettings::class, 'Google_Service_Gmail_Resource_UsersSettings');

View File

@@ -0,0 +1,33 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
/**
* The "cse" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $cse = $gmailService->users_settings_cse;
* </code>
*/
class UsersSettingsCse extends \Google\Service\Resource
{
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UsersSettingsCse::class, 'Google_Service_Gmail_Resource_UsersSettingsCse');

View File

@@ -0,0 +1,129 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
use Google\Service\Gmail\CseIdentity;
use Google\Service\Gmail\ListCseIdentitiesResponse;
/**
* The "identities" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $identities = $gmailService->users_settings_cse_identities;
* </code>
*/
class UsersSettingsCseIdentities extends \Google\Service\Resource
{
/**
* Creates and configures a client-side encryption identity that's authorized to
* send mail from the user account. Google publishes the S/MIME certificate to a
* shared domain-wide directory so that people within a Google Workspace
* organization can encrypt and send mail to the identity. (identities.create)
*
* @param string $userId The requester's primary email address. To indicate the
* authenticated user, you can use the special value `me`.
* @param CseIdentity $postBody
* @param array $optParams Optional parameters.
* @return CseIdentity
*/
public function create($userId, CseIdentity $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], CseIdentity::class);
}
/**
* Deletes a client-side encryption identity. The authenticated user can no
* longer use the identity to send encrypted messages. You cannot restore the
* identity after you delete it. Instead, use the CreateCseIdentity method to
* create another identity with the same configuration. (identities.delete)
*
* @param string $userId The requester's primary email address. To indicate the
* authenticated user, you can use the special value `me`.
* @param string $cseEmailAddress The primary email address associated with the
* client-side encryption identity configuration that's removed.
* @param array $optParams Optional parameters.
*/
public function delete($userId, $cseEmailAddress, $optParams = [])
{
$params = ['userId' => $userId, 'cseEmailAddress' => $cseEmailAddress];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params]);
}
/**
* Retrieves a client-side encryption identity configuration. (identities.get)
*
* @param string $userId The requester's primary email address. To indicate the
* authenticated user, you can use the special value `me`.
* @param string $cseEmailAddress The primary email address associated with the
* client-side encryption identity configuration that's retrieved.
* @param array $optParams Optional parameters.
* @return CseIdentity
*/
public function get($userId, $cseEmailAddress, $optParams = [])
{
$params = ['userId' => $userId, 'cseEmailAddress' => $cseEmailAddress];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], CseIdentity::class);
}
/**
* Lists the client-side encrypted identities for an authenticated user.
* (identities.listUsersSettingsCseIdentities)
*
* @param string $userId The requester's primary email address. To indicate the
* authenticated user, you can use the special value `me`.
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize The number of identities to return. If not provided,
* the page size will default to 20 entries.
* @opt_param string pageToken Pagination token indicating which page of
* identities to return. If the token is not supplied, then the API will return
* the first page of results.
* @return ListCseIdentitiesResponse
*/
public function listUsersSettingsCseIdentities($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListCseIdentitiesResponse::class);
}
/**
* Associates a different key pair with an existing client-side encryption
* identity. The updated key pair must validate against Google's [S/MIME
* certificate profiles](https://support.google.com/a/answer/7300887).
* (identities.patch)
*
* @param string $userId The requester's primary email address. To indicate the
* authenticated user, you can use the special value `me`.
* @param string $emailAddress The email address of the client-side encryption
* identity to update.
* @param CseIdentity $postBody
* @param array $optParams Optional parameters.
* @return CseIdentity
*/
public function patch($userId, $emailAddress, CseIdentity $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'emailAddress' => $emailAddress, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('patch', [$params], CseIdentity::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UsersSettingsCseIdentities::class, 'Google_Service_Gmail_Resource_UsersSettingsCseIdentities');

View File

@@ -0,0 +1,149 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
use Google\Service\Gmail\CseKeyPair;
use Google\Service\Gmail\DisableCseKeyPairRequest;
use Google\Service\Gmail\EnableCseKeyPairRequest;
use Google\Service\Gmail\ListCseKeyPairsResponse;
use Google\Service\Gmail\ObliterateCseKeyPairRequest;
/**
* The "keypairs" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $keypairs = $gmailService->users_settings_cse_keypairs;
* </code>
*/
class UsersSettingsCseKeypairs extends \Google\Service\Resource
{
/**
* Creates and uploads a client-side encryption S/MIME public key certificate
* chain and private key metadata for the authenticated user. (keypairs.create)
*
* @param string $userId The requester's primary email address. To indicate the
* authenticated user, you can use the special value `me`.
* @param CseKeyPair $postBody
* @param array $optParams Optional parameters.
* @return CseKeyPair
*/
public function create($userId, CseKeyPair $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], CseKeyPair::class);
}
/**
* Turns off a client-side encryption key pair. The authenticated user can no
* longer use the key pair to decrypt incoming CSE message texts or sign
* outgoing CSE mail. To regain access, use the EnableCseKeyPair to turn on the
* key pair. After 30 days, you can permanently delete the key pair by using the
* ObliterateCseKeyPair method. (keypairs.disable)
*
* @param string $userId The requester's primary email address. To indicate the
* authenticated user, you can use the special value `me`.
* @param string $keyPairId The identifier of the key pair to turn off.
* @param DisableCseKeyPairRequest $postBody
* @param array $optParams Optional parameters.
* @return CseKeyPair
*/
public function disable($userId, $keyPairId, DisableCseKeyPairRequest $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'keyPairId' => $keyPairId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('disable', [$params], CseKeyPair::class);
}
/**
* Turns on a client-side encryption key pair that was turned off. The key pair
* becomes active again for any associated client-side encryption identities.
* (keypairs.enable)
*
* @param string $userId The requester's primary email address. To indicate the
* authenticated user, you can use the special value `me`.
* @param string $keyPairId The identifier of the key pair to turn on.
* @param EnableCseKeyPairRequest $postBody
* @param array $optParams Optional parameters.
* @return CseKeyPair
*/
public function enable($userId, $keyPairId, EnableCseKeyPairRequest $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'keyPairId' => $keyPairId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('enable', [$params], CseKeyPair::class);
}
/**
* Retrieves an existing client-side encryption key pair. (keypairs.get)
*
* @param string $userId The requester's primary email address. To indicate the
* authenticated user, you can use the special value `me`.
* @param string $keyPairId The identifier of the key pair to retrieve.
* @param array $optParams Optional parameters.
* @return CseKeyPair
*/
public function get($userId, $keyPairId, $optParams = [])
{
$params = ['userId' => $userId, 'keyPairId' => $keyPairId];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], CseKeyPair::class);
}
/**
* Lists client-side encryption key pairs for an authenticated user.
* (keypairs.listUsersSettingsCseKeypairs)
*
* @param string $userId The requester's primary email address. To indicate the
* authenticated user, you can use the special value `me`.
* @param array $optParams Optional parameters.
*
* @opt_param int pageSize The number of key pairs to return. If not provided,
* the page size will default to 20 entries.
* @opt_param string pageToken Pagination token indicating which page of key
* pairs to return. If the token is not supplied, then the API will return the
* first page of results.
* @return ListCseKeyPairsResponse
*/
public function listUsersSettingsCseKeypairs($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListCseKeyPairsResponse::class);
}
/**
* Deletes a client-side encryption key pair permanently and immediately. You
* can only permanently delete key pairs that have been turned off for more than
* 30 days. To turn off a key pair, use the DisableCseKeyPair method. Gmail
* can't restore or decrypt any messages that were encrypted by an obliterated
* key. Authenticated users and Google Workspace administrators lose access to
* reading the encrypted messages. (keypairs.obliterate)
*
* @param string $userId The requester's primary email address. To indicate the
* authenticated user, you can use the special value `me`.
* @param string $keyPairId The identifier of the key pair to obliterate.
* @param ObliterateCseKeyPairRequest $postBody
* @param array $optParams Optional parameters.
*/
public function obliterate($userId, $keyPairId, ObliterateCseKeyPairRequest $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'keyPairId' => $keyPairId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('obliterate', [$params]);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UsersSettingsCseKeypairs::class, 'Google_Service_Gmail_Resource_UsersSettingsCseKeypairs');

View File

@@ -0,0 +1,115 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
use Google\Service\Gmail\Delegate;
use Google\Service\Gmail\ListDelegatesResponse;
/**
* The "delegates" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $delegates = $gmailService->users_settings_delegates;
* </code>
*/
class UsersSettingsDelegates extends \Google\Service\Resource
{
/**
* Adds a delegate with its verification status set directly to `accepted`,
* without sending any verification email. The delegate user must be a member of
* the same Google Workspace organization as the delegator user. Gmail imposes
* limitations on the number of delegates and delegators each user in a Google
* Workspace organization can have. These limits depend on your organization,
* but in general each user can have up to 25 delegates and up to 10 delegators.
* Note that a delegate user must be referred to by their primary email address,
* and not an email alias. Also note that when a new delegate is created, there
* may be up to a one minute delay before the new delegate is available for use.
* This method is only available to service account clients that have been
* delegated domain-wide authority. (delegates.create)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param Delegate $postBody
* @param array $optParams Optional parameters.
* @return Delegate
*/
public function create($userId, Delegate $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], Delegate::class);
}
/**
* Removes the specified delegate (which can be of any verification status), and
* revokes any verification that may have been required for using it. Note that
* a delegate user must be referred to by their primary email address, and not
* an email alias. This method is only available to service account clients that
* have been delegated domain-wide authority. (delegates.delete)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param string $delegateEmail The email address of the user to be removed as a
* delegate.
* @param array $optParams Optional parameters.
*/
public function delete($userId, $delegateEmail, $optParams = [])
{
$params = ['userId' => $userId, 'delegateEmail' => $delegateEmail];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params]);
}
/**
* Gets the specified delegate. Note that a delegate user must be referred to by
* their primary email address, and not an email alias. This method is only
* available to service account clients that have been delegated domain-wide
* authority. (delegates.get)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param string $delegateEmail The email address of the user whose delegate
* relationship is to be retrieved.
* @param array $optParams Optional parameters.
* @return Delegate
*/
public function get($userId, $delegateEmail, $optParams = [])
{
$params = ['userId' => $userId, 'delegateEmail' => $delegateEmail];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Delegate::class);
}
/**
* Lists the delegates for the specified account. This method is only available
* to service account clients that have been delegated domain-wide authority.
* (delegates.listUsersSettingsDelegates)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
* @return ListDelegatesResponse
*/
public function listUsersSettingsDelegates($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListDelegatesResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UsersSettingsDelegates::class, 'Google_Service_Gmail_Resource_UsersSettingsDelegates');

View File

@@ -0,0 +1,95 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
use Google\Service\Gmail\Filter;
use Google\Service\Gmail\ListFiltersResponse;
/**
* The "filters" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $filters = $gmailService->users_settings_filters;
* </code>
*/
class UsersSettingsFilters extends \Google\Service\Resource
{
/**
* Creates a filter. Note: you can only create a maximum of 1,000 filters.
* (filters.create)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param Filter $postBody
* @param array $optParams Optional parameters.
* @return Filter
*/
public function create($userId, Filter $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], Filter::class);
}
/**
* Immediately and permanently deletes the specified filter. (filters.delete)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param string $id The ID of the filter to be deleted.
* @param array $optParams Optional parameters.
*/
public function delete($userId, $id, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params]);
}
/**
* Gets a filter. (filters.get)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param string $id The ID of the filter to be fetched.
* @param array $optParams Optional parameters.
* @return Filter
*/
public function get($userId, $id, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Filter::class);
}
/**
* Lists the message filters of a Gmail user. (filters.listUsersSettingsFilters)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
* @return ListFiltersResponse
*/
public function listUsersSettingsFilters($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListFiltersResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UsersSettingsFilters::class, 'Google_Service_Gmail_Resource_UsersSettingsFilters');

View File

@@ -0,0 +1,103 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
use Google\Service\Gmail\ForwardingAddress;
use Google\Service\Gmail\ListForwardingAddressesResponse;
/**
* The "forwardingAddresses" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $forwardingAddresses = $gmailService->users_settings_forwardingAddresses;
* </code>
*/
class UsersSettingsForwardingAddresses extends \Google\Service\Resource
{
/**
* Creates a forwarding address. If ownership verification is required, a
* message will be sent to the recipient and the resource's verification status
* will be set to `pending`; otherwise, the resource will be created with
* verification status set to `accepted`. This method is only available to
* service account clients that have been delegated domain-wide authority.
* (forwardingAddresses.create)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param ForwardingAddress $postBody
* @param array $optParams Optional parameters.
* @return ForwardingAddress
*/
public function create($userId, ForwardingAddress $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], ForwardingAddress::class);
}
/**
* Deletes the specified forwarding address and revokes any verification that
* may have been required. This method is only available to service account
* clients that have been delegated domain-wide authority.
* (forwardingAddresses.delete)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param string $forwardingEmail The forwarding address to be deleted.
* @param array $optParams Optional parameters.
*/
public function delete($userId, $forwardingEmail, $optParams = [])
{
$params = ['userId' => $userId, 'forwardingEmail' => $forwardingEmail];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params]);
}
/**
* Gets the specified forwarding address. (forwardingAddresses.get)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param string $forwardingEmail The forwarding address to be retrieved.
* @param array $optParams Optional parameters.
* @return ForwardingAddress
*/
public function get($userId, $forwardingEmail, $optParams = [])
{
$params = ['userId' => $userId, 'forwardingEmail' => $forwardingEmail];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], ForwardingAddress::class);
}
/**
* Lists the forwarding addresses for the specified account.
* (forwardingAddresses.listUsersSettingsForwardingAddresses)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
* @return ListForwardingAddressesResponse
*/
public function listUsersSettingsForwardingAddresses($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListForwardingAddressesResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UsersSettingsForwardingAddresses::class, 'Google_Service_Gmail_Resource_UsersSettingsForwardingAddresses');

View File

@@ -0,0 +1,159 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
use Google\Service\Gmail\ListSendAsResponse;
use Google\Service\Gmail\SendAs;
/**
* The "sendAs" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $sendAs = $gmailService->users_settings_sendAs;
* </code>
*/
class UsersSettingsSendAs extends \Google\Service\Resource
{
/**
* Creates a custom "from" send-as alias. If an SMTP MSA is specified, Gmail
* will attempt to connect to the SMTP service to validate the configuration
* before creating the alias. If ownership verification is required for the
* alias, a message will be sent to the email address and the resource's
* verification status will be set to `pending`; otherwise, the resource will be
* created with verification status set to `accepted`. If a signature is
* provided, Gmail will sanitize the HTML before saving it with the alias. This
* method is only available to service account clients that have been delegated
* domain-wide authority. (sendAs.create)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param SendAs $postBody
* @param array $optParams Optional parameters.
* @return SendAs
*/
public function create($userId, SendAs $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], SendAs::class);
}
/**
* Deletes the specified send-as alias. Revokes any verification that may have
* been required for using it. This method is only available to service account
* clients that have been delegated domain-wide authority. (sendAs.delete)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param string $sendAsEmail The send-as alias to be deleted.
* @param array $optParams Optional parameters.
*/
public function delete($userId, $sendAsEmail, $optParams = [])
{
$params = ['userId' => $userId, 'sendAsEmail' => $sendAsEmail];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params]);
}
/**
* Gets the specified send-as alias. Fails with an HTTP 404 error if the
* specified address is not a member of the collection. (sendAs.get)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param string $sendAsEmail The send-as alias to be retrieved.
* @param array $optParams Optional parameters.
* @return SendAs
*/
public function get($userId, $sendAsEmail, $optParams = [])
{
$params = ['userId' => $userId, 'sendAsEmail' => $sendAsEmail];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], SendAs::class);
}
/**
* Lists the send-as aliases for the specified account. The result includes the
* primary send-as address associated with the account as well as any custom
* "from" aliases. (sendAs.listUsersSettingsSendAs)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
* @return ListSendAsResponse
*/
public function listUsersSettingsSendAs($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListSendAsResponse::class);
}
/**
* Patch the specified send-as alias. (sendAs.patch)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param string $sendAsEmail The send-as alias to be updated.
* @param SendAs $postBody
* @param array $optParams Optional parameters.
* @return SendAs
*/
public function patch($userId, $sendAsEmail, SendAs $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'sendAsEmail' => $sendAsEmail, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('patch', [$params], SendAs::class);
}
/**
* Updates a send-as alias. If a signature is provided, Gmail will sanitize the
* HTML before saving it with the alias. Addresses other than the primary
* address for the account can only be updated by service account clients that
* have been delegated domain-wide authority. (sendAs.update)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param string $sendAsEmail The send-as alias to be updated.
* @param SendAs $postBody
* @param array $optParams Optional parameters.
* @return SendAs
*/
public function update($userId, $sendAsEmail, SendAs $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'sendAsEmail' => $sendAsEmail, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('update', [$params], SendAs::class);
}
/**
* Sends a verification email to the specified send-as alias address. The
* verification status must be `pending`. This method is only available to
* service account clients that have been delegated domain-wide authority.
* (sendAs.verify)
*
* @param string $userId User's email address. The special value "me" can be
* used to indicate the authenticated user.
* @param string $sendAsEmail The send-as alias to be verified.
* @param array $optParams Optional parameters.
*/
public function verify($userId, $sendAsEmail, $optParams = [])
{
$params = ['userId' => $userId, 'sendAsEmail' => $sendAsEmail];
$params = array_merge($params, $optParams);
return $this->call('verify', [$params]);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UsersSettingsSendAs::class, 'Google_Service_Gmail_Resource_UsersSettingsSendAs');

View File

@@ -0,0 +1,123 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
use Google\Service\Gmail\ListSmimeInfoResponse;
use Google\Service\Gmail\SmimeInfo;
/**
* The "smimeInfo" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $smimeInfo = $gmailService->users_settings_sendAs_smimeInfo;
* </code>
*/
class UsersSettingsSendAsSmimeInfo extends \Google\Service\Resource
{
/**
* Deletes the specified S/MIME config for the specified send-as alias.
* (smimeInfo.delete)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $sendAsEmail The email address that appears in the "From:"
* header for mail sent using this alias.
* @param string $id The immutable ID for the SmimeInfo.
* @param array $optParams Optional parameters.
*/
public function delete($userId, $sendAsEmail, $id, $optParams = [])
{
$params = ['userId' => $userId, 'sendAsEmail' => $sendAsEmail, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params]);
}
/**
* Gets the specified S/MIME config for the specified send-as alias.
* (smimeInfo.get)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $sendAsEmail The email address that appears in the "From:"
* header for mail sent using this alias.
* @param string $id The immutable ID for the SmimeInfo.
* @param array $optParams Optional parameters.
* @return SmimeInfo
*/
public function get($userId, $sendAsEmail, $id, $optParams = [])
{
$params = ['userId' => $userId, 'sendAsEmail' => $sendAsEmail, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], SmimeInfo::class);
}
/**
* Insert (upload) the given S/MIME config for the specified send-as alias. Note
* that pkcs12 format is required for the key. (smimeInfo.insert)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $sendAsEmail The email address that appears in the "From:"
* header for mail sent using this alias.
* @param SmimeInfo $postBody
* @param array $optParams Optional parameters.
* @return SmimeInfo
*/
public function insert($userId, $sendAsEmail, SmimeInfo $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'sendAsEmail' => $sendAsEmail, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('insert', [$params], SmimeInfo::class);
}
/**
* Lists S/MIME configs for the specified send-as alias.
* (smimeInfo.listUsersSettingsSendAsSmimeInfo)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $sendAsEmail The email address that appears in the "From:"
* header for mail sent using this alias.
* @param array $optParams Optional parameters.
* @return ListSmimeInfoResponse
*/
public function listUsersSettingsSendAsSmimeInfo($userId, $sendAsEmail, $optParams = [])
{
$params = ['userId' => $userId, 'sendAsEmail' => $sendAsEmail];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListSmimeInfoResponse::class);
}
/**
* Sets the default S/MIME config for the specified send-as alias.
* (smimeInfo.setDefault)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $sendAsEmail The email address that appears in the "From:"
* header for mail sent using this alias.
* @param string $id The immutable ID for the SmimeInfo.
* @param array $optParams Optional parameters.
*/
public function setDefault($userId, $sendAsEmail, $id, $optParams = [])
{
$params = ['userId' => $userId, 'sendAsEmail' => $sendAsEmail, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('setDefault', [$params]);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UsersSettingsSendAsSmimeInfo::class, 'Google_Service_Gmail_Resource_UsersSettingsSendAsSmimeInfo');

View File

@@ -0,0 +1,148 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail\Resource;
use Google\Service\Gmail\ListThreadsResponse;
use Google\Service\Gmail\ModifyThreadRequest;
use Google\Service\Gmail\Thread;
/**
* The "threads" collection of methods.
* Typical usage is:
* <code>
* $gmailService = new Google\Service\Gmail(...);
* $threads = $gmailService->users_threads;
* </code>
*/
class UsersThreads extends \Google\Service\Resource
{
/**
* Immediately and permanently deletes the specified thread. Any messages that
* belong to the thread are also deleted. This operation cannot be undone.
* Prefer `threads.trash` instead. (threads.delete)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id ID of the Thread to delete.
* @param array $optParams Optional parameters.
*/
public function delete($userId, $id, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params]);
}
/**
* Gets the specified thread. (threads.get)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the thread to retrieve.
* @param array $optParams Optional parameters.
*
* @opt_param string format The format to return the messages in.
* @opt_param string metadataHeaders When given and format is METADATA, only
* include headers specified.
* @return Thread
*/
public function get($userId, $id, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Thread::class);
}
/**
* Lists the threads in the user's mailbox. (threads.listUsersThreads)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param array $optParams Optional parameters.
*
* @opt_param bool includeSpamTrash Include threads from `SPAM` and `TRASH` in
* the results.
* @opt_param string labelIds Only return threads with labels that match all of
* the specified label IDs.
* @opt_param string maxResults Maximum number of threads to return. This field
* defaults to 100. The maximum allowed value for this field is 500.
* @opt_param string pageToken Page token to retrieve a specific page of results
* in the list.
* @opt_param string q Only return threads matching the specified query.
* Supports the same query format as the Gmail search box. For example,
* `"from:someuser@example.com rfc822msgid: is:unread"`. Parameter cannot be
* used when accessing the api using the gmail.metadata scope.
* @return ListThreadsResponse
*/
public function listUsersThreads($userId, $optParams = [])
{
$params = ['userId' => $userId];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListThreadsResponse::class);
}
/**
* Modifies the labels applied to the thread. This applies to all messages in
* the thread. (threads.modify)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the thread to modify.
* @param ModifyThreadRequest $postBody
* @param array $optParams Optional parameters.
* @return Thread
*/
public function modify($userId, $id, ModifyThreadRequest $postBody, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('modify', [$params], Thread::class);
}
/**
* Moves the specified thread to the trash. Any messages that belong to the
* thread are also moved to the trash. (threads.trash)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the thread to Trash.
* @param array $optParams Optional parameters.
* @return Thread
*/
public function trash($userId, $id, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('trash', [$params], Thread::class);
}
/**
* Removes the specified thread from the trash. Any messages that belong to the
* thread are also removed from the trash. (threads.untrash)
*
* @param string $userId The user's email address. The special value `me` can be
* used to indicate the authenticated user.
* @param string $id The ID of the thread to remove from Trash.
* @param array $optParams Optional parameters.
* @return Thread
*/
public function untrash($userId, $id, $optParams = [])
{
$params = ['userId' => $userId, 'id' => $id];
$params = array_merge($params, $optParams);
return $this->call('untrash', [$params], Thread::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(UsersThreads::class, 'Google_Service_Gmail_Resource_UsersThreads');

View File

@@ -0,0 +1,186 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class SendAs extends \Google\Model
{
/**
* @var string
*/
public $displayName;
/**
* @var bool
*/
public $isDefault;
/**
* @var bool
*/
public $isPrimary;
/**
* @var string
*/
public $replyToAddress;
/**
* @var string
*/
public $sendAsEmail;
/**
* @var string
*/
public $signature;
protected $smtpMsaType = SmtpMsa::class;
protected $smtpMsaDataType = '';
/**
* @var bool
*/
public $treatAsAlias;
/**
* @var string
*/
public $verificationStatus;
/**
* @param string
*/
public function setDisplayName($displayName)
{
$this->displayName = $displayName;
}
/**
* @return string
*/
public function getDisplayName()
{
return $this->displayName;
}
/**
* @param bool
*/
public function setIsDefault($isDefault)
{
$this->isDefault = $isDefault;
}
/**
* @return bool
*/
public function getIsDefault()
{
return $this->isDefault;
}
/**
* @param bool
*/
public function setIsPrimary($isPrimary)
{
$this->isPrimary = $isPrimary;
}
/**
* @return bool
*/
public function getIsPrimary()
{
return $this->isPrimary;
}
/**
* @param string
*/
public function setReplyToAddress($replyToAddress)
{
$this->replyToAddress = $replyToAddress;
}
/**
* @return string
*/
public function getReplyToAddress()
{
return $this->replyToAddress;
}
/**
* @param string
*/
public function setSendAsEmail($sendAsEmail)
{
$this->sendAsEmail = $sendAsEmail;
}
/**
* @return string
*/
public function getSendAsEmail()
{
return $this->sendAsEmail;
}
/**
* @param string
*/
public function setSignature($signature)
{
$this->signature = $signature;
}
/**
* @return string
*/
public function getSignature()
{
return $this->signature;
}
/**
* @param SmtpMsa
*/
public function setSmtpMsa(SmtpMsa $smtpMsa)
{
$this->smtpMsa = $smtpMsa;
}
/**
* @return SmtpMsa
*/
public function getSmtpMsa()
{
return $this->smtpMsa;
}
/**
* @param bool
*/
public function setTreatAsAlias($treatAsAlias)
{
$this->treatAsAlias = $treatAsAlias;
}
/**
* @return bool
*/
public function getTreatAsAlias()
{
return $this->treatAsAlias;
}
/**
* @param string
*/
public function setVerificationStatus($verificationStatus)
{
$this->verificationStatus = $verificationStatus;
}
/**
* @return string
*/
public function getVerificationStatus()
{
return $this->verificationStatus;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(SendAs::class, 'Google_Service_Gmail_SendAs');

View File

@@ -0,0 +1,152 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class SmimeInfo extends \Google\Model
{
/**
* @var string
*/
public $encryptedKeyPassword;
/**
* @var string
*/
public $expiration;
/**
* @var string
*/
public $id;
/**
* @var bool
*/
public $isDefault;
/**
* @var string
*/
public $issuerCn;
/**
* @var string
*/
public $pem;
/**
* @var string
*/
public $pkcs12;
/**
* @param string
*/
public function setEncryptedKeyPassword($encryptedKeyPassword)
{
$this->encryptedKeyPassword = $encryptedKeyPassword;
}
/**
* @return string
*/
public function getEncryptedKeyPassword()
{
return $this->encryptedKeyPassword;
}
/**
* @param string
*/
public function setExpiration($expiration)
{
$this->expiration = $expiration;
}
/**
* @return string
*/
public function getExpiration()
{
return $this->expiration;
}
/**
* @param string
*/
public function setId($id)
{
$this->id = $id;
}
/**
* @return string
*/
public function getId()
{
return $this->id;
}
/**
* @param bool
*/
public function setIsDefault($isDefault)
{
$this->isDefault = $isDefault;
}
/**
* @return bool
*/
public function getIsDefault()
{
return $this->isDefault;
}
/**
* @param string
*/
public function setIssuerCn($issuerCn)
{
$this->issuerCn = $issuerCn;
}
/**
* @return string
*/
public function getIssuerCn()
{
return $this->issuerCn;
}
/**
* @param string
*/
public function setPem($pem)
{
$this->pem = $pem;
}
/**
* @return string
*/
public function getPem()
{
return $this->pem;
}
/**
* @param string
*/
public function setPkcs12($pkcs12)
{
$this->pkcs12 = $pkcs12;
}
/**
* @return string
*/
public function getPkcs12()
{
return $this->pkcs12;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(SmimeInfo::class, 'Google_Service_Gmail_SmimeInfo');

View File

@@ -0,0 +1,116 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class SmtpMsa extends \Google\Model
{
/**
* @var string
*/
public $host;
/**
* @var string
*/
public $password;
/**
* @var int
*/
public $port;
/**
* @var string
*/
public $securityMode;
/**
* @var string
*/
public $username;
/**
* @param string
*/
public function setHost($host)
{
$this->host = $host;
}
/**
* @return string
*/
public function getHost()
{
return $this->host;
}
/**
* @param string
*/
public function setPassword($password)
{
$this->password = $password;
}
/**
* @return string
*/
public function getPassword()
{
return $this->password;
}
/**
* @param int
*/
public function setPort($port)
{
$this->port = $port;
}
/**
* @return int
*/
public function getPort()
{
return $this->port;
}
/**
* @param string
*/
public function setSecurityMode($securityMode)
{
$this->securityMode = $securityMode;
}
/**
* @return string
*/
public function getSecurityMode()
{
return $this->securityMode;
}
/**
* @param string
*/
public function setUsername($username)
{
$this->username = $username;
}
/**
* @return string
*/
public function getUsername()
{
return $this->username;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(SmtpMsa::class, 'Google_Service_Gmail_SmtpMsa');

View File

@@ -0,0 +1,97 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class Thread extends \Google\Collection
{
protected $collection_key = 'messages';
/**
* @var string
*/
public $historyId;
/**
* @var string
*/
public $id;
protected $messagesType = Message::class;
protected $messagesDataType = 'array';
/**
* @var string
*/
public $snippet;
/**
* @param string
*/
public function setHistoryId($historyId)
{
$this->historyId = $historyId;
}
/**
* @return string
*/
public function getHistoryId()
{
return $this->historyId;
}
/**
* @param string
*/
public function setId($id)
{
$this->id = $id;
}
/**
* @return string
*/
public function getId()
{
return $this->id;
}
/**
* @param Message[]
*/
public function setMessages($messages)
{
$this->messages = $messages;
}
/**
* @return Message[]
*/
public function getMessages()
{
return $this->messages;
}
/**
* @param string
*/
public function setSnippet($snippet)
{
$this->snippet = $snippet;
}
/**
* @return string
*/
public function getSnippet()
{
return $this->snippet;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Thread::class, 'Google_Service_Gmail_Thread');

View File

@@ -0,0 +1,170 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class VacationSettings extends \Google\Model
{
/**
* @var bool
*/
public $enableAutoReply;
/**
* @var string
*/
public $endTime;
/**
* @var string
*/
public $responseBodyHtml;
/**
* @var string
*/
public $responseBodyPlainText;
/**
* @var string
*/
public $responseSubject;
/**
* @var bool
*/
public $restrictToContacts;
/**
* @var bool
*/
public $restrictToDomain;
/**
* @var string
*/
public $startTime;
/**
* @param bool
*/
public function setEnableAutoReply($enableAutoReply)
{
$this->enableAutoReply = $enableAutoReply;
}
/**
* @return bool
*/
public function getEnableAutoReply()
{
return $this->enableAutoReply;
}
/**
* @param string
*/
public function setEndTime($endTime)
{
$this->endTime = $endTime;
}
/**
* @return string
*/
public function getEndTime()
{
return $this->endTime;
}
/**
* @param string
*/
public function setResponseBodyHtml($responseBodyHtml)
{
$this->responseBodyHtml = $responseBodyHtml;
}
/**
* @return string
*/
public function getResponseBodyHtml()
{
return $this->responseBodyHtml;
}
/**
* @param string
*/
public function setResponseBodyPlainText($responseBodyPlainText)
{
$this->responseBodyPlainText = $responseBodyPlainText;
}
/**
* @return string
*/
public function getResponseBodyPlainText()
{
return $this->responseBodyPlainText;
}
/**
* @param string
*/
public function setResponseSubject($responseSubject)
{
$this->responseSubject = $responseSubject;
}
/**
* @return string
*/
public function getResponseSubject()
{
return $this->responseSubject;
}
/**
* @param bool
*/
public function setRestrictToContacts($restrictToContacts)
{
$this->restrictToContacts = $restrictToContacts;
}
/**
* @return bool
*/
public function getRestrictToContacts()
{
return $this->restrictToContacts;
}
/**
* @param bool
*/
public function setRestrictToDomain($restrictToDomain)
{
$this->restrictToDomain = $restrictToDomain;
}
/**
* @return bool
*/
public function getRestrictToDomain()
{
return $this->restrictToDomain;
}
/**
* @param string
*/
public function setStartTime($startTime)
{
$this->startTime = $startTime;
}
/**
* @return string
*/
public function getStartTime()
{
return $this->startTime;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(VacationSettings::class, 'Google_Service_Gmail_VacationSettings');

View File

@@ -0,0 +1,99 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class WatchRequest extends \Google\Collection
{
protected $collection_key = 'labelIds';
/**
* @var string
*/
public $labelFilterAction;
/**
* @var string
*/
public $labelFilterBehavior;
/**
* @var string[]
*/
public $labelIds;
/**
* @var string
*/
public $topicName;
/**
* @param string
*/
public function setLabelFilterAction($labelFilterAction)
{
$this->labelFilterAction = $labelFilterAction;
}
/**
* @return string
*/
public function getLabelFilterAction()
{
return $this->labelFilterAction;
}
/**
* @param string
*/
public function setLabelFilterBehavior($labelFilterBehavior)
{
$this->labelFilterBehavior = $labelFilterBehavior;
}
/**
* @return string
*/
public function getLabelFilterBehavior()
{
return $this->labelFilterBehavior;
}
/**
* @param string[]
*/
public function setLabelIds($labelIds)
{
$this->labelIds = $labelIds;
}
/**
* @return string[]
*/
public function getLabelIds()
{
return $this->labelIds;
}
/**
* @param string
*/
public function setTopicName($topicName)
{
$this->topicName = $topicName;
}
/**
* @return string
*/
public function getTopicName()
{
return $this->topicName;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(WatchRequest::class, 'Google_Service_Gmail_WatchRequest');

View File

@@ -0,0 +1,62 @@
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
namespace Google\Service\Gmail;
class WatchResponse extends \Google\Model
{
/**
* @var string
*/
public $expiration;
/**
* @var string
*/
public $historyId;
/**
* @param string
*/
public function setExpiration($expiration)
{
$this->expiration = $expiration;
}
/**
* @return string
*/
public function getExpiration()
{
return $this->expiration;
}
/**
* @param string
*/
public function setHistoryId($historyId)
{
$this->historyId = $historyId;
}
/**
* @return string
*/
public function getHistoryId()
{
return $this->historyId;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(WatchResponse::class, 'Google_Service_Gmail_WatchResponse');