Comment collection¶
Read/write
This resource type refers to a collection of feed-specific comment items.
In other Collection+JSON resource representations this resource type is linked by any link relation with attribute:
"rel": "comments"
-
GET
/api/v1/
(int: feed_id)/comments/
¶ Synopsis: Gets the list of comments for the the feed (feed_id). Example request:
GET /api/v1/35/comments/ HTTP/1.1 Host: localhost:8000 Accept: application/vnd.collection+json
Example response:
HTTP/1.1 200 OK Allow: GET, POST Content-Type: application/vnd.collection+json { "collection": { "href": "https://localhost:8000/api/v1/35/comments/", "items": [ { "data": [ { "name": "title", "value": "Looks good" }, { "name": "owner", "value": "jbernal" }, { "name": "content", "value": "The data looks really good!" } ], "href": "https://localhost:8000/api/v1/comments/1/", "links": [ { "href": "https://localhost:8000/api/v1/35/", "rel": "feed" } ] } ], "links": [ { "href": "https://localhost:8000/api/v1/35/", "rel": "feed" } ], "template": { "data": [ { "name": "title", "value": "" }, { "name": "content", "value": "" } ] }, "version": "1.0" } }
Request Headers: - Accept – application/vnd.collection+json
Response Headers: - Content-Type – application/vnd.collection+json
Status Codes: - 200 OK – no error
- 401 Unauthorized – authentication credentials were not provided
- 404 Not Found – not found
Properties (API semantic descriptors):
- comment item properties
- comment item link relations