Class: Google::Apis::BloggerV3::BloggerService

Inherits:
Core::BaseService show all
Defined in:
generated/google/apis/blogger_v3/service.rb

Overview

Blogger API

API for access to the data within Blogger.

Examples:

require 'google/apis/blogger_v3'

Blogger = Google::Apis::BloggerV3 # Alias the module
service = Blogger::BloggerService.new

See Also:

Instance Attribute Summary collapse

Attributes inherited from Core::BaseService

#authorization, #base_path, #batch_path, #client, #client_options, #request_options, #root_url, #upload_path

Instance Method Summary collapse

Methods inherited from Core::BaseService

#batch, #batch_upload, #fetch_all, #http

Methods included from Core::Logging

#logger

Constructor Details

#initializeBloggerService

Returns a new instance of BloggerService



51
52
53
54
# File 'generated/google/apis/blogger_v3/service.rb', line 51

def initialize
  super('https://www.googleapis.com/', 'blogger/v3/')
  @batch_path = 'batch'
end

Instance Attribute Details

#keyString

Returns API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.

Returns:

  • (String)

    API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.



38
39
40
# File 'generated/google/apis/blogger_v3/service.rb', line 38

def key
  @key
end

#quota_userString

Returns Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

Returns:

  • (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.



44
45
46
# File 'generated/google/apis/blogger_v3/service.rb', line 44

def quota_user
  @quota_user
end

#user_ipString

Returns IP address of the site where the request originates. Use this if you want to enforce per-user limits.

Returns:

  • (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.



49
50
51
# File 'generated/google/apis/blogger_v3/service.rb', line 49

def user_ip
  @user_ip
end

Instance Method Details

#approve_comment(blog_id, post_id, comment_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Comment

Marks a comment as not spam.

Parameters:

  • blog_id (String)

    The ID of the Blog.

  • post_id (String)

    The ID of the Post.

  • comment_id (String)

    The ID of the comment to mark as not spam.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



260
261
262
263
264
265
266
267
268
269
270
271
# File 'generated/google/apis/blogger_v3/service.rb', line 260

def approve_comment(blog_id, post_id, comment_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:post, 'blogs/{blogId}/posts/{postId}/comments/{commentId}/approve', options)
  command.response_representation = Google::Apis::BloggerV3::Comment::Representation
  command.response_class = Google::Apis::BloggerV3::Comment
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['postId'] = post_id unless post_id.nil?
  command.params['commentId'] = comment_id unless comment_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#delete_comment(blog_id, post_id, comment_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... }

This method returns an undefined value.

Delete a comment by ID.

Parameters:

  • blog_id (String)

    The ID of the Blog.

  • post_id (String)

    The ID of the Post.

  • comment_id (String)

    The ID of the comment to delete.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

  • result (NilClass)

    No result returned for this method

  • err (StandardError)

    error object if request failed

Raises:



301
302
303
304
305
306
307
308
309
310
# File 'generated/google/apis/blogger_v3/service.rb', line 301

def delete_comment(blog_id, post_id, comment_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:delete, 'blogs/{blogId}/posts/{postId}/comments/{commentId}', options)
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['postId'] = post_id unless post_id.nil?
  command.params['commentId'] = comment_id unless comment_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#delete_page(blog_id, page_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... }

This method returns an undefined value.

Delete a page by ID.

Parameters:

  • blog_id (String)

    The ID of the Blog.

  • page_id (String)

    The ID of the Page.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

  • result (NilClass)

    No result returned for this method

  • err (StandardError)

    error object if request failed

Raises:



615
616
617
618
619
620
621
622
623
# File 'generated/google/apis/blogger_v3/service.rb', line 615

def delete_page(blog_id, page_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:delete, 'blogs/{blogId}/pages/{pageId}', options)
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['pageId'] = page_id unless page_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#delete_post(blog_id, post_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... }

This method returns an undefined value.

Delete a post by ID.

Parameters:

  • blog_id (String)

    The ID of the Blog.

  • post_id (String)

    The ID of the Post.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

  • result (NilClass)

    No result returned for this method

  • err (StandardError)

    error object if request failed

Raises:



1071
1072
1073
1074
1075
1076
1077
1078
1079
# File 'generated/google/apis/blogger_v3/service.rb', line 1071

def delete_post(blog_id, post_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:delete, 'blogs/{blogId}/posts/{postId}', options)
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['postId'] = post_id unless post_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#get_blog(blog_id, max_posts: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Blog

Gets one blog by ID.

Parameters:

  • blog_id (String)

    The ID of the blog to get.

  • max_posts (Fixnum)

    Maximum number of posts to pull back with the blog.

  • view (String)

    Access level with which to view the blog. Note that some fields require elevated access.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



127
128
129
130
131
132
133
134
135
136
137
138
# File 'generated/google/apis/blogger_v3/service.rb', line 127

def get_blog(blog_id, max_posts: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'blogs/{blogId}', options)
  command.response_representation = Google::Apis::BloggerV3::Blog::Representation
  command.response_class = Google::Apis::BloggerV3::Blog
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.query['maxPosts'] = max_posts unless max_posts.nil?
  command.query['view'] = view unless view.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#get_blog_by_url(url, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Blog

Retrieve a Blog by URL.

Parameters:

  • url (String)

    The URL of the blog to retrieve.

  • view (String)

    Access level with which to view the blog. Note that some fields require elevated access.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



167
168
169
170
171
172
173
174
175
176
177
# File 'generated/google/apis/blogger_v3/service.rb', line 167

def get_blog_by_url(url, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'blogs/byurl', options)
  command.response_representation = Google::Apis::BloggerV3::Blog::Representation
  command.response_class = Google::Apis::BloggerV3::Blog
  command.query['url'] = url unless url.nil?
  command.query['view'] = view unless view.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#get_blog_user_info(user_id, blog_id, max_posts: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::BlogUserInfo

Gets one blog and user info pair by blogId and userId.

Parameters:

  • user_id (String)

    ID of the user whose blogs are to be fetched. Either the word 'self' (sans quote marks) or the user's profile identifier.

  • blog_id (String)

    The ID of the blog to get.

  • max_posts (Fixnum)

    Maximum number of posts to pull back with the blog.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



85
86
87
88
89
90
91
92
93
94
95
96
# File 'generated/google/apis/blogger_v3/service.rb', line 85

def (user_id, blog_id, max_posts: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'users/{userId}/blogs/{blogId}', options)
  command.response_representation = Google::Apis::BloggerV3::BlogUserInfo::Representation
  command.response_class = Google::Apis::BloggerV3::BlogUserInfo
  command.params['userId'] = user_id unless user_id.nil?
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.query['maxPosts'] = max_posts unless max_posts.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#get_comment(blog_id, post_id, comment_id, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Comment

Gets one comment by ID.

Parameters:

  • blog_id (String)

    ID of the blog to containing the comment.

  • post_id (String)

    ID of the post to fetch posts from.

  • comment_id (String)

    The ID of the comment to get.

  • view (String)

    Access level for the requested comment (default: READER). Note that some comments will require elevated permissions, for example comments where the parent posts which is in a draft state, or comments that are pending moderation.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



345
346
347
348
349
350
351
352
353
354
355
356
357
# File 'generated/google/apis/blogger_v3/service.rb', line 345

def get_comment(blog_id, post_id, comment_id, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'blogs/{blogId}/posts/{postId}/comments/{commentId}', options)
  command.response_representation = Google::Apis::BloggerV3::Comment::Representation
  command.response_class = Google::Apis::BloggerV3::Comment
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['postId'] = post_id unless post_id.nil?
  command.params['commentId'] = comment_id unless comment_id.nil?
  command.query['view'] = view unless view.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#get_page(blog_id, page_id, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Page

Gets one blog page by ID.

Parameters:

  • blog_id (String)

    ID of the blog containing the page.

  • page_id (String)

    The ID of the page to get.

  • view (String)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



652
653
654
655
656
657
658
659
660
661
662
663
# File 'generated/google/apis/blogger_v3/service.rb', line 652

def get_page(blog_id, page_id, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'blogs/{blogId}/pages/{pageId}', options)
  command.response_representation = Google::Apis::BloggerV3::Page::Representation
  command.response_class = Google::Apis::BloggerV3::Page
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['pageId'] = page_id unless page_id.nil?
  command.query['view'] = view unless view.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#get_page_view(blog_id, range: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Pageviews

Retrieve pageview stats for a Blog.

Parameters:

  • blog_id (String)

    The ID of the blog to get.

  • range (Array<String>, String)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



577
578
579
580
581
582
583
584
585
586
587
# File 'generated/google/apis/blogger_v3/service.rb', line 577

def get_page_view(blog_id, range: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'blogs/{blogId}/pageviews', options)
  command.response_representation = Google::Apis::BloggerV3::Pageviews::Representation
  command.response_class = Google::Apis::BloggerV3::Pageviews
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.query['range'] = range unless range.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#get_post(blog_id, post_id, fetch_body: nil, fetch_images: nil, max_comments: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Post

Get a post by ID.

Parameters:

  • blog_id (String)

    ID of the blog to fetch the post from.

  • post_id (String)

    The ID of the post

  • fetch_body (Boolean)

    Whether the body content of the post is included (default: true). This should be set to false when the post bodies are not required, to help minimize traffic.

  • fetch_images (Boolean)

    Whether image URL metadata for each post is included (default: false).

  • max_comments (Fixnum)

    Maximum number of comments to pull back on a post.

  • view (String)

    Access level with which to view the returned result. Note that some fields require elevated access.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
# File 'generated/google/apis/blogger_v3/service.rb', line 1118

def get_post(blog_id, post_id, fetch_body: nil, fetch_images: nil, max_comments: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'blogs/{blogId}/posts/{postId}', options)
  command.response_representation = Google::Apis::BloggerV3::Post::Representation
  command.response_class = Google::Apis::BloggerV3::Post
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['postId'] = post_id unless post_id.nil?
  command.query['fetchBody'] = fetch_body unless fetch_body.nil?
  command.query['fetchImages'] = fetch_images unless fetch_images.nil?
  command.query['maxComments'] = max_comments unless max_comments.nil?
  command.query['view'] = view unless view.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#get_post_by_path(blog_id, path, max_comments: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Post

Retrieve a Post by Path.

Parameters:

  • blog_id (String)

    ID of the blog to fetch the post from.

  • path (String)

    Path of the Post to retrieve.

  • max_comments (Fixnum)

    Maximum number of comments to pull back on a post.

  • view (String)

    Access level with which to view the returned result. Note that some fields require elevated access.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
# File 'generated/google/apis/blogger_v3/service.rb', line 1165

def get_post_by_path(blog_id, path, max_comments: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'blogs/{blogId}/posts/bypath', options)
  command.response_representation = Google::Apis::BloggerV3::Post::Representation
  command.response_class = Google::Apis::BloggerV3::Post
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.query['maxComments'] = max_comments unless max_comments.nil?
  command.query['path'] = path unless path.nil?
  command.query['view'] = view unless view.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#get_post_user_info(user_id, blog_id, post_id, max_comments: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::PostUserInfo

Gets one post and user info pair, by post ID and user ID. The post user info contains per-user information about the post, such as access rights, specific to the user.

Parameters:

  • user_id (String)

    ID of the user for the per-user information to be fetched. Either the word ' self' (sans quote marks) or the user's profile identifier.

  • blog_id (String)

    The ID of the blog.

  • post_id (String)

    The ID of the post to get.

  • max_comments (Fixnum)

    Maximum number of comments to pull back on a post.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



963
964
965
966
967
968
969
970
971
972
973
974
975
# File 'generated/google/apis/blogger_v3/service.rb', line 963

def (user_id, blog_id, post_id, max_comments: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'users/{userId}/blogs/{blogId}/posts/{postId}', options)
  command.response_representation = Google::Apis::BloggerV3::PostUserInfo::Representation
  command.response_class = Google::Apis::BloggerV3::PostUserInfo
  command.params['userId'] = user_id unless user_id.nil?
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['postId'] = post_id unless post_id.nil?
  command.query['maxComments'] = max_comments unless max_comments.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#get_user(user_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::User

Gets one user by ID.

Parameters:

  • user_id (String)

    The ID of the user to get.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
# File 'generated/google/apis/blogger_v3/service.rb', line 1567

def get_user(user_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'users/{userId}', options)
  command.response_representation = Google::Apis::BloggerV3::User::Representation
  command.response_class = Google::Apis::BloggerV3::User
  command.params['userId'] = user_id unless user_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#insert_page(blog_id, page_object = nil, is_draft: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Page

Add a page.

Parameters:

  • blog_id (String)

    ID of the blog to add the page to.

  • page_object (Google::Apis::BloggerV3::Page) (defaults to: nil)
  • is_draft (Boolean)

    Whether to create the page as a draft (default: false).

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



692
693
694
695
696
697
698
699
700
701
702
703
704
# File 'generated/google/apis/blogger_v3/service.rb', line 692

def insert_page(blog_id, page_object = nil, is_draft: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:post, 'blogs/{blogId}/pages', options)
  command.request_representation = Google::Apis::BloggerV3::Page::Representation
  command.request_object = page_object
  command.response_representation = Google::Apis::BloggerV3::Page::Representation
  command.response_class = Google::Apis::BloggerV3::Page
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.query['isDraft'] = is_draft unless is_draft.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#insert_post(blog_id, post_object = nil, fetch_body: nil, fetch_images: nil, is_draft: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Post

Add a post.

Parameters:

  • blog_id (String)

    ID of the blog to add the post to.

  • post_object (Google::Apis::BloggerV3::Post) (defaults to: nil)
  • fetch_body (Boolean)

    Whether the body content of the post is included with the result (default: true).

  • fetch_images (Boolean)

    Whether image URL metadata for each post is included in the returned result ( default: false).

  • is_draft (Boolean)

    Whether to create the post as a draft (default: false).

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
# File 'generated/google/apis/blogger_v3/service.rb', line 1212

def insert_post(blog_id, post_object = nil, fetch_body: nil, fetch_images: nil, is_draft: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:post, 'blogs/{blogId}/posts', options)
  command.request_representation = Google::Apis::BloggerV3::Post::Representation
  command.request_object = post_object
  command.response_representation = Google::Apis::BloggerV3::Post::Representation
  command.response_class = Google::Apis::BloggerV3::Post
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.query['fetchBody'] = fetch_body unless fetch_body.nil?
  command.query['fetchImages'] = fetch_images unless fetch_images.nil?
  command.query['isDraft'] = is_draft unless is_draft.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#list_blogs_by_user(user_id, fetch_user_info: nil, role: nil, status: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::BlogList

Retrieves a list of blogs, possibly filtered.

Parameters:

  • user_id (String)

    ID of the user whose blogs are to be fetched. Either the word 'self' (sans quote marks) or the user's profile identifier.

  • fetch_user_info (Boolean)

    Whether the response is a list of blogs with per-user information instead of just blogs.

  • role (Array<String>, String)

    User access types for blogs to include in the results, e.g. AUTHOR will return blogs where the user has author level access. If no roles are specified, defaults to ADMIN and AUTHOR roles.

  • status (Array<String>, String)

    Blog statuses to include in the result (default: Live blogs only). Note that ADMIN access is required to view deleted blogs.

  • view (String)

    Access level with which to view the blogs. Note that some fields require elevated access.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



217
218
219
220
221
222
223
224
225
226
227
228
229
230
# File 'generated/google/apis/blogger_v3/service.rb', line 217

def list_blogs_by_user(user_id, fetch_user_info: nil, role: nil, status: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'users/{userId}/blogs', options)
  command.response_representation = Google::Apis::BloggerV3::BlogList::Representation
  command.response_class = Google::Apis::BloggerV3::BlogList
  command.params['userId'] = user_id unless user_id.nil?
  command.query['fetchUserInfo'] =  unless .nil?
  command.query['role'] = role unless role.nil?
  command.query['status'] = status unless status.nil?
  command.query['view'] = view unless view.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#list_comments(blog_id, post_id, end_date: nil, fetch_bodies: nil, max_results: nil, page_token: nil, start_date: nil, status: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::CommentList

Retrieves the comments for a post, possibly filtered.

Parameters:

  • blog_id (String)

    ID of the blog to fetch comments from.

  • post_id (String)

    ID of the post to fetch posts from.

  • end_date (DateTime)

    Latest date of comment to fetch, a date-time with RFC 3339 formatting.

  • fetch_bodies (Boolean)

    Whether the body content of the comments is included.

  • max_results (Fixnum)

    Maximum number of comments to include in the result.

  • page_token (String)

    Continuation token if request is paged.

  • start_date (DateTime)

    Earliest date of comment to fetch, a date-time with RFC 3339 formatting.

  • status (Array<String>, String)
  • view (String)

    Access level with which to view the returned result. Note that some fields require elevated access.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
# File 'generated/google/apis/blogger_v3/service.rb', line 399

def list_comments(blog_id, post_id, end_date: nil, fetch_bodies: nil, max_results: nil, page_token: nil, start_date: nil, status: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'blogs/{blogId}/posts/{postId}/comments', options)
  command.response_representation = Google::Apis::BloggerV3::CommentList::Representation
  command.response_class = Google::Apis::BloggerV3::CommentList
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['postId'] = post_id unless post_id.nil?
  command.query['endDate'] = end_date unless end_date.nil?
  command.query['fetchBodies'] = fetch_bodies unless fetch_bodies.nil?
  command.query['maxResults'] = max_results unless max_results.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['startDate'] = start_date unless start_date.nil?
  command.query['status'] = status unless status.nil?
  command.query['view'] = view unless view.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#list_comments_by_blog(blog_id, end_date: nil, fetch_bodies: nil, max_results: nil, page_token: nil, start_date: nil, status: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::CommentList

Retrieves the comments for a blog, across all posts, possibly filtered.

Parameters:

  • blog_id (String)

    ID of the blog to fetch comments from.

  • end_date (DateTime)

    Latest date of comment to fetch, a date-time with RFC 3339 formatting.

  • fetch_bodies (Boolean)

    Whether the body content of the comments is included.

  • max_results (Fixnum)

    Maximum number of comments to include in the result.

  • page_token (String)

    Continuation token if request is paged.

  • start_date (DateTime)

    Earliest date of comment to fetch, a date-time with RFC 3339 formatting.

  • status (Array<String>, String)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
# File 'generated/google/apis/blogger_v3/service.rb', line 453

def list_comments_by_blog(blog_id, end_date: nil, fetch_bodies: nil, max_results: nil, page_token: nil, start_date: nil, status: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'blogs/{blogId}/comments', options)
  command.response_representation = Google::Apis::BloggerV3::CommentList::Representation
  command.response_class = Google::Apis::BloggerV3::CommentList
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.query['endDate'] = end_date unless end_date.nil?
  command.query['fetchBodies'] = fetch_bodies unless fetch_bodies.nil?
  command.query['maxResults'] = max_results unless max_results.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['startDate'] = start_date unless start_date.nil?
  command.query['status'] = status unless status.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#list_pages(blog_id, fetch_bodies: nil, max_results: nil, page_token: nil, status: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::PageList

Retrieves the pages for a blog, optionally including non-LIVE statuses.

Parameters:

  • blog_id (String)

    ID of the blog to fetch Pages from.

  • fetch_bodies (Boolean)

    Whether to retrieve the Page bodies.

  • max_results (Fixnum)

    Maximum number of Pages to fetch.

  • page_token (String)

    Continuation token if the request is paged.

  • status (Array<String>, String)
  • view (String)

    Access level with which to view the returned result. Note that some fields require elevated access.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
# File 'generated/google/apis/blogger_v3/service.rb', line 740

def list_pages(blog_id, fetch_bodies: nil, max_results: nil, page_token: nil, status: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'blogs/{blogId}/pages', options)
  command.response_representation = Google::Apis::BloggerV3::PageList::Representation
  command.response_class = Google::Apis::BloggerV3::PageList
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.query['fetchBodies'] = fetch_bodies unless fetch_bodies.nil?
  command.query['maxResults'] = max_results unless max_results.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['status'] = status unless status.nil?
  command.query['view'] = view unless view.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#list_post_user_info(user_id, blog_id, end_date: nil, fetch_bodies: nil, labels: nil, max_results: nil, order_by: nil, page_token: nil, start_date: nil, status: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::PostUserInfosList

Retrieves a list of post and post user info pairs, possibly filtered. The post user info contains per-user information about the post, such as access rights, specific to the user.

Parameters:

  • user_id (String)

    ID of the user for the per-user information to be fetched. Either the word ' self' (sans quote marks) or the user's profile identifier.

  • blog_id (String)

    ID of the blog to fetch posts from.

  • end_date (DateTime)

    Latest post date to fetch, a date-time with RFC 3339 formatting.

  • fetch_bodies (Boolean)

    Whether the body content of posts is included. Default is false.

  • labels (String)

    Comma-separated list of labels to search for.

  • max_results (Fixnum)

    Maximum number of posts to fetch.

  • order_by (String)

    Sort order applied to search results. Default is published.

  • page_token (String)

    Continuation token if the request is paged.

  • start_date (DateTime)

    Earliest post date to fetch, a date-time with RFC 3339 formatting.

  • status (Array<String>, String)
  • view (String)

    Access level with which to view the returned result. Note that some fields require elevated access.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
# File 'generated/google/apis/blogger_v3/service.rb', line 1024

def (user_id, blog_id, end_date: nil, fetch_bodies: nil, labels: nil, max_results: nil, order_by: nil, page_token: nil, start_date: nil, status: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'users/{userId}/blogs/{blogId}/posts', options)
  command.response_representation = Google::Apis::BloggerV3::PostUserInfosList::Representation
  command.response_class = Google::Apis::BloggerV3::PostUserInfosList
  command.params['userId'] = user_id unless user_id.nil?
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.query['endDate'] = end_date unless end_date.nil?
  command.query['fetchBodies'] = fetch_bodies unless fetch_bodies.nil?
  command.query['labels'] = labels unless labels.nil?
  command.query['maxResults'] = max_results unless max_results.nil?
  command.query['orderBy'] = order_by unless order_by.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['startDate'] = start_date unless start_date.nil?
  command.query['status'] = status unless status.nil?
  command.query['view'] = view unless view.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#list_posts(blog_id, end_date: nil, fetch_bodies: nil, fetch_images: nil, labels: nil, max_results: nil, order_by: nil, page_token: nil, start_date: nil, status: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::PostList

Retrieves a list of posts, possibly filtered.

Parameters:

  • blog_id (String)

    ID of the blog to fetch posts from.

  • end_date (DateTime)

    Latest post date to fetch, a date-time with RFC 3339 formatting.

  • fetch_bodies (Boolean)

    Whether the body content of posts is included (default: true). This should be set to false when the post bodies are not required, to help minimize traffic.

  • fetch_images (Boolean)

    Whether image URL metadata for each post is included.

  • labels (String)

    Comma-separated list of labels to search for.

  • max_results (Fixnum)

    Maximum number of posts to fetch.

  • order_by (String)

    Sort search results

  • page_token (String)

    Continuation token if the request is paged.

  • start_date (DateTime)

    Earliest post date to fetch, a date-time with RFC 3339 formatting.

  • status (Array<String>, String)

    Statuses to include in the results.

  • view (String)

    Access level with which to view the returned result. Note that some fields require escalated access.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
# File 'generated/google/apis/blogger_v3/service.rb', line 1274

def list_posts(blog_id, end_date: nil, fetch_bodies: nil, fetch_images: nil, labels: nil, max_results: nil, order_by: nil, page_token: nil, start_date: nil, status: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'blogs/{blogId}/posts', options)
  command.response_representation = Google::Apis::BloggerV3::PostList::Representation
  command.response_class = Google::Apis::BloggerV3::PostList
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.query['endDate'] = end_date unless end_date.nil?
  command.query['fetchBodies'] = fetch_bodies unless fetch_bodies.nil?
  command.query['fetchImages'] = fetch_images unless fetch_images.nil?
  command.query['labels'] = labels unless labels.nil?
  command.query['maxResults'] = max_results unless max_results.nil?
  command.query['orderBy'] = order_by unless order_by.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['startDate'] = start_date unless start_date.nil?
  command.query['status'] = status unless status.nil?
  command.query['view'] = view unless view.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#mark_comment_as_spam(blog_id, post_id, comment_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Comment

Marks a comment as spam.

Parameters:

  • blog_id (String)

    The ID of the Blog.

  • post_id (String)

    The ID of the Post.

  • comment_id (String)

    The ID of the comment to mark as spam.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



498
499
500
501
502
503
504
505
506
507
508
509
# File 'generated/google/apis/blogger_v3/service.rb', line 498

def mark_comment_as_spam(blog_id, post_id, comment_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:post, 'blogs/{blogId}/posts/{postId}/comments/{commentId}/spam', options)
  command.response_representation = Google::Apis::BloggerV3::Comment::Representation
  command.response_class = Google::Apis::BloggerV3::Comment
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['postId'] = post_id unless post_id.nil?
  command.params['commentId'] = comment_id unless comment_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#patch_page(blog_id, page_id, page_object = nil, publish: nil, revert: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Page

Update a page. This method supports patch semantics.

Parameters:

  • blog_id (String)

    The ID of the Blog.

  • page_id (String)

    The ID of the Page.

  • page_object (Google::Apis::BloggerV3::Page) (defaults to: nil)
  • publish (Boolean)

    Whether a publish action should be performed when the page is updated (default: false).

  • revert (Boolean)

    Whether a revert action should be performed when the page is updated (default: false).

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
# File 'generated/google/apis/blogger_v3/service.rb', line 789

def patch_page(blog_id, page_id, page_object = nil, publish: nil, revert: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:patch, 'blogs/{blogId}/pages/{pageId}', options)
  command.request_representation = Google::Apis::BloggerV3::Page::Representation
  command.request_object = page_object
  command.response_representation = Google::Apis::BloggerV3::Page::Representation
  command.response_class = Google::Apis::BloggerV3::Page
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['pageId'] = page_id unless page_id.nil?
  command.query['publish'] = publish unless publish.nil?
  command.query['revert'] = revert unless revert.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#patch_post(blog_id, post_id, post_object = nil, fetch_body: nil, fetch_images: nil, max_comments: nil, publish: nil, revert: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Post

Update a post. This method supports patch semantics.

Parameters:

  • blog_id (String)

    The ID of the Blog.

  • post_id (String)

    The ID of the Post.

  • post_object (Google::Apis::BloggerV3::Post) (defaults to: nil)
  • fetch_body (Boolean)

    Whether the body content of the post is included with the result (default: true).

  • fetch_images (Boolean)

    Whether image URL metadata for each post is included in the returned result ( default: false).

  • max_comments (Fixnum)

    Maximum number of comments to retrieve with the returned post.

  • publish (Boolean)

    Whether a publish action should be performed when the post is updated (default: false).

  • revert (Boolean)

    Whether a revert action should be performed when the post is updated (default: false).

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
# File 'generated/google/apis/blogger_v3/service.rb', line 1336

def patch_post(blog_id, post_id, post_object = nil, fetch_body: nil, fetch_images: nil, max_comments: nil, publish: nil, revert: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:patch, 'blogs/{blogId}/posts/{postId}', options)
  command.request_representation = Google::Apis::BloggerV3::Post::Representation
  command.request_object = post_object
  command.response_representation = Google::Apis::BloggerV3::Post::Representation
  command.response_class = Google::Apis::BloggerV3::Post
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['postId'] = post_id unless post_id.nil?
  command.query['fetchBody'] = fetch_body unless fetch_body.nil?
  command.query['fetchImages'] = fetch_images unless fetch_images.nil?
  command.query['maxComments'] = max_comments unless max_comments.nil?
  command.query['publish'] = publish unless publish.nil?
  command.query['revert'] = revert unless revert.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#publish_page(blog_id, page_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Page

Publishes a draft page.

Parameters:

  • blog_id (String)

    The ID of the blog.

  • page_id (String)

    The ID of the page.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



831
832
833
834
835
836
837
838
839
840
841
# File 'generated/google/apis/blogger_v3/service.rb', line 831

def publish_page(blog_id, page_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:post, 'blogs/{blogId}/pages/{pageId}/publish', options)
  command.response_representation = Google::Apis::BloggerV3::Page::Representation
  command.response_class = Google::Apis::BloggerV3::Page
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['pageId'] = page_id unless page_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#publish_post(blog_id, post_id, publish_date: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Post

Publishes a draft post, optionally at the specific time of the given publishDate parameter.

Parameters:

  • blog_id (String)

    The ID of the Blog.

  • post_id (String)

    The ID of the Post.

  • publish_date (DateTime)

    Optional date and time to schedule the publishing of the Blog. If no publishDate parameter is given, the post is either published at the a previously saved schedule date (if present), or the current time. If a future date is given, the post will be scheduled to be published.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
# File 'generated/google/apis/blogger_v3/service.rb', line 1387

def publish_post(blog_id, post_id, publish_date: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:post, 'blogs/{blogId}/posts/{postId}/publish', options)
  command.response_representation = Google::Apis::BloggerV3::Post::Representation
  command.response_class = Google::Apis::BloggerV3::Post
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['postId'] = post_id unless post_id.nil?
  command.query['publishDate'] = publish_date unless publish_date.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#remove_comment_content(blog_id, post_id, comment_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Comment

Removes the content of a comment.

Parameters:

  • blog_id (String)

    The ID of the Blog.

  • post_id (String)

    The ID of the Post.

  • comment_id (String)

    The ID of the comment to delete content from.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



539
540
541
542
543
544
545
546
547
548
549
550
# File 'generated/google/apis/blogger_v3/service.rb', line 539

def remove_comment_content(blog_id, post_id, comment_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:post, 'blogs/{blogId}/posts/{postId}/comments/{commentId}/removecontent', options)
  command.response_representation = Google::Apis::BloggerV3::Comment::Representation
  command.response_class = Google::Apis::BloggerV3::Comment
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['postId'] = post_id unless post_id.nil?
  command.params['commentId'] = comment_id unless comment_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#revert_page(blog_id, page_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Page

Revert a published or scheduled page to draft state.

Parameters:

  • blog_id (String)

    The ID of the blog.

  • page_id (String)

    The ID of the page.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



869
870
871
872
873
874
875
876
877
878
879
# File 'generated/google/apis/blogger_v3/service.rb', line 869

def revert_page(blog_id, page_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:post, 'blogs/{blogId}/pages/{pageId}/revert', options)
  command.response_representation = Google::Apis::BloggerV3::Page::Representation
  command.response_class = Google::Apis::BloggerV3::Page
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['pageId'] = page_id unless page_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#revert_post(blog_id, post_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Post

Revert a published or scheduled post to draft state.

Parameters:

  • blog_id (String)

    The ID of the Blog.

  • post_id (String)

    The ID of the Post.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
# File 'generated/google/apis/blogger_v3/service.rb', line 1426

def revert_post(blog_id, post_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:post, 'blogs/{blogId}/posts/{postId}/revert', options)
  command.response_representation = Google::Apis::BloggerV3::Post::Representation
  command.response_class = Google::Apis::BloggerV3::Post
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['postId'] = post_id unless post_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#search_posts(blog_id, q, fetch_bodies: nil, order_by: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::PostList

Search for a post.

Parameters:

  • blog_id (String)

    ID of the blog to fetch the post from.

  • q (String)

    Query terms to search this blog for matching posts.

  • fetch_bodies (Boolean)

    Whether the body content of posts is included (default: true). This should be set to false when the post bodies are not required, to help minimize traffic.

  • order_by (String)

    Sort search results

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
# File 'generated/google/apis/blogger_v3/service.rb', line 1469

def search_posts(blog_id, q, fetch_bodies: nil, order_by: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:get, 'blogs/{blogId}/posts/search', options)
  command.response_representation = Google::Apis::BloggerV3::PostList::Representation
  command.response_class = Google::Apis::BloggerV3::PostList
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.query['fetchBodies'] = fetch_bodies unless fetch_bodies.nil?
  command.query['orderBy'] = order_by unless order_by.nil?
  command.query['q'] = q unless q.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#update_page(blog_id, page_id, page_object = nil, publish: nil, revert: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Page

Update a page.

Parameters:

  • blog_id (String)

    The ID of the Blog.

  • page_id (String)

    The ID of the Page.

  • page_object (Google::Apis::BloggerV3::Page) (defaults to: nil)
  • publish (Boolean)

    Whether a publish action should be performed when the page is updated (default: false).

  • revert (Boolean)

    Whether a revert action should be performed when the page is updated (default: false).

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
# File 'generated/google/apis/blogger_v3/service.rb', line 914

def update_page(blog_id, page_id, page_object = nil, publish: nil, revert: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:put, 'blogs/{blogId}/pages/{pageId}', options)
  command.request_representation = Google::Apis::BloggerV3::Page::Representation
  command.request_object = page_object
  command.response_representation = Google::Apis::BloggerV3::Page::Representation
  command.response_class = Google::Apis::BloggerV3::Page
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['pageId'] = page_id unless page_id.nil?
  command.query['publish'] = publish unless publish.nil?
  command.query['revert'] = revert unless revert.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end

#update_post(blog_id, post_id, post_object = nil, fetch_body: nil, fetch_images: nil, max_comments: nil, publish: nil, revert: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BloggerV3::Post

Update a post.

Parameters:

  • blog_id (String)

    The ID of the Blog.

  • post_id (String)

    The ID of the Post.

  • post_object (Google::Apis::BloggerV3::Post) (defaults to: nil)
  • fetch_body (Boolean)

    Whether the body content of the post is included with the result (default: true).

  • fetch_images (Boolean)

    Whether image URL metadata for each post is included in the returned result ( default: false).

  • max_comments (Fixnum)

    Maximum number of comments to retrieve with the returned post.

  • publish (Boolean)

    Whether a publish action should be performed when the post is updated (default: false).

  • revert (Boolean)

    Whether a revert action should be performed when the post is updated (default: false).

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.

  • user_ip (String)

    IP address of the site where the request originates. Use this if you want to enforce per-user limits.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
# File 'generated/google/apis/blogger_v3/service.rb', line 1524

def update_post(blog_id, post_id, post_object = nil, fetch_body: nil, fetch_images: nil, max_comments: nil, publish: nil, revert: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
  command =  make_simple_command(:put, 'blogs/{blogId}/posts/{postId}', options)
  command.request_representation = Google::Apis::BloggerV3::Post::Representation
  command.request_object = post_object
  command.response_representation = Google::Apis::BloggerV3::Post::Representation
  command.response_class = Google::Apis::BloggerV3::Post
  command.params['blogId'] = blog_id unless blog_id.nil?
  command.params['postId'] = post_id unless post_id.nil?
  command.query['fetchBody'] = fetch_body unless fetch_body.nil?
  command.query['fetchImages'] = fetch_images unless fetch_images.nil?
  command.query['maxComments'] = max_comments unless max_comments.nil?
  command.query['publish'] = publish unless publish.nil?
  command.query['revert'] = revert unless revert.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  command.query['userIp'] = user_ip unless user_ip.nil?
  execute_or_queue_command(command, &block)
end