by-filename resource endpoint

URL: /blogs/<id>/post-assets/@by-filename/<id>.<format>

This endpoint allows you to take the elements that uniquely identify a post from a URL and find the post, if any, that matches them.

A post is uniquely identified by a year, a month and a filename. The year and month are those in which the post is published, and the filename is either provided by the user or synthesized from the content of the post.

The "id" for this endpoint is a colon-delimited list of year, month and filename. The year must be four digits and the month must be two digits, zero-padded. For example, 2010:08:hello-world.

This endpoint is useful if you are building an alternative blog renderer for a TypePad blog which must figure out what Post to render for the year, month and filename given in a request URL.

Note that since this endpoint is a filter it returns a list of posts, but since the year, month and filename uniquely identify a post this list will only ever contain zero items, if no post matches, or one item if there was a match.

Supported Methods

GET Get zero or one posts matching the given year, month and filename.

Query String Arguments

start-index
Index of the first item to return. The first item in the list has index 1.
max-results
Maximum number of items to return in the list response.

Resource Type

This endpoint returns an object of type List<Post>.

entries (array<Post>)
The items within the selected range.
totalResults (integer)
The total number of items in the whole list of which this object is a chunk.

Client Library Methods for PHP

Get zero or one posts matching the given year, month and filename.
$tp->blogs->getPostAssetsByFilename(array(

    # Required Parameters
    "id" => $id,
    "filename" => $filename,

    # Optional Parameters
    "limit" => $limit,
    "offset" => $offset,

))