Post Lookup

Endpoints:

GET /posts/{post_id}

Scope: none

Retrieve a post object.

URL Parameters

Name Description
post_id Post to retrieve
Example
curl "https://api.pnut.io/v0/posts/20" \
    -H "Authorization: Bearer ${ACCESS_TOKEN}" \
    -H "X-Pretty-Json: 1"

Returns a post

"call for example 1"

GET /posts

Scope: none

Retrieve a list of specified post objects. Only retrieves the first 200 found.

Query String Parameters

Name Description
ids Comma-separated list of post IDs.
Example
curl "https://api.pnut.io/v0/posts?ids=20,21,4" \
    -H "Authorization: Bearer ${ACCESS_TOKEN}" \
    -H "X-Pretty-Json: 1"

Returns a list of posts

"call for example 2"

GET /posts/{post_id}/revisions

Scope: none

Retrieve a list of previous versions of a post, not including the most recent. Currently a post can only have one previous version.

URL Parameters

Name Description
post_id Post ID to retrieve any revisions of
Example
curl "https://api.pnut.io/v0/posts/2392/revisions" \
    -H "Authorization: Bearer ${ACCESS_TOKEN}" \
    -H "X-Pretty-Json: 1"

Returns a list of posts

"call for example 3"