Google_Service_Blogger_Posts_Resource

The "posts" collection of methods.

Defined (1)

The class is defined in the following location(s).

/lib/Google/Service/Blogger.php  
  1. class Google_Service_Blogger_Posts_Resource extends Google_Service_Resource 
  2.  
  3. /** 
  4. * Delete a post by id. (posts.delete) 
  5. * @param string $blogId 
  6. * The Id of the Blog. 
  7. * @param string $postId 
  8. * The ID of the Post. 
  9. * @param array $optParams Optional parameters. 
  10. */ 
  11. public function delete($blogId, $postId, $optParams = array()) 
  12. $params = array('blogId' => $blogId, 'postId' => $postId); 
  13. $params = array_merge($params, $optParams); 
  14. return $this->call('delete', array($params)); 
  15. /** 
  16. * Get a post by id. (posts.get) 
  17. * @param string $blogId 
  18. * ID of the blog to fetch the post from. 
  19. * @param string $postId 
  20. * The ID of the post 
  21. * @param array $optParams Optional parameters. 
  22. * @opt_param bool fetchBody 
  23. * Whether the body content of the post is included (default: true). This should be set to false 
  24. * when the post bodies are not required, to help minimize traffic. 
  25. * @opt_param string maxComments 
  26. * Maximum number of comments to pull back on a post. 
  27. * @opt_param bool fetchImages 
  28. * Whether image URL metadata for each post is included (default: false). 
  29. * @opt_param string view 
  30. * Access level with which to view the returned result. Note that some fields require elevated 
  31. * access. 
  32. * @return Google_Service_Blogger_Post 
  33. */ 
  34. public function get($blogId, $postId, $optParams = array()) 
  35. $params = array('blogId' => $blogId, 'postId' => $postId); 
  36. $params = array_merge($params, $optParams); 
  37. return $this->call('get', array($params), "Google_Service_Blogger_Post"); 
  38. /** 
  39. * Retrieve a Post by Path. (posts.getByPath) 
  40. * @param string $blogId 
  41. * ID of the blog to fetch the post from. 
  42. * @param string $path 
  43. * Path of the Post to retrieve. 
  44. * @param array $optParams Optional parameters. 
  45. * @opt_param string maxComments 
  46. * Maximum number of comments to pull back on a post. 
  47. * @opt_param string view 
  48. * Access level with which to view the returned result. Note that some fields require elevated 
  49. * access. 
  50. * @return Google_Service_Blogger_Post 
  51. */ 
  52. public function getByPath($blogId, $path, $optParams = array()) 
  53. $params = array('blogId' => $blogId, 'path' => $path); 
  54. $params = array_merge($params, $optParams); 
  55. return $this->call('getByPath', array($params), "Google_Service_Blogger_Post"); 
  56. /** 
  57. * Add a post. (posts.insert) 
  58. * @param string $blogId 
  59. * ID of the blog to add the post to. 
  60. * @param Google_Post $postBody 
  61. * @param array $optParams Optional parameters. 
  62. * @opt_param bool fetchImages 
  63. * Whether image URL metadata for each post is included in the returned result (default: false). 
  64. * @opt_param bool isDraft 
  65. * Whether to create the post as a draft (default: false). 
  66. * @opt_param bool fetchBody 
  67. * Whether the body content of the post is included with the result (default: true). 
  68. * @return Google_Service_Blogger_Post 
  69. */ 
  70. public function insert($blogId, Google_Service_Blogger_Post $postBody, $optParams = array()) 
  71. $params = array('blogId' => $blogId, 'postBody' => $postBody); 
  72. $params = array_merge($params, $optParams); 
  73. return $this->call('insert', array($params), "Google_Service_Blogger_Post"); 
  74. /** 
  75. * Retrieves a list of posts, possibly filtered. (posts.listPosts) 
  76. * @param string $blogId 
  77. * ID of the blog to fetch posts from. 
  78. * @param array $optParams Optional parameters. 
  79. * @opt_param string orderBy 
  80. * Sort search results 
  81. * @opt_param string startDate 
  82. * Earliest post date to fetch, a date-time with RFC 3339 formatting. 
  83. * @opt_param string endDate 
  84. * Latest post date to fetch, a date-time with RFC 3339 formatting. 
  85. * @opt_param string labels 
  86. * Comma-separated list of labels to search for. 
  87. * @opt_param string maxResults 
  88. * Maximum number of posts to fetch. 
  89. * @opt_param bool fetchImages 
  90. * Whether image URL metadata for each post is included. 
  91. * @opt_param string pageToken 
  92. * Continuation token if the request is paged. 
  93. * @opt_param string status 
  94. * Statuses to include in the results. 
  95. * @opt_param bool fetchBodies 
  96. * Whether the body content of posts is included (default: true). This should be set to false when 
  97. * the post bodies are not required, to help minimize traffic. 
  98. * @opt_param string view 
  99. * Access level with which to view the returned result. Note that some fields require escalated 
  100. * access. 
  101. * @return Google_Service_Blogger_PostList 
  102. */ 
  103. public function listPosts($blogId, $optParams = array()) 
  104. $params = array('blogId' => $blogId); 
  105. $params = array_merge($params, $optParams); 
  106. return $this->call('list', array($params), "Google_Service_Blogger_PostList"); 
  107. /** 
  108. * Update a post. This method supports patch semantics. (posts.patch) 
  109. * @param string $blogId 
  110. * The ID of the Blog. 
  111. * @param string $postId 
  112. * The ID of the Post. 
  113. * @param Google_Post $postBody 
  114. * @param array $optParams Optional parameters. 
  115. * @opt_param bool revert 
  116. * Whether a revert action should be performed when the post is updated (default: false). 
  117. * @opt_param bool publish 
  118. * Whether a publish action should be performed when the post is updated (default: false). 
  119. * @opt_param bool fetchBody 
  120. * Whether the body content of the post is included with the result (default: true). 
  121. * @opt_param string maxComments 
  122. * Maximum number of comments to retrieve with the returned post. 
  123. * @opt_param bool fetchImages 
  124. * Whether image URL metadata for each post is included in the returned result (default: false). 
  125. * @return Google_Service_Blogger_Post 
  126. */ 
  127. public function patch($blogId, $postId, Google_Service_Blogger_Post $postBody, $optParams = array()) 
  128. $params = array('blogId' => $blogId, 'postId' => $postId, 'postBody' => $postBody); 
  129. $params = array_merge($params, $optParams); 
  130. return $this->call('patch', array($params), "Google_Service_Blogger_Post"); 
  131. /** 
  132. * Publish a draft post. (posts.publish) 
  133. * @param string $blogId 
  134. * The ID of the Blog. 
  135. * @param string $postId 
  136. * The ID of the Post. 
  137. * @param array $optParams Optional parameters. 
  138. * @opt_param string publishDate 
  139. * The date and time to schedule the publishing of the Blog. 
  140. * @return Google_Service_Blogger_Post 
  141. */ 
  142. public function publish($blogId, $postId, $optParams = array()) 
  143. $params = array('blogId' => $blogId, 'postId' => $postId); 
  144. $params = array_merge($params, $optParams); 
  145. return $this->call('publish', array($params), "Google_Service_Blogger_Post"); 
  146. /** 
  147. * Revert a published or scheduled post to draft state. (posts.revert) 
  148. * @param string $blogId 
  149. * The ID of the Blog. 
  150. * @param string $postId 
  151. * The ID of the Post. 
  152. * @param array $optParams Optional parameters. 
  153. * @return Google_Service_Blogger_Post 
  154. */ 
  155. public function revert($blogId, $postId, $optParams = array()) 
  156. $params = array('blogId' => $blogId, 'postId' => $postId); 
  157. $params = array_merge($params, $optParams); 
  158. return $this->call('revert', array($params), "Google_Service_Blogger_Post"); 
  159. /** 
  160. * Search for a post. (posts.search) 
  161. * @param string $blogId 
  162. * ID of the blog to fetch the post from. 
  163. * @param string $q 
  164. * Query terms to search this blog for matching posts. 
  165. * @param array $optParams Optional parameters. 
  166. * @opt_param string orderBy 
  167. * Sort search results 
  168. * @opt_param bool fetchBodies 
  169. * Whether the body content of posts is included (default: true). This should be set to false when 
  170. * the post bodies are not required, to help minimize traffic. 
  171. * @return Google_Service_Blogger_PostList 
  172. */ 
  173. public function search($blogId, $q, $optParams = array()) 
  174. $params = array('blogId' => $blogId, 'q' => $q); 
  175. $params = array_merge($params, $optParams); 
  176. return $this->call('search', array($params), "Google_Service_Blogger_PostList"); 
  177. /** 
  178. * Update a post. (posts.update) 
  179. * @param string $blogId 
  180. * The ID of the Blog. 
  181. * @param string $postId 
  182. * The ID of the Post. 
  183. * @param Google_Post $postBody 
  184. * @param array $optParams Optional parameters. 
  185. * @opt_param bool revert 
  186. * Whether a revert action should be performed when the post is updated (default: false). 
  187. * @opt_param bool publish 
  188. * Whether a publish action should be performed when the post is updated (default: false). 
  189. * @opt_param bool fetchBody 
  190. * Whether the body content of the post is included with the result (default: true). 
  191. * @opt_param string maxComments 
  192. * Maximum number of comments to retrieve with the returned post. 
  193. * @opt_param bool fetchImages 
  194. * Whether image URL metadata for each post is included in the returned result (default: false). 
  195. * @return Google_Service_Blogger_Post 
  196. */ 
  197. public function update($blogId, $postId, Google_Service_Blogger_Post $postBody, $optParams = array()) 
  198. $params = array('blogId' => $blogId, 'postId' => $postId, 'postBody' => $postBody); 
  199. $params = array_merge($params, $optParams); 
  200. return $this->call('update', array($params), "Google_Service_Blogger_Post");