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 |
|
---|
18 | namespace Google\Service\Apigee\Resource;
|
---|
19 |
|
---|
20 | use Google\Service\Apigee\GoogleCloudApigeeV1Attribute;
|
---|
21 | use Google\Service\Apigee\GoogleCloudApigeeV1Attributes;
|
---|
22 |
|
---|
23 | /**
|
---|
24 | * The "attributes" collection of methods.
|
---|
25 | * Typical usage is:
|
---|
26 | * <code>
|
---|
27 | * $apigeeService = new Google\Service\Apigee(...);
|
---|
28 | * $attributes = $apigeeService->organizations_developers_apps_attributes;
|
---|
29 | * </code>
|
---|
30 | */
|
---|
31 | class OrganizationsDevelopersAppsAttributes extends \Google\Service\Resource
|
---|
32 | {
|
---|
33 | /**
|
---|
34 | * Deletes a developer app attribute. (attributes.delete)
|
---|
35 | *
|
---|
36 | * @param string $name Required. Name of the developer app attribute. Use the
|
---|
37 | * following structure in your request: `organizations/{org}/developers/{develop
|
---|
38 | * er_email}/apps/{app}/attributes/{attribute}`
|
---|
39 | * @param array $optParams Optional parameters.
|
---|
40 | * @return GoogleCloudApigeeV1Attribute
|
---|
41 | * @throws \Google\Service\Exception
|
---|
42 | */
|
---|
43 | public function delete($name, $optParams = [])
|
---|
44 | {
|
---|
45 | $params = ['name' => $name];
|
---|
46 | $params = array_merge($params, $optParams);
|
---|
47 | return $this->call('delete', [$params], GoogleCloudApigeeV1Attribute::class);
|
---|
48 | }
|
---|
49 | /**
|
---|
50 | * Returns a developer app attribute. (attributes.get)
|
---|
51 | *
|
---|
52 | * @param string $name Required. Name of the developer app attribute. Use the
|
---|
53 | * following structure in your request: `organizations/{org}/developers/{develop
|
---|
54 | * er_email}/apps/{app}/attributes/{attribute}`
|
---|
55 | * @param array $optParams Optional parameters.
|
---|
56 | * @return GoogleCloudApigeeV1Attribute
|
---|
57 | * @throws \Google\Service\Exception
|
---|
58 | */
|
---|
59 | public function get($name, $optParams = [])
|
---|
60 | {
|
---|
61 | $params = ['name' => $name];
|
---|
62 | $params = array_merge($params, $optParams);
|
---|
63 | return $this->call('get', [$params], GoogleCloudApigeeV1Attribute::class);
|
---|
64 | }
|
---|
65 | /**
|
---|
66 | * Returns a list of all developer app attributes.
|
---|
67 | * (attributes.listOrganizationsDevelopersAppsAttributes)
|
---|
68 | *
|
---|
69 | * @param string $parent Required. Name of the developer app. Use the following
|
---|
70 | * structure in your request:
|
---|
71 | * `organizations/{org}/developers/{developer_email}/apps/{app}`
|
---|
72 | * @param array $optParams Optional parameters.
|
---|
73 | * @return GoogleCloudApigeeV1Attributes
|
---|
74 | * @throws \Google\Service\Exception
|
---|
75 | */
|
---|
76 | public function listOrganizationsDevelopersAppsAttributes($parent, $optParams = [])
|
---|
77 | {
|
---|
78 | $params = ['parent' => $parent];
|
---|
79 | $params = array_merge($params, $optParams);
|
---|
80 | return $this->call('list', [$params], GoogleCloudApigeeV1Attributes::class);
|
---|
81 | }
|
---|
82 | /**
|
---|
83 | * Updates a developer app attribute. **Note**: OAuth access tokens and Key
|
---|
84 | * Management Service (KMS) entities (apps, developers, and API products) are
|
---|
85 | * cached for 180 seconds (current default). Any custom attributes associated
|
---|
86 | * with these entities are cached for at least 180 seconds after the entity is
|
---|
87 | * accessed at runtime. Therefore, an `ExpiresIn` element on the OAuthV2 policy
|
---|
88 | * won't be able to expire an access token in less than 180 seconds.
|
---|
89 | * (attributes.updateDeveloperAppAttribute)
|
---|
90 | *
|
---|
91 | * @param string $name Required. Name of the developer app attribute. Use the
|
---|
92 | * following structure in your request: `organizations/{org}/developers/{develop
|
---|
93 | * er_email}/apps/{app}/attributes/{attribute}`
|
---|
94 | * @param GoogleCloudApigeeV1Attribute $postBody
|
---|
95 | * @param array $optParams Optional parameters.
|
---|
96 | * @return GoogleCloudApigeeV1Attribute
|
---|
97 | * @throws \Google\Service\Exception
|
---|
98 | */
|
---|
99 | public function updateDeveloperAppAttribute($name, GoogleCloudApigeeV1Attribute $postBody, $optParams = [])
|
---|
100 | {
|
---|
101 | $params = ['name' => $name, 'postBody' => $postBody];
|
---|
102 | $params = array_merge($params, $optParams);
|
---|
103 | return $this->call('updateDeveloperAppAttribute', [$params], GoogleCloudApigeeV1Attribute::class);
|
---|
104 | }
|
---|
105 | }
|
---|
106 |
|
---|
107 | // Adding a class alias for backwards compatibility with the previous class name.
|
---|
108 | class_alias(OrganizationsDevelopersAppsAttributes::class, 'Google_Service_Apigee_Resource_OrganizationsDevelopersAppsAttributes');
|
---|