# Blogger API . pages

## Instance Methods

Delete a page by ID.

Gets one blog page by ID.

Add a page.

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

Retrieves the next page of results.

Update a page. This method supports patch semantics.

Publishes a draft page.

Revert a published or scheduled page to draft state.

Update a page.

### Method Details

`delete(blogId, pageId)`

    Delete a page by ID.

    Args:
      blogId: string, The ID of the Blog. (required)
      pageId: string, The ID of the Page. (required)

`get(blogId, pageId, view=None)`

    Gets one blog page by ID.

    Args:
      blogId: string, ID of the blog containing the page. (required)
      pageId: string, The ID of the page to get. (required)
      view: string, A parameter
        Allowed values
          ADMIN - Admin level detail
          AUTHOR - Author level detail
          READER - Reader level detail

    Returns:
      An object of the form:

        {
          "status": "A String", # The status of the page for admin resources (either LIVE or DRAFT).
          "content": "A String", # The body content of this Page, in HTML.
          "kind": "blogger#page", # The kind of this entity. Always blogger#page
          "author": { # The author of this Page.
            "url": "A String", # The URL of the Page creator's Profile page.
            "image": { # The page author's avatar.
              "url": "A String", # The page author's avatar URL.
            },
            "displayName": "A String", # The display name.
            "id": "A String", # The identifier of the Page creator.
          },
          "url": "A String", # The URL that this Page is displayed at.
          "title": "A String", # The title of this entity. This is the name displayed in the Admin user interface.
          "updated": "A String", # RFC 3339 date-time when this Page was last updated.
          "blog": { # Data about the blog containing this Page.
            "id": "A String", # The identifier of the blog containing this page.
          },
          "etag": "A String", # Etag of the resource.
          "published": "A String", # RFC 3339 date-time when this Page was published.
          "id": "A String", # The identifier for this resource.
          "selfLink": "A String", # The API REST URL to fetch this resource from.
        }

`insert(blogId, body, isDraft=None)`

    Add a page.

    Args:
      blogId: string, ID of the blog to add the page to. (required)
      body: object, The request body. (required)
        The object takes the form of:

    {
        "status": "A String", # The status of the page for admin resources (either LIVE or DRAFT).
        "content": "A String", # The body content of this Page, in HTML.
        "kind": "blogger#page", # The kind of this entity. Always blogger#page
        "author": { # The author of this Page.
          "url": "A String", # The URL of the Page creator's Profile page.
          "image": { # The page author's avatar.
            "url": "A String", # The page author's avatar URL.
          },
          "displayName": "A String", # The display name.
          "id": "A String", # The identifier of the Page creator.
        },
        "url": "A String", # The URL that this Page is displayed at.
        "title": "A String", # The title of this entity. This is the name displayed in the Admin user interface.
        "updated": "A String", # RFC 3339 date-time when this Page was last updated.
        "blog": { # Data about the blog containing this Page.
          "id": "A String", # The identifier of the blog containing this page.
        },
        "etag": "A String", # Etag of the resource.
        "published": "A String", # RFC 3339 date-time when this Page was published.
        "id": "A String", # The identifier for this resource.
        "selfLink": "A String", # The API REST URL to fetch this resource from.
      }

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

    Returns:
      An object of the form:

        {
          "status": "A String", # The status of the page for admin resources (either LIVE or DRAFT).
          "content": "A String", # The body content of this Page, in HTML.
          "kind": "blogger#page", # The kind of this entity. Always blogger#page
          "author": { # The author of this Page.
            "url": "A String", # The URL of the Page creator's Profile page.
            "image": { # The page author's avatar.
              "url": "A String", # The page author's avatar URL.
            },
            "displayName": "A String", # The display name.
            "id": "A String", # The identifier of the Page creator.
          },
          "url": "A String", # The URL that this Page is displayed at.
          "title": "A String", # The title of this entity. This is the name displayed in the Admin user interface.
          "updated": "A String", # RFC 3339 date-time when this Page was last updated.
          "blog": { # Data about the blog containing this Page.
            "id": "A String", # The identifier of the blog containing this page.
          },
          "etag": "A String", # Etag of the resource.
          "published": "A String", # RFC 3339 date-time when this Page was published.
          "id": "A String", # The identifier for this resource.
          "selfLink": "A String", # The API REST URL to fetch this resource from.
        }

