Recommender.php 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566
  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 Recommender (v1).
  21. *
  22. * <p>
  23. </p>
  24. *
  25. * <p>
  26. * For more information about this service, see the API
  27. * <a href="https://cloud.google.com/recommender/docs/" target="_blank">Documentation</a>
  28. * </p>
  29. *
  30. * @author Google, Inc.
  31. */
  32. class Recommender extends \Google\Service
  33. {
  34. /** See, edit, configure, and delete your Google Cloud data and see the email address for your Google Account.. */
  35. const CLOUD_PLATFORM =
  36. "https://www.googleapis.com/auth/cloud-platform";
  37. public $billingAccounts_locations_insightTypes_insights;
  38. public $billingAccounts_locations_recommenders_recommendations;
  39. public $folders_locations_insightTypes_insights;
  40. public $folders_locations_recommenders_recommendations;
  41. public $organizations_locations_insightTypes_insights;
  42. public $organizations_locations_recommenders_recommendations;
  43. public $projects_locations_insightTypes_insights;
  44. public $projects_locations_recommenders_recommendations;
  45. /**
  46. * Constructs the internal representation of the Recommender service.
  47. *
  48. * @param Client|array $clientOrConfig The client used to deliver requests, or a
  49. * config array to pass to a new Client instance.
  50. * @param string $rootUrl The root URL used for requests to the service.
  51. */
  52. public function __construct($clientOrConfig = [], $rootUrl = null)
  53. {
  54. parent::__construct($clientOrConfig);
  55. $this->rootUrl = $rootUrl ?: 'https://recommender.googleapis.com/';
  56. $this->servicePath = '';
  57. $this->batchPath = 'batch';
  58. $this->version = 'v1';
  59. $this->serviceName = 'recommender';
  60. $this->billingAccounts_locations_insightTypes_insights = new Recommender\Resource\BillingAccountsLocationsInsightTypesInsights(
  61. $this,
  62. $this->serviceName,
  63. 'insights',
  64. [
  65. 'methods' => [
  66. 'get' => [
  67. 'path' => 'v1/{+name}',
  68. 'httpMethod' => 'GET',
  69. 'parameters' => [
  70. 'name' => [
  71. 'location' => 'path',
  72. 'type' => 'string',
  73. 'required' => true,
  74. ],
  75. ],
  76. ],'list' => [
  77. 'path' => 'v1/{+parent}/insights',
  78. 'httpMethod' => 'GET',
  79. 'parameters' => [
  80. 'parent' => [
  81. 'location' => 'path',
  82. 'type' => 'string',
  83. 'required' => true,
  84. ],
  85. 'filter' => [
  86. 'location' => 'query',
  87. 'type' => 'string',
  88. ],
  89. 'pageSize' => [
  90. 'location' => 'query',
  91. 'type' => 'integer',
  92. ],
  93. 'pageToken' => [
  94. 'location' => 'query',
  95. 'type' => 'string',
  96. ],
  97. ],
  98. ],'markAccepted' => [
  99. 'path' => 'v1/{+name}:markAccepted',
  100. 'httpMethod' => 'POST',
  101. 'parameters' => [
  102. 'name' => [
  103. 'location' => 'path',
  104. 'type' => 'string',
  105. 'required' => true,
  106. ],
  107. ],
  108. ],
  109. ]
  110. ]
  111. );
  112. $this->billingAccounts_locations_recommenders_recommendations = new Recommender\Resource\BillingAccountsLocationsRecommendersRecommendations(
  113. $this,
  114. $this->serviceName,
  115. 'recommendations',
  116. [
  117. 'methods' => [
  118. 'get' => [
  119. 'path' => 'v1/{+name}',
  120. 'httpMethod' => 'GET',
  121. 'parameters' => [
  122. 'name' => [
  123. 'location' => 'path',
  124. 'type' => 'string',
  125. 'required' => true,
  126. ],
  127. ],
  128. ],'list' => [
  129. 'path' => 'v1/{+parent}/recommendations',
  130. 'httpMethod' => 'GET',
  131. 'parameters' => [
  132. 'parent' => [
  133. 'location' => 'path',
  134. 'type' => 'string',
  135. 'required' => true,
  136. ],
  137. 'filter' => [
  138. 'location' => 'query',
  139. 'type' => 'string',
  140. ],
  141. 'pageSize' => [
  142. 'location' => 'query',
  143. 'type' => 'integer',
  144. ],
  145. 'pageToken' => [
  146. 'location' => 'query',
  147. 'type' => 'string',
  148. ],
  149. ],
  150. ],'markClaimed' => [
  151. 'path' => 'v1/{+name}:markClaimed',
  152. 'httpMethod' => 'POST',
  153. 'parameters' => [
  154. 'name' => [
  155. 'location' => 'path',
  156. 'type' => 'string',
  157. 'required' => true,
  158. ],
  159. ],
  160. ],'markFailed' => [
  161. 'path' => 'v1/{+name}:markFailed',
  162. 'httpMethod' => 'POST',
  163. 'parameters' => [
  164. 'name' => [
  165. 'location' => 'path',
  166. 'type' => 'string',
  167. 'required' => true,
  168. ],
  169. ],
  170. ],'markSucceeded' => [
  171. 'path' => 'v1/{+name}:markSucceeded',
  172. 'httpMethod' => 'POST',
  173. 'parameters' => [
  174. 'name' => [
  175. 'location' => 'path',
  176. 'type' => 'string',
  177. 'required' => true,
  178. ],
  179. ],
  180. ],
  181. ]
  182. ]
  183. );
  184. $this->folders_locations_insightTypes_insights = new Recommender\Resource\FoldersLocationsInsightTypesInsights(
  185. $this,
  186. $this->serviceName,
  187. 'insights',
  188. [
  189. 'methods' => [
  190. 'get' => [
  191. 'path' => 'v1/{+name}',
  192. 'httpMethod' => 'GET',
  193. 'parameters' => [
  194. 'name' => [
  195. 'location' => 'path',
  196. 'type' => 'string',
  197. 'required' => true,
  198. ],
  199. ],
  200. ],'list' => [
  201. 'path' => 'v1/{+parent}/insights',
  202. 'httpMethod' => 'GET',
  203. 'parameters' => [
  204. 'parent' => [
  205. 'location' => 'path',
  206. 'type' => 'string',
  207. 'required' => true,
  208. ],
  209. 'filter' => [
  210. 'location' => 'query',
  211. 'type' => 'string',
  212. ],
  213. 'pageSize' => [
  214. 'location' => 'query',
  215. 'type' => 'integer',
  216. ],
  217. 'pageToken' => [
  218. 'location' => 'query',
  219. 'type' => 'string',
  220. ],
  221. ],
  222. ],'markAccepted' => [
  223. 'path' => 'v1/{+name}:markAccepted',
  224. 'httpMethod' => 'POST',
  225. 'parameters' => [
  226. 'name' => [
  227. 'location' => 'path',
  228. 'type' => 'string',
  229. 'required' => true,
  230. ],
  231. ],
  232. ],
  233. ]
  234. ]
  235. );
  236. $this->folders_locations_recommenders_recommendations = new Recommender\Resource\FoldersLocationsRecommendersRecommendations(
  237. $this,
  238. $this->serviceName,
  239. 'recommendations',
  240. [
  241. 'methods' => [
  242. 'get' => [
  243. 'path' => 'v1/{+name}',
  244. 'httpMethod' => 'GET',
  245. 'parameters' => [
  246. 'name' => [
  247. 'location' => 'path',
  248. 'type' => 'string',
  249. 'required' => true,
  250. ],
  251. ],
  252. ],'list' => [
  253. 'path' => 'v1/{+parent}/recommendations',
  254. 'httpMethod' => 'GET',
  255. 'parameters' => [
  256. 'parent' => [
  257. 'location' => 'path',
  258. 'type' => 'string',
  259. 'required' => true,
  260. ],
  261. 'filter' => [
  262. 'location' => 'query',
  263. 'type' => 'string',
  264. ],
  265. 'pageSize' => [
  266. 'location' => 'query',
  267. 'type' => 'integer',
  268. ],
  269. 'pageToken' => [
  270. 'location' => 'query',
  271. 'type' => 'string',
  272. ],
  273. ],
  274. ],'markClaimed' => [
  275. 'path' => 'v1/{+name}:markClaimed',
  276. 'httpMethod' => 'POST',
  277. 'parameters' => [
  278. 'name' => [
  279. 'location' => 'path',
  280. 'type' => 'string',
  281. 'required' => true,
  282. ],
  283. ],
  284. ],'markFailed' => [
  285. 'path' => 'v1/{+name}:markFailed',
  286. 'httpMethod' => 'POST',
  287. 'parameters' => [
  288. 'name' => [
  289. 'location' => 'path',
  290. 'type' => 'string',
  291. 'required' => true,
  292. ],
  293. ],
  294. ],'markSucceeded' => [
  295. 'path' => 'v1/{+name}:markSucceeded',
  296. 'httpMethod' => 'POST',
  297. 'parameters' => [
  298. 'name' => [
  299. 'location' => 'path',
  300. 'type' => 'string',
  301. 'required' => true,
  302. ],
  303. ],
  304. ],
  305. ]
  306. ]
  307. );
  308. $this->organizations_locations_insightTypes_insights = new Recommender\Resource\OrganizationsLocationsInsightTypesInsights(
  309. $this,
  310. $this->serviceName,
  311. 'insights',
  312. [
  313. 'methods' => [
  314. 'get' => [
  315. 'path' => 'v1/{+name}',
  316. 'httpMethod' => 'GET',
  317. 'parameters' => [
  318. 'name' => [
  319. 'location' => 'path',
  320. 'type' => 'string',
  321. 'required' => true,
  322. ],
  323. ],
  324. ],'list' => [
  325. 'path' => 'v1/{+parent}/insights',
  326. 'httpMethod' => 'GET',
  327. 'parameters' => [
  328. 'parent' => [
  329. 'location' => 'path',
  330. 'type' => 'string',
  331. 'required' => true,
  332. ],
  333. 'filter' => [
  334. 'location' => 'query',
  335. 'type' => 'string',
  336. ],
  337. 'pageSize' => [
  338. 'location' => 'query',
  339. 'type' => 'integer',
  340. ],
  341. 'pageToken' => [
  342. 'location' => 'query',
  343. 'type' => 'string',
  344. ],
  345. ],
  346. ],'markAccepted' => [
  347. 'path' => 'v1/{+name}:markAccepted',
  348. 'httpMethod' => 'POST',
  349. 'parameters' => [
  350. 'name' => [
  351. 'location' => 'path',
  352. 'type' => 'string',
  353. 'required' => true,
  354. ],
  355. ],
  356. ],
  357. ]
  358. ]
  359. );
  360. $this->organizations_locations_recommenders_recommendations = new Recommender\Resource\OrganizationsLocationsRecommendersRecommendations(
  361. $this,
  362. $this->serviceName,
  363. 'recommendations',
  364. [
  365. 'methods' => [
  366. 'get' => [
  367. 'path' => 'v1/{+name}',
  368. 'httpMethod' => 'GET',
  369. 'parameters' => [
  370. 'name' => [
  371. 'location' => 'path',
  372. 'type' => 'string',
  373. 'required' => true,
  374. ],
  375. ],
  376. ],'list' => [
  377. 'path' => 'v1/{+parent}/recommendations',
  378. 'httpMethod' => 'GET',
  379. 'parameters' => [
  380. 'parent' => [
  381. 'location' => 'path',
  382. 'type' => 'string',
  383. 'required' => true,
  384. ],
  385. 'filter' => [
  386. 'location' => 'query',
  387. 'type' => 'string',
  388. ],
  389. 'pageSize' => [
  390. 'location' => 'query',
  391. 'type' => 'integer',
  392. ],
  393. 'pageToken' => [
  394. 'location' => 'query',
  395. 'type' => 'string',
  396. ],
  397. ],
  398. ],'markClaimed' => [
  399. 'path' => 'v1/{+name}:markClaimed',
  400. 'httpMethod' => 'POST',
  401. 'parameters' => [
  402. 'name' => [
  403. 'location' => 'path',
  404. 'type' => 'string',
  405. 'required' => true,
  406. ],
  407. ],
  408. ],'markFailed' => [
  409. 'path' => 'v1/{+name}:markFailed',
  410. 'httpMethod' => 'POST',
  411. 'parameters' => [
  412. 'name' => [
  413. 'location' => 'path',
  414. 'type' => 'string',
  415. 'required' => true,
  416. ],
  417. ],
  418. ],'markSucceeded' => [
  419. 'path' => 'v1/{+name}:markSucceeded',
  420. 'httpMethod' => 'POST',
  421. 'parameters' => [
  422. 'name' => [
  423. 'location' => 'path',
  424. 'type' => 'string',
  425. 'required' => true,
  426. ],
  427. ],
  428. ],
  429. ]
  430. ]
  431. );
  432. $this->projects_locations_insightTypes_insights = new Recommender\Resource\ProjectsLocationsInsightTypesInsights(
  433. $this,
  434. $this->serviceName,
  435. 'insights',
  436. [
  437. 'methods' => [
  438. 'get' => [
  439. 'path' => 'v1/{+name}',
  440. 'httpMethod' => 'GET',
  441. 'parameters' => [
  442. 'name' => [
  443. 'location' => 'path',
  444. 'type' => 'string',
  445. 'required' => true,
  446. ],
  447. ],
  448. ],'list' => [
  449. 'path' => 'v1/{+parent}/insights',
  450. 'httpMethod' => 'GET',
  451. 'parameters' => [
  452. 'parent' => [
  453. 'location' => 'path',
  454. 'type' => 'string',
  455. 'required' => true,
  456. ],
  457. 'filter' => [
  458. 'location' => 'query',
  459. 'type' => 'string',
  460. ],
  461. 'pageSize' => [
  462. 'location' => 'query',
  463. 'type' => 'integer',
  464. ],
  465. 'pageToken' => [
  466. 'location' => 'query',
  467. 'type' => 'string',
  468. ],
  469. ],
  470. ],'markAccepted' => [
  471. 'path' => 'v1/{+name}:markAccepted',
  472. 'httpMethod' => 'POST',
  473. 'parameters' => [
  474. 'name' => [
  475. 'location' => 'path',
  476. 'type' => 'string',
  477. 'required' => true,
  478. ],
  479. ],
  480. ],
  481. ]
  482. ]
  483. );
  484. $this->projects_locations_recommenders_recommendations = new Recommender\Resource\ProjectsLocationsRecommendersRecommendations(
  485. $this,
  486. $this->serviceName,
  487. 'recommendations',
  488. [
  489. 'methods' => [
  490. 'get' => [
  491. 'path' => 'v1/{+name}',
  492. 'httpMethod' => 'GET',
  493. 'parameters' => [
  494. 'name' => [
  495. 'location' => 'path',
  496. 'type' => 'string',
  497. 'required' => true,
  498. ],
  499. ],
  500. ],'list' => [
  501. 'path' => 'v1/{+parent}/recommendations',
  502. 'httpMethod' => 'GET',
  503. 'parameters' => [
  504. 'parent' => [
  505. 'location' => 'path',
  506. 'type' => 'string',
  507. 'required' => true,
  508. ],
  509. 'filter' => [
  510. 'location' => 'query',
  511. 'type' => 'string',
  512. ],
  513. 'pageSize' => [
  514. 'location' => 'query',
  515. 'type' => 'integer',
  516. ],
  517. 'pageToken' => [
  518. 'location' => 'query',
  519. 'type' => 'string',
  520. ],
  521. ],
  522. ],'markClaimed' => [
  523. 'path' => 'v1/{+name}:markClaimed',
  524. 'httpMethod' => 'POST',
  525. 'parameters' => [
  526. 'name' => [
  527. 'location' => 'path',
  528. 'type' => 'string',
  529. 'required' => true,
  530. ],
  531. ],
  532. ],'markFailed' => [
  533. 'path' => 'v1/{+name}:markFailed',
  534. 'httpMethod' => 'POST',
  535. 'parameters' => [
  536. 'name' => [
  537. 'location' => 'path',
  538. 'type' => 'string',
  539. 'required' => true,
  540. ],
  541. ],
  542. ],'markSucceeded' => [
  543. 'path' => 'v1/{+name}:markSucceeded',
  544. 'httpMethod' => 'POST',
  545. 'parameters' => [
  546. 'name' => [
  547. 'location' => 'path',
  548. 'type' => 'string',
  549. 'required' => true,
  550. ],
  551. ],
  552. ],
  553. ]
  554. ]
  555. );
  556. }
  557. }
  558. // Adding a class alias for backwards compatibility with the previous class name.
  559. class_alias(Recommender::class, 'Google_Service_Recommender');