Initial commit

This commit is contained in:
Local Administrator
2025-04-18 10:32:42 +02:00
commit b83134aca3
29643 changed files with 3045897 additions and 0 deletions

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\MyBusinessAccountManagement;
class AcceptInvitationRequest extends \Google\Model
{
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(AcceptInvitationRequest::class, 'Google_Service_MyBusinessAccountManagement_AcceptInvitationRequest');

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\MyBusinessAccountManagement;
class Account extends \Google\Model
{
/**
* @var string
*/
public $accountName;
/**
* @var string
*/
public $accountNumber;
/**
* @var string
*/
public $name;
protected $organizationInfoType = OrganizationInfo::class;
protected $organizationInfoDataType = '';
/**
* @var string
*/
public $permissionLevel;
/**
* @var string
*/
public $primaryOwner;
/**
* @var string
*/
public $role;
/**
* @var string
*/
public $type;
/**
* @var string
*/
public $verificationState;
/**
* @var string
*/
public $vettedState;
/**
* @param string
*/
public function setAccountName($accountName)
{
$this->accountName = $accountName;
}
/**
* @return string
*/
public function getAccountName()
{
return $this->accountName;
}
/**
* @param string
*/
public function setAccountNumber($accountNumber)
{
$this->accountNumber = $accountNumber;
}
/**
* @return string
*/
public function getAccountNumber()
{
return $this->accountNumber;
}
/**
* @param string
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* @param OrganizationInfo
*/
public function setOrganizationInfo(OrganizationInfo $organizationInfo)
{
$this->organizationInfo = $organizationInfo;
}
/**
* @return OrganizationInfo
*/
public function getOrganizationInfo()
{
return $this->organizationInfo;
}
/**
* @param string
*/
public function setPermissionLevel($permissionLevel)
{
$this->permissionLevel = $permissionLevel;
}
/**
* @return string
*/
public function getPermissionLevel()
{
return $this->permissionLevel;
}
/**
* @param string
*/
public function setPrimaryOwner($primaryOwner)
{
$this->primaryOwner = $primaryOwner;
}
/**
* @return string
*/
public function getPrimaryOwner()
{
return $this->primaryOwner;
}
/**
* @param string
*/
public function setRole($role)
{
$this->role = $role;
}
/**
* @return string
*/
public function getRole()
{
return $this->role;
}
/**
* @param string
*/
public function setType($type)
{
$this->type = $type;
}
/**
* @return string
*/
public function getType()
{
return $this->type;
}
/**
* @param string
*/
public function setVerificationState($verificationState)
{
$this->verificationState = $verificationState;
}
/**
* @return string
*/
public function getVerificationState()
{
return $this->verificationState;
}
/**
* @param string
*/
public function setVettedState($vettedState)
{
$this->vettedState = $vettedState;
}
/**
* @return string
*/
public function getVettedState()
{
return $this->vettedState;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Account::class, 'Google_Service_MyBusinessAccountManagement_Account');

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\MyBusinessAccountManagement;
class Admin extends \Google\Model
{
/**
* @var string
*/
public $account;
/**
* @var string
*/
public $admin;
/**
* @var string
*/
public $name;
/**
* @var bool
*/
public $pendingInvitation;
/**
* @var string
*/
public $role;
/**
* @param string
*/
public function setAccount($account)
{
$this->account = $account;
}
/**
* @return string
*/
public function getAccount()
{
return $this->account;
}
/**
* @param string
*/
public function setAdmin($admin)
{
$this->admin = $admin;
}
/**
* @return string
*/
public function getAdmin()
{
return $this->admin;
}
/**
* @param string
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* @param bool
*/
public function setPendingInvitation($pendingInvitation)
{
$this->pendingInvitation = $pendingInvitation;
}
/**
* @return bool
*/
public function getPendingInvitation()
{
return $this->pendingInvitation;
}
/**
* @param string
*/
public function setRole($role)
{
$this->role = $role;
}
/**
* @return string
*/
public function getRole()
{
return $this->role;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Admin::class, 'Google_Service_MyBusinessAccountManagement_Admin');

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\MyBusinessAccountManagement;
class DeclineInvitationRequest extends \Google\Model
{
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(DeclineInvitationRequest::class, 'Google_Service_MyBusinessAccountManagement_DeclineInvitationRequest');

View File

@@ -0,0 +1,112 @@
<?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\MyBusinessAccountManagement;
class Invitation extends \Google\Model
{
/**
* @var string
*/
public $name;
/**
* @var string
*/
public $role;
protected $targetAccountType = Account::class;
protected $targetAccountDataType = '';
protected $targetLocationType = TargetLocation::class;
protected $targetLocationDataType = '';
/**
* @var string
*/
public $targetType;
/**
* @param string
*/
public function setName($name)
{
$this->name = $name;
}
/**
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* @param string
*/
public function setRole($role)
{
$this->role = $role;
}
/**
* @return string
*/
public function getRole()
{
return $this->role;
}
/**
* @param Account
*/
public function setTargetAccount(Account $targetAccount)
{
$this->targetAccount = $targetAccount;
}
/**
* @return Account
*/
public function getTargetAccount()
{
return $this->targetAccount;
}
/**
* @param TargetLocation
*/
public function setTargetLocation(TargetLocation $targetLocation)
{
$this->targetLocation = $targetLocation;
}
/**
* @return TargetLocation
*/
public function getTargetLocation()
{
return $this->targetLocation;
}
/**
* @param string
*/
public function setTargetType($targetType)
{
$this->targetType = $targetType;
}
/**
* @return string
*/
public function getTargetType()
{
return $this->targetType;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Invitation::class, 'Google_Service_MyBusinessAccountManagement_Invitation');

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\MyBusinessAccountManagement;
class ListAccountAdminsResponse extends \Google\Collection
{
protected $collection_key = 'accountAdmins';
protected $accountAdminsType = Admin::class;
protected $accountAdminsDataType = 'array';
/**
* @param Admin[]
*/
public function setAccountAdmins($accountAdmins)
{
$this->accountAdmins = $accountAdmins;
}
/**
* @return Admin[]
*/
public function getAccountAdmins()
{
return $this->accountAdmins;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListAccountAdminsResponse::class, 'Google_Service_MyBusinessAccountManagement_ListAccountAdminsResponse');

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\MyBusinessAccountManagement;
class ListAccountsResponse extends \Google\Collection
{
protected $collection_key = 'accounts';
protected $accountsType = Account::class;
protected $accountsDataType = 'array';
/**
* @var string
*/
public $nextPageToken;
/**
* @param Account[]
*/
public function setAccounts($accounts)
{
$this->accounts = $accounts;
}
/**
* @return Account[]
*/
public function getAccounts()
{
return $this->accounts;
}
/**
* @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(ListAccountsResponse::class, 'Google_Service_MyBusinessAccountManagement_ListAccountsResponse');

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\MyBusinessAccountManagement;
class ListInvitationsResponse extends \Google\Collection
{
protected $collection_key = 'invitations';
protected $invitationsType = Invitation::class;
protected $invitationsDataType = 'array';
/**
* @param Invitation[]
*/
public function setInvitations($invitations)
{
$this->invitations = $invitations;
}
/**
* @return Invitation[]
*/
public function getInvitations()
{
return $this->invitations;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListInvitationsResponse::class, 'Google_Service_MyBusinessAccountManagement_ListInvitationsResponse');

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\MyBusinessAccountManagement;
class ListLocationAdminsResponse extends \Google\Collection
{
protected $collection_key = 'admins';
protected $adminsType = Admin::class;
protected $adminsDataType = 'array';
/**
* @param Admin[]
*/
public function setAdmins($admins)
{
$this->admins = $admins;
}
/**
* @return Admin[]
*/
public function getAdmins()
{
return $this->admins;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(ListLocationAdminsResponse::class, 'Google_Service_MyBusinessAccountManagement_ListLocationAdminsResponse');

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\MyBusinessAccountManagement;
class MybusinessaccountmanagementEmpty extends \Google\Model
{
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(MybusinessaccountmanagementEmpty::class, 'Google_Service_MyBusinessAccountManagement_MybusinessaccountmanagementEmpty');

View File

@@ -0,0 +1,78 @@
<?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\MyBusinessAccountManagement;
class OrganizationInfo extends \Google\Model
{
protected $addressType = PostalAddress::class;
protected $addressDataType = '';
/**
* @var string
*/
public $phoneNumber;
/**
* @var string
*/
public $registeredDomain;
/**
* @param PostalAddress
*/
public function setAddress(PostalAddress $address)
{
$this->address = $address;
}
/**
* @return PostalAddress
*/
public function getAddress()
{
return $this->address;
}
/**
* @param string
*/
public function setPhoneNumber($phoneNumber)
{
$this->phoneNumber = $phoneNumber;
}
/**
* @return string
*/
public function getPhoneNumber()
{
return $this->phoneNumber;
}
/**
* @param string
*/
public function setRegisteredDomain($registeredDomain)
{
$this->registeredDomain = $registeredDomain;
}
/**
* @return string
*/
public function getRegisteredDomain()
{
return $this->registeredDomain;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(OrganizationInfo::class, 'Google_Service_MyBusinessAccountManagement_OrganizationInfo');

View File

@@ -0,0 +1,225 @@
<?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\MyBusinessAccountManagement;
class PostalAddress extends \Google\Collection
{
protected $collection_key = 'recipients';
/**
* @var string[]
*/
public $addressLines;
/**
* @var string
*/
public $administrativeArea;
/**
* @var string
*/
public $languageCode;
/**
* @var string
*/
public $locality;
/**
* @var string
*/
public $organization;
/**
* @var string
*/
public $postalCode;
/**
* @var string[]
*/
public $recipients;
/**
* @var string
*/
public $regionCode;
/**
* @var int
*/
public $revision;
/**
* @var string
*/
public $sortingCode;
/**
* @var string
*/
public $sublocality;
/**
* @param string[]
*/
public function setAddressLines($addressLines)
{
$this->addressLines = $addressLines;
}
/**
* @return string[]
*/
public function getAddressLines()
{
return $this->addressLines;
}
/**
* @param string
*/
public function setAdministrativeArea($administrativeArea)
{
$this->administrativeArea = $administrativeArea;
}
/**
* @return string
*/
public function getAdministrativeArea()
{
return $this->administrativeArea;
}
/**
* @param string
*/
public function setLanguageCode($languageCode)
{
$this->languageCode = $languageCode;
}
/**
* @return string
*/
public function getLanguageCode()
{
return $this->languageCode;
}
/**
* @param string
*/
public function setLocality($locality)
{
$this->locality = $locality;
}
/**
* @return string
*/
public function getLocality()
{
return $this->locality;
}
/**
* @param string
*/
public function setOrganization($organization)
{
$this->organization = $organization;
}
/**
* @return string
*/
public function getOrganization()
{
return $this->organization;
}
/**
* @param string
*/
public function setPostalCode($postalCode)
{
$this->postalCode = $postalCode;
}
/**
* @return string
*/
public function getPostalCode()
{
return $this->postalCode;
}
/**
* @param string[]
*/
public function setRecipients($recipients)
{
$this->recipients = $recipients;
}
/**
* @return string[]
*/
public function getRecipients()
{
return $this->recipients;
}
/**
* @param string
*/
public function setRegionCode($regionCode)
{
$this->regionCode = $regionCode;
}
/**
* @return string
*/
public function getRegionCode()
{
return $this->regionCode;
}
/**
* @param int
*/
public function setRevision($revision)
{
$this->revision = $revision;
}
/**
* @return int
*/
public function getRevision()
{
return $this->revision;
}
/**
* @param string
*/
public function setSortingCode($sortingCode)
{
$this->sortingCode = $sortingCode;
}
/**
* @return string
*/
public function getSortingCode()
{
return $this->sortingCode;
}
/**
* @param string
*/
public function setSublocality($sublocality)
{
$this->sublocality = $sublocality;
}
/**
* @return string
*/
public function getSublocality()
{
return $this->sublocality;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(PostalAddress::class, 'Google_Service_MyBusinessAccountManagement_PostalAddress');

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\MyBusinessAccountManagement\Resource;
use Google\Service\MyBusinessAccountManagement\Account;
use Google\Service\MyBusinessAccountManagement\ListAccountsResponse;
/**
* The "accounts" collection of methods.
* Typical usage is:
* <code>
* $mybusinessaccountmanagementService = new Google\Service\MyBusinessAccountManagement(...);
* $accounts = $mybusinessaccountmanagementService->accounts;
* </code>
*/
class Accounts extends \Google\Service\Resource
{
/**
* Creates an account with the specified name and type under the given parent. -
* Personal accounts and Organizations cannot be created. - User Groups cannot
* be created with a Personal account as primary owner. - Location Groups cannot
* be created with a primary owner of a Personal account if the Personal account
* is in an Organization. - Location Groups cannot own Location Groups.
* (accounts.create)
*
* @param Account $postBody
* @param array $optParams Optional parameters.
* @return Account
* @throws \Google\Service\Exception
*/
public function create(Account $postBody, $optParams = [])
{
$params = ['postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], Account::class);
}
/**
* Gets the specified account. Returns `NOT_FOUND` if the account does not exist
* or if the caller does not have access rights to it. (accounts.get)
*
* @param string $name Required. The name of the account to fetch.
* @param array $optParams Optional parameters.
* @return Account
* @throws \Google\Service\Exception
*/
public function get($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('get', [$params], Account::class);
}
/**
* Lists all of the accounts for the authenticated user. This includes all
* accounts that the user owns, as well as any accounts for which the user has
* management rights. (accounts.listAccounts)
*
* @param array $optParams Optional parameters.
*
* @opt_param string filter Optional. A filter constraining the accounts to
* return. The response includes only entries that match the filter. If `filter`
* is empty, then no constraints are applied and all accounts (paginated) are
* retrieved for the requested account. For example, a request with the filter
* `type=USER_GROUP` will only return user groups. The `type` field is the only
* supported filter.
* @opt_param int pageSize Optional. How many accounts to fetch per page. The
* default and maximum is 20.
* @opt_param string pageToken Optional. If specified, the next page of accounts
* is retrieved. The `pageToken` is returned when a call to `accounts.list`
* returns more results than can fit into the requested page size.
* @opt_param string parentAccount Optional. The resource name of the account
* for which the list of directly accessible accounts is to be retrieved. This
* only makes sense for Organizations and User Groups. If empty, will return
* `ListAccounts` for the authenticated user. `accounts/{account_id}`.
* @return ListAccountsResponse
* @throws \Google\Service\Exception
*/
public function listAccounts($optParams = [])
{
$params = [];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListAccountsResponse::class);
}
/**
* Updates the specified business account. Personal accounts cannot be updated
* using this method. (accounts.patch)
*
* @param string $name Immutable. The resource name, in the format
* `accounts/{account_id}`.
* @param Account $postBody
* @param array $optParams Optional parameters.
*
* @opt_param string updateMask Required. The specific fields that should be
* updated. The only editable field is `accountName`.
* @opt_param bool validateOnly Optional. If true, the request is validated
* without actually updating the account.
* @return Account
* @throws \Google\Service\Exception
*/
public function patch($name, Account $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('patch', [$params], Account::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Accounts::class, 'Google_Service_MyBusinessAccountManagement_Resource_Accounts');

View File

@@ -0,0 +1,107 @@
<?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\MyBusinessAccountManagement\Resource;
use Google\Service\MyBusinessAccountManagement\Admin;
use Google\Service\MyBusinessAccountManagement\ListAccountAdminsResponse;
use Google\Service\MyBusinessAccountManagement\MybusinessaccountmanagementEmpty;
/**
* The "admins" collection of methods.
* Typical usage is:
* <code>
* $mybusinessaccountmanagementService = new Google\Service\MyBusinessAccountManagement(...);
* $admins = $mybusinessaccountmanagementService->accounts_admins;
* </code>
*/
class AccountsAdmins extends \Google\Service\Resource
{
/**
* Invites the specified user to become an administrator for the specified
* account. The invitee must accept the invitation in order to be granted access
* to the account. See AcceptInvitation to programmatically accept an
* invitation. (admins.create)
*
* @param string $parent Required. The resource name of the account this admin
* is created for. `accounts/{account_id}`.
* @param Admin $postBody
* @param array $optParams Optional parameters.
* @return Admin
* @throws \Google\Service\Exception
*/
public function create($parent, Admin $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], Admin::class);
}
/**
* Removes the specified admin from the specified account. (admins.delete)
*
* @param string $name Required. The resource name of the admin to remove from
* the account. `accounts/{account_id}/admins/{admin_id}`.
* @param array $optParams Optional parameters.
* @return MybusinessaccountmanagementEmpty
* @throws \Google\Service\Exception
*/
public function delete($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params], MybusinessaccountmanagementEmpty::class);
}
/**
* Lists the admins for the specified account. (admins.listAccountsAdmins)
*
* @param string $parent Required. The name of the account from which to
* retrieve a list of admins. `accounts/{account_id}/admins`.
* @param array $optParams Optional parameters.
* @return ListAccountAdminsResponse
* @throws \Google\Service\Exception
*/
public function listAccountsAdmins($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListAccountAdminsResponse::class);
}
/**
* Updates the Admin for the specified Account Admin. (admins.patch)
*
* @param string $name Immutable. The resource name. For account admins, this is
* in the form: `accounts/{account_id}/admins/{admin_id}` For location admins,
* this is in the form: `locations/{location_id}/admins/{admin_id}` This field
* will be ignored if set during admin creation.
* @param Admin $postBody
* @param array $optParams Optional parameters.
*
* @opt_param string updateMask Required. The specific fields that should be
* updated. The only editable field is role.
* @return Admin
* @throws \Google\Service\Exception
*/
public function patch($name, Admin $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('patch', [$params], Admin::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(AccountsAdmins::class, 'Google_Service_MyBusinessAccountManagement_Resource_AccountsAdmins');

View File

@@ -0,0 +1,89 @@
<?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\MyBusinessAccountManagement\Resource;
use Google\Service\MyBusinessAccountManagement\AcceptInvitationRequest;
use Google\Service\MyBusinessAccountManagement\DeclineInvitationRequest;
use Google\Service\MyBusinessAccountManagement\ListInvitationsResponse;
use Google\Service\MyBusinessAccountManagement\MybusinessaccountmanagementEmpty;
/**
* The "invitations" collection of methods.
* Typical usage is:
* <code>
* $mybusinessaccountmanagementService = new Google\Service\MyBusinessAccountManagement(...);
* $invitations = $mybusinessaccountmanagementService->accounts_invitations;
* </code>
*/
class AccountsInvitations extends \Google\Service\Resource
{
/**
* Accepts the specified invitation. (invitations.accept)
*
* @param string $name Required. The name of the invitation that is being
* accepted. `accounts/{account_id}/invitations/{invitation_id}`
* @param AcceptInvitationRequest $postBody
* @param array $optParams Optional parameters.
* @return MybusinessaccountmanagementEmpty
* @throws \Google\Service\Exception
*/
public function accept($name, AcceptInvitationRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('accept', [$params], MybusinessaccountmanagementEmpty::class);
}
/**
* Declines the specified invitation. (invitations.decline)
*
* @param string $name Required. The name of the account invitation that is
* being declined. `accounts/{account_id}/invitations/{invitation_id}`
* @param DeclineInvitationRequest $postBody
* @param array $optParams Optional parameters.
* @return MybusinessaccountmanagementEmpty
* @throws \Google\Service\Exception
*/
public function decline($name, DeclineInvitationRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('decline', [$params], MybusinessaccountmanagementEmpty::class);
}
/**
* Lists pending invitations for the specified account.
* (invitations.listAccountsInvitations)
*
* @param string $parent Required. The name of the account from which the list
* of invitations is being retrieved. `accounts/{account_id}/invitations`
* @param array $optParams Optional parameters.
*
* @opt_param string filter Optional. Filtering the response is supported via
* the Invitation.target_type field.
* @return ListInvitationsResponse
* @throws \Google\Service\Exception
*/
public function listAccountsInvitations($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListInvitationsResponse::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(AccountsInvitations::class, 'Google_Service_MyBusinessAccountManagement_Resource_AccountsInvitations');

View File

@@ -0,0 +1,55 @@
<?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\MyBusinessAccountManagement\Resource;
use Google\Service\MyBusinessAccountManagement\MybusinessaccountmanagementEmpty;
use Google\Service\MyBusinessAccountManagement\TransferLocationRequest;
/**
* The "locations" collection of methods.
* Typical usage is:
* <code>
* $mybusinessaccountmanagementService = new Google\Service\MyBusinessAccountManagement(...);
* $locations = $mybusinessaccountmanagementService->locations;
* </code>
*/
class Locations extends \Google\Service\Resource
{
/**
* Moves a location from an account that the user owns to another account that
* the same user administers. The user must be an owner of the account the
* location is currently associated with and must also be at least a manager of
* the destination account. (locations.transfer)
*
* @param string $name Required. The name of the location to transfer.
* `locations/{location_id}`.
* @param TransferLocationRequest $postBody
* @param array $optParams Optional parameters.
* @return MybusinessaccountmanagementEmpty
* @throws \Google\Service\Exception
*/
public function transfer($name, TransferLocationRequest $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('transfer', [$params], MybusinessaccountmanagementEmpty::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Locations::class, 'Google_Service_MyBusinessAccountManagement_Resource_Locations');

View File

@@ -0,0 +1,110 @@
<?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\MyBusinessAccountManagement\Resource;
use Google\Service\MyBusinessAccountManagement\Admin;
use Google\Service\MyBusinessAccountManagement\ListLocationAdminsResponse;
use Google\Service\MyBusinessAccountManagement\MybusinessaccountmanagementEmpty;
/**
* The "admins" collection of methods.
* Typical usage is:
* <code>
* $mybusinessaccountmanagementService = new Google\Service\MyBusinessAccountManagement(...);
* $admins = $mybusinessaccountmanagementService->locations_admins;
* </code>
*/
class LocationsAdmins extends \Google\Service\Resource
{
/**
* Invites the specified user to become an administrator for the specified
* location. The invitee must accept the invitation in order to be granted
* access to the location. See AcceptInvitation to programmatically accept an
* invitation. (admins.create)
*
* @param string $parent Required. The resource name of the location this admin
* is created for. `locations/{location_id}/admins`.
* @param Admin $postBody
* @param array $optParams Optional parameters.
* @return Admin
* @throws \Google\Service\Exception
*/
public function create($parent, Admin $postBody, $optParams = [])
{
$params = ['parent' => $parent, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('create', [$params], Admin::class);
}
/**
* Removes the specified admin as a manager of the specified location.
* (admins.delete)
*
* @param string $name Required. The resource name of the admin to remove from
* the location.
* @param array $optParams Optional parameters.
* @return MybusinessaccountmanagementEmpty
* @throws \Google\Service\Exception
*/
public function delete($name, $optParams = [])
{
$params = ['name' => $name];
$params = array_merge($params, $optParams);
return $this->call('delete', [$params], MybusinessaccountmanagementEmpty::class);
}
/**
* Lists all of the admins for the specified location.
* (admins.listLocationsAdmins)
*
* @param string $parent Required. The name of the location to list admins of.
* `locations/{location_id}/admins`.
* @param array $optParams Optional parameters.
* @return ListLocationAdminsResponse
* @throws \Google\Service\Exception
*/
public function listLocationsAdmins($parent, $optParams = [])
{
$params = ['parent' => $parent];
$params = array_merge($params, $optParams);
return $this->call('list', [$params], ListLocationAdminsResponse::class);
}
/**
* Updates the Admin for the specified location. Only the AdminRole of the Admin
* can be updated. (admins.patch)
*
* @param string $name Immutable. The resource name. For account admins, this is
* in the form: `accounts/{account_id}/admins/{admin_id}` For location admins,
* this is in the form: `locations/{location_id}/admins/{admin_id}` This field
* will be ignored if set during admin creation.
* @param Admin $postBody
* @param array $optParams Optional parameters.
*
* @opt_param string updateMask Required. The specific fields that should be
* updated. The only editable field is role.
* @return Admin
* @throws \Google\Service\Exception
*/
public function patch($name, Admin $postBody, $optParams = [])
{
$params = ['name' => $name, 'postBody' => $postBody];
$params = array_merge($params, $optParams);
return $this->call('patch', [$params], Admin::class);
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(LocationsAdmins::class, 'Google_Service_MyBusinessAccountManagement_Resource_LocationsAdmins');

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\MyBusinessAccountManagement;
class TargetLocation extends \Google\Model
{
/**
* @var string
*/
public $address;
/**
* @var string
*/
public $locationName;
/**
* @param string
*/
public function setAddress($address)
{
$this->address = $address;
}
/**
* @return string
*/
public function getAddress()
{
return $this->address;
}
/**
* @param string
*/
public function setLocationName($locationName)
{
$this->locationName = $locationName;
}
/**
* @return string
*/
public function getLocationName()
{
return $this->locationName;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(TargetLocation::class, 'Google_Service_MyBusinessAccountManagement_TargetLocation');

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\MyBusinessAccountManagement;
class TransferLocationRequest extends \Google\Model
{
/**
* @var string
*/
public $destinationAccount;
/**
* @param string
*/
public function setDestinationAccount($destinationAccount)
{
$this->destinationAccount = $destinationAccount;
}
/**
* @return string
*/
public function getDestinationAccount()
{
return $this->destinationAccount;
}
}
// Adding a class alias for backwards compatibility with the previous class name.
class_alias(TransferLocationRequest::class, 'Google_Service_MyBusinessAccountManagement_TransferLocationRequest');