source: vendor/google/apiclient-services/src/AdExchangeBuyerII/Resource/AccountsClientsUsers.php

Last change on this file was e3d4e0a, checked in by Vlado 222039 <vlado.popovski@…>, 10 days ago

Upload project files

  • Property mode set to 100644
File size: 4.3 KB
Line 
1<?php
2/*
3 * Copyright 2014 Google Inc.
4 *
5 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
6 * use this file except in compliance with the License. You may obtain a copy of
7 * the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14 * License for the specific language governing permissions and limitations under
15 * the License.
16 */
17
18namespace Google\Service\AdExchangeBuyerII\Resource;
19
20use Google\Service\AdExchangeBuyerII\ClientUser;
21use Google\Service\AdExchangeBuyerII\ListClientUsersResponse;
22
23/**
24 * The "users" collection of methods.
25 * Typical usage is:
26 * <code>
27 * $adexchangebuyer2Service = new Google\Service\AdExchangeBuyerII(...);
28 * $users = $adexchangebuyer2Service->accounts_clients_users;
29 * </code>
30 */
31class AccountsClientsUsers extends \Google\Service\Resource
32{
33 /**
34 * Retrieves an existing client user. (users.get)
35 *
36 * @param string $accountId Numerical account ID of the client's sponsor buyer.
37 * (required)
38 * @param string $clientAccountId Numerical account ID of the client buyer that
39 * the user to be retrieved is associated with. (required)
40 * @param string $userId Numerical identifier of the user to retrieve.
41 * (required)
42 * @param array $optParams Optional parameters.
43 * @return ClientUser
44 * @throws \Google\Service\Exception
45 */
46 public function get($accountId, $clientAccountId, $userId, $optParams = [])
47 {
48 $params = ['accountId' => $accountId, 'clientAccountId' => $clientAccountId, 'userId' => $userId];
49 $params = array_merge($params, $optParams);
50 return $this->call('get', [$params], ClientUser::class);
51 }
52 /**
53 * Lists all the known client users for a specified sponsor buyer account ID.
54 * (users.listAccountsClientsUsers)
55 *
56 * @param string $accountId Numerical account ID of the sponsor buyer of the
57 * client to list users for. (required)
58 * @param string $clientAccountId The account ID of the client buyer to list
59 * users for. (required) You must specify either a string representation of a
60 * numerical account identifier or the `-` character to list all the client
61 * users for all the clients of a given sponsor buyer.
62 * @param array $optParams Optional parameters.
63 *
64 * @opt_param int pageSize Requested page size. The server may return fewer
65 * clients than requested. If unspecified, the server will pick an appropriate
66 * default.
67 * @opt_param string pageToken A token identifying a page of results the server
68 * should return. Typically, this is the value of
69 * ListClientUsersResponse.nextPageToken returned from the previous call to the
70 * accounts.clients.users.list method.
71 * @return ListClientUsersResponse
72 * @throws \Google\Service\Exception
73 */
74 public function listAccountsClientsUsers($accountId, $clientAccountId, $optParams = [])
75 {
76 $params = ['accountId' => $accountId, 'clientAccountId' => $clientAccountId];
77 $params = array_merge($params, $optParams);
78 return $this->call('list', [$params], ListClientUsersResponse::class);
79 }
80 /**
81 * Updates an existing client user. Only the user status can be changed on
82 * update. (users.update)
83 *
84 * @param string $accountId Numerical account ID of the client's sponsor buyer.
85 * (required)
86 * @param string $clientAccountId Numerical account ID of the client buyer that
87 * the user to be retrieved is associated with. (required)
88 * @param string $userId Numerical identifier of the user to retrieve.
89 * (required)
90 * @param ClientUser $postBody
91 * @param array $optParams Optional parameters.
92 * @return ClientUser
93 * @throws \Google\Service\Exception
94 */
95 public function update($accountId, $clientAccountId, $userId, ClientUser $postBody, $optParams = [])
96 {
97 $params = ['accountId' => $accountId, 'clientAccountId' => $clientAccountId, 'userId' => $userId, 'postBody' => $postBody];
98 $params = array_merge($params, $optParams);
99 return $this->call('update', [$params], ClientUser::class);
100 }
101}
102
103// Adding a class alias for backwards compatibility with the previous class name.
104class_alias(AccountsClientsUsers::class, 'Google_Service_AdExchangeBuyerII_Resource_AccountsClientsUsers');
Note: See TracBrowser for help on using the repository browser.