暫無描述

Slides.php 5.1KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  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. /**
  18. * Service definition for Slides (v1).
  19. *
  20. * <p>
  21. * An API for creating and editing Google Slides presentations.</p>
  22. *
  23. * <p>
  24. * For more information about this service, see the API
  25. * <a href="https://developers.google.com/slides/" target="_blank">Documentation</a>
  26. * </p>
  27. *
  28. * @author Google, Inc.
  29. */
  30. class Google_Service_Slides extends Google_Service
  31. {
  32. /** View and manage the files in your Google Drive. */
  33. const DRIVE =
  34. "https://www.googleapis.com/auth/drive";
  35. /** View and manage Google Drive files and folders that you have opened or created with this app. */
  36. const DRIVE_FILE =
  37. "https://www.googleapis.com/auth/drive.file";
  38. /** View the files in your Google Drive. */
  39. const DRIVE_READONLY =
  40. "https://www.googleapis.com/auth/drive.readonly";
  41. /** View and manage your Google Slides presentations. */
  42. const PRESENTATIONS =
  43. "https://www.googleapis.com/auth/presentations";
  44. /** View your Google Slides presentations. */
  45. const PRESENTATIONS_READONLY =
  46. "https://www.googleapis.com/auth/presentations.readonly";
  47. /** View and manage your spreadsheets in Google Drive. */
  48. const SPREADSHEETS =
  49. "https://www.googleapis.com/auth/spreadsheets";
  50. /** View your Google Spreadsheets. */
  51. const SPREADSHEETS_READONLY =
  52. "https://www.googleapis.com/auth/spreadsheets.readonly";
  53. public $presentations;
  54. public $presentations_pages;
  55. /**
  56. * Constructs the internal representation of the Slides service.
  57. *
  58. * @param Google_Client $client
  59. */
  60. public function __construct(Google_Client $client)
  61. {
  62. parent::__construct($client);
  63. $this->rootUrl = 'https://slides.googleapis.com/';
  64. $this->servicePath = '';
  65. $this->version = 'v1';
  66. $this->serviceName = 'slides';
  67. $this->presentations = new Google_Service_Slides_Resource_Presentations(
  68. $this,
  69. $this->serviceName,
  70. 'presentations',
  71. array(
  72. 'methods' => array(
  73. 'batchUpdate' => array(
  74. 'path' => 'v1/presentations/{presentationId}:batchUpdate',
  75. 'httpMethod' => 'POST',
  76. 'parameters' => array(
  77. 'presentationId' => array(
  78. 'location' => 'path',
  79. 'type' => 'string',
  80. 'required' => true,
  81. ),
  82. ),
  83. ),'create' => array(
  84. 'path' => 'v1/presentations',
  85. 'httpMethod' => 'POST',
  86. 'parameters' => array(),
  87. ),'get' => array(
  88. 'path' => 'v1/presentations/{+presentationId}',
  89. 'httpMethod' => 'GET',
  90. 'parameters' => array(
  91. 'presentationId' => array(
  92. 'location' => 'path',
  93. 'type' => 'string',
  94. 'required' => true,
  95. ),
  96. ),
  97. ),
  98. )
  99. )
  100. );
  101. $this->presentations_pages = new Google_Service_Slides_Resource_PresentationsPages(
  102. $this,
  103. $this->serviceName,
  104. 'pages',
  105. array(
  106. 'methods' => array(
  107. 'get' => array(
  108. 'path' => 'v1/presentations/{presentationId}/pages/{pageObjectId}',
  109. 'httpMethod' => 'GET',
  110. 'parameters' => array(
  111. 'presentationId' => array(
  112. 'location' => 'path',
  113. 'type' => 'string',
  114. 'required' => true,
  115. ),
  116. 'pageObjectId' => array(
  117. 'location' => 'path',
  118. 'type' => 'string',
  119. 'required' => true,
  120. ),
  121. ),
  122. ),'getThumbnail' => array(
  123. 'path' => 'v1/presentations/{presentationId}/pages/{pageObjectId}/thumbnail',
  124. 'httpMethod' => 'GET',
  125. 'parameters' => array(
  126. 'presentationId' => array(
  127. 'location' => 'path',
  128. 'type' => 'string',
  129. 'required' => true,
  130. ),
  131. 'pageObjectId' => array(
  132. 'location' => 'path',
  133. 'type' => 'string',
  134. 'required' => true,
  135. ),
  136. 'thumbnailProperties.mimeType' => array(
  137. 'location' => 'query',
  138. 'type' => 'string',
  139. ),
  140. 'thumbnailProperties.thumbnailSize' => array(
  141. 'location' => 'query',
  142. 'type' => 'string',
  143. ),
  144. ),
  145. ),
  146. )
  147. )
  148. );
  149. }
  150. }