Verifiedaccess.php 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  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 Verifiedaccess (v2).
  21. *
  22. * <p>
  23. * API for Verified Access chrome extension to provide credential verification
  24. * for chrome devices connecting to an enterprise network</p>
  25. *
  26. * <p>
  27. * For more information about this service, see the API
  28. * <a href="https://developers.google.com/chrome/verified-access" target="_blank">Documentation</a>
  29. * </p>
  30. *
  31. * @author Google, Inc.
  32. */
  33. class Verifiedaccess extends \Google\Service
  34. {
  35. /** Verify your enterprise credentials. */
  36. const VERIFIEDACCESS =
  37. "https://www.googleapis.com/auth/verifiedaccess";
  38. public $challenge;
  39. /**
  40. * Constructs the internal representation of the Verifiedaccess service.
  41. *
  42. * @param Client|array $clientOrConfig The client used to deliver requests, or a
  43. * config array to pass to a new Client instance.
  44. * @param string $rootUrl The root URL used for requests to the service.
  45. */
  46. public function __construct($clientOrConfig = [], $rootUrl = null)
  47. {
  48. parent::__construct($clientOrConfig);
  49. $this->rootUrl = $rootUrl ?: 'https://verifiedaccess.googleapis.com/';
  50. $this->servicePath = '';
  51. $this->batchPath = 'batch';
  52. $this->version = 'v2';
  53. $this->serviceName = 'verifiedaccess';
  54. $this->challenge = new Verifiedaccess\Resource\Challenge(
  55. $this,
  56. $this->serviceName,
  57. 'challenge',
  58. [
  59. 'methods' => [
  60. 'generate' => [
  61. 'path' => 'v2/challenge:generate',
  62. 'httpMethod' => 'POST',
  63. 'parameters' => [],
  64. ],'verify' => [
  65. 'path' => 'v2/challenge:verify',
  66. 'httpMethod' => 'POST',
  67. 'parameters' => [],
  68. ],
  69. ]
  70. ]
  71. );
  72. }
  73. }
  74. // Adding a class alias for backwards compatibility with the previous class name.
  75. class_alias(Verifiedaccess::class, 'Google_Service_Verifiedaccess');