DoubleClickBidManager.php 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178
  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. namespace Google\Service;
  18. use Google\Client;
  19. /**
  20. * Service definition for DoubleClickBidManager (v2).
  21. *
  22. * <p>
  23. * DoubleClick Bid Manager API allows users to manage and create campaigns and
  24. * reports.</p>
  25. *
  26. * <p>
  27. * For more information about this service, see the API
  28. * <a href="https://developers.google.com/bid-manager/" target="_blank">Documentation</a>
  29. * </p>
  30. *
  31. * @author Google, Inc.
  32. */
  33. class DoubleClickBidManager extends \Google\Service
  34. {
  35. /** View and manage your reports in DoubleClick Bid Manager. */
  36. const DOUBLECLICKBIDMANAGER =
  37. "https://www.googleapis.com/auth/doubleclickbidmanager";
  38. public $queries;
  39. public $queries_reports;
  40. /**
  41. * Constructs the internal representation of the DoubleClickBidManager
  42. * service.
  43. *
  44. * @param Client|array $clientOrConfig The client used to deliver requests, or a
  45. * config array to pass to a new Client instance.
  46. * @param string $rootUrl The root URL used for requests to the service.
  47. */
  48. public function __construct($clientOrConfig = [], $rootUrl = null)
  49. {
  50. parent::__construct($clientOrConfig);
  51. $this->rootUrl = $rootUrl ?: 'https://doubleclickbidmanager.googleapis.com/';
  52. $this->servicePath = 'v2/';
  53. $this->batchPath = 'batch';
  54. $this->version = 'v2';
  55. $this->serviceName = 'doubleclickbidmanager';
  56. $this->queries = new DoubleClickBidManager\Resource\Queries(
  57. $this,
  58. $this->serviceName,
  59. 'queries',
  60. [
  61. 'methods' => [
  62. 'create' => [
  63. 'path' => 'queries',
  64. 'httpMethod' => 'POST',
  65. 'parameters' => [],
  66. ],'delete' => [
  67. 'path' => 'queries/{queryId}',
  68. 'httpMethod' => 'DELETE',
  69. 'parameters' => [
  70. 'queryId' => [
  71. 'location' => 'path',
  72. 'type' => 'string',
  73. 'required' => true,
  74. ],
  75. ],
  76. ],'get' => [
  77. 'path' => 'queries/{queryId}',
  78. 'httpMethod' => 'GET',
  79. 'parameters' => [
  80. 'queryId' => [
  81. 'location' => 'path',
  82. 'type' => 'string',
  83. 'required' => true,
  84. ],
  85. ],
  86. ],'list' => [
  87. 'path' => 'queries',
  88. 'httpMethod' => 'GET',
  89. 'parameters' => [
  90. 'orderBy' => [
  91. 'location' => 'query',
  92. 'type' => 'string',
  93. ],
  94. 'pageSize' => [
  95. 'location' => 'query',
  96. 'type' => 'integer',
  97. ],
  98. 'pageToken' => [
  99. 'location' => 'query',
  100. 'type' => 'string',
  101. ],
  102. ],
  103. ],'run' => [
  104. 'path' => 'queries/{queryId}:run',
  105. 'httpMethod' => 'POST',
  106. 'parameters' => [
  107. 'queryId' => [
  108. 'location' => 'path',
  109. 'type' => 'string',
  110. 'required' => true,
  111. ],
  112. 'synchronous' => [
  113. 'location' => 'query',
  114. 'type' => 'boolean',
  115. ],
  116. ],
  117. ],
  118. ]
  119. ]
  120. );
  121. $this->queries_reports = new DoubleClickBidManager\Resource\QueriesReports(
  122. $this,
  123. $this->serviceName,
  124. 'reports',
  125. [
  126. 'methods' => [
  127. 'get' => [
  128. 'path' => 'queries/{queryId}/reports/{reportId}',
  129. 'httpMethod' => 'GET',
  130. 'parameters' => [
  131. 'queryId' => [
  132. 'location' => 'path',
  133. 'type' => 'string',
  134. 'required' => true,
  135. ],
  136. 'reportId' => [
  137. 'location' => 'path',
  138. 'type' => 'string',
  139. 'required' => true,
  140. ],
  141. ],
  142. ],'list' => [
  143. 'path' => 'queries/{queryId}/reports',
  144. 'httpMethod' => 'GET',
  145. 'parameters' => [
  146. 'queryId' => [
  147. 'location' => 'path',
  148. 'type' => 'string',
  149. 'required' => true,
  150. ],
  151. 'orderBy' => [
  152. 'location' => 'query',
  153. 'type' => 'string',
  154. ],
  155. 'pageSize' => [
  156. 'location' => 'query',
  157. 'type' => 'integer',
  158. ],
  159. 'pageToken' => [
  160. 'location' => 'query',
  161. 'type' => 'string',
  162. ],
  163. ],
  164. ],
  165. ]
  166. ]
  167. );
  168. }
  169. }
  170. // Adding a class alias for backwards compatibility with the previous class name.
  171. class_alias(DoubleClickBidManager::class, 'Google_Service_DoubleClickBidManager');