SpyREST

Supported by Mashape

Home » demo.wp-api.org Versions » v2 Resources » comments » GET /wp-json/wp/v2/comments

GET /wp-json/wp/v2/comments

Description

Response Fields

Name Type Description
Array
[].id Integer
[].post Integer
[].parent Integer
[].author Integer
[].author_name String
[].author_url String
[].author_avatar_urls.24 String
[].author_avatar_urls.48 String
[].author_avatar_urls.96 String
[].date String (Time ISO8601)
[].date_gmt String (Time ISO8601)
[].content.rendered String
[].link String
[].status String
[].type String
[]._links.self Array
[]._links.self[].href String
[]._links.collection Array
[]._links.collection[].href String
[]._links.up Array
[]._links.up[].embeddable Boolean
[]._links.up[].post_type String
[]._links.up[].href String
Write
Preview

Examples

Shows all the comments

Shows all the comments

Recorded at

2015-11-22 02:03:32 UTC

Try with cURL

Request URL

GET /wp-json/wp/v2/comments      

Request Headers

proxy-connection: Keep-Alive
accept: */*
user-agent: curl/7.37.1
      

Response Headers

x-amz-cf-id: McIWJzEUE79m9QLnEJV8toFu-gMoEM7h5g6uDMK2fhtSLNdR5fNTpg==
via: 1.1 84da4601f3b7a85ee4beaede1928e823.cloudfront.net (CloudFront)
x-cache: Miss from cloudfront
vary: Cookie
x-wp-totalpages: 21
x-wp-total: 201
x-powered-by: PHP/5.5.9-1ubuntu4.9
x-ec2-instance-id: i-1789a8bd
x-content-type-options: nosniff
x-cached: MISS
x-batcache: HIT
server: nginx/1.4.6 (Ubuntu)
link: <http://demo.wp-api.org/wp-json/wp/v2/comments?page=2>; rel="next"
date: Sun, 22 Nov 2015 02:03:31 GMT
allow: GET
access-control-expose-headers: X-WP-Total, X-WP-TotalPages
access-control-allow-headers: Authorization
connection: close
transfer-encoding: chunked
content-type: application/json; charset=UTF-8
      

Response Body

Shortened for readability

[
  {
    "id": 91,
    "post": 49,
    "parent": 0,
    "author": 0,
    "author_name": "Luisa Bayer",
    "author_url": "https://www.Boyer.com/ea-error-et-quae-venia",
    "author_avatar_urls": {
      "24": "http://0.gravatar.com/avatar/6dc1a8b839f97d2cd06d7028b1b73634?s=24&d=mm&r=g",
      "48": "http://0.gravatar.com/avatar/6dc1a8b839f97d2cd06d7028b1b73634?s=48&d=mm&r=g",
      "96": "http://0.gravatar.com/avatar/6dc1a8b839f97d2cd06d7028b1b73634?s=96&d=mm&r=g"
    },
    "date": "2015-12-29T03:00:52",
    "date_gmt": "2015-12-29T03:00:52",
    "content": {
      "rendered": "<p>Aut voluptates odit sit ducimus. Quidem accusantium iusto sapiente debitis tenetur et. Et odit aspernatur repellendus voluptas.</p>\n<p>Repudiandae nostrum inventore enim sapiente expedita accusamus sunt quia. Voluptatem expedita voluptates dolorem accusantium perferendis ut. Magni perspiciatis ea autem repellendus dolor.</p>\n<p>Rerum laboriosam debitis asperiores omnis nulla odio. Molestiae impedit porro officiis et nesciunt voluptas tempore. Aut aut voluptatem ut voluptatum quia suscipit.</p>\n<p>Est incidunt veritatis dolor qui. Molestias consequatur neque deserunt molestias nam. Natus reiciendis enim quia aut est sint perferendis.</p>\n<p>Commodi aliquam velit possimus ea quaerat. Quasi officiis error aut. Atque exercitationem sed error deserunt.</p>\n<p>Aut illum dolorem eveniet facilis. Eum dolorem dicta magni eum qui veniam ex temporibus. Error natus nihil pariatur officiis rerum minus. Est a suscipit voluptas repudiandae doloremque et.</p>\n<p>Dicta aut rem ipsa quis dolores dicta animi. Perferendis accusamus reprehenderit aut eos explicabo eos deserunt porro. Vel aperiam placeat tempore sit.</p>\n<p>Architecto consequatur occaecati provident voluptatibus cupiditate dicta. Nesciunt quia odio sed. Nisi velit animi sapiente.</p>\n"
    },
    "link": "http://demo.wp-api.org/2015/05/26/commodi-facere-sunt-rerum/comment-page-1/#comment-91",
    "status": "approved",
    "type": "comment",
    "_links": {
      "self": [
        {
          "href": "http://demo.wp-api.org/wp-json/wp/v2/comments/91"
        }
      ],
      "collection": [
        {
          "href": "http://demo.wp-api.org/wp-json/wp/v2/comments"
        }
      ],
      "up": [
        {
          "embeddable": true,
          "post_type": "post",
          "href": "http://demo.wp-api.org/wp-json/wp/v2/posts/49"
        }
      ]
    }
  },
  {
    "id": 136,
    "post": 1,
    "parent": 0,
    "author": 0,
    "author_name": "Ms. Leila Leuschke",
    "author_url": "http://Graham.com/nobis-voluptatum-quod-nobis-asperiore",
    "author_avatar_urls": {
      "24": "http://2.gravatar.com/avatar/e42abcce071f8b87f435f7184eff0fcc?s=24&d=mm&r=g",
      "48": "http://2.gravatar.com/avatar/e42abcce071f8b87f435f7184eff0fcc?s=48&d=mm&r=g",
      "96": "http://2.gravatar.com/avatar/e42abcce071f8b87f435f7184eff0fcc?s=96&d=mm&r=g"
    },
    "date": "2015-12-28T13:20:55",
    "date_gmt": "2015-12-28T13:20:55",
    "content": {
      "rendered": "<p>Voluptatum culpa aut rem saepe voluptatem. Rerum ad ut harum magnam. Consequatur similique necessitatibus blanditiis error magni delectus enim. Architecto magnam harum voluptatibus consequuntur impedit iure. Cupiditate officiis sed quidem.</p>\n"
    },
    "link": "http://demo.wp-api.org/2015/06/03/hello-world/comment-page-1/#comment-136",
    "status": "approved",
    "type": "comment",
    "_links": {
      "self": [
        {
          "href": "http://demo.wp-api.org/wp-json/wp/v2/comments/136"
        }
      ],
      "collection": [
        {
          "href": "http://demo.wp-api.org/wp-json/wp/v2/comments"
        }
      ],
      "up": [
        {
          "embeddable": true,
          "post_type": "post",
          "href": "http://demo.wp-api.org/wp-json/wp/v2/posts/1"
        }
      ]
    }
  }
]