Datapipelines.php 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200
  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 Datapipelines (v1).
  21. *
  22. * <p>
  23. * Data Pipelines provides an interface for creating, updating, and managing
  24. * recurring Data Analytics jobs.</p>
  25. *
  26. * <p>
  27. * For more information about this service, see the API
  28. * <a href="https://cloud.google.com/dataflow/docs/guides/data-pipelines" target="_blank">Documentation</a>
  29. * </p>
  30. *
  31. * @author Google, Inc.
  32. */
  33. class Datapipelines extends \Google\Service
  34. {
  35. /** See, edit, configure, and delete your Google Cloud data and see the email address for your Google Account.. */
  36. const CLOUD_PLATFORM =
  37. "https://www.googleapis.com/auth/cloud-platform";
  38. public $projects_locations;
  39. public $projects_locations_pipelines;
  40. public $projects_locations_pipelines_jobs;
  41. /**
  42. * Constructs the internal representation of the Datapipelines 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://datapipelines.googleapis.com/';
  52. $this->servicePath = '';
  53. $this->batchPath = 'batch';
  54. $this->version = 'v1';
  55. $this->serviceName = 'datapipelines';
  56. $this->projects_locations = new Datapipelines\Resource\ProjectsLocations(
  57. $this,
  58. $this->serviceName,
  59. 'locations',
  60. [
  61. 'methods' => [
  62. 'listPipelines' => [
  63. 'path' => 'v1/{+parent}',
  64. 'httpMethod' => 'GET',
  65. 'parameters' => [
  66. 'parent' => [
  67. 'location' => 'path',
  68. 'type' => 'string',
  69. 'required' => true,
  70. ],
  71. 'filter' => [
  72. 'location' => 'query',
  73. 'type' => 'string',
  74. ],
  75. 'pageSize' => [
  76. 'location' => 'query',
  77. 'type' => 'integer',
  78. ],
  79. 'pageToken' => [
  80. 'location' => 'query',
  81. 'type' => 'string',
  82. ],
  83. ],
  84. ],
  85. ]
  86. ]
  87. );
  88. $this->projects_locations_pipelines = new Datapipelines\Resource\ProjectsLocationsPipelines(
  89. $this,
  90. $this->serviceName,
  91. 'pipelines',
  92. [
  93. 'methods' => [
  94. 'create' => [
  95. 'path' => 'v1/{+parent}/pipelines',
  96. 'httpMethod' => 'POST',
  97. 'parameters' => [
  98. 'parent' => [
  99. 'location' => 'path',
  100. 'type' => 'string',
  101. 'required' => true,
  102. ],
  103. ],
  104. ],'delete' => [
  105. 'path' => 'v1/{+name}',
  106. 'httpMethod' => 'DELETE',
  107. 'parameters' => [
  108. 'name' => [
  109. 'location' => 'path',
  110. 'type' => 'string',
  111. 'required' => true,
  112. ],
  113. ],
  114. ],'get' => [
  115. 'path' => 'v1/{+name}',
  116. 'httpMethod' => 'GET',
  117. 'parameters' => [
  118. 'name' => [
  119. 'location' => 'path',
  120. 'type' => 'string',
  121. 'required' => true,
  122. ],
  123. ],
  124. ],'patch' => [
  125. 'path' => 'v1/{+name}',
  126. 'httpMethod' => 'PATCH',
  127. 'parameters' => [
  128. 'name' => [
  129. 'location' => 'path',
  130. 'type' => 'string',
  131. 'required' => true,
  132. ],
  133. 'updateMask' => [
  134. 'location' => 'query',
  135. 'type' => 'string',
  136. ],
  137. ],
  138. ],'run' => [
  139. 'path' => 'v1/{+name}:run',
  140. 'httpMethod' => 'POST',
  141. 'parameters' => [
  142. 'name' => [
  143. 'location' => 'path',
  144. 'type' => 'string',
  145. 'required' => true,
  146. ],
  147. ],
  148. ],'stop' => [
  149. 'path' => 'v1/{+name}:stop',
  150. 'httpMethod' => 'POST',
  151. 'parameters' => [
  152. 'name' => [
  153. 'location' => 'path',
  154. 'type' => 'string',
  155. 'required' => true,
  156. ],
  157. ],
  158. ],
  159. ]
  160. ]
  161. );
  162. $this->projects_locations_pipelines_jobs = new Datapipelines\Resource\ProjectsLocationsPipelinesJobs(
  163. $this,
  164. $this->serviceName,
  165. 'jobs',
  166. [
  167. 'methods' => [
  168. 'list' => [
  169. 'path' => 'v1/{+parent}/jobs',
  170. 'httpMethod' => 'GET',
  171. 'parameters' => [
  172. 'parent' => [
  173. 'location' => 'path',
  174. 'type' => 'string',
  175. 'required' => true,
  176. ],
  177. 'pageSize' => [
  178. 'location' => 'query',
  179. 'type' => 'integer',
  180. ],
  181. 'pageToken' => [
  182. 'location' => 'query',
  183. 'type' => 'string',
  184. ],
  185. ],
  186. ],
  187. ]
  188. ]
  189. );
  190. }
  191. }
  192. // Adding a class alias for backwards compatibility with the previous class name.
  193. class_alias(Datapipelines::class, 'Google_Service_Datapipelines');