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\Cloudchannel\Resource;
19
20use Google\Service\Cloudchannel\GoogleCloudChannelV1ListSkusResponse;
21
22/**
23 * The "skus" collection of methods.
24 * Typical usage is:
25 *  <code>
26 *   $cloudchannelService = new Google\Service\Cloudchannel(...);
27 *   $skus = $cloudchannelService->skus;
28 *  </code>
29 */
30class ProductsSkus extends \Google\Service\Resource
31{
32  /**
33   * Lists the SKUs for a product the reseller is authorized to sell. Possible
34   * error codes: * INVALID_ARGUMENT: Required request parameters are missing or
35   * invalid. (skus.listProductsSkus)
36   *
37   * @param string $parent Required. The resource name of the Product to list SKUs
38   * for. Parent uses the format: products/{product_id}. Supports products/- to
39   * retrieve SKUs for all products.
40   * @param array $optParams Optional parameters.
41   *
42   * @opt_param string account Required. Resource name of the reseller. Format:
43   * accounts/{account_id}.
44   * @opt_param string languageCode Optional. The BCP-47 language code. For
45   * example, "en-US". The response will localize in the corresponding language
46   * code, if specified. The default value is "en-US".
47   * @opt_param int pageSize Optional. Requested page size. Server might return
48   * fewer results than requested. If unspecified, returns at most 100 SKUs. The
49   * maximum value is 1000; the server will coerce values above 1000.
50   * @opt_param string pageToken Optional. A token for a page of results other
51   * than the first page. Optional.
52   * @return GoogleCloudChannelV1ListSkusResponse
53   */
54  public function listProductsSkus($parent, $optParams = [])
55  {
56    $params = ['parent' => $parent];
57    $params = array_merge($params, $optParams);
58    return $this->call('list', [$params], GoogleCloudChannelV1ListSkusResponse::class);
59  }
60}
61
62// Adding a class alias for backwards compatibility with the previous class name.
63class_alias(ProductsSkus::class, 'Google_Service_Cloudchannel_Resource_ProductsSkus');
64