source: vendor/google/apiclient-services/src/ShoppingContent/Resource/Regionalinventory.php

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

Upload project files

  • Property mode set to 100644
File size: 2.9 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\ShoppingContent\Resource;
19
20use Google\Service\ShoppingContent\RegionalInventory as RegionalInventoryModel;
21use Google\Service\ShoppingContent\RegionalinventoryCustomBatchRequest;
22use Google\Service\ShoppingContent\RegionalinventoryCustomBatchResponse;
23
24/**
25 * The "regionalinventory" collection of methods.
26 * Typical usage is:
27 * <code>
28 * $contentService = new Google\Service\ShoppingContent(...);
29 * $regionalinventory = $contentService->regionalinventory;
30 * </code>
31 */
32class Regionalinventory extends \Google\Service\Resource
33{
34 /**
35 * Updates regional inventory for multiple products or regions in a single
36 * request. (regionalinventory.custombatch)
37 *
38 * @param RegionalinventoryCustomBatchRequest $postBody
39 * @param array $optParams Optional parameters.
40 * @return RegionalinventoryCustomBatchResponse
41 * @throws \Google\Service\Exception
42 */
43 public function custombatch(RegionalinventoryCustomBatchRequest $postBody, $optParams = [])
44 {
45 $params = ['postBody' => $postBody];
46 $params = array_merge($params, $optParams);
47 return $this->call('custombatch', [$params], RegionalinventoryCustomBatchResponse::class);
48 }
49 /**
50 * Updates the regional inventory of a product in your Merchant Center account.
51 * If a regional inventory with the same region ID already exists, this method
52 * updates that entry. (regionalinventory.insert)
53 *
54 * @param string $merchantId The ID of the account that contains the product.
55 * This account cannot be a multi-client account.
56 * @param string $productId The REST ID of the product for which to update the
57 * regional inventory.
58 * @param RegionalInventoryModel $postBody
59 * @param array $optParams Optional parameters.
60 * @return RegionalInventoryModel
61 * @throws \Google\Service\Exception
62 */
63 public function insert($merchantId, $productId, RegionalInventoryModel $postBody, $optParams = [])
64 {
65 $params = ['merchantId' => $merchantId, 'productId' => $productId, 'postBody' => $postBody];
66 $params = array_merge($params, $optParams);
67 return $this->call('insert', [$params], RegionalInventoryModel::class);
68 }
69}
70
71// Adding a class alias for backwards compatibility with the previous class name.
72class_alias(Regionalinventory::class, 'Google_Service_ShoppingContent_Resource_Regionalinventory');
Note: See TracBrowser for help on using the repository browser.