`list(blogId, status=None, pageToken=None, maxResults=None, fetchBodies=None, view=None)`

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

    Args:
      blogId: string, ID of the blog to fetch Pages from. (required)
      status: string, A parameter (repeated)
        Allowed values
          draft - Draft (unpublished) Pages
          live - Pages that are publicly visible
      pageToken: string, Continuation token if the request is paged.
      maxResults: integer, Maximum number of Pages to fetch.
      fetchBodies: boolean, Whether to retrieve the Page bodies.
      view: string, Access level with which to view the returned result. Note that some fields require elevated access.
        Allowed values
          ADMIN - Admin level detail
          AUTHOR - Author level detail
          READER - Reader level detail

    Returns:
      An object of the form:

        {
        "nextPageToken": "A String", # Pagination token to fetch the next page, if one exists.
        "items": [ # The list of Pages for a Blog.
          {
              "status": "A String", # The status of the page for admin resources (either LIVE or DRAFT).
              "content": "A String", # The body content of this Page, in HTML.
              "kind": "blogger#page", # The kind of this entity. Always blogger#page
              "author": { # The author of this Page.
                "url": "A String", # The URL of the Page creator's Profile page.
                "image": { # The page author's avatar.
                  "url": "A String", # The page author's avatar URL.
                },
                "displayName": "A String", # The display name.
                "id": "A String", # The identifier of the Page creator.
              },
              "url": "A String", # The URL that this Page is displayed at.
              "title": "A String", # The title of this entity. This is the name displayed in the Admin user interface.
              "updated": "A String", # RFC 3339 date-time when this Page was last updated.
              "blog": { # Data about the blog containing this Page.
                "id": "A String", # The identifier of the blog containing this page.
              },
              "etag": "A String", # Etag of the resource.
              "published": "A String", # RFC 3339 date-time when this Page was published.
              "id": "A String", # The identifier for this resource.
              "selfLink": "A String", # The API REST URL to fetch this resource from.
            },
        ],
        "kind": "blogger#pageList", # The kind of this entity. Always blogger#pageList
      }

`list_next(previous_request, previous_response)`

    Retrieves the next page of results.

    Args:
      previous_request: The request for the previous page. (required)
      previous_response: The response from the request for the previous page. (required)

    Returns:
      A request object that you can call 'execute()' on to request the next
      page. Returns None if there are no more items in the collection.

`patch(blogId, pageId, body, revert=None, publish=None)`

    Update a page. This method supports patch semantics.

    Args:
      blogId: string, The ID of the Blog. (required)
      pageId: string, The ID of the Page. (required)
      body: object, The request body. (required)
        The object takes the form of:

    {
        "status": "A String", # The status of the page for admin resources (either LIVE or DRAFT).
        "content": "A String", # The body content of this Page, in HTML.
        "kind": "blogger#page", # The kind of this entity. Always blogger#page
        "author": { # The author of this Page.
          "url": "A String", # The URL of the Page creator's Profile page.
          "image": { # The page author's avatar.
            "url": "A String", # The page author's avatar URL.
          },
          "displayName": "A String", # The display name.
          "id": "A String", # The identifier of the Page creator.
        },
        "url": "A String", # The URL that this Page is displayed at.
        "title": "A String", # The title of this entity. This is the name displayed in the Admin user interface.
        "updated": "A String", # RFC 3339 date-time when this Page was last updated.
        "blog": { # Data about the blog containing this Page.
          "id": "A String", # The identifier of the blog containing this page.
        },
        "etag": "A String", # Etag of the resource.
        "published": "A String", # RFC 3339 date-time when this Page was published.
        "id": "A String", # The identifier for this resource.
        "selfLink": "A String", # The API REST URL to fetch this resource from.
      }

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

    Returns:
      An object of the form:

        {
          "status": "A String", # The status of the page for admin resources (either LIVE or DRAFT).
          "content": "A String", # The body content of this Page, in HTML.
          "kind": "blogger#page", # The kind of this entity. Always blogger#page
          "author": { # The author of this Page.
            "url": "A String", # The URL of the Page creator's Profile page.
            "image": { # The page author's avatar.
              "url": "A String", # The page author's avatar URL.
            },
            "displayName": "A String", # The display name.
            "id": "A String", # The identifier of the Page creator.
          },
          "url": "A String", # The URL that this Page is displayed at.
          "title": "A String", # The title of this entity. This is the name displayed in the Admin user interface.
          "updated": "A String", # RFC 3339 date-time when this Page was last updated.
          "blog": { # Data about the blog containing this Page.
            "id": "A String", # The identifier of the blog containing this page.
          },
          "etag": "A String", # Etag of the resource.
          "published": "A String", # RFC 3339 date-time when this Page was published.
          "id": "A String", # The identifier for this resource.
          "selfLink": "A String", # The API REST URL to fetch this resource from.
        }

`publish(blogId, pageId)`

    Publishes a draft page.

    Args:
      blogId: string, The ID of the blog. (required)
      pageId: string, The ID of the page. (required)

    Returns:
      An object of the form:

        {
          "status": "A String", # The status of the page for admin resources (either LIVE or DRAFT).
          "content": "A String", # The body content of this Page, in HTML.
          "kind": "blogger#page", # The kind of this entity. Always blogger#page
          "author": { # The author of this Page.
            "url": "A String", # The URL of the Page creator's Profile page.
            "image": { # The page author's avatar.
              "url": "A String", # The page author's avatar URL.
            },
            "displayName": "A String", # The display name.
            "id": "A String", # The identifier of the Page creator.
          },
          "url": "A String", # The URL that this Page is displayed at.
          "title": "A String", # The title of this entity. This is the name displayed in the Admin user interface.
          "updated": "A String", # RFC 3339 date-time when this Page was last updated.
          "blog": { # Data about the blog containing this Page.
            "id": "A String", # The identifier of the blog containing this page.
          },
          "etag": "A String", # Etag of the resource.
          "published": "A String", # RFC 3339 date-time when this Page was published.
          "id": "A String", # The identifier for this resource.
          "selfLink": "A String", # The API REST URL to fetch this resource from.
        }

`revert(blogId, pageId)`

    Revert a published or scheduled page to draft state.

    Args:
      blogId: string, The ID of the blog. (required)
      pageId: string, The ID of the page. (required)

    Returns:
      An object of the form:

        {
          "status": "A String", # The status of the page for admin resources (either LIVE or DRAFT).
          "content": "A String", # The body content of this Page, in HTML.
          "kind": "blogger#page", # The kind of this entity. Always blogger#page
          "author": { # The author of this Page.
            "url": "A String", # The URL of the Page creator's Profile page.
            "image": { # The page author's avatar.
              "url": "A String", # The page author's avatar URL.
            },
            "displayName": "A String", # The display name.
            "id": "A String", # The identifier of the Page creator.
          },
          "url": "A String", # The URL that this Page is displayed at.
          "title": "A String", # The title of this entity. This is the name displayed in the Admin user interface.
          "updated": "A String", # RFC 3339 date-time when this Page was last updated.
          "blog": { # Data about the blog containing this Page.
            "id": "A String", # The identifier of the blog containing this page.
          },
          "etag": "A String", # Etag of the resource.
          "published": "A String", # RFC 3339 date-time when this Page was published.
          "id": "A String", # The identifier for this resource.
          "selfLink": "A String", # The API REST URL to fetch this resource from.
        }

`update(blogId, pageId, body, revert=None, publish=None)`

    Update a page.

    Args:
      blogId: string, The ID of the Blog. (required)
      pageId: string, The ID of the Page. (required)
      body: object, The request body. (required)
        The object takes the form of:

    {
        "status": "A String", # The status of the page for admin resources (either LIVE or DRAFT).
        "content": "A String", # The body content of this Page, in HTML.
        "kind": "blogger#page", # The kind of this entity. Always blogger#page
        "author": { # The author of this Page.
          "url": "A String", # The URL of the Page creator's Profile page.
          "image": { # The page author's avatar.
            "url": "A String", # The page author's avatar URL.
          },
          "displayName": "A String", # The display name.
          "id": "A String", # The identifier of the Page creator.
        },
        "url": "A String", # The URL that this Page is displayed at.
        "title": "A String", # The title of this entity. This is the name displayed in the Admin user interface.
        "updated": "A String", # RFC 3339 date-time when this Page was last updated.
        "blog": { # Data about the blog containing this Page.
          "id": "A String", # The identifier of the blog containing this page.
        },
        "etag": "A String", # Etag of the resource.
        "published": "A String", # RFC 3339 date-time when this Page was published.
        "id": "A String", # The identifier for this resource.
        "selfLink": "A String", # The API REST URL to fetch this resource from.
      }

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

    Returns:
      An object of the form:

        {
          "status": "A String", # The status of the page for admin resources (either LIVE or DRAFT).
          "content": "A String", # The body content of this Page, in HTML.
          "kind": "blogger#page", # The kind of this entity. Always blogger#page
          "author": { # The author of this Page.
            "url": "A String", # The URL of the Page creator's Profile page.
            "image": { # The page author's avatar.
              "url": "A String", # The page author's avatar URL.
            },
            "displayName": "A String", # The display name.
            "id": "A String", # The identifier of the Page creator.
          },
          "url": "A String", # The URL that this Page is displayed at.
          "title": "A String", # The title of this entity. This is the name displayed in the Admin user interface.
          "updated": "A String", # RFC 3339 date-time when this Page was last updated.
          "blog": { # Data about the blog containing this Page.
            "id": "A String", # The identifier of the blog containing this page.
          },
          "etag": "A String", # Etag of the resource.
          "published": "A String", # RFC 3339 date-time when this Page was published.
          "id": "A String", # The identifier for this resource.
          "selfLink": "A String", # The API REST URL to fetch this resource from.
        }