GET /read/tags/$tag/posts

Get a list of posts from a tag.

Resource Information

Method GET
Requires authentication? No

Method Parameters

Parameter Type Description
$tag (string) The tag name

Query Parameters

Parameter Type Description
http_envelope (bool)
Some environments (like in-browser JavaScript or Flash) block or divert responses with a non-200 HTTP status code. Setting this parameter will force the HTTP status code to always be 200. The JSON response is wrapped in an "envelope" containing the "real" HTTP status code and headers.
pretty (bool)
Output pretty JSON
meta (string) Optional. Loads data from the endpoints found in the 'meta' part of the response. Comma-separated list. Example: meta=site,likes
fields (string) Optional. Returns specified fields only. Comma-separated list. Example: fields=ID,title
callback (string) An optional JSONP callback function.
number (int) The number of posts to return. Limit: 40. Default: 10.
page (int) Return the Nth 1-indexed page of posts.
order (string)
(default) Return posts in descending order. For dates, that means newest to oldest.
Return posts in ascending order. For dates, that means oldest to newest.
after (iso 8601 datetime) Return posts dated after the specified datetime.
before (iso 8601 datetime) Return posts dated before the specified datetime.

Response Parameters

Parameter Type Description
ID (int) The post ID.
site_ID (int) The site ID.
author (object) The author of the post.
date (iso 8601 datetime) The post's creation time.
modified (iso 8601 datetime) The post's most recent update time.
title (html) context dependent.
URL (url) The full permalink URL to the post.
short_URL (url) The short URL.
content (html) context dependent.
excerpt (html) context dependent.
slug (string) The name (slug) for the post, used in URLs.
guid (string) The GUID for the post.
status (string)
The post is published.
The post is saved as a draft.
The post is pending editorial approval.
The post is published privately
The post is scheduled for future publishing.
The post is in the trash.
The post is a placeholder for a new post.
sticky (bool) Is the post sticky?
password (string) The plaintext password protecting the post, or, more likely, the empty string if the post is not password protected.
parent (object|false) A reference to the post's parent, if it has one.
type (string) The post's post_type. Post types besides post, page and revision need to be whitelisted using the rest_api_allowed_post_types filter.
comments_open (bool) Is the post open for comments?
pings_open (bool) Is the post open for pingbacks, trackbacks?
likes_enabled (bool) Is the post open to likes?
sharing_enabled (bool) Should sharing buttons show on this post?
comment_count (int) The number of comments for this post.
like_count (int) The number of likes for this post.
i_like (bool) Does the current user like this post?
is_reblogged (bool) Did the current user reblog this post?
is_following (bool) Is the current user following this blog?
global_ID (string) A unique representation of a post.
featured_image (url) The URL to the featured image for this post if it has one.
post_thumbnail (object) The attachment object for the featured image if it has one.
format (string)
geo (object|false)
menu_order (int) (Pages Only) The order pages should appear in.
publicize_URLs (array) Array of Twitter and Facebook URLs published by this post.
tags (object) Hash of tags (keyed by tag name) applied to the post.
categories (object) Hash of categories (keyed by category name) applied to the post.
attachments (object) Hash of post attachments (keyed by attachment ID).
metadata (array) Array of post metadata keys and values. All unprotected meta keys are available by default for read requests. Both unprotected and protected meta keys are available for authenticated requests with access. Protected meta keys can be made available with the rest_api_allowed_public_metadata filter.
meta (object) API result meta data
current_user_can (object) List of permissions. Note, deprecated in favor of `capabilities`
capabilities (object) List of post-specific permissions for the user; publish_post, edit_post, delete_post
date_range (object) date range covered by current results.
number (int) The number of posts brought back by current query.
posts (array) An array of post objects.

Resource Errors

These are the possible errors returned by this endpoint.

HTTP Code Error Identifier Error Message
400 invalid_tag The tag requested does not seem to be valid.
403 unauthorized User cannot view taxonomy
403 unauthorized User cannot view post
400 invalid_topic The TOPIC parameter must be specified.
403 unauthorized User cannot edit taxonomy
400 invalid_post Invalid post
400 invalid_context Invalid API CONTEXT
403 unauthorized User cannot edit post
404 unknown_post Unknown post


curl ''
$options  = array (
  'http' => 
  array (
    'ignore_errors' => true,

$context  = stream_context_create( $options );
$response = file_get_contents(
$response = json_decode( $response );


“date_range”: {
“before”: “2016-08-23T05:58:47+00:00”,
“after”: “2016-08-23T06:55:06+01:00”
“number”: 2,
“posts”: [
“ID”: 11,
“site_ID”: 115673171,
“author”: {
“ID”: 108860066,
“login”: “psdfiletomagento”,
“email”: false,
“name”: “psdfiletomagento”,
“first_name”: “”,
“last_name”: “”,
“nice_name”: “psdfiletomagento”,
“URL”: “http:\/\/”,
“avatar_URL”: “https:\/\/\/avatar\/0355773c77446db2bd63cc3f35d3c7d9?s=96&d=identicon&r=G”,
“profile_URL”: “http:\/\/\/psdfiletomagento”,
“site_ID”: 115408980
“date”: “2016-08-23T05:58:47+00:00”,
“modified”: “2016-08-23T05:58:52+00:00”,
“title”: “Top 5 Beautiful & Free Responsive WordPress Themes For Your Online Business”,
“URL”: “https:\/\/\/2016\/08\/23\/top-5-beautiful-free-responsive-wordpress-themes-for-your-online-business\/”,
“short_URL”: “http:\/\/\/p7PlSj-b”,
“content”: “

We all are aware of the humongous advantages come along with choosing WordPress platform for the online business. Selecting a nice and tempting theme without having to pay any cost is one of them. With more than hundred free themes, it’s difficult to choose the best as they aren’t supported properly, or developed by amateurs. However, some WordPress themes are amazing and provide better functionality than many paid themes.\n

Top 5 Free Responsive WordPress\n

To help give you some direction, we put together a list of themes to run through when planning a new e-commerce store. From background effects to classy pages and sub-pages, each one of these themes will impede you to go for a paid theme.\n


With over 600 Google fonts to change the typography, Sydney is a powerful business theme that provides a strong online presence to the businesses. Its full screen header image option can benefact users by letting them add a full screen image or a full screen slide show with a call to action.\n


The parallax effect, which is totally user-oriented, helps in engaging a huge amount of audience. Another feature that makes Sydney stand out in its niche is the custom widgets. There are over 12 widgets in Sydney theme that you can add anywhere on your online store to make it more captivating.\n


If you are looking to