Back to top

The Movable Type Data API is a REST interface to the Movable Type Content Management System. The Data API is available for Movable Type Pro and Movable Type Advanced / Enterprise, Version 6.0 and higher.

Movable Type > 開発者向け ドキュメント > Movable Type Data API ドキュメント

Assets 

This is the Assets resource.

Property NameTypeData TypeDatabase ColumnPrivateRead OnlyDescriptionVersion
blogobject-The blog of this asset.v2
blog.idvaluenumbermt_asset.asset_blog_idYThe ID of the blog that contains this asset.v2
classvaluestringmt_asset.asset_classYThe type of this asset. This value is similar to ‘type’ attribute but this value is never localized.v2
createdByObject-YThe user who created this asset.v2
createdBy.idvaluenumbermt_asset.asset_created_byYYThe ID of user who created asset.v2
createdBy.displayNamevaluestringYThe display name of user who created asset.v2
createdBy.userpicUrlvaluestringYThe URL of creating user’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, empty string will be returned.v2
createdDatevalueiso 8601 datetimemt_asset.asset_created_onYThe created time for this asset.v2
customFieldsARRAY-The list of customfields data for this asset.v2
customFields.basenamevaluestringmt_field.field_basenameThe basename of this customfield.v2
customFields.valuevaluestringThe value of this customfield.v2
descriptionvaluestringmt_asset_asset_descriptionThe description of this asset.v1
fileExtvaluestringmt_asset.asset_file_extYThe file extension of this asset. Returns the file extension without the leading period.v2
filenamevaluestringmt_asset.asset_filenameYThe filename of this asset that includes file extension.v1
idvaluenumbermt_asset.asset_idYThe ID of this asset.v1
labelvaluestringmt_asset.asset_labelThe label of this asset.v1
metaobject-The meta information of this asset.v2
meta.fileSizevaluenumberYThe file size of this asset. If this asset is not file-based asset, will return null.v2
meta.heightvaluenumberYThe height of this asset. If this asset has no height meta information, will return null.v2
meta.widthvaluenumberYThe width of this asset. If this asset has no width meta information, will return null.v2
mimeTypevaluestringmt_asset.asset_mime_typeYThe MIME Type of this asset.v1
modifiedByObject-YThe user who last modified this asset.v2
modifiedBy.displayNamevaluestringYThe display name of user who last modified asset.v2
modifiedBy.idvaluenumbermt_asset.asset_modified_byYYThe ID of user who last modified asset.v2
modifiedBy.userpicUrlvaluestringYThe URL of last modified user’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, empty string will be returned.v2
modifiedDatevalueiso 8601 datetimemt_asset.asset_modified_onYThe last modified time for this asset.v2
parentobject-The parent asset of this asset. If this asset is not a child of any assets, will return null.v2
parent.idvaluenumberasset_parentYThe ID of parent asset.v2
tagsARRAYstringA list of tags associated with this asset.v1
typevaluestringmt_asset.asset_classYThe type of this asset. The value returned will be localized value with DefaultLanguage.v2
updatablevaluebooleanY
true
The user who accessed can update this asset.
false
The user who accessed cannot update this asset.
v2
urlvaluestringmt_asset.asset_urlYThe permalink URL of this asset.v1
        {
          "createdBy" : {
            "id" : 1
            "userpicUrl" : "/mt-static/support/assets_c/userpics/userpic-1-100x100.png",
            "displayName" : "Yuji Takayama"
          },
          "updatable" : false,
          "meta" : {
            "width" : "800",
            "fileSize" : 194272,
            "height" : "600"
          },
          "url" : "http://example.com/images/1ab89ee2.jpg",
          "id" : "5",
          "modifiedDate" : "2014-11-05T12:59:36+09:00",
          "modifiedBy" : {
            "id" : 1
            "userpicUrl" : "/mt-static/support/assets_c/userpics/userpic-1-100x100.png",
            "displayName" : "Yuji Takayama"
          },
          "parent" : null,
          "blog" : {
            "id" : "22"
          },
          "description" : "Cat photo",
          "tags" : [
            "black",
            "cat",
            "white"
          ],
          "filename" : "1ab89ee2.jpg",
          "type" : "Images",
          "mimeType" : "image/jpeg",
          "label" : "Cat One",
          "createdDate" : "2014-11-05T12:58:52+09:00",
          "class" : "image",
          "customFields" : [],
          "fileExtension" : "jpg"
        },

uploadAssetForSite 

Upload a file to specific site.
/sites/:site_id/assets/upload
  • This endpoint is marked as deprecated in v2.0.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to upload file.
404Not FoundSite not found.
409ConflictUploaded file already exists.
413Request Entity Too LargeUpload file size is larger than CGIMaxUpload.

Permissions

  • upload

Request Body Parameters

NameTypeRequiredDefaultDescription
pathstringYesThe upload destination. You can specify the path to be under the site path.
filefileYesActual file data
autoRenameIfExistsbooleanfalseIf this value is true and a file with the same filename exists, the uploaded file is automatically renamed to a random generated name.
normalizeOrientationbooleantrueIf this value is true and the uploaded file has orientation information in Exif data, this file’s orientation is automatically normalized.
  • Parameters
  • site_id
    number (required) 

    The site ID.

  • Request  Assets resource
  • Headers
    Content-Type: multipart/form-data
    Body
    path=/images&file=filedata&autoRenameIfExists=true&normalizeOrientation=false
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "id" : 1,
      "label" : "The Bridge",
      "mimeType" : "image/jpeg",
      "url" : "http://example.com/images/the-bridge.jpg",
      "filename" : "the-bridge",
      "description" : "Taken from over the bridge.",
      "tags" : [
        "boston",
        "bridge",
        "light"
      ],
      "blog" : {
        "id" : 1
      },
      "updatable" : true,
      "modifiedBy" : {
        "id" : 1,
        "displayName" : "Yuji Takayama",
        "userpicUrl" : null
      },
      "modifiedDate" : "2014-10-10T13:13:01+09:00",
      "createdBy" : {
        "id" : 1,
        "displayName" : "Yuji Takayama",
        "userpicUrl" : null
      },
      "cratedDate" : "2014-10-10T13:13:01+09:00",
      "type" : "Image",
      "class" : "image",
      "fileExt" : "jpg",
      "parent" : {
        "id" : null
      },
      "meta" : {
        "height" : 768,
        "width" : 1024,
        "fileSize" : 339773
      }
    }
    

uploadAsset 

New in v2.0: Upload a file.
/assets/upload(?overwrite_once)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to upload file.
404Not FoundSite not found.
409ConflictUploaded file already exists.
413Request Entity Too LargeUpload file size is larger than CGIMaxUpload.

Permissions

  • upload

Request Body Parameters

NameTypeRequiredDefaultDescription
site_idnumberYesThe site ID.
pathstringYesThe upload destination. You can specify the path to be under the site path.
filefileYesActual file data
autoRenameIfExistsbooleanfalseIf this value is true and a file with the same filename exists, the uploaded file is automatically renamed to a random generated name.
normalizeOrientationbooleantrueIf this value is true and the uploaded file has orientation information in Exif data, this file’s orientation is automatically normalized.
  • Parameters
  • overwrite_once
    number (optional) 

    If specify “1”, the API always overwrites an existing file with the uploaded file. This parameter is available in Movable Type 6.1.2

  • Request  Assets resource
  • Headers
    Content-Type: multipart/form-data
    Body
    site_id=1&path=/images&file=filedata&autoRenameIfExists=true&normalizeOrientation=false
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "id" : 1,
      "label" : "The Bridge",
      "mimeType" : "image/jpeg",
      "url" : "http://example.com/images/the-bridge.jpg",
      "filename" : "the-bridge",
      "description" : "Taken from over the bridge.",
      "tags" : [
        "boston",
        "bridge",
        "light"
      ],
      "blog" : {
        "id" : 1
      },
      "updatable" : true,
      "modifiedBy" : {
        "id" : 1,
        "displayName" : "Yuji Takayama",
        "userpicUrl" : null
      },
      "modifiedDate" : "2014-10-10T13:13:01+09:00",
      "createdBy" : {
        "id" : 1,
        "displayName" : "Yuji Takayama",
        "userpicUrl" : null
      },
      "cratedDate" : "2014-10-10T13:13:01+09:00",
      "type" : "Image",
      "class" : "image",
      "fileExt" : "jpg",
      "parent" : {
        "id" : null
      },
      "meta" : {
        "height" : 768,
        "width" : 1024,
        "fileSize" : 339773
      }
    }
    

listAssets 

New in v2.0: Retrieve assets in the specified site.
/sites/:site_id/assets(?search, searchFields, limit, offset, class, sortBy, sortOrder, fields, relatedAssets)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of assets.
404Not FoundSite not found.
  • Parameters
  • site_id
    number (required) 

    The site ID. If 0 specified, will retrieve system-level assets.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: label 

    The comma separated list of field names to search.

    limit
    number (optional) Default: 10 

    Maximum number of assets to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    class
    string (optional) 

    The target asset class to retrieve. Supported values are 'image’, 'audio’, 'video’, 'file’, and any values added by plugins. If you want to retrieve multiple classes, specify the values separated by commas.

    sortBy
    string (optional) Default: created_on 
    file_name
    Sort by the filename of each asset.
    created_by
    Sort by the ID of user who created each asset.
    created_on
    (default) Sort by the created time of each asset.
    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return assets in descending order. For sorting by date, it means from newest to oldest.
    ascend
    Return assets in ascending order. For sorting by date, it means from oldest to newest.
    fields
    string (optional) 

    The field list to retrieve as part of the Assets resource. The list of field names should be separated by commas. If this parameter is not specified, all fields will be returned.

    relatedAssets
    boolean (optional) 

    If you want to retrieve related assets (e.g. thumbnail, popup html) that generated by original asset, you should specify this parameter as true.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
      {
        "id" : 1,
        "label" : "The Bridge",
        "mimeType" : "image/jpeg",
        "url" : "http://example.com/images/the-bridge.jpg",
        "filename" : "the-bridge",
        "description" : "Taken from over the bridge.",
        "tags" : [
          "boston",
          "bridge",
          "light"
        ],
        "blog" : {
          "id" : 1
        },
        "updatable" : true,
        "modifiedBy" : {
          "id" : 1,
          "displayName" : "Yuji Takayama",
          "userpicUrl" : null
        },
        "modifiedDate" : "2014-10-10T13:13:01+09:00",
        "createdBy" : {
          "id" : 1,
          "displayName" : "Yuji Takayama",
          "userpicUrl" : null
        },
        "cratedDate" : "2014-10-10T13:13:01+09:00",
        "type" : "Image",
        "class" : "image",
        "fileExt" : "jpg",
        "parent" : {
          "id" : null
        },
        "meta" : {
          "height" : 768,
          "width" : 1024,
          "fileSize" : 339773
        }
      ]
    }
    

listAssetsForEntry 

New in v2.0: Retrieve assets that related with specified entry.
/sites/:site_id/entries/:entry_id/assets(?limit, offset, class, sortBy, sortOrder, fields)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of assets.
404Not FoundSite or entry not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    entry_id
    number (required) 

    The entry ID.

    limit
    number (optional) Default: 10 

    Maximum number of assets to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    class
    string (optional) 

    The target asset class to retrieve. Supported values are image, audio, video, file and any values added by plugins. If you want to retrieve multiple classes, specify the values separated by commas.

    sortBy
    string (optional) Default: created_on 
    file_name
    Sort by the filename of each asset.
    created_by
    Sort by the ID of user who created each asset.
    created_on
    (default) Sort by the created time of each asset.
    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return assets in descending order. For sorting by date, it means from newest to oldest.
    ascend
    Return assets in ascending order. For sorting by date, it means from oldest to newest.
    fields
    string (optional) 

    The field list to retrieve as part of the Assets resource. The list of field names should be separated by commas. If this parameter is not specified, all fields will be returned.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
      {
        "id" : 1,
        "label" : "The Bridge",
        "mimeType" : "image/jpeg",
        "url" : "http://example.com/images/the-bridge.jpg",
        "filename" : "the-bridge",
        "description" : "Taken from over the bridge.",
        "tags" : [
          "boston",
          "bridge",
          "light"
        ],
        "blog" : {
          "id" : 1
        },
        "updatable" : true,
        "modifiedBy" : {
          "id" : 1,
          "displayName" : "Yuji Takayama",
          "userpicUrl" : null
        },
        "modifiedDate" : "2014-10-10T13:13:01+09:00",
        "createdBy" : {
          "id" : 1,
          "displayName" : "Yuji Takayama",
          "userpicUrl" : null
        },
        "cratedDate" : "2014-10-10T13:13:01+09:00",
        "type" : "Image",
        "class" : "image",
        "fileExt" : "jpg",
        "parent" : {
          "id" : null
        },
        "meta" : {
          "height" : 768,
          "width" : 1024,
          "fileSize" : 339773
        }
      ]
    }
    

listAssetsForPage 

New in v2.0: Retrieve assets that related with specified page.
/sites/:site_id/pages/:page_id/assets(?limit, offset, class, sortBy, sortOrder, fields)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of assets.
404Not FoundSite or page not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    page_id
    number (required) 

    The page ID.

    limit
    number (optional) Default: 10 

    Maximum number of assets to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    class
    string (optional) 

    The target asset class to retrieve. Supported values are image, audio, video, file and any values added by plugins. If you want to retrieve multiple classes, specify the values separated by commas.

    sortBy
    string (optional) Default: created_on 
    file_name
    Sort by the filename of each asset.
    created_by
    Sort by the ID of user who created each asset.
    created_on
    (default) Sort by the created time of each asset.
    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return assets in descending order. For sorting by date, it means from newest to oldest.
    ascend
    Return assets in ascending order. For sorting by date, it means from oldest to newest.
    fields
    string (optional) 

    The field list to retrieve as part of the Assets resource. The list of field names should be separated by commas. If this parameter is not specified, all fields will be returned.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
      {
        "id" : 1,
        "label" : "The Bridge",
        "mimeType" : "image/jpeg",
        "url" : "http://example.com/images/the-bridge.jpg",
        "filename" : "the-bridge",
        "description" : "Taken from over the bridge.",
        "tags" : [
          "boston",
          "bridge",
          "light"
        ],
        "blog" : {
          "id" : 1
        },
        "updatable" : true,
        "modifiedBy" : {
          "id" : 1,
          "displayName" : "Yuji Takayama",
          "userpicUrl" : null
        },
        "modifiedDate" : "2014-10-10T13:13:01+09:00",
        "createdBy" : {
          "id" : 1,
          "displayName" : "Yuji Takayama",
          "userpicUrl" : null
        },
        "cratedDate" : "2014-10-10T13:13:01+09:00",
        "type" : "Image",
        "class" : "image",
        "fileExt" : "jpg",
        "parent" : {
          "id" : null
        },
        "meta" : {
          "height" : 768,
          "width" : 1024,
          "fileSize" : 339773
        }
      ]
    }
    

listAssetsForSiteAndTag 

New in v2.0: Retrieve assets that related with specified tag.
/sites/:site_id/tags/:tag_id/assets(?limit, offset, class, sortBy, sortOrder, fields)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of assets.
404Not FoundSite or tag not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    tag_id
    number (required) 

    The tag ID.

    limit
    number (optional) Default: 10 

    Maximum number of assets to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    class
    string (optional) 

    The target asset class to retrieve. Supported values are image, audio, video, file and any values added by plugins. If you want to retrieve multiple classes, specify the values separated by commas.

    sortBy
    string (optional) Default: created_on 
    file_name
    Sort by the filename of each asset.
    created_by
    Sort by the ID of user who created each asset.
    created_on
    (default) Sort by the created time of each asset.
    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return assets in descending order. For sorting by date, it means from newest to oldest.
    ascend
    Return assets in ascending order. For sorting by date, it means from oldest to newest.
    fields
    string (optional) 

    The field list to retrieve as part of the Assets resource. The list of fields should be separated by commas. If this parameter is not specified, all fields will be returned.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
      {
        "id" : 1,
        "label" : "The Bridge",
        "mimeType" : "image/jpeg",
        "url" : "http://example.com/images/the-bridge.jpg",
        "filename" : "the-bridge",
        "description" : "Taken from over the bridge.",
        "tags" : [
          "boston",
          "bridge",
          "light"
        ],
        "blog" : {
          "id" : 1
        },
        "updatable" : true,
        "modifiedBy" : {
          "id" : 1,
          "displayName" : "Yuji Takayama",
          "userpicUrl" : null
        },
        "modifiedDate" : "2014-10-10T13:13:01+09:00",
        "createdBy" : {
          "id" : 1,
          "displayName" : "Yuji Takayama",
          "userpicUrl" : null
        },
        "cratedDate" : "2014-10-10T13:13:01+09:00",
        "type" : "Image",
        "class" : "image",
        "fileExt" : "jpg",
        "parent" : {
          "id" : null
        },
        "meta" : {
          "height" : 768,
          "width" : 1024,
          "fileSize" : 339773
        }
      ]
    }
    

getAsset 

New in v2.0: Retrieve single asset by its ID.
/sites/:site_id/assets/:asset_id(?fields)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve an asset.
404Not FoundAsset (or site) not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    asset_id
    number (required) 

    The asset ID.

    fields
    string (optional) 

    The field list to retrieve as part of the Assets resource. The list of field names should be separated by commas. If this parameter is not specified, all fields will be returned.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "id" : 1,
      "label" : "The Bridge",
      "mimeType" : "image/jpeg",
      "url" : "http://example.com/images/the-bridge.jpg",
      "filename" : "the-bridge",
      "description" : "Taken from over the bridge.",
      "tags" : [
        "boston",
        "bridge",
        "light"
      ],
      "blog" : {
        "id" : 1
      },
      "updatable" : true,
      "modifiedBy" : {
        "id" : 1,
        "displayName" : "Yuji Takayama",
        "userpicUrl" : null
      },
      "modifiedDate" : "2014-10-10T13:13:01+09:00",
      "createdBy" : {
        "id" : 1,
        "displayName" : "Yuji Takayama",
        "userpicUrl" : null
      },
      "cratedDate" : "2014-10-10T13:13:01+09:00",
      "type" : "Image",
      "class" : "image",
      "fileExt" : "jpg",
      "parent" : {
        "id" : null
      },
      "meta" : {
        "height" : 768,
        "width" : 1024,
        "fileSize" : 339773
      }
    }
    

updateAsset 

New in v2.0: Update an asset.
/sites/:site_id/assets/:asset_id
  • Authorization is required.

  • This method accepts PUT and POST with __method=PUT.

Status Code

CodeStatusDescription
200OKNo Errors.
401UnauthorizedAuthentication required
403ForbiddenDo not have permission to update an asset.
404Not FoundAsset (or site) not found.
405Method Not AllowedRequest method is not ‘PUT’ or ‘POST’ with ‘__method=PUT’

Permissions

  • Manage Assets
  • Parameters
  • site_id
    number (required) 

    The site ID.

    asset_id
    number (required) 

    The asset ID.

  • Request  Assets resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    asset={
      "url" : "http://localhost/blog/20140917-2/images/0cf61aae.jpg",
      "id" : "1",
      "parent" : null,
      "blog" : {
        "id" : "1"
      },
      "description" : "Over the rainbow.",
      "tags" : [
        "boston",
        "bridge",
        "light",
        "night"
      ],
      "label" : "Night Bridge",
    }
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "id" : 1,
      "label" : "Night Bridge",
      "mimeType" : "image/jpeg",
      "url" : "http://example.com/images/the-bridge.jpg",
      "filename" : "the-bridge",
      "description" : "Over the rainbow.",
      "tags" : [
        "boston",
        "bridge",
        "light",
        "night"
      ],
      "blog" : {
        "id" : 1
      },
      "updatable" : true,
      "modifiedBy" : {
        "id" : 1,
        "displayName" : "Yuji Takayama",
        "userpicUrl" : null
      },
      "modifiedDate" : "2014-10-10T14:13:01+09:00",
      "createdBy" : {
        "id" : 1,
        "displayName" : "Yuji Takayama",
        "userpicUrl" : null
      },
      "cratedDate" : "2014-10-10T13:13:01+09:00",
      "type" : "Image",
      "class" : "image",
      "fileExt" : "jpg",
      "parent" : {
        "id" : null
      },
      "meta" : {
        "height" : 768,
        "width" : 1024,
        "fileSize" : 339773
      }
    }
    

deleteAsset 

New in v2.0: Delete an asset.
/sites/:site_id/assets/:asset_id
  • Authorization is required.

  • This method accepts DELETE and POST with __method=DELETE.

Status Code

CodeStatusDescription
200OKNo Errors.
401UnauthorizedAuthentication required
403ForbiddenDo not have permission to delete an asset.
404Not FoundAsset (or site) not found.
405Method Not AllowedRequest method is not ‘DELETE’ or ‘POST’ with ‘__method=DELETE’

Permissions

  • Manage Assets
  • Parameters
  • site_id
    number (required) 

    The site ID.

    asset_id
    number (required) 

    The asset ID.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "id" : 1,
      "label" : "The Bridge",
      "mimeType" : "image/jpeg",
      "url" : "http://example.com/images/the-bridge.jpg",
      "filename" : "the-bridge",
      "description" : "Taken from over the bridge.",
      "tags" : [
        "boston",
        "bridge",
        "light"
      ],
      "blog" : {
        "id" : 1
      },
      "updatable" : false,
      "modifiedBy" : {
        "id" : 1,
        "displayName" : "Yuji Takayama",
        "userpicUrl" : null
      },
      "modifiedDate" : "2014-10-10T13:13:01+09:00",
      "createdBy" : {
        "id" : 1,
        "displayName" : "Yuji Takayama",
        "userpicUrl" : null
      },
      "cratedDate" : "2014-10-10T13:13:01+09:00",
      "type" : "Image",
      "class" : "image",
      "fileExt" : "jpg",
      "parent" : {
        "id" : null
      },
      "meta" : {
        "height" : 768,
        "width" : 1024,
        "fileSize" : 339773
      }
    }
    

getThubmbnail 

New in v2.0: Get thumbnail of an asset.
/sites/:site_id/assets/:asset_id/thumbnail(?width, height, scale, square)

This endpoint requires one of parameter ‘width’ or ‘height’ or ‘scale’ Also, cannot use these parameters at same time.

Status Code

CodeStatusDescription
200OKNo Errors.
400Bad RequestAn asset does not support to generate thumbnail file.
403ForbiddenDo not have permission to update an asset.
404Not FoundAsset (or site) not found.

Permissions

  • Parameters
  • site_id
    number (required) 

    The site ID.

    asset_id
    number (required) 

    The asset ID.

    width
    number (optional) 

    The width of the thumbnail to generate. If this is the only parameter specified then the thumbnail’s width will be scaled proportionally to the height. When a value longer than the original image is specified, it will be ignored.

    height
    number (optional) 

    The height of the thumbnail to generate. If this is the only parameter specified then the thumbnail’s height will be scaled proportionally to the width. When both of height and width are specified, the longer side of the original image will be processed, and the lesser side will be scaled proportionally.

    scale
    string (optional) 

    The percentage by which to reduce or increase the size of the current asset.

    square
    boolean (optional) 

    If set to true then the thumbnail generated will be square, where the length of each side of the square will be equal to the shortest side of the image.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "height": 200,
      "width": 200,
      "url": "http://example.com/assets_c/2014/10/the-bridge-200x200-1.jpg"
    }
    

Authentication 

authorization 

Show sign in screen, then redirect to application screen.
/authorization?(redirectUrl,clientId)
  • Parameters
  • redirectUrl
    string (required) 

    After a successful sign-in, you will be redirected to the specified URL with "#_login".

    clientId
    string (required) 

    The client ID of the application. You should use same clientid in you app.

  • Response  200
  • Headers
    Content-Type: application/json

authentication 

Create new session and access token. This is like sign-in.
/authentication
  • Attributes
    • username (required, string) … The username to authenticate.
    • password (required, string) … The password of the user.
    • remember (optional, boolean) … If true (generally, “1” is specified.), a new session will be created as a persistent session. If you want to specify false, you can pass “” or “0” to this parameter.
    • clientId (optional, string) … If you want create a new session or access token, you should specify the clientId. If you specify session id via “X-MT-Authorization” in the request header, clientId is not required.
    • mtDataApiLoginMagicToken (optional, string) … This is not required if you authenticate except via browser. If this parameter is passed and valid Movable Type will set cookie in order to start a session.
  • Request
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    username=<Your Sign-in Name>&password=<Your sign-in Password>&clientid=<Your Client ID>
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
        {
          "accessToken" : "EowKdyeBcEUNbiFEXlp0bdQz5RJgdkJYLbBDRJ4m",
          "sessionId" : "8VtaTLTLp8V9OR5Dz40hO7by8wf0wbCsCkBue0Xv",
          "expiresIn" : 3600,
          "remember" : true
        }
    
  • Response  401
  • Headers
    Content-Type: application/json
    Body
        {
          "error" : {
            "code" : 401,
            "message" : "Invalid login"
          }
        }
    

revokeAuthentication 

Invalidate current session. This is like logout.
/authentication
  • Invalidate current session. This is like logout. All access tokens related to that session are invalidated too.

  • This method accepts DELETE and POST with __method=DELETE.

  • Attributes

    • clientId (optional, string) … If you specify session id via “X-MT-Authorization” in the request header, clientId is not required.
  • Request
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth sessionId=<SessionId>
  • Response  200
  • Headers
    Content-Type: application/json
    Body
        {
          "status" : "success"
        }
    

token 

Create new access token related to current session.
/token
  • Attributes
    • clientId (optional, string) … If you specify session id via “X-MT-Authorization” in the request header, clientId is not required.
  • Request
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth sessionId=<SessionId>
  • Response  200
  • Headers
    Content-Type: application/json
    Body
        {
          "accessToken" : "EowKdyeBcEUNbiFEXlp0bdQz5RJgdkJYLbBDRJ4m",
          "expiresIn" : 3600,
        }
    
  • Response  401
  • Headers
    Content-Type: application/json
    Body
        {
          "error" : {
            "code" : 401,
            "message" : "Unauthorized"
          }
        }
    

RevokeToken 

Invalidate current access token. This is not logout.
/token
  • Invalidate current access token. This is not logout. If the browser has active session id, new access token can be obtained easily.

  • This method accepts DELETE and POST with __method=DELETE.

  • Request
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth accessToken=<AccessToken>
  • Response  200
  • Headers
    Content-Type: application/json
    Body
        {
          "status" : "success"
        }
    

Categories 

This is the Categories resource.

Property NameTypeData TypeDatabase ColumnPrivateRead OnlyDescriptionVersion
archiveLinkvaluestringYThe category archive URL of this category. If “Category” archive mapping is not configured, this value will be null.v2
basenamevaluestringmt_category_category_basenameThe basename of this category.v1
blogobject-The blog of this category.v1
blog.idvaluenumbermt_category.category_blog_idYThe ID of the blog that contains this category.v1
classvaluestringmt_category.category_classYThe object class for this category.v1
createdByObject-YThe user who created this category.v2
createdBy.displayNamevaluestringYThe display name of the user who created this category.v2
createdBy.idvaluenumbermt_category.category_created_byYYThe ID of the user who created this category.v2
createdBy.userpicUrlvaluestringYThe URL of created user’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, empty string will be returned.v2
createdDatevalueiso 8601 datetimemt_ctegory.category_created_onYThe created time for this category.v2
customFieldsARRAY-The list of customfields data for this category.v1
customFields.basenamevaluestringmt_field.field_basenameThe basename of this customfield.v1
customFields.valuevaluestringThe value of this customfield.v1
descriptionvaluestringmt_category.category_descriptionYThe description of this category.v1
idvaluenumbermt_category.category_idYThe ID of this category.v1
labelvaluestringmt_category.category_labelYThe label of this category.v1
modifiedByObject-YThe user who last modified this category.v2
modifiedBy.idvaluenumbermt_category.category_modified_byYYThe ID of user who last modified category.v2
modifiedBy.displayNamevaluestringYThe display name of user who last modified category.v2
modifiedBy.userpicUrlvaluestringYThe URL of last modified user’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, empty string will be returned.v2
modifiedDatevalueiso 8601 datetimemt_category.category_modified_onYThe last modified time for this category.v2
parentvaluenumbermt_category.cateogry_parentThe ID of the parent category for this category. This field can be updated from v2.v1
updatablevaluebooleanY
true
The user who accessed can update this category.
false
The user who accessed cannot update this category.
v2
        {
          "parent" : "0",
          "createdBy" : {
            "id" : 1
            "userpicUrl" : "/mt-static/support/assets_c/userpics/userpic-1-100x100.png",
            "displayName" : "Yuji Takayama"
          },
          "updatable" : false,
          "blog" : {
            "id" : "22"
          },
          "description" : "This category includes news articles",
          "basename" : "news",
          "archiveLink" : "http://example.com/news/index.html",
          "id" : 23,
          "class" : "category",
          "label" : "News",
          "createdDate" : "2014-11-05T12:48:27+09:00",
          "modifiedDate" : "2014-11-05T12:52:51+09:00",
          "modifiedBy" : {
            "id" : 1
            "userpicUrl" : "/mt-static/support/assets_c/userpics/userpic-1-100x100.png",
            "displayName" : "Yuji Takayama"
          },
          "customFields" : [
            {
              "basename" : "bannerimage",
              "value" : "<form mt:asset-id=\"3\" class=\"mt-enclosure mt-enclosure-image\" style=\"display: inline;\"><a href=\"http://localhost/blog/20141105-1/images/4db95178.png\">4db95178.png</a></form>"
            },
            {
              "basename" : "address",
              "value" : ""
            }

listCategories 

Retrieve categories in the specified site.
/sites/:site_id/categories(?search, searchFields, limit, offset, sortBy, sortOrder, fields, top, includeIds, excludeIds)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of categories.
404Not FoundSite not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: label,basename 

    The comma separated list of field names to search.

    limit
    number (optional) Default: 10 

    Maximum number of categories to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: user_custom 
    user_custom
    Sort order you specified on the Manage Categories screen.
    created_by
    Sort by the ID of user who created each category.
    id
    Sort by the ID of each category.
    basename
    Sort by the basename of each category.
    label
    Sort by the label of each category.
    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return categories in descending order.
    ascend
    Return categories in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Categories resource. The list of field names should be separated by commas. If this parameter is not specified, all fields will be returned.

    top
    number (optional) Default: 0 

    If set to 1, retrieves only top level categories. New in v2

    includeIds
    string (optional) 

    The comma separated list of category IDs to include in result.

    excludeIds
    string (optional) 

    The comma separated list of category IDs to exclude from result.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : "1",
      "items" : [
        {
        "basename" : "news",
        "parent" : "0",
        "archiveLink" : "http://example.com/news/index.html",
        "updatable" : false,
        "label" : "News",
        "class" : "category",
        "id" : 2,
        "blog" : {
          "id" : "1"
        },
        "description" : null
      ]
    }
    

listCategoriesForEntry 

New in v2.0: Retrieve categories in the specified entry.
/sites/:site_id/entries/:entry_id/categories(?search, searchFields, limit, offset, sortBy, sortOrder, fields, type, includeIds, excludeIds, top)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of categories.
404Not FoundSite or Entry not found.

Permissions

  • edit_entry
    • If want to retrieve the non-published entry’s categories.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    entry_id
    number (required) 

    The entry ID.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: label,basename 

    The comma separated list of field names to search.

    limit
    number (optional) Default: 10 

    Maximum number of categories to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: user_custom 
    user_custom
    Sort order you specified on the Manage Categories screen.
    created_by
    Sort by the ID of user who created each category.
    id
    Sort by the ID of each category.
    basename
    Sort by the basename of each category.
    label
    Sort by the label of each category.
    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return categories in descending order.
    ascend
    Return categories in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Categories resource. The list of field names should be separated by commas. If this parameter is not specified, all fields will be returned.

    top
    number (optional) Default: 0 

    If set to 1, retrieves only top level categories. New in v2

    includeIds
    string (optional) 

    The comma separated list of category IDs to include in result.

    excludeIds
    string (optional) 

    The comma separated list of category IDs to exclude from result.

    type
    string (optional) 
    primary
    Retrieve primary category only
    secondary
    Retrieve secondary categories only
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : "1",
      "items" : [
        {
        "basename" : "news",
        "parent" : "0",
        "archiveLink" : "http://example.com/news/index.html",
        "updatable" : false,
        "label" : "News",
        "class" : "category",
        "id" : 2,
        "blog" : {
          "id" : "1"
        },
        "description" : null
      ]
    }
    

listParentCategories 

New in v2.0: Retrieve parent categories from the specified category.
/sites/:site_id/categories/:category_id/parents(?maxDepth, includeCurrent)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of categories.
404Not FoundSite or Category not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    category_id
    number (required) 

    The category ID.

    maxDepth
    number (optional) Default: 0 

    The depth of retrieving parent categories.

    includeCurrent
    number (optional) Default: 0 
    1
    The list does not include current category.
    0
    The list includes current category.
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : "1",
      "items" : [
        {
        "basename" : "news",
        "parent" : "0",
        "archiveLink" : "http://example.com/news/index.html",
        "updatable" : false,
        "label" : "News",
        "class" : "category",
        "id" : 2,
        "blog" : {
          "id" : "1"
        },
        "description" : null
      ]
    }
    

listSiblingCategories 

New in v2.0: Retrieve siblings categories from the specified category.
/sites/:site_id/categories/:category_id/siblings(?search, searchFields, limit, offset, sortBy, sortOrder, fields, top, includeIds, excludeIds)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of categories.
404Not FoundSite or Category not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    category_id
    number (required) 

    The category ID.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: label,basename 

    The comma separated list of field names to search.

    limit
    number (optional) Default: 10 

    Maximum number of categories to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: user_custom 
    user_custom
    Sort order you specified on the Manage Categories screen.
    created_by
    Sort by the ID of user who created each category.
    id
    Sort by the ID of each category.
    basename
    Sort by the basename of each category.
    label
    Sort by the label of each category.
    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return categories in descending order.
    ascend
    Return categories in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Categories resource. The list of field names should be separated by commas. If this parameter is not specified, all fields will be returned.

    top
    number (optional) Default: 0 

    If set to 1, retrieves only top level categories. New in v2

    includeIds
    string (optional) 

    The comma separated list of category IDs to include in result.

    excludeIds
    string (optional) 

    The comma separated list of category IDs to exclude from result.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : "1",
      "items" : [
        {
        "basename" : "news",
        "parent" : "0",
        "archiveLink" : "http://example.com/news/index.html",
        "updatable" : false,
        "label" : "News",
        "class" : "category",
        "id" : 2,
        "blog" : {
          "id" : "1"
        },
        "description" : null
      ]
    }
    

listChildCategories 

New in v2.0: Retrieve child categories from the specified category.
/sites/:site_id/categories/:category_id/children(?maxDepth, includeCurrent)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of categories.
404Not FoundSite or Category not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    category_id
    number (required) 

    The category ID.

    maxDepth
    number (optional) Default: 0 

    The depth of retrieving parent categories.

    includeCurrent
    number (optional) Default: 0 
    0
    The list does not include current category.
    1
    The list includes current category.
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : "1",
      "items" : [
        {
        "basename" : "news",
        "parent" : "0",
        "archiveLink" : "http://example.com/news/index.html",
        "updatable" : false,
        "label" : "News",
        "class" : "category",
        "id" : 2,
        "blog" : {
          "id" : "1"
        },
        "description" : null
      ]
    }
    

createCategory 

New in v2.0: Create a new category.
/sites/:site_id/categories
  • Authorization is required.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to create a new category.
404Not FoundSite not found.

Permission

  • Manage Categories

Request Body Parameters

NameTypeRequiredDefaultDescription
categoryObjectYesSingle Categories resource
  • Parameters
  • site_id
    number (required) 

    The site ID.

  • Request  Assets resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    category={"basename" : "news","parent" : "0","archiveLink" : "http://example.com/news/index.html","updatable" : false,"label" : "News","class" : "category","id" : "1","blog" : {"id" : "1"},"description" : null,"customFields" : [{"basename" : "bannerImage","value" : "http://example.com/images/banner.jpg"}]}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : "1",
      "items" : [
        {
        "basename" : "news",
        "parent" : "0",
        "archiveLink" : "http://example.com/news/index.html",
        "updatable" : false,
        "label" : "News",
        "class" : "category",
        "id" : 2,
        "blog" : {
          "id" : "1"
        },
        "description" : null
      ]
    }
    

getCategory 

New in v2.0: Retrieve single category by its ID.
/sites/:site_id/categories/:category_id(?fields)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve an category.
404Not FoundCategory or site not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    category_id
    number (required) 

    The category ID.

    fields
    string (optional) 

    The field list to retrieve as part of the Categories resource. The list of field names should be separated by commas. If this parameter is not specified, all fields will be returned.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "basename" : "news",
      "parent" : "0",
      "archiveLink" : "http://example.com/news/index.html",
      "updatable" : false,
      "label" : "News",
      "class" : "category",
      "id" : 2,
      "blog" : {
        "id" : "1"
      },
      "description" : null
    }
    

updateCategory 

New in v2.0: Update an existing category.
/sites/:site_id/categories/:category_id
  • Authorization is required.

  • This method accepts PUT and POST with __method=PUT.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to update a category.
404Not FoundSite or Category not found.

Permission

  • Manage Categories

Request Body Parameters

NameTypeRequiredDefaultDescription
categoryObjectYesSingle Categories resource
  • Parameters
  • site_id
    number (required) 

    The site ID.

    category_id
    number (required) 

    The category ID.

  • Request  Categories resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    category={"basename" : "news","parent" : "0","archiveLink" : "http://example.com/news/index.html","updatable" : false,"label" : "News","class" : "category","id" : "1","blog" : {"id" : "1"},"description" : null,"customFields" : [{"basename" : "bannerImage","value" : "http://example.com/images/banner.jpg"}]}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "basename" : "news",
      "parent" : "0",
      "archiveLink" : "http://example.com/news/index.html",
      "updatable" : false,
      "label" : "News",
      "class" : "category",
      "id" : 2,
      "blog" : {
        "id" : "1"
      },
      "description" : null
    }
    

deleteCategory 

New in v2.0: Delete an existing category.
/sites/:site_id/categories/:category_id
  • Authorization is required.

  • This method accepts DELETE and POST with __method=DELETE.

  • This method returns deleted Category resource.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to delete a category.
404Not FoundSite or Category not found.

Permission

  • Manage Categories
  • Parameters
  • site_id
    number (required) 

    The site ID.

    category_id
    number (required) 

    The category ID.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "basename" : "news",
      "parent" : "0",
      "archiveLink" : "http://example.com/news/index.html",
      "updatable" : false,
      "label" : "News",
      "class" : "category",
      "id" : 2,
      "blog" : {
        "id" : "1"
      },
      "description" : null
    }
    

permutateCategories 

New in v2.0: Rearrange existing categories in a new order.
/sites/:site_id/categories/permutate
  • Authorization is required.

  • This method returns rearranged Categories resource.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to delete a category.
404Not FoundSite not found.

Permission

  • Manage Categories

Request Body Parameters

NameTypeRequiredDefaultDescription
categoriesARRAYYesArray of Categories resource that were rearranged.
  • Parameters
  • site_id
    number (required) 

    The site ID.

  • Request  Assets resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    category=[{"basename" : "news","parent" : "0","archiveLink" : "http://example.com/news/index.html","updatable" : false,"label" : "News","class" : "category","id" : "1","blog" : {"id" : "1"},"description" : null,"customFields" : [{"basename" : "bannerImage","value" : "http://example.com/images/banner.jpg"}]}]
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    [
      {
        "basename" : "news",
        "parent" : "0",
        "archiveLink" : "http://example.com/news/index.html",
        "updatable" : false,
        "label" : "News",
        "class" : "category",
        "id" : 2,
        "blog" : {
          "id" : "1"
        },
        "description" : null
      }
    ]
    

Comments 

This is the Comments resource.

Property NameTypeData TypeDatabase ColumnPrivateRead OnlyDescriptionVersion
authorObject-YThe commenter of this comment.v1
author.idvaluenumbermt_comment.comment_commenter_idYYThe ID of this commenter. If commenter is not a registerd user, this field is empty.v1
author.displayNamevaluestringmt_comment.comment_authorYThe display name of this commenter.v1
author.userpicUrlvaluenumberYThe URL of this commenter’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If a commenter is not a registered user or a commenter does not set own userpic, will be returned empty string.v1
blogObjectYThe blog of this comment.v1
blog.idvaluenumbermt_comment.comment_blog_idYThe ID of the blog that contains this comment.v1
bodyvaluestringmt_comment.comment_textThe contents of this comment.v1
createdByObject-YThe created user of this comment. In most cases, this is alias of author.v2
createdBy.idvaluenumbermt_comment.comment_created_byYYThe ID of created user.v2
createdBy.displayNamevaluestringYThe display name of created user.v2
createdBy.userpicUrlvaluestringYThe URL of created user’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, will be returned empty string.v2
createdDatevalueiso 8601 datetimemt_comment.comment_created_onYThe created time for this comment.v2
customFieldsARRAY-The list of customfields data for this category.v1
customFields.basenamevaluestringmt_field.field_basenameThe basename of this customfield.v1
customFields.valuevaluestringThe value of this customfield.v1
datevalueiso 8601 datetimemt_comment.comment_created_onYThe creation time for this comment. This property is marked as deprecated in v2.0.v1
entryObject-YThe container entry of this comment.v1
entry.idvaluenumbermt_comment.comment_entry_idYThe ID of the entry that contains this comment.v1
idvaluenumbermt_comment.comment_idYThe ID of this comment.v1
linkvaluestringYThe permalink for this comment.v1
modifiedByObject-YThe last modified user of this comment.v2
modifiedBy.displayNamevaluestringYThe display name of last modified user.v2
modifiedBy.idvaluenumbermt_comment.comment_modified_byYYThe ID of last modified user.v2
modifiedBy.userpicUrlvaluestringYThe URL of last modified user’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, will be returned empty string.v2
modifiedDatevalueiso 8601 datetimemt_comment.comment_modified_onYThe last modified time for this comment.v2
parentvaluenumbermt_comment.comment_parent_idThe ID of the parent of this comment. If this comment is not a reply, will be returned as null.v1
statusvaluestringThe publishing status of this comment.
Approved
This comment has been approved.
In the database, comment_visible = 1 and comment_junk_status = 1.
Pending
This comment has not been approved.
In the database, comment_visible = 0 and comment_junk_status = 1.
Spam
This comment has been marked as Spam.
In the database, comment_visible = 0 and comment_junk_status = -1.
v1
updatablevaluebooleanY
true
The user who accessed can update this comment.
false
The user who accessed cannot update this comment.
v1
    {
      "link" : "http://example.com/blog/2014/11/hello-movable-type.html#comment-1",
      "parent" : null,
      "entry" : {
        "id" : "45"
      },
      "createdBy" : {
        "id" : 2
        "userpicUrl" : null,
        "displayName" : "Ichiro Aikawa"
      },
      "status" : "Approved",
      "date" : "2014-11-05T14:41:39+09:00",
      "updatable" : false,
      "blog" : {
        "id" : "22"
      },
      "author" : {
        "id" : 2
        "userpicUrl" : null,
        "displayName" : "Ichiro Aikawa"
      },
      "body" : "<p>Hi, congrats!</p>",
      "createdDate" : "2014-11-05T14:41:39+09:00",
      "id" : 1,
      "modifiedDate" : "2014-11-05T14:41:39+09:00",
      "customFields" : []
    }

listComments 

Retrieve a list of comments in the specified site.
/sites/{site_id}/comments(?search, searchFields, limit, offset, sortBy, sortOrder, fields, includeIds, excludeIds, status, entryStatus)
  • Authorization is required if want to include unpublished comments.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of comments.
404Not FoundSite not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: body 

    The comma separated field name list to search.

    limit
    number (optional) Default: 10 

    Maximum number of comments to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: id 

    The field name for sort.

    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return comments in descending order.
    ascend
    Return comments in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Comments resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    includeIds
    string (optional) 

    The comma separated ID list of comments to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of comments to exclude from result.

    status
    string (optional) 

    Filter by status.

    Approved
    comment_visible is 1 and comment_junk_status is 1.
    Pending
    comment_visible is 0 and comment_junk_status is 1.
    Spam
    comment_junk_status is -1.

    entryStatus
    string (optional) 

    Filter by container entry’s status.

    Draft
    entry_status is 1.
    Publish
    entry_status is 2.
    Review
    entry_status is 3.
    Future
    entry_status is 4.
    Spam
    entry_status is 5.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : "1",
      "items" : [
        {
          "link" : "http://example.com/blog/2014/11/hello-movable-type.html#comment-1",
          "parent" : null,
          "entry" : {
            "id" : "45"
          },
          "createdBy" : {
            "id" : 2
            "userpicUrl" : null,
            "displayName" : "Ichiro Aikawa"
          },
          "status" : "Approved",
          "date" : "2014-11-05T14:41:39+09:00",
          "updatable" : false,
          "blog" : {
            "id" : "22"
          },
          "author" : {
            "id" : 2
            "userpicUrl" : null,
            "displayName" : "Ichiro Aikawa"
          },
          "body" : "<p>Hi, congrats!</p>",
          "createdDate" : "2014-11-05T14:41:39+09:00",
          "id" : 1,
          "modifiedDate" : "2014-11-05T14:41:39+09:00",
          "customFields" : []
        }
      ]
    }
    

listCommentsForEntry 

Retrieve a list of comments for the specified entry.
/sites/{site_id}/entries/{entry_id}/comments(?search, searchFields, limit, offset, sortBy, sortOrder, fields, includeIds, excludeIds, status)
  • Authorization is required if want to include unpublished comments.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of comments.
404Not FoundSite or Entry not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    entry_id
    number (required) 

    The entry ID.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: body 

    The comma separated field name list to search.

    limit
    number (optional) Default: 10 

    Maximum number of comments to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: id 

    The field name for sort.

    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return comments in descending order.
    ascend
    Return comments in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Comments resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    includeIds
    string (optional) 

    The comma separated ID list of comments to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of comments to exclude from result.

    status
    string (optional) 

    Filter by status.

    Approved
    comment_visible is 1 and comment_junk_status is 1.
    Pending
    comment_visible is 0 and comment_junk_status is 1.
    Spam
    comment_junk_status is -1.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : "1",
      "items" : [
        {
          "link" : "http://example.com/blog/2014/11/hello-movable-type.html#comment-1",
          "parent" : null,
          "entry" : {
            "id" : "45"
          },
          "createdBy" : {
            "id" : 2
            "userpicUrl" : null,
            "displayName" : "Ichiro Aikawa"
          },
          "status" : "Approved",
          "date" : "2014-11-05T14:41:39+09:00",
          "updatable" : false,
          "blog" : {
            "id" : "22"
          },
          "author" : {
            "id" : 2
            "userpicUrl" : null,
            "displayName" : "Ichiro Aikawa"
          },
          "body" : "<p>Hi, congrats!</p>",
          "createdDate" : "2014-11-05T14:41:39+09:00",
          "id" : 1,
          "modifiedDate" : "2014-11-05T14:41:39+09:00",
          "customFields" : []
        }
      ]
    }
    

listCommentsForPage 

Retrieve a list of comments for the specified page.
/sites/{site_id}/pages/{page_id}/comments(?search, searchFields, limit, offset, sortBy, sortOrder, fields, includeIds, excludeIds, status)
  • Authorization is required if want to include unpublished comments.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of comments.
404Not FoundSite or Page not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    page_id
    number (required) 

    The page ID.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: body 

    The comma separated field name list to search.

    limit
    number (optional) Default: 10 

    Maximum number of comments to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: id 

    The field name for sort.

    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return comments in descending order.
    ascend
    Return comments in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Comments resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    includeIds
    string (optional) 

    The comma separated ID list of comments to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of comments to exclude from result.

    status
    string (optional) 

    Filter by status.

    Approved
    comment_visible is 1 and comment_junk_status is 1.
    Pending
    comment_visible is 0 and comment_junk_status is 1.
    Spam
    comment_junk_status is -1.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : "1",
      "items" : [
        {
          "link" : "http://example.com/blog/2014/11/hello-movable-type.html#comment-1",
          "parent" : null,
          "entry" : {
            "id" : "45"
          },
          "createdBy" : {
            "id" : 2
            "userpicUrl" : null,
            "displayName" : "Ichiro Aikawa"
          },
          "status" : "Approved",
          "date" : "2014-11-05T14:41:39+09:00",
          "updatable" : false,
          "blog" : {
            "id" : "22"
          },
          "author" : {
            "id" : 2
            "userpicUrl" : null,
            "displayName" : "Ichiro Aikawa"
          },
          "body" : "<p>Hi, congrats!</p>",
          "createdDate" : "2014-11-05T14:41:39+09:00",
          "id" : 1,
          "modifiedDate" : "2014-11-05T14:41:39+09:00",
          "customFields" : []
        }
      ]
    }
    

createComment 

Create a new comment for entry.
/sites/{site_id}/entries/{entry_id}/comments
  • Authorization is required.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to create a new coment.
404Not FoundSite or Entry not found.

Permission

  • Comment

Request Body Parameters

NameTypeRequiredDefaultDescription
commentObjectYesSingle Comments resource
  • Parameters
  • site_id
    number (required) 

    The site ID.

    entry_id
    number (required) 

    The entry ID.

  • Request  Assets resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    comment={"body" : "This is a test comment.\nHe he he"}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "link" : "http://example.com/blog/2014/11/hello-movable-type.html#comment-1",
      "parent" : null,
      "entry" : {
        "id" : "45"
      },
      "createdBy" : {
        "id" : 2
        "userpicUrl" : null,
        "displayName" : "Ichiro Aikawa"
      },
      "status" : "Approved",
      "date" : "2014-11-05T14:41:39+09:00",
      "updatable" : false,
      "blog" : {
        "id" : "22"
      },
      "author" : {
        "id" : 2
        "userpicUrl" : null,
        "displayName" : "Ichiro Aikawa"
      },
      "body" : "<p>Hi, congrats!</p>",
      "createdDate" : "2014-11-05T14:41:39+09:00",
      "id" : 1,
      "modifiedDate" : "2014-11-05T14:41:39+09:00",
      "customFields" : []
    }
    

postNewCommentForEntry 

New In v2.0: Create a new comment for page.
/sites/{site_id}/pages/{page_id}/comments
  • Authorization is required.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to create a new coment.
404Not FoundSite or Page not found.

Permission

  • Comment

Request Body Parameters

NameTypeRequiredDefaultDescription
commentObjectYesSingle Comments resource
  • Parameters
  • site_id
    number (required) 

    The site ID.

    page_id
    number (required) 

    The page ID.

  • Request  Assets resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    comment={"body" : "This is a test comment.\nHe he he"}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "link" : "http://example.com/blog/2014/11/hello-movable-type.html#comment-1",
      "parent" : null,
      "entry" : {
        "id" : "45"
      },
      "createdBy" : {
        "id" : 2
        "userpicUrl" : null,
        "displayName" : "Ichiro Aikawa"
      },
      "status" : "Approved",
      "date" : "2014-11-05T14:41:39+09:00",
      "updatable" : false,
      "blog" : {
        "id" : "22"
      },
      "author" : {
        "id" : 2
        "userpicUrl" : null,
        "displayName" : "Ichiro Aikawa"
      },
      "body" : "<p>Hi, congrats!</p>",
      "createdDate" : "2014-11-05T14:41:39+09:00",
      "id" : 1,
      "modifiedDate" : "2014-11-05T14:41:39+09:00",
      "customFields" : []
    }
    

createReplyComment 

Reply to specified comment.
/sites/{site_id}/comments/{comment_id}/replies
  • Authorization is required.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to reply coment.
404Not FoundSite or Comment not found.

Permission

  • Comment

Request Body Parameters

NameTypeRequiredDefaultDescription
commentObjectYesSingle Comments resource
  • Parameters
  • site_id
    number (required) 

    The site ID.

    comment_id
    number (required) 

    The page ID.

  • Request  Assets resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    comment={"body" : "This is a test comment.\nHe he he"}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "link" : "http://example.com/blog/2014/11/hello-movable-type.html#comment-1",
      "parent" : null,
      "entry" : {
        "id" : "45"
      },
      "createdBy" : {
        "id" : 2
        "userpicUrl" : null,
        "displayName" : "Ichiro Aikawa"
      },
      "status" : "Approved",
      "date" : "2014-11-05T14:41:39+09:00",
      "updatable" : false,
      "blog" : {
        "id" : "22"
      },
      "author" : {
        "id" : 2
        "userpicUrl" : null,
        "displayName" : "Ichiro Aikawa"
      },
      "body" : "<p>Hi, congrats!</p>",
      "createdDate" : "2014-11-05T14:41:39+09:00",
      "id" : 1,
      "modifiedDate" : "2014-11-05T14:41:39+09:00",
      "customFields" : []
    }
    

getComment 

Retrieve a single comment by its ID.
/sites/{site_id}/comments/{comment_id}(?fields)
  • Authorization is required if the comment status is "unpublished". If the comment status is "published", then this method can be called without authorization.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the requested comment.
404Not FoundSite or Comment not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    comment_id
    number (required) 

    The comment ID.

    fields
    string (optional) 

    The field list to retrieve as part of the Comments resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "link" : "http://example.com/blog/2014/11/hello-movable-type.html#comment-1",
      "parent" : null,
      "entry" : {
        "id" : "45"
      },
      "createdBy" : {
        "id" : 2
        "userpicUrl" : null,
        "displayName" : "Ichiro Aikawa"
      },
      "status" : "Approved",
      "date" : "2014-11-05T14:41:39+09:00",
      "updatable" : false,
      "blog" : {
        "id" : "22"
      },
      "author" : {
        "id" : 2
        "userpicUrl" : null,
        "displayName" : "Ichiro Aikawa"
      },
      "body" : "<p>Hi, congrats!</p>",
      "createdDate" : "2014-11-05T14:41:39+09:00",
      "id" : 1,
      "modifiedDate" : "2014-11-05T14:41:39+09:00",
      "customFields" : []
    }
    

updateComment 

Update an exsiting comment.
/sites/{site_id}/comments/{comment_id}
  • Authorization is required.

  • This method accepts PUT and POST with __method=PUT.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to update the requested comment.
404Not FoundSite or Comment not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    comment_id
    number (required) 

    The comment ID.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "link" : "http://example.com/blog/2014/11/hello-movable-type.html#comment-1",
      "parent" : null,
      "entry" : {
        "id" : "45"
      },
      "createdBy" : {
        "id" : 2
        "userpicUrl" : null,
        "displayName" : "Ichiro Aikawa"
      },
      "status" : "Approved",
      "date" : "2014-11-05T14:41:39+09:00",
      "updatable" : false,
      "blog" : {
        "id" : "22"
      },
      "author" : {
        "id" : 2
        "userpicUrl" : null,
        "displayName" : "Ichiro Aikawa"
      },
      "body" : "<p>Hi, congrats!</p>",
      "createdDate" : "2014-11-05T14:41:39+09:00",
      "id" : 1,
      "modifiedDate" : "2014-11-05T14:41:39+09:00",
      "customFields" : []
    }
    

updateComment 

Delete an existing comment.
/sites/{site_id}/comments/{comment_id}
  • Authorization is required.

  • This method accepts PUT and POST with __method=DELETE.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to delete the requested comment.
404Not FoundSite or Comment not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    comment_id
    number (required) 

    The comment ID.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "link" : "http://example.com/blog/2014/11/hello-movable-type.html#comment-1",
      "parent" : null,
      "entry" : {
        "id" : "45"
      },
      "createdBy" : {
        "id" : 2
        "userpicUrl" : null,
        "displayName" : "Ichiro Aikawa"
      },
      "status" : "Approved",
      "date" : "2014-11-05T14:41:39+09:00",
      "updatable" : false,
      "blog" : {
        "id" : "22"
      },
      "author" : {
        "id" : 2
        "userpicUrl" : null,
        "displayName" : "Ichiro Aikawa"
      },
      "body" : "<p>Hi, congrats!</p>",
      "createdDate" : "2014-11-05T14:41:39+09:00",
      "id" : 1,
      "modifiedDate" : "2014-11-05T14:41:39+09:00",
      "customFields" : []
    }
    

Entries 

This is the Entries resource.

Property NameTypeData TypeDatabase ColumnPrivateRead OnlyDescriptionVersion
allowCommentsvaluebooleanmt_entry.entry_allow_comments
false
This entry does not accepts comments. In the database, this value is 0.
true
This entry accepts comments. In the database, this value is 1.
v1
allowTrackbacksvaluebooleanmt_entry.entry_allow_pings
false
This entry does not accepts trackbacks. In the database, this value is 0.
true
This entry accepts trackbacks. In the database, this value is 1.
v1
assetsARRAYAssetsYThe list of related assets for this entry.v1
authorObjectYThe author of this entry.v1
author.displayNamevaluestringmt_author.nickameYThe display name of this entry creator.v1
author.idvaluenumbermt_entry.entry_author_idYYThe ID of this entry creator.v1
author.userpicUrlvaluestringYThe URL of this entry creator’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, will be returned empty string.v1
basenamevaluestringmt_entry.entry_basenameThe basename for this entry.v1
blogObjectYThe blog of this entry.v1
blog.idvaluenumbermt_entry.entry_blog_idYThe ID of the blog that contains this entry.v1
bodyvaluestringmt_entry.entry_textThe contents of this entry that the text format is applied. [update in v2] if you want to get the raw contents, you should sent a “no_text_filter=1” parameter with authenticated request.v1
categoriesARRAYCategoriesA list of categories associated with the entry. The first element of the array is the primary category. OTHER categories are sorted by label category. [Update in v2] The value of this property was changed from “category label” to "Categories object".v1
classvaluestringmt_entry.entry_classYThe object class for this entry.v1
commentCountvaluenumbermt_entry.entry_comment_countYThe number of comments for this entry.v1
commentsARRAYCommentsYThe list of comments for this entry. The list is sorted by ID of the comment and The parent ID of the comment.v1
createdDatevalueiso 8601 datetimemt_entry.entry_created_onYThe created time for this entry.v1
customFieldsARRAYObjectThe list of customfields data for this entry.v1
customField.basenamevaluestringmt_field.field_basenameYThe basename of this customfield.v1
customField.valuevaluestringThe value of this customfield.v1
datevalueiso 8601 datetimemt_entry.entry_authored_onThe published time for this entry.v1
excerptvaluestringmt_entry.entry_excerptThe excerpt value of this entry if one is specified or, if not, an auto-generated excerpt from the Entry Body field followed by an ellipsis (“…”). If an excerpt is auto-generated also note that any HTML is stripped. The length of the auto-generated output of this tag can be set in the blog’s Entry Settings.v1
formatvaluestringmt_entry.entry_convert_breaksYThe text format of this entry.v2
idvaluenumbermt_entry.entry_idYThe ID of this entry.v1
keywordsvaluestringmt_entry.entry_keywordsThe keywords text for this entry.v1
modifiedDatevalueiso 8601 datetimemt_entry.entry_modified_onYThe last modified time for this entry.v1
morevaluestringmt_entry.entry_text_moreThe extended contents for this entry. [update in v2] if you want to get the raw contents, you should sent a “no_text_filter=1” parameter with authenticated request.v1
permalinkvaluevaluestringYThe parmalink URL for this entry.v1
pingsSentUrlARRAYstringYThe list of TrackBack pings sent from this entry.v1
statusvaluestring
Draft
This entry is saved as draft.
entry_status is 1.
Publish
This entry is published.
entry_status is 2.
Review
This entry is waiting for approval.
entry_status is 3.
Future
This entry is scheduled for future publishing.
entry_status is 4.
Spam
This entry is marked as Spam.
entry_status is 5.
v1
tagsARRAYstringThe list of entry tags for this entry.v1
titlevaluestringmt_entry.entry_titleThe title of this entry.v1
trackbackCountvaluenumbermt_entry.entry_comment_countThe number of received trackbacks for this entry.v1
trackbacksARRAYTrackbacksYThe list of received trackbacks for this entry. The list is sorted by the ID of trackback.v1
updatablevaluebooleanY
true
The user who accessed can update this entry.
false
The user who accessed cannot update this entry.
v1
    {
      "excerpt" : "We are excited to announce that Six Apar...",
      "status" : "Publish",
      "date" : "2014-11-14T13:08:42¥u002b09:00",
      "updatable" : false,
      "author" : {
        "userpicUrl" : null,
        "displayName" : "Yuji Takayama"
      },
      "allowComments" : true,
      "comments" : [],
      "permalink" : "http://localhost/blog/20141114-1/2014/11/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
      "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
      "keywords" : "",
      "allowTrackbacks" : false,
      "id" : 5,
      "trackbacks" : [],
      "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
      "trackbackCount" : "0",
      "categories" : [],
      "blog" : {
        "id" : "1"
      },
      "commentCount" : "0",
      "tags" : [],
      "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
      "assets" : [],
      "pingsSentUrl" : [],
      "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
      "class" : "entry",
      "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
      "more" : "",
      "customFields" : [
        {
          "basename" : "place",
          "value" : "New York City"
        },
        {
          "basename" : "agenda",
          "value" : "Movable Type¥nTopics"
        }
      ]
    }

listEntries 

Retrieve a list of entries in the specified site.
/sites/{site_id}/entries(?search, searchFields, limit, offset, sortBy, sortOrder, fields, includeIds, excludeIds, status, maxComments, maxTrackbacks, no_text_filter)
  • Authorization is required if want to include unpublished entries.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of entries.
404Not FoundSite not found.

Permissions

  • edit_entry
    • for retrieve unpublished entry
  • Parameters
  • site_id
    number (required) 

    The site ID.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: title,body,more,keywords,excerpt,basename 

    The comma separated field name list to search.

    limit
    number (optional) Default: 10 

    Maximum number of entries to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: authored_on 

    The field name for sort. You can specify one of following values

    • authored_on
    • title
    • created_on
    • modified_on

    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return entries in descending order.
    ascend
    Return entries in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Entries resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    includeIds
    string (optional) 

    The comma separated ID list of entries to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of entries to exclude from result.

    status
    string (optional) 

    Filter by container entry’s status.

    Draft
    entry_status is 1.
    Publish
    entry_status is 2.
    Review
    entry_status is 3.
    Future
    entry_status is 4.
    Spam
    entry_status is 5.

    maxComments
    number (optional) 

    This is an optional parameter. Maximum number of comments to retrieve as part of the Entries resource. If this parameter is not supplied, no comments will be returned.

    maxTrackbacks
    number (optional) 

    This is an optional parameter. Maximum number of received trackbacks to retrieve as part of the Entries resource. If this parameter is not supplied, no trackbacks will be returned.

    no_text_filter
    number (optional) Default: 0 

    If you want to fetch the raw text, set to '1’. New in v2

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "excerpt" : "We are excited to announce that Six Apar...",
          "status" : "Publish",
          "date" : "2014-11-14T13:08:42¥u002b09:00",
          "updatable" : false,
          "author" : {
            "userpicUrl" : null,
            "displayName" : "Yuji Takayama"
          },
          "allowComments" : true,
          "comments" : [],
          "permalink" : "http://localhost/blog/20141114-1/2014/11/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
          "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
          "keywords" : "",
          "allowTrackbacks" : false,
          "id" : 5,
          "trackbacks" : [],
          "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
          "trackbackCount" : "0",
          "categories" : [],
          "blog" : {
            "id" : "1"
          },
          "commentCount" : "0",
          "tags" : [],
          "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
          "assets" : [],
          "pingsSentUrl" : [],
          "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
          "class" : "entry",
          "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
          "more" : "",
          "customFields" : [
            {
              "basename" : "place",
              "value" : "New York City"
            },
            {
              "basename" : "agenda",
              "value" : "Movable Type¥nTopics"
            }
          ]
        }
      ]
    }
    

listEntriesForCategory 

New in v2.0: Retrieve a list of entries by specific category.
/sites/{site_id}/categories/{category_id}/entries(?search, searchFields, limit, offset, sortBy, sortOrder, fields, includeIds, excludeIds, status, maxComments, maxTrackbacks, no_text_filter)
  • Authorization is required if want to include unpublished entries.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of entries.
404Not FoundSite or Category not found.

Permissions

  • edit_entry
    • for retrieve unpublished entry
  • Parameters
  • site_id
    number (required) 

    The site ID.

    category_id
    number (required) 

    The category ID.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: title,body,more,keywords,excerpt,basename 

    The comma separated field name list to search.

    limit
    number (optional) Default: 10 

    Maximum number of entries to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: authored_on 

    The field name for sort. You can specify one of following values

    • authored_on
    • title
    • created_on
    • modified_on

    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return entries in descending order.
    ascend
    Return entries in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Entries resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    includeIds
    string (optional) 

    The comma separated ID list of entries to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of entries to exclude from result.

    status
    string (optional) 

    Filter by container entry’s status.

    Draft
    entry_status is 1.
    Publish
    entry_status is 2.
    Review
    entry_status is 3.
    Future
    entry_status is 4.
    Spam
    entry_status is 5.

    maxComments
    number (optional) 

    This is an optional parameter. Maximum number of comments to retrieve as part of the Entries resource. If this parameter is not supplied, no comments will be returned.

    maxTrackbacks
    number (optional) 

    This is an optional parameter. Maximum number of received trackbacks to retrieve as part of the Entries resource. If this parameter is not supplied, no trackbacks will be returned.

    no_text_filter
    number (optional) Default: 0 

    If you want to fetch the raw text, set to '1’. New in v2

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "excerpt" : "We are excited to announce that Six Apar...",
          "status" : "Publish",
          "date" : "2014-11-14T13:08:42¥u002b09:00",
          "updatable" : false,
          "author" : {
            "userpicUrl" : null,
            "displayName" : "Yuji Takayama"
          },
          "allowComments" : true,
          "comments" : [],
          "permalink" : "http://localhost/blog/20141114-1/2014/11/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
          "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
          "keywords" : "",
          "allowTrackbacks" : false,
          "id" : 5,
          "trackbacks" : [],
          "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
          "trackbackCount" : "0",
          "categories" : [],
          "blog" : {
            "id" : "1"
          },
          "commentCount" : "0",
          "tags" : [],
          "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
          "assets" : [],
          "pingsSentUrl" : [],
          "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
          "class" : "entry",
          "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
          "more" : "",
          "customFields" : [
            {
              "basename" : "place",
              "value" : "New York City"
            },
            {
              "basename" : "agenda",
              "value" : "Movable Type¥nTopics"
            }
          ]
        }
      ]
    }
    

listEntriesForAsset 

New in v2.0: Retrieve a list of entries that related with specific asset.
/sites/{site_id}/assets/{asset_id}/entries(?search, searchFields, limit, offset, sortBy, sortOrder, fields, includeIds, excludeIds, status, maxComments, maxTrackbacks, no_text_filter)
  • Authorization is required if want to include unpublished entries.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of entries.
404Not FoundSite or Asset not found.

Permissions

  • edit_entry
    • for retrieve unpublished entry
  • Parameters
  • site_id
    number (required) 

    The site ID.

    asset_id
    number (required) 

    The asset ID.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: title,body,more,keywords,excerpt,basename 

    The comma separated field name list to search.

    limit
    number (optional) Default: 10 

    Maximum number of entries to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: authored_on 

    The field name for sort. You can specify one of following values

    • authored_on
    • title
    • created_on
    • modified_on

    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return entries in descending order.
    ascend
    Return entries in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Entries resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    includeIds
    string (optional) 

    The comma separated ID list of entries to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of entries to exclude from result.

    status
    string (optional) 

    Filter by container entry’s status.

    Draft
    entry_status is 1.
    Publish
    entry_status is 2.
    Review
    entry_status is 3.
    Future
    entry_status is 4.
    Spam
    entry_status is 5.

    maxComments
    number (optional) 

    This is an optional parameter. Maximum number of comments to retrieve as part of the Entries resource. If this parameter is not supplied, no comments will be returned.

    maxTrackbacks
    number (optional) 

    This is an optional parameter. Maximum number of received trackbacks to retrieve as part of the Entries resource. If this parameter is not supplied, no trackbacks will be returned.

    no_text_filter
    number (optional) Default: 0 

    If you want to fetch the raw text, set to '1’. New in v2

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "excerpt" : "We are excited to announce that Six Apar...",
          "status" : "Publish",
          "date" : "2014-11-14T13:08:42¥u002b09:00",
          "updatable" : false,
          "author" : {
            "userpicUrl" : null,
            "displayName" : "Yuji Takayama"
          },
          "allowComments" : true,
          "comments" : [],
          "permalink" : "http://localhost/blog/20141114-1/2014/11/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
          "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
          "keywords" : "",
          "allowTrackbacks" : false,
          "id" : 5,
          "trackbacks" : [],
          "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
          "trackbackCount" : "0",
          "categories" : [],
          "blog" : {
            "id" : "1"
          },
          "commentCount" : "0",
          "tags" : [],
          "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
          "assets" : [],
          "pingsSentUrl" : [],
          "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
          "class" : "entry",
          "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
          "more" : "",
          "customFields" : [
            {
              "basename" : "place",
              "value" : "New York City"
            },
            {
              "basename" : "agenda",
              "value" : "Movable Type¥nTopics"
            }
          ]
        }
      ]
    }
    

listEntriesForSiteAndTag 

New in v2.0: Retrieve a list of entries that related with specific tag.
/sites/{site_id}/tags/{tag_id}/entries(?search, searchFields, limit, offset, sortBy, sortOrder, fields, includeIds, excludeIds, status, status, maxComments, maxTrackbacks, no_text_filter)
  • Authorization is required if want to include unpublished entries.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of entries.
404Not FoundSite or Tag not found.

Permissions

  • edit_entry
    • for retrieve unpublished entry
  • Parameters
  • site_id
    number (required) 

    The site ID.

    tag_id
    number (required) 

    The tag ID.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: title,body,more,keywords,excerpt,basename 

    The comma separated field name list to search.

    limit
    number (optional) Default: 10 

    Maximum number of entries to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: authored_on 

    The field name for sort. You can specify one of following values

    • authored_on
    • title
    • created_on
    • modified_on

    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return entries in descending order.
    ascend
    Return entries in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Entries resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    includeIds
    string (optional) 

    The comma separated ID list of entries to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of entries to exclude from result.

    status
    string (optional) 

    Filter by container entry’s status.

    Draft
    entry_status is 1.
    Publish
    entry_status is 2.
    Review
    entry_status is 3.
    Future
    entry_status is 4.
    Spam
    entry_status is 5.

    maxComments
    number (optional) 

    This is an optional parameter. Maximum number of comments to retrieve as part of the Entries resource. If this parameter is not supplied, no comments will be returned.

    maxTrackbacks
    number (optional) 

    This is an optional parameter. Maximum number of received trackbacks to retrieve as part of the Entries resource. If this parameter is not supplied, no trackbacks will be returned.

    no_text_filter
    number (optional) Default: 0 

    If you want to fetch the raw text, set to '1’. New in v2

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "excerpt" : "We are excited to announce that Six Apar...",
          "status" : "Publish",
          "date" : "2014-11-14T13:08:42¥u002b09:00",
          "updatable" : false,
          "author" : {
            "userpicUrl" : null,
            "displayName" : "Yuji Takayama"
          },
          "allowComments" : true,
          "comments" : [],
          "permalink" : "http://localhost/blog/20141114-1/2014/11/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
          "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
          "keywords" : "",
          "allowTrackbacks" : false,
          "id" : 5,
          "trackbacks" : [],
          "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
          "trackbackCount" : "0",
          "categories" : [],
          "blog" : {
            "id" : "1"
          },
          "commentCount" : "0",
          "tags" : [],
          "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
          "assets" : [],
          "pingsSentUrl" : [],
          "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
          "class" : "entry",
          "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
          "more" : "",
          "customFields" : [
            {
              "basename" : "place",
              "value" : "New York City"
            },
            {
              "basename" : "agenda",
              "value" : "Movable Type¥nTopics"
            }
          ]
        }
      ]
    }
    

createEntry 

Create a new entry.
/sites/{site_id}/entries
  • Authorization is required.

Update in v2.0

  • You can attach categories and assets in the one request.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to create a new entry.
404Not FoundSite not found.

Permissions

  • create_post

Request Body Parameters

NameTypeRequiredDefaultDescription
entryObjectYesSingle Entries resource
  • Parameters
  • site_id
    number (required) 

    The site ID.

  • Request  Entries resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    entry={"excerpt" : "We are excited to announce that Six Apar...","status" : "Publish","allowComments" : true,"body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e","keywords" : "","allowTrackbacks" : false,"basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades","title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades","more" : "","customFields" : [{"basename" : "place","value" : "New York City"},{"basename" : "agenda","value" : "Movable Type¥nTopics"}]}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "excerpt" : "We are excited to announce that Six Apar...",
      "status" : "Publish",
      "date" : "2014-11-14T13:08:42¥u002b09:00",
      "updatable" : false,
      "author" : {
        "userpicUrl" : null,
        "displayName" : "Yuji Takayama"
      },
      "allowComments" : true,
      "comments" : [],
      "permalink" : "http://localhost/blog/20141114-1/2014/11/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
      "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
      "keywords" : "",
      "allowTrackbacks" : false,
      "id" : 5,
      "trackbacks" : [],
      "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
      "trackbackCount" : "0",
      "categories" : [],
      "blog" : {
        "id" : "1"
      },
      "commentCount" : "0",
      "tags" : [],
      "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
      "assets" : [],
      "pingsSentUrl" : [],
      "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
      "class" : "entry",
      "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
      "more" : "",
      "customFields" : [
        {
          "basename" : "place",
          "value" : "New York City"
        },
        {
          "basename" : "agenda",
          "value" : "Movable Type¥nTopics"
        }
      ]
    }
    

getEntry 

Retrieve a single entry by its ID.
/sites/{site_id}/entries/{entry_id}(?fields)
  • Authorization is required if the entry status is "unpublished". If the entry status is "published", then this method can be called without authorization.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the requested entry.
404Not FoundSite or Entry not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    entry_id
    number (required) 

    The entry ID.

    fields
    string (optional) 

    The field list to retrieve as part of the Entries resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "excerpt" : "We are excited to announce that Six Apar...",
      "status" : "Publish",
      "date" : "2014-11-14T13:08:42¥u002b09:00",
      "updatable" : false,
      "author" : {
        "userpicUrl" : null,
        "displayName" : "Yuji Takayama"
      },
      "allowComments" : true,
      "comments" : [],
      "permalink" : "http://localhost/blog/20141114-1/2014/11/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
      "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
      "keywords" : "",
      "allowTrackbacks" : false,
      "id" : 5,
      "trackbacks" : [],
      "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
      "trackbackCount" : "0",
      "categories" : [],
      "blog" : {
        "id" : "1"
      },
      "commentCount" : "0",
      "tags" : [],
      "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
      "assets" : [],
      "pingsSentUrl" : [],
      "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
      "class" : "entry",
      "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
      "more" : "",
      "customFields" : [
        {
          "basename" : "place",
          "value" : "New York City"
        },
        {
          "basename" : "agenda",
          "value" : "Movable Type¥nTopics"
        }
      ]
    }
    

updateEntry 

Update an existing entry.
/sites/{site_id}/entries/{entry_id}
  • Authorization is required.

  • This method accepts PUT and POST with __method=PUT.

Update in v2.0

  • You can attach/detach categories and assets in the one request.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to update the speciied entry.
404Not FoundSite or Entry not found.

Permissions

  • edit_entry
    • for retrieve unpublished entry
  • Parameters
  • site_id
    number (required) 

    The site ID.

    entry_id
    number (required) 

    The entry ID.

  • Request  Entries resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    entry={"excerpt" : "We are excited to announce that Six Apar...","status" : "Publish","allowComments" : true,"body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e","keywords" : "","allowTrackbacks" : false,"basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades","title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades","more" : "","customFields" : [{"basename" : "place","value" : "New York City"},{"basename" : "agenda","value" : "Movable Type¥nTopics"}]}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "excerpt" : "We are excited to announce that Six Apar...",
      "status" : "Publish",
      "date" : "2014-11-14T13:08:42¥u002b09:00",
      "updatable" : false,
      "author" : {
        "userpicUrl" : null,
        "displayName" : "Yuji Takayama"
      },
      "allowComments" : true,
      "comments" : [],
      "permalink" : "http://localhost/blog/20141114-1/2014/11/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
      "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
      "keywords" : "",
      "allowTrackbacks" : false,
      "id" : 5,
      "trackbacks" : [],
      "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
      "trackbackCount" : "0",
      "categories" : [],
      "blog" : {
        "id" : "1"
      },
      "commentCount" : "0",
      "tags" : [],
      "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
      "assets" : [],
      "pingsSentUrl" : [],
      "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
      "class" : "entry",
      "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
      "more" : "",
      "customFields" : [
        {
          "basename" : "place",
          "value" : "New York City"
        },
        {
          "basename" : "agenda",
          "value" : "Movable Type¥nTopics"
        }
      ]
    }
    

deleteEntry 

Delete an existing entry.
/sites/{site_id}/entries/{entry_id}
  • Authorization is required. This method accepts PUT and POST with __method=DELETE.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to delete the speciied entry.
404Not FoundSite or Entry not found.

Permissions

  • edit_entry
    • for retrieve unpublished entry
  • Parameters
  • site_id
    number (required) 

    The site ID.

    entry_id
    number (required) 

    The entry ID.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "excerpt" : "We are excited to announce that Six Apar...",
      "status" : "Publish",
      "date" : "2014-11-14T13:08:42¥u002b09:00",
      "updatable" : false,
      "author" : {
        "userpicUrl" : null,
        "displayName" : "Yuji Takayama"
      },
      "allowComments" : true,
      "comments" : [],
      "permalink" : "http://localhost/blog/20141114-1/2014/11/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
      "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
      "keywords" : "",
      "allowTrackbacks" : false,
      "id" : 5,
      "trackbacks" : [],
      "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
      "trackbackCount" : "0",
      "categories" : [],
      "blog" : {
        "id" : "1"
      },
      "commentCount" : "0",
      "tags" : [],
      "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
      "assets" : [],
      "pingsSentUrl" : [],
      "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
      "class" : "entry",
      "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
      "more" : "",
      "customFields" : [
        {
          "basename" : "place",
          "value" : "New York City"
        },
        {
          "basename" : "agenda",
          "value" : "Movable Type¥nTopics"
        }
      ]
    }
    

previewEntry 

new in v2.0: Make a preview for a entry.
/sites/:site_id/entries/preview(?raw)
  • Authorization is required.

  • This endpoint is available in Movable Type 6.1.2 or later.

Permissions

  • create_post
  • Parameters
  • site_id
    number (required) 

    The site ID.

    raw
    number (optional) 

    If specify “1”, will be returned preview contents.

  • Request  Entries resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    entry={ "title" : "My First Post", "body" : "This is my first post!" }
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status": "success",
      "preview": "http://example.com/2015/07/my-first-post.html"
    }
    
  • Response  403
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Do not have permission to get entry preview.",
        "code": "403"
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Site not found",
        "code": "404"
      }
    }
    
  • Response  500
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Some error message is here",
        "code": "500"
      }
    }
    

previewEntryById 

new in v2.0: Make a preview for a entry with existing data.
/sites/:site_id/entries/:entry_id/preview(?raw)
  • Authorization is required.

  • This endpoint is available in Movable Type 6.1.2 or later.

  • entry parameter is required. If you just want to get preview entry from existing data, you should provide entry parameter with empty json.

Permissions

  • create_post
  • Parameters
  • site_id
    number (required) 

    The site ID.

    entry_id
    number (required) 

    The entry ID.

    raw
    number (optional) 

    If specify “1”, will be returned preview contents.

  • Request  Templates resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    entry={}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status": "success",
      "preview": "http://example.com/2015/07/existing-entry.html"
    }
    
  • Response  403
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Do not have permission to get entry preview.",
        "code": "403"
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Site not found / Entry not found",
        "code": "404"
      }
    }
    
  • Response  500
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Some error message is here",
        "code": "500"
      }
    }
    

Folders 

This is the Folders resource.

Property NameTypeData TypeDatabase ColumnPrivateRead OnlyDescriptionVersion
basenamevaluestringmt_category.category_basenameThe basename for this folder.v2
blogObjectBlogYThe blog for this folder.v2
blog.idvaluenumbermt_category.category_blog_idYThe ID of the blog that contains this folder.v2
classvaluestringmt_category.category_classYThe class for this folder. Always "folder".v2
createdByObjectUserYCreated user of this folder.v2
createdBy.displayNamevaluestringmt_author.author_nicknameYThe display name of this folder creator.v2
createdBy.idvaluenumbermt_category.category_created_byYYThe ID of this folder creator.v2
createdBy.userpicUrlvaluestringmt_author.author_userpic_urlYThe URL of this folder creator’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, will be returned empty string.v2
createdDatevalueiso 8601 datetimemt_category.category_created_onYCreated date of this folder.v2
customFieldsARRAYObjectYThe list of customfields data for this folder.v2
customField.basenamevaluestringmt_field.field_basenameYThe basename for this customfield.v2
customField.valuevaluestringmt_template_meta.*The value of this customfield.v2
descriptionvaluestringmt_category.category_descriptionThe description for this folder.v2
idvaluenumbermt_category.category_idYThe ID for this folder.v2
labelvaluestringmt_category.category_labelThe label for this folder.v2
modifiedByObjectUserYLast modified user of this folder.v2
modifiedBy.displayNamevaluestringmt_author.author_nicknameYThe display name of this folder modifier.v2
modifiedBy.idvaluenumbermt_category.category_modified_byYYThe ID of this folder modifier.v2
modifiedBy.userpicUrlvaluestringmt_author.author_userpic_urlYThe URL of this folder modifier’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, will be returned empty string.New in v2
modifiedDatevalueiso 8601 datetimemt_category.category_modified_onYLast modified date of this folder.v2
pathvaluestringYThe path for this folder.v2
updatablevaluebooleanY
true
The user who accessed can update this folder.
false
The user who accessed cannot update this folder.
v2
    {
      "parent": "0",
      "createdBy": {
        "userpicUrl": null,
        "displayName": "Yuji Takayama"
      },
      "updatable": false,
      "blog": {
        "id": "2"
      },
      "path": "http://path/to/downloads/",
      "description": null,
      "basename": "downloads",
      "label": "downloads",
      "class": "folder",
      "id": 12,
      "createdDate": "2015-03-30T22:47:08+09:00",
      "modifiedDate": "2015-03-30T22:47:08+09:00",
      "customFields": []
    },

listFolders 

New in v2.0: Retrieve a list of folders.
//sites/:site_id/folders(?limit, offset, sortBy, sortOrder, fields, searchFields, search, includeIds, excludeIds, top)
  • Authentication required if you want to get private properties.
  • Parameters
  • site_id
    number (required) 

    The site ID

    limit
    number (optional) Default: 10 

    Maximum number of folders to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: user_custom 
    user_custom
    Sort order you specified on the Manage Folders screen.
    created_by
    Sort by the ID of creator.
    id
    Sort by its own ID.
    basename
    Sort by the basename of each folders.
    label
    Sort by the label of each folders.
    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return folders in descending order.
    ascend
    Return folders in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Folders resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    searchFields
    string (optional) Default: label,basename 

    The comma separated field name list to search.

    search
    string (optional) 

    Search query.

    includeIds
    string (optional) 

    The comma separated ID list of folders to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of folders to exclude from result.

    top
    number (optional) Default: 0 

    If set to 1, retrieves only top level folders.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : "1",
      "items" : [
        {
          "parent": "0",
          "createdBy": {
            "userpicUrl": null,
            "displayName": "Yuji Takayama"
          },
          "updatable": false,
          "blog": {
            "id": "2"
          },
          "path": "http://path/to/downloads/",
          "description": null,
          "basename": "downloads",
          "label": "downloads",
          "class": "folder",
          "id": 12,
          "createdDate": "2015-03-30T22:47:08+09:00",
          "modifiedDate": "2015-03-30T22:47:08+09:00",
          "customFields": []
        },
      ]
    }
    

listParentFolders 

New in v2.0: Retrieve a list of parent folders of the requested folder.
/sites/:site_id/folders/:folder_id/parents(?maxDepth, includeCurrent)
  • Authentication required if you want to get private properties.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    folder_id
    number (required) 

    The folder ID.

    maxDepth
    numner (optional) 

    The depth of retrieving parent folders.

    includeCurrent
    number (optional) Default: 0 
    1
    The results includes current folder.
    0
    The results do not include current folder.
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : "1",
      "items" : [
        {
          "parent": "0",
          "createdBy": {
            "userpicUrl": null,
            "displayName": "Yuji Takayama"
          },
          "updatable": false,
          "blog": {
            "id": "2"
          },
          "path": "http://path/to/downloads/",
          "description": null,
          "basename": "downloads",
          "label": "downloads",
          "class": "folder",
          "id": 12,
          "createdDate": "2015-03-30T22:47:08+09:00",
          "modifiedDate": "2015-03-30T22:47:08+09:00",
          "customFields": []
        },
      ]
    }
    

listSiblingFolders 

New in v2.0: Retrieve a list of sibling folders of the requested folder.
/sites/:site_id/folders/:folder_id/siblings(?limit, offset, sortBy, sortOrder, fields, searchFields, search, includeIds, excludeIds, top)
  • Authentication required if you want to get private properties.
  • Parameters
  • site_id
    number (required) 

    The site ID

    folder_id
    number (required) 

    The folder ID.

    limit
    number (optional) Default: 10 

    Maximum number of folders to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: user_custom 
    user_custom
    Sort order you specified on the Manage Folders screen.
    created_by
    Sort by the ID of creator.
    id
    Sort by its own ID.
    basename
    Sort by the basename of each folders.
    label
    Sort by the label of each folders.
    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return folders in descending order.
    ascend
    Return folders in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Folders resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    searchFields
    string (optional) Default: label,basename 

    The comma separated field name list to search.

    search
    string (optional) 

    Search query.

    includeIds
    string (optional) 

    The comma separated ID list of folders to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of folders to exclude from result.

    top
    number (optional) Default: 0 

    If set to 1, retrieves only top level folders.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : "1",
      "items" : [
        {
          "parent": "0",
          "createdBy": {
            "userpicUrl": null,
            "displayName": "Yuji Takayama"
          },
          "updatable": false,
          "blog": {
            "id": "2"
          },
          "path": "http://path/to/downloads/",
          "description": null,
          "basename": "downloads",
          "label": "downloads",
          "class": "folder",
          "id": 12,
          "createdDate": "2015-03-30T22:47:08+09:00",
          "modifiedDate": "2015-03-30T22:47:08+09:00",
          "customFields": []
        },
      ]
    }
    

listChildFolders 

New in v2.0: Retrieve a list of child folders of the requested folder.
/sites/:site_id/folders/:folder_id/children(?maxDepth, includeCurrent)
  • Authentication required if you want to get private properties.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    folder_id
    number (required) 

    The folder ID.

    maxDepth
    numner (optional) 

    The depth of retrieving child folders.

    includeCurrent
    number (optional) Default: 0 
    1
    The results includes current folder.
    0
    The results do not include current folder.
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : "1",
      "items" : [
        {
          "parent": "0",
          "createdBy": {
            "userpicUrl": null,
            "displayName": "Yuji Takayama"
          },
          "updatable": false,
          "blog": {
            "id": "2"
          },
          "path": "http://path/to/downloads/",
          "description": null,
          "basename": "downloads",
          "label": "downloads",
          "class": "folder",
          "id": 12,
          "createdDate": "2015-03-30T22:47:08+09:00",
          "modifiedDate": "2015-03-30T22:47:08+09:00",
          "customFields": []
        },
      ]
    }
    

Pages 

This is the Pages resource.

Property NameTypeData TypeDatabase ColumnPrivateRead OnlyDescriptionVersion
allowCommentsvaluebooleanmt_entry.entry_allow_comments
false
This page does not accepts comments. In the database, this value is 0.
true
This page accepts comments. In the database, this value is 1.
v2
allowTrackbacksvaluebooleanmt_entry.entry_allow_pings
false
This page does not accepts trackbacks. In the database, this value is 0.
true
This page accepts trackbacks. In the database, this value is 1.
v2
assetsARRAYAssetsYThe list of related assets for this page.v2
authorObjectYThe author of this page.v2
author.displayNamevaluestringmt_author.nickameYThe display name of this page creator.v2
author.idvaluenumbermt_entry.entry_author_idYYThe ID of this page creator.v2
author.userpicUrlvaluestringYThe URL of this page creator’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, will be returned empty string.v2
basenamevaluestringmt_entry.entry_basenameThe basename for this page.v2
blogObjectYThe blog of this page.v2
blog.idvaluenumbermt_entry.entry_blog_idYThe ID of the blog that contains this page.v2
bodyvaluestringmt_entry.entry_textThe contents of this page that the text format is applied. [update in v2] if you want to get the raw contents, you should sent a “no_text_filter=1” parameter with authenticated request.v2
folderObjectFolderThe container folder of this page.v2
classvaluestringmt_entry.entry_classYThe object class for this page.v2
commentCountvaluenumbermt_entry.entry_comment_countYThe number of comments for this page.v2
commentsARRAYCommentsYThe list of comments for this page. The list is sorted by ID of the comment and The parent ID of the comment.v2
createdDatevalueiso 8601 datetimemt_entry.entry_created_onYThe created time for this page.v2
customFieldsARRAYObjectThe list of customfields data for this page.v2
customField.basenamevaluestringmt_field.field_basenameYThe basename of this customfield.v2
customField.valuevaluestringThe value of this customfield.v2
datevalueiso 8601 datetimemt_entry.entry_authored_onThe published time for this page.v2
excerptvaluestringmt_entry.entry_excerptThe excerpt value of this page if one is specified or, if not, an auto-generated excerpt from the page Body field followed by an ellipsis (“…”). If an excerpt is auto-generated also note that any HTML is stripped. The length of the auto-generated output of this tag can be set in the blog’s page Settings.v2
formatvaluestringmt_entry.entry_convert_breaksYThe text format of this page.v2
idvaluenumbermt_entry.entry_idYThe ID of this page.v2
keywordsvaluestringmt_entry.entry_keywordsThe keywords text for this page.v2
modifiedDatevalueiso 8601 datetimemt_entry.entry_modified_onYThe last modified time for this page.v2
morevaluestringmt_entry.entry_text_moreThe extended contents for this page. if you want to get the raw contents, you should sent a “no_text_filter=1” parameter with authenticated request.v2
permalinkvaluevaluestringYThe parmalink URL for this page.v2
pingsSentUrlARRAYstringYThe list of TrackBack pings sent from this page.v2
statusvaluestring
Draft
This page is saved as draft.
status is 1.
Publish
This page is published.
status is 2.
Review
This page is waiting for approval.
status is 3.
Future
This page is scheduled for future publishing.
status is 4.
Spam
This page is marked as Spam.
status is 5.
v2
tagsARRAYstringThe list of page tags for this page.v2
titlevaluestringmt_entry.entry_titleThe title of this page.v2
trackbackCountvaluenumbermt_entry.entry_comment_countThe number of received trackbacks for this page.v2
trackbacksARRAYTrackbacksYThe list of received trackbacks for this page. The list is sorted by the ID of trackback.v2
updatablevaluebooleanY
true
The user who accessed can update this entry.
false
The user who accessed cannot update this page.
v2
    {
      "excerpt" : "We are excited to announce that Six Apar...",
      "status" : "Publish",
      "date" : "2014-11-14T13:08:42¥u002b09:00",
      "updatable" : false,
      "author" : {
        "userpicUrl" : null,
        "displayName" : "Yuji Takayama"
      },
      "allowComments" : true,
      "comments" : [],
      "permalink" : "http://localhost/news/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
      "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
      "keywords" : "",
      "allowTrackbacks" : false,
      "id" : 5,
      "trackbacks" : [],
      "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
      "trackbackCount" : "0",
      "folder" : {
        "id" : 2,
        "parent" : 1,
        "label" : "news"
      },
      "blog" : {
        "id" : "1"
      },
      "commentCount" : "0",
      "tags" : [],
      "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
      "assets" : [],
      "pingsSentUrl" : [],
      "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
      "class" : "entry",
      "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
      "more" : "",
      "customFields" : [
        {
          "basename" : "place",
          "value" : "New York City"
        },
        {
          "basename" : "agenda",
          "value" : "Movable Type¥nTopics"
        }
      ]
    }

listPages 

New in v2.0: Retrieve a list of pages in the specified site.
/sites/{site_id}/pages(?search, searchFields, limit, offset, sortBy, sortOrder, fields, includeIds, excludeIds, status, maxComments, maxTrackbacks, no_text_filter)
  • Authorization is required if want to include unpublished pages.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of pages.
404Not FoundSite not found.

Permissions

  • manage_pages
    • for retrieve unpublished page
  • Parameters
  • site_id
    number (required) 

    The site ID.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: title,body,more,keywords,excerpt,basename 

    The comma separated field name list to search.

    limit
    number (optional) Default: 10 

    Maximum number of pages to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: modified_on 

    The field name for sort. You can specify one of following values

    • authored_on
    • title
    • created_on
    • modified_on

    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return pages in descending order.
    ascend
    Return pages in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Pages resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    includeIds
    string (optional) 

    The comma separated ID list of pages to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of pages to exclude from result.

    status
    string (optional) 

    Filter by container page’s status.

    Draft
    status is 1.
    Publish
    status is 2.
    Review
    status is 3.
    Future
    status is 4.
    Spam
    status is 5.

    maxComments
    number (optional) 

    This is an optional parameter. Maximum number of pages to retrieve as part of the Pages resource. If this parameter is not supplied, no pages will be returned.

    maxTrackbacks
    number (optional) 

    This is an optional parameter. Maximum number of received trackbacks to retrieve as part of the Pages resource. If this parameter is not supplied, no trackbacks will be returned.

    no_text_filter
    number (optional) Default: 0 

    If you want to fetch the raw text, set to '1’. New in v2

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "excerpt" : "We are excited to announce that Six Apar...",
          "status" : "Publish",
          "date" : "2014-11-14T13:08:42¥u002b09:00",
          "updatable" : false,
          "author" : {
            "userpicUrl" : null,
            "displayName" : "Yuji Takayama"
          },
          "allowComments" : true,
          "comments" : [],
          "permalink" : "http://localhost/news/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
          "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
          "keywords" : "",
          "allowTrackbacks" : false,
          "id" : 5,
          "trackbacks" : [],
          "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
          "trackbackCount" : "0",
          "folder" : {
            "id" : 2,
            "parent" : 1,
            "label" : "news"
          },
          "blog" : {
            "id" : "1"
          },
          "commentCount" : "0",
          "tags" : [],
          "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
          "assets" : [],
          "pingsSentUrl" : [],
          "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
          "class" : "entry",
          "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
          "more" : "",
          "customFields" : [
            {
              "basename" : "place",
              "value" : "New York City"
            },
            {
              "basename" : "agenda",
              "value" : "Movable Type¥nTopics"
            }
          ]
        }
      ]
    }
    

listPagesForFolder 

New in v2.0: Retrieve a list of pages by specific folder.
/sites/{site_id}/folders/{folder_id}/pages(?search, searchFields, limit, offset, sortBy, sortOrder, fields, includeIds, excludeIds, status, maxComments, maxTrackbacks, no_text_filter)
  • Authorization is required if want to include unpublished pages.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of pages.
404Not FoundSite or Folder not found.

Permissions

  • manage_pages
    • for retrieve unpublished page
  • Parameters
  • site_id
    number (required) 

    The site ID.

    folder_id
    number (required) 

    The folder ID.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: title,body,more,keywords,excerpt,basename 

    The comma separated field name list to search.

    limit
    number (optional) Default: 10 

    Maximum number of pages to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: modified_on 

    The field name for sort. You can specify one of following values

    • authored_on
    • title
    • created_on
    • modified_on

    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return pages in descending order.
    ascend
    Return pages in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Pages resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    includeIds
    string (optional) 

    The comma separated ID list of pages to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of pages to exclude from result.

    status
    string (optional) 

    Filter by container page’s status.

    Draft
    status is 1.
    Publish
    status is 2.
    Review
    status is 3.
    Future
    status is 4.
    Spam
    status is 5.

    maxComments
    number (optional) 

    This is an optional parameter. Maximum number of comments to retrieve as part of the Pages resource. If this parameter is not supplied, no comments will be returned.

    maxTrackbacks
    number (optional) 

    This is an optional parameter. Maximum number of received trackbacks to retrieve as part of the Pages resource. If this parameter is not supplied, no trackbacks will be returned.

    no_text_filter
    number (optional) Default: 0 

    If you want to fetch the raw text, set to '1’. New in v2

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "excerpt" : "We are excited to announce that Six Apar...",
          "status" : "Publish",
          "date" : "2014-11-14T13:08:42¥u002b09:00",
          "updatable" : false,
          "author" : {
            "userpicUrl" : null,
            "displayName" : "Yuji Takayama"
          },
          "allowComments" : true,
          "comments" : [],
          "permalink" : "http://localhost/news/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
          "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
          "keywords" : "",
          "allowTrackbacks" : false,
          "id" : 5,
          "trackbacks" : [],
          "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
          "trackbackCount" : "0",
          "folder" : {
            "id" : 2,
            "parent" : 1,
            "label" : "news"
          },
          "blog" : {
            "id" : "1"
          },
          "commentCount" : "0",
          "tags" : [],
          "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
          "assets" : [],
          "pingsSentUrl" : [],
          "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
          "class" : "entry",
          "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
          "more" : "",
          "customFields" : [
            {
              "basename" : "place",
              "value" : "New York City"
            },
            {
              "basename" : "agenda",
              "value" : "Movable Type¥nTopics"
            }
          ]
        }
      ]
    }
    

listPagesForAsset 

New in v2.0: Retrieve a list of pages that related with specific asset.
/sites/{site_id}/assets/{asset_id}/pages(?search, searchFields, limit, offset, sortBy, sortOrder, fields, includeIds, excludeIds, status, maxComments, maxTrackbacks, no_text_filter)
  • Authorization is required if want to include unpublished pages.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of pages.
404Not FoundSite or Asset not found.

Permissions

  • manage_pages
    • for retrieve unpublished page
  • Parameters
  • site_id
    number (required) 

    The site ID.

    asset_id
    number (required) 

    The asset ID.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: title,body,more,keywords,excerpt,basename 

    The comma separated field name list to search.

    limit
    number (optional) Default: 10 

    Maximum number of pages to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: authored_on 

    The field name for sort. You can specify one of following values

    • authored_on
    • title
    • created_on
    • modified_on

    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return pages in descending order.
    ascend
    Return pages in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Pages resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    includeIds
    string (optional) 

    The comma separated ID list of pages to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of pages to exclude from result.

    status
    string (optional) 

    Filter by container entry’s status.

    Draft
    entry_status is 1.
    Publish
    entry_status is 2.
    Review
    entry_status is 3.
    Future
    entry_status is 4.
    Spam
    entry_status is 5.

    maxComments
    number (optional) 

    This is an optional parameter. Maximum number of pages to retrieve as part of the Pages resource. If this parameter is not supplied, no pages will be returned.

    maxTrackbacks
    number (optional) 

    This is an optional parameter. Maximum number of received trackbacks to retrieve as part of the Pages resource. If this parameter is not supplied, no trackbacks will be returned.

    no_text_filter
    number (optional) Default: 0 

    If you want to fetch the raw text, set to '1’. New in v2

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "excerpt" : "We are excited to announce that Six Apar...",
          "status" : "Publish",
          "date" : "2014-11-14T13:08:42¥u002b09:00",
          "updatable" : false,
          "author" : {
            "userpicUrl" : null,
            "displayName" : "Yuji Takayama"
          },
          "allowComments" : true,
          "comments" : [],
          "permalink" : "http://localhost/blog/20141114-1/2014/11/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
          "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
          "keywords" : "",
          "allowTrackbacks" : false,
          "id" : 5,
          "trackbacks" : [],
          "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
          "trackbackCount" : "0",
          "folder" : {
            "id" : 2,
            "parent" : 1,
            "label" : "news"
          },
          "blog" : {
            "id" : "1"
          },
          "commentCount" : "0",
          "tags" : [],
          "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
          "assets" : [],
          "pingsSentUrl" : [],
          "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
          "class" : "entry",
          "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
          "more" : "",
          "customFields" : [
            {
              "basename" : "place",
              "value" : "New York City"
            },
            {
              "basename" : "agenda",
              "value" : "Movable Type¥nTopics"
            }
          ]
        }
      ]
    }
    

listPagesForSiteAndTag 

New in v2.0: Retrieve a list of pages that related with specific tag.
/sites/{site_id}/tags/{tag_id}/pages(?search, searchFields, limit, offset, sortBy, sortOrder, fields, includeIds, excludeIds, status, status, maxComments, maxTrackbacks, no_text_filter)
  • Authorization is required if want to include unpublished pages.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of pages.
404Not FoundSite or Tag not found.

Permissions

  • manage_pages
    • for retrieve unpublished page
  • Parameters
  • site_id
    number (required) 

    The site ID.

    tag_id
    number (required) 

    The tag ID.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: title,body,more,keywords,excerpt,basename 

    The comma separated field name list to search.

    limit
    number (optional) Default: 10 

    Maximum number of pages to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: modified_on 

    The field name for sort. You can specify one of following values

    • authored_on
    • title
    • created_on
    • modified_on

    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return pages in descending order.
    ascend
    Return pages in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Pages resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    includeIds
    string (optional) 

    The comma separated ID list of pages to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of pages to exclude from result.

    status
    string (optional) 

    Filter by container entry’s status.

    Draft
    entry_status is 1.
    Publish
    entry_status is 2.
    Review
    entry_status is 3.
    Future
    entry_status is 4.
    Spam
    entry_status is 5.

    maxComments
    number (optional) 

    This is an optional parameter. Maximum number of pages to retrieve as part of the Pages resource. If this parameter is not supplied, no pages will be returned.

    maxTrackbacks
    number (optional) 

    This is an optional parameter. Maximum number of received trackbacks to retrieve as part of the Pages resource. If this parameter is not supplied, no trackbacks will be returned.

    no_text_filter
    number (optional) Default: 0 

    If you want to fetch the raw text, set to '1’.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "excerpt" : "We are excited to announce that Six Apar...",
          "status" : "Publish",
          "date" : "2014-11-14T13:08:42¥u002b09:00",
          "updatable" : false,
          "author" : {
            "userpicUrl" : null,
            "displayName" : "Yuji Takayama"
          },
          "allowComments" : true,
          "comments" : [],
          "permalink" : "http://localhost/blog/20141114-1/2014/11/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
          "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
          "keywords" : "",
          "allowTrackbacks" : false,
          "id" : 5,
          "trackbacks" : [],
          "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
          "trackbackCount" : "0",
          "folder" : {
            "id" : 2,
            "parent" : 1,
            "label" : "news"
          },
          "blog" : {
            "id" : "1"
          },
          "commentCount" : "0",
          "tags" : [],
          "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
          "assets" : [],
          "pingsSentUrl" : [],
          "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
          "class" : "entry",
          "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
          "more" : "",
          "customFields" : [
            {
              "basename" : "place",
              "value" : "New York City"
            },
            {
              "basename" : "agenda",
              "value" : "Movable Type¥nTopics"
            }
          ]
        }
      ]
    }
    

createPage 

Create a new page.
/sites/{site_id}/pages
  • Authorization is required.

Update in v2.0

  • You can attach folder and assets in the one request.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to create a new page.
404Not FoundSite not found.

Permissions

  • manage_post

Request Body Parameters

NameTypeRequiredDefaultDescription
pageObjectYesSingle Pages resource
  • Parameters
  • site_id
    number (required) 

    The site ID.

  • Request  Pages resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    page={"excerpt" : "We are excited to announce that Six Apar...","status" : "Publish","allowComments" : true,"body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e","keywords" : "","allowTrackbacks" : false,"basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades","title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades","more" : "","customFields" : [{"basename" : "place","value" : "New York City"},{"basename" : "agenda","value" : "Movable Type¥nTopics"}]}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "excerpt" : "We are excited to announce that Six Apar...",
      "status" : "Publish",
      "date" : "2014-11-14T13:08:42¥u002b09:00",
      "updatable" : false,
      "author" : {
        "userpicUrl" : null,
        "displayName" : "Yuji Takayama"
      },
      "allowComments" : true,
      "comments" : [],
      "permalink" : "http://localhost/blog/20141114-1/2014/11/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
      "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
      "keywords" : "",
      "allowTrackbacks" : false,
      "id" : 5,
      "trackbacks" : [],
      "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
      "trackbackCount" : "0",
      "folder" : {
        "id" : 2,
        "parent" : 1,
        "label" : "news"
      },
      "blog" : {
        "id" : "1"
      },
      "commentCount" : "0",
      "tags" : [],
      "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
      "assets" : [],
      "pingsSentUrl" : [],
      "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
      "class" : "entry",
      "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
      "more" : "",
      "customFields" : [
        {
          "basename" : "place",
          "value" : "New York City"
        },
        {
          "basename" : "agenda",
          "value" : "Movable Type¥nTopics"
        }
      ]
    }
    

getPage 

Retrieve a single page by its ID.
/sites/{site_id}/pages/{page_id}(?fields)
  • Authorization is required if the page status is "unpublished". If the page status is "published", then this method can be called without authorization.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the requested page.
404Not FoundSite or Page not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    page_id
    number (required) 

    The page ID.

    fields
    string (optional) 

    The field list to retrieve as part of the Pages resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "excerpt" : "We are excited to announce that Six Apar...",
      "status" : "Publish",
      "date" : "2014-11-14T13:08:42¥u002b09:00",
      "updatable" : false,
      "author" : {
        "userpicUrl" : null,
        "displayName" : "Yuji Takayama"
      },
      "allowComments" : true,
      "comments" : [],
      "permalink" : "http://localhost/blog/20141114-1/2014/11/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
      "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
      "keywords" : "",
      "allowTrackbacks" : false,
      "id" : 5,
      "trackbacks" : [],
      "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
      "trackbackCount" : "0",
      "folder" : {
        "id" : 2,
        "parent" : 1,
        "label" : "news"
      },
      "blog" : {
        "id" : "1"
      },
      "commentCount" : "0",
      "tags" : [],
      "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
      "assets" : [],
      "pingsSentUrl" : [],
      "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
      "class" : "entry",
      "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
      "more" : "",
      "customFields" : [
        {
          "basename" : "place",
          "value" : "New York City"
        },
        {
          "basename" : "agenda",
          "value" : "Movable Type¥nTopics"
        }
      ]
    }
    

updatePage 

Update an existing page.
/sites/{site_id}/pages/{page_id}
  • Authorization is required.

  • This method accepts PUT and POST with __method=PUT.

** Update in v2.0 **

  • You can attach/detach folder and assets in the one request.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to update the speciied age.
404Not FoundSite or Pagenot found.

Permissions

  • manage_pages
  • Parameters
  • site_id
    number (required) 

    The site ID.

    page_id
    number (required) 

    The page ID.

  • Request  Entries resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    page={"excerpt" : "We are excited to announce that Six Apar...","status" : "Publish","allowComments" : true,"body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e","keywords" : "","allowTrackbacks" : false,"basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades","title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades","more" : "","customFields" : [{"basename" : "place","value" : "New York City"},{"basename" : "agenda","value" : "Movable Type¥nTopics"}]}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "excerpt" : "We are excited to announce that Six Apar...",
      "status" : "Publish",
      "date" : "2014-11-14T13:08:42¥u002b09:00",
      "updatable" : false,
      "author" : {
        "userpicUrl" : null,
        "displayName" : "Yuji Takayama"
      },
      "allowComments" : true,
      "comments" : [],
      "permalink" : "http://localhost/blog/20141114-1/2014/11/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
      "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
      "keywords" : "",
      "allowTrackbacks" : false,
      "id" : 5,
      "trackbacks" : [],
      "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
      "trackbackCount" : "0",
      "folder" : {
        "id" : 2,
        "parent" : 1,
        "label" : "news"
      },
      "blog" : {
        "id" : "1"
      },
      "commentCount" : "0",
      "tags" : [],
      "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
      "assets" : [],
      "pingsSentUrl" : [],
      "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
      "class" : "entry",
      "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
      "more" : "",
      "customFields" : [
        {
          "basename" : "place",
          "value" : "New York City"
        },
        {
          "basename" : "agenda",
          "value" : "Movable Type¥nTopics"
        }
      ]
    }
    

deletePage 

Delete an existing page.
/sites/{site_id}/pages/{page_id}
  • Authorization is required. This method accepts PUT and POST with __method=DELETE.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to delete the speciied page.
404Not FoundSite or Page not found.

Permissions

  • edit_entry
  • Parameters
  • site_id
    number (required) 

    The site ID.

    page_id
    number (required) 

    The page ID.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "excerpt" : "We are excited to announce that Six Apar...",
      "status" : "Publish",
      "date" : "2014-11-14T13:08:42¥u002b09:00",
      "updatable" : false,
      "author" : {
        "userpicUrl" : null,
        "displayName" : "Yuji Takayama"
      },
      "allowComments" : true,
      "comments" : [],
      "permalink" : "http://localhost/blog/20141114-1/2014/11/six-apart-acquires-topics-server-to-simplify-site-upgrades.html",
      "body" : "¥u003cp¥u003e¥u003cspan¥u003eWe are excited to announce that Six Apart has acquired Topics, a dynamic online publishing product. This offering will provide Six Apart customers with an easy and cost-effective way to adapt existing content to evolving digital platforms.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eThis new product will save Six Apart customers a significant amount of time and money by allowing users to upgrade their websites and applications without migrating from their current content management systems. Clients who need to scale large amounts of data or even revamp a website on an entirely new platform can now achieve these changes with minimal effort.¥u003c/span¥u003e¥u003c/p¥u003e¥n¥u003cp¥u003e¥u003cspan¥u003eSix Apart customers will benefit not only from saved time and money, but also from ease of use. Topics does not have a user interface, so there is no new software to learn. Instead, it exists as a middle layer between the data library and the published page - automatically gathering, organizing and redistributing data.¥u003c/span¥u003e¥u003c/p¥u003e",
      "keywords" : "",
      "allowTrackbacks" : false,
      "id" : 5,
      "trackbacks" : [],
      "modifiedDate" : "2014-11-14T13:17:52¥u002b09:00",
      "trackbackCount" : "0",
      "folder" : {
        "id" : 2,
        "parent" : 1,
        "label" : "news"
      },
      "blog" : {
        "id" : "1"
      },
      "commentCount" : "0",
      "tags" : [],
      "basename" : "six_apart_acquires_topics_server_to_simplify_site_upgrades",
      "assets" : [],
      "pingsSentUrl" : [],
      "title" : "Six Apart Acquires Topics Server to Simplify Site Upgrades",
      "class" : "entry",
      "createdDate" : "2014-11-14T13:17:52¥u002b09:00",
      "more" : "",
      "customFields" : [
        {
          "basename" : "place",
          "value" : "New York City"
        },
        {
          "basename" : "agenda",
          "value" : "Movable Type¥nTopics"
        }
      ]
    }
    

previewPage 

new in v2.0: Make a preview for a page.
/sites/:site_id/pages/preview(?raw)
  • Authorization is required.

  • This endpoint is available in Movable Type 6.1.2 or later.

Permissions

  • manage_pages
  • Parameters
  • site_id
    number (required) 

    The site ID.

    raw
    number (optional) 

    If specify “1”, will be returned preview contents.

  • Request  Entries resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    page={ "title" : "My First Post", "body" : "This is my first post!" }
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status": "success",
      "preview": "http://example.com/my-first-post.html"
    }
    
  • Response  403
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Do not have permission to get page preview.",
        "code": "403"
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Site not found",
        "code": "404"
      }
    }
    
  • Response  500
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Some error message is here",
        "code": "500"
      }
    }
    

previewPageById 

new in v2.0: Make a preview for a page with existing data.
/sites/:site_id/pages/:page_id/preview(?raw)
  • Authorization is required.

  • This endpoint is available in Movable Type 6.1.2 or later.

  • page parameter is required. If you just want to get preview page from existing data, you should provide page parameter with empty json.

Permissions

  • manage_post
  • Parameters
  • site_id
    number (required) 

    The site ID.

    page_id
    number (required) 

    The page ID.

    raw
    number (optional) 

    If specify “1”, will be returned preview contents.

  • Request  Templates resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    page={}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status": "success",
      "preview": "http://example.com/existing-page.html"
    }
    
  • Response  403
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Do not have permission to get entry preview.",
        "code": "403"
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Site not found / Page not found",
        "code": "404"
      }
    }
    
  • Response  500
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Some error message is here",
        "code": "500"
      }
    }
    

Permissions 

This is the Permissions resource. In this case, Permission means Association record.

Property NameTypeData TypeDatabase ColumnPrivateRead OnlyDescriptionVersion
blogOjbectBlogYThe blog of this permission.v2
blog.idvaluenumbermt_permission.permission_blog_idYThe ID of the blog.v1
idvaluenumbermt_permission.permission_idYThe ID for this permission.v2
createdByObjectUserYCreated user of this permission.v2
createdBy.displayNamevaluestringmt_author.author_nicknameYThe display name of this permission creator.v2
createdBy.idvaluenumbermt_permission.permission_created_byYThe ID of this permission creator.v2
createdBy.userpicUrlvaluestringmt_author.author_userpic_urlYThe URL of this permission creator’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, will be returned empty string.v2
createdDatevalueiso 8601 datetimemt_permission.permission_created_onYCreated date of this permission.v2
permissionsARRAYstringmt_permission.permission_permissions, mt_permission.permissoin_restrictionsYThe list of granted permissions. The restricted permissions are excluded from this list.v2
rolesARRAYRoleYThe list of roles.v2
role.idvaluenumbermt_role.role_idYThe ID of this role.v2
role.namevaluestringmt_role.role_nameYThe name of this role.v2
userObjectUserYThe user of this permission.v2
user.displayNamevaluestringmt_author.author_nicknameYThe nickname for this permission user.v2
user.idvaluenumbermt_permission.permission_author_idYThe ID for this permission user.v2
user.userpicUrlvaluestringmt_author.author_userpic_urlYThe URL of this permission user’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, will be returned empty string.v2
    {
      "roles" : [
        {
          "name" : "Website Administrator",
          "id" : 1
        }
      ],
      "permissions" : [
        "administer",
        "administer_blog",
        "administer_website",
        "comment",
        "create_blog",
        "create_post",
        "create_website",
        "edit_all_posts",
        "edit_assets",
        "edit_categories",
        "edit_config",
        "edit_notifications",
        "edit_tags",
        "edit_templates",
        "manage_feedback",
        "manage_member_blogs",
        "manage_pages",
        "manage_plugins",
        "manage_themes",
        "manage_users",
        "publish_post",
        "rebuild",
        "save_image_defaults",
        "send_notifications",
        "set_publish_paths",
        "upload",
        "view_blog_log",
        "view_log"
      ],
      "createdBy" : {
        "userpicUrl" : null,
        "id" : "1",
        "displayName" : "Yuji Takayama"
      },
      "user" : {
        "userpicUrl" : null,
        "id" : "1",
        "displayName" : "Yuji Takayama"
      },
      "blog" : {
        "id" : "2"
      },
      "id" : "3",
      "createdDate" : "2015-03-21T19:37:53+09:00"
    }

listPermissions 

New in v2.0: Retrieve a list of permissions.
/permissions(?limit, offset, sortBy, sortOrder, fields, blogIds)
  • Authentication is required

  • Need Administer privilege.

  • Parameters
  • limit
    number (optional) Default: 25 

    Maximum number of permissions to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: bog_id 

    The field name for sort. You can specify one of following values

    • id
    • blog_id
    • author_id
    • created_by
    • created_on

    sortOrder
    string (optional) Default: ascend 
    descend
    (default) Return permissions in descending order.
    ascend
    Return permissions in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Permissions resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    blogIds
    number (optional) 

    The comma-separated blog id list that to be included in the result.

  • Request
  • Headers
    X-MT-Authorization: MTAuth accessToken=<Token>
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "roles" : [
            {
              "name" : "Website Administrator",
              "id" : 1
            }
          ],
          "permissions" : [
            "administer",
            "administer_blog",
            "administer_website",
            "comment",
            "create_blog",
            "create_post",
            "create_website",
            "edit_all_posts",
            "edit_assets",
            "edit_categories",
            "edit_config",
            "edit_notifications",
            "edit_tags",
            "edit_templates",
            "manage_feedback",
            "manage_member_blogs",
            "manage_pages",
            "manage_plugins",
            "manage_themes",
            "manage_users",
            "publish_post",
            "rebuild",
            "save_image_defaults",
            "send_notifications",
            "set_publish_paths",
            "upload",
            "view_blog_log",
            "view_log"
          ],
          "createdBy" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "user" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "blog" : {
            "id" : "2"
          },
          "id" : "3",
          "createdDate" : "2015-03-21T19:37:53+09:00"
        }
      ]
    }
    

listPermissionsForUser 

Retrieve a list of permissions for user.
/users/:user_id/permissions(?limit, offset, sortBy, sortOrder, fields, blogIds)
  • Authentication is required

  • If you want to get others list, you should have Administer privilege.

  • Parameters
  • user_id
    number or the word 'me' (required) 

    The user ID.

    limit
    number (optional) Default: 25 

    Maximum number of permissions to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: bog_id 

    The field name for sort. You can specify one of following values

    • id
    • blog_id
    • author_id
    • created_by
    • created_on

    sortOrder
    string (optional) Default: ascend 
    descend
    (default) Return permissions in descending order.
    ascend
    Return permissions in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Permissions resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    blogIds
    number (optional) 

    The comma-separated blog id list that to be included in the result.

  • Request
  • Headers
    X-MT-Authorization: MTAuth accessToken=<Token>
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "roles" : [
            {
              "name" : "Website Administrator",
              "id" : 1
            }
          ],
          "permissions" : [
            "administer",
            "administer_blog",
            "administer_website",
            "comment",
            "create_blog",
            "create_post",
            "create_website",
            "edit_all_posts",
            "edit_assets",
            "edit_categories",
            "edit_config",
            "edit_notifications",
            "edit_tags",
            "edit_templates",
            "manage_feedback",
            "manage_member_blogs",
            "manage_pages",
            "manage_plugins",
            "manage_themes",
            "manage_users",
            "publish_post",
            "rebuild",
            "save_image_defaults",
            "send_notifications",
            "set_publish_paths",
            "upload",
            "view_blog_log",
            "view_log"
          ],
          "createdBy" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "user" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "blog" : {
            "id" : "2"
          },
          "id" : "3",
          "createdDate" : "2015-03-21T19:37:53+09:00"
        }
      ]
    }
    

listPermissionsForSite 

New in v2.0: Retrieve a list of permissions for site.
/sites/:site_id/permissions(?limit, offset, sortBy, sortOrder, fields)
  • Authentication is required

  • Permissions

    • Administer
    • Website Administrator for websites
    • Blog Administrator for blog
  • Parameters
  • site_id
    number (required) 

    The site ID.

    limit
    number (optional) Default: 25 

    Maximum number of permissions to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: bog_id 

    The field name for sort. You can specify one of following values

    • id
    • blog_id
    • author_id
    • created_by
    • created_on

    sortOrder
    string (optional) Default: ascend 
    descend
    (default) Return permissions in descending order.
    ascend
    Return permissions in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Permissions resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

  • Request
  • Headers
    X-MT-Authorization: MTAuth accessToken=<Token>
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "roles" : [
            {
              "name" : "Website Administrator",
              "id" : 1
            }
          ],
          "permissions" : [
            "administer",
            "administer_blog",
            "administer_website",
            "comment",
            "create_blog",
            "create_post",
            "create_website",
            "edit_all_posts",
            "edit_assets",
            "edit_categories",
            "edit_config",
            "edit_notifications",
            "edit_tags",
            "edit_templates",
            "manage_feedback",
            "manage_member_blogs",
            "manage_pages",
            "manage_plugins",
            "manage_themes",
            "manage_users",
            "publish_post",
            "rebuild",
            "save_image_defaults",
            "send_notifications",
            "set_publish_paths",
            "upload",
            "view_blog_log",
            "view_log"
          ],
          "createdBy" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "user" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "blog" : {
            "id" : "2"
          },
          "id" : "3",
          "createdDate" : "2015-03-21T19:37:53+09:00"
        }
      ]
    }
    

listPermissionsForRole 

New in v2.0: Retrieve a list of permissions by role.
/roles/:role_id/permissions(?limit, offset, sortBy, sortOrder, fields, blogIds)
  • Authentication is required

  • Permissions

    • Administer
  • Parameters
  • role_id
    number (required) 

    The role ID.

    limit
    number (optional) Default: 25 

    Maximum number of permissions to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: bog_id 

    The field name for sort. You can specify one of following values

    • id
    • blog_id
    • author_id
    • created_by
    • created_on

    sortOrder
    string (optional) Default: ascend 
    descend
    (default) Return permissions in descending order.
    ascend
    Return permissions in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Permissions resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    blogIds
    number (optional) 

    The comma-separated blog id list that to be included in the result.

  • Request
  • Headers
    X-MT-Authorization: MTAuth accessToken=<Token>
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "roles" : [
            {
              "name" : "Website Administrator",
              "id" : 1
            }
          ],
          "permissions" : [
            "administer",
            "administer_blog",
            "administer_website",
            "comment",
            "create_blog",
            "create_post",
            "create_website",
            "edit_all_posts",
            "edit_assets",
            "edit_categories",
            "edit_config",
            "edit_notifications",
            "edit_tags",
            "edit_templates",
            "manage_feedback",
            "manage_member_blogs",
            "manage_pages",
            "manage_plugins",
            "manage_themes",
            "manage_users",
            "publish_post",
            "rebuild",
            "save_image_defaults",
            "send_notifications",
            "set_publish_paths",
            "upload",
            "view_blog_log",
            "view_log"
          ],
          "createdBy" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "user" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "blog" : {
            "id" : "2"
          },
          "id" : "3",
          "createdDate" : "2015-03-21T19:37:53+09:00"
        }
      ]
    }
    

grantPermissionToSite 

New in v2.0: Grant permissions to site.
/sites/:site_id/permissions/grant
  • Authentication is required

  • You should have grant_administer_role or grant_role_for_blog (Need grant_administer_role when granting role having administer_blog)

  • Parameters
  • site_id
    number (required) 

    The site ID.

    role_id
    number (required) 

    The role ID.

    user_id
    number (required) 

    The user ID.

  • Request
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth accessToken=<Token>
    Body
    role_id=1&user_id=4
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {"status":"success"}
    

grantPermissionToUser 

New in v2.0: Grant permissions to user.
/users/:user_id/permissions/grant
  • Authentication is required

  • You should have grant_administer_role or grant_role_for_blog (Need grant_administer_role when granting role having administer_blog)

  • Parameters
  • user_id
    number (required) 

    The user ID.

    site_id
    number (required) 

    The site ID.

    role_id
    number (required) 

    The role ID.

  • Request
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth accessToken=<Token>
    Body
    role_id=1&site_id=1
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {"status":"success"}
    

revokePermissionFromSite 

New in v2.0: Revoke permissions from site.
/sites/:site_id/permissions/revoke
  • Authentication is required

  • You should have revoke_role(Need revoke_administer_role when granting role having administer_blog )

  • Parameters
  • site_id
    number (required) 

    The site ID.

    user_id
    number (required) 

    The user ID.

    role_id
    number (required) 

    The role ID.

  • Request
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth accessToken=<Token>
    Body
    role_id=1&user_id=1
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {"status":"success"}
    

revokePermissionFromUser 

New in v2.0: Revoke permissions from user.
/users/:user_id/permissions/revoke
  • Authentication is required

  • You should have revoke_role(Need revoke_administer_role when granting role having administer_blog )

  • Parameters
  • user_id
    number (required) 

    The user ID.

    site_id
    number (required) 

    The site ID.

    role_id
    number (required) 

    The role ID.

  • Request
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth accessToken=<Token>
    Body
    role_id=1&site_id=1
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {"status":"success"}
    
New in v2.0: Searching entries.
/search(?search, blog_id, IncludeBlogs, ExcludeBlogs, limit, offset, SearchSortBy, SearchResultDisplay, SearchMaxResults)
  • Parameters
  • search
    string (required) 

    The search term.

    You can specify search term, like [foo], [foo AND bar], 'foo NOT bar’.

    Also, you can specify category filter, like [category:foo], [category:"hoge OR 'foo bar’"]

    Also, you can specify author filter, like [author:Melody]

    Also, you can specify Custom Fields filter, like [field:address:akasaka] in this case, address is basename of Custom Fields. akasaka is filter value.

    blog_id
    number (optional) 

    The site ID for search. If you want to specify multiple site ID, you must use IncludeBlogs.

    IncludeBlogs
    string (optional) 

    The list of the site ID that will be included in the search it should be separated by comma.

    ExcludeBlogs
    string (optional) 

    The list of the site ID will be excluded from the search it should be separated by comma.

    limit
    number (optional) Default: 20 

    Maximum number of entries to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    SearchSortBy
    string (optional) 

    The sort column for the search results. Available value is follows.

    created_on
    Will sort the entries by the authored on date.
    title
    Will sort the entries by title.

    SearchResultDisplay
    string (optional) Default: ascend 

    Defines the sort order search results. Available value is follows.

    ascend
    will list the entries in chronological order (oldest entry at the top)
    descend
    will list the entries in reverse chronological order (newest entry at the top).

    SearchMaxResults
    number (optional) Default: 20 

    Maximum number of entries to retrieve.

    NOTE: By default, “SearchMaxResults” override is disabled.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults": "4",
      "items": [
        {
          "excerpt": "Lorem ipsum dolor sit amet...",
          "status": "Publish",
          "date": "2015-04-14T17:58:40+09:00",
          "updatable": false,
          "author": {
            "userpicUrl": null,
            "displayName": "Melody Nelson"
          },
          "allowComments": true,
          "comments": [],
          "permalink": "http://localhost/blog/20150407-1/2015/04/post-6.html",
          "body": "<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>",
          "keywords": "",
          "allowTrackbacks": false,
          "id": 20,
          "trackbacks": [],
          "modifiedDate": "2015-04-14T17:58:55+09:00",
          "trackbackCount": "0",
          "categories": [],
          "blog": {
            "id": "1"
          },
          "commentCount": "0",
          "tags": [],
          "basename": "post_6",
          "assets": [],
          "pingsSentUrl": [],
          "title": "Lorem ipsum",
          "class": "entry",
          "createdDate": "2015-04-14T17:58:55+09:00",
          "more": "",
          "customFields": []
        }
      ]
    }
    

Sites 

This is the Sites resource.

Property NameTypeData TypeDatabase ColumnPrivateRead OnlyDescriptionVersion
allowCommenterRegistvaluebooleanmt_blog.blog_allow_commenter_registY
true
Allow visitors to register as members of this website using one of the Authentication Methods selected below.
false
Not allowed.
v2
allowCommentHtmlvaluebooleanmt_blog.blog_allow_comment_htmlY
true
Allow commenters to include a limited set of HTML tags in their comments.
false
All HTML will be stripped out.
v2
allowCommentsvaluebooleanmt_blog.blog_allow_reg_comments
mt_blog.blog_allow_unreg_comments
Y
true
Accept comments.
false
Do not accept comments.
v2
allowCommentsDefaultvaluebooleanmt_blog.blog_allow_comments_defaultYThe state of the comment acceptance of default in this site.
true
Comments are accepted.
false
Comments are not accepted.
v2
allowPingsvaluebooleanmt_blog.blog_allow_pingsY-
true
Accept TrackBacks from any source.
false
Do not accept.
v2
allowPingsDefaultvaluebooleanmt_blog.blog_allow_pings_defaultYThe state of the comment acceptance of default in this site. Available value is follows.
true
Trackbacks are accepted.
false
Trackbacks are not accepted.
v2
allowUnregCommentsvaluebooleanmt_blog.blog_allow_unreg_commentsY
true
Allow comments from anonymous or unauthenticated users.
false
Not allowed.
v2
archivePathvaluestringmt_blog.blog_archive_pathYThe archive path for this site. This property only accepts absolute path.v2
archiveTypePreferredvaluestringmt_blog.blog_archive_type_preferredYThe preferred archive type for this site.v2
archiveUrlvaluestringmt_blog.blog_archive_urlThe archive url of this site. [Update in v2] This property was changed to updatable.v1
autodiscoverLinksvaluebooleanmt_blog.blog_autodiscovery_linksY
true
Enable External TrackBack Auto-Discovery.
false
Disable.
v2
autolinkUrlsvaluebooleanmt_blog.blog_autolink_urlsY
true
Transform URLs in comment text into HTML links
false
Do not transform.
v2
basenameLimitvaluenumbermt_blog.blog_basename_limitYThe maximum length of basename.v2
ccLicenseImagevaluestringmt_blog.blog_cc_license-YThe URL for the Creative Commons License image for this site.v2
ccLicenseUrlvaluestringmt_blog.blog_cc_license-YThe URL for the Creative Commons License url for this site.v2
classvaluestringmt_blog.blog_classYThe object class for this site.v1
commenterAuthenticatorsARRAYstringmt_blog_meta.commenter_authenticatorsYArray of commenter authenticators for this site.v2
convertParasCommentsvaluestringmt_blog.blog_convert_paras_commentsYThe text formatting of this site’s comment.v2
contentCssvaluestringmt_blog.blog_content_cssYThe CSS applying to WYSIWYG editor of this site.v2
convertParasvaluestringmt_blog.blog_convert_parasYThe default text formatting in this site. Available value in default is follows.
0
The default text formatting is ‘None’
default
The default text formatting is ‘Convert Line Breaks’
markdown
The default text formatting is ‘Markdown’
markdown_with_smartypants
The default text formatting is ‘Markdown With SmartyPants’
richtext
The default text formatting is ‘Rich Text’
textile_2
The default text formatting is ‘Textile 2’
v2
createdByObject-YThe created user of this website.v2
createdBy.idvaluenumbermt_blog.blog_created_byYYThe ID of created user.v2
createdBy.displayNamevaluestringYThe display name of created user.v2
createdBy.userpicUrlvaluestringYThe URL of created user’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, will be returned empty string.v2
createdDatevalueiso 8601 datetimemt_blog.blog_created_onYThe created time for this website.v2
customDynamicTemplatesvaluestringmt_blog.blog_custom_dynamic_templatesYPublishing profile for this site. Available value is follows.
none
Immediately publish all index templates and archive templates statically.
all
Publish all index templates and archive templates dynamically.
archives
Publish all archive templates dynamically. Immediately publish all index templates statically.
async_all
All index templates and archive templates published statically via Publish Que.
async_partial
mmediately publish Main Index template, Page archives statically. Use Publish Queue to publish all other index templates and archive templates statically.
v2
daysOrPostsvaluestringmt_blog.blog_days_on_index
mt_blog.blog_entries_on_index
YThe type of listing default. Available value is follows.
days
Listing entries that written in the past N days. N is a value of listOnIndex.
posts
Listing most recent N entries. N is a value of listOnIndex.
v2
dateLanguagevaluestringmt_blog.blog_date_language--The date locale settings for this site. Available valus is follow.
cz
Czech
dk
Danish
nl
Dutch
en
English
et
Estonian
fr
French
de
German
is
Icelandic
it
Italian
ja
Japanese
no
Norwegian
pl
Polish
pt
Portuguese
sk
Slovak
si
Slovenian
es
Spanish
fi
Suomi
se
Swedish
v2
descriptionvaluestringmt_blog.blog_descriptionThe description of this site. [Update in v2] This property was changed to updatable.v1
dynamicCachevaluebooleanYCannot set this property when dynamic templates does not exist.
true
Dynamic cache for dynamic publishing is enabled.
false
Dynamic cache for dynamic publishing is disabled.
v2
dynamicConditionalvaluebooleanYCannot set this property when dynamic templates does not exist.
true
Dynamic conditional retrieval of dynamic publishing is enabled.
false
Dynamic conditional retrieval of dynamic publishing is disabled.
v2
entryCustomPrefsARRAYstringYYDefault displayed fields of this site’s entry. Available value is follows.
title
Title field
text
Body and extended field
category
Category list
excerpt
Excerpt field
keywords
Keyword field
tags
Tags field
feedback
Comment and trackback setting field
assets
Entry assets list
customfield_<basename>
Each custom Fields
v2
emailNewCommentsvaluenumbermt_blog.blog_email_new_commentsYEmail notification when posting comment to this site.
0
Off.
1
On.
2
Only when attension is required.
v2
emailNewPingsvaluenumbermt_blog.blog_email_new_pingsY"Email notification setting when accepting trackback to this site.
0
Off.
1
On.
2
Only when attention is required.
v2
fileExtensionvaluestringmt_blog.blog_file_extensionYThe file extension for this site.v2
followAuthLinksvaluebooleanmt_blog_meta.follow_auth_linksY
true
Do not add the ‘nofollow’ attribute when a comment is submitted by a trusted commenter.
false
Add the ‘nofollow’ attribute .
v2
hostvaluestringmt_blog.blog_site_url-YThe host name of this site.v2
idvaluenumbermt_blog.blog_idYThe ID of this site.v1
includeCachevaluebooleanmt_blog_meta:include_cacheY
true
Module cache is enabled.
false
Module cache is disabled.
v2
includeSystemvaluestringmt_blog_meta:include_systemY
‘’ (empty string)
Server Side Includes is disabled.
php
Server Side Include is enabled with PHP.
shtml
Server Side Include is enabled with Apache SSI.
asp
Server Side Include is enabled with ASP.
jsp
Server Side Include is enabled with JSP.
v2
languagevaluestringmt_blog.blog_languageThe language for this site. Available value is follows.
de
German
en
English
es
Spanish
fl
French
nl
Dutch
ja
Japanese
v2
internalAutodiscoveryvaluebooleanmt_blog.blog_internal_autodiscoveryY-
true
Enable Internal TrackBack Auto-Discovery
false
Disable.
v2
junkFolderExpiryvaluenumbermt_blog.blog_junk_folder_expiryYThe period for deleting spam comments and trackbacks.v2
junkScoreThresholdvaluenumbermt_blog.blog_junk_score_thresholdYThe spam score threshold of this site.v2
listOnIndexvaluenumbermt_blog.blog_days_on_index
mt_blog.blog_entries_on_index
YThe number of entries shown in the list by default.v2
maxRevisionsEntryvaluenumbermt_blog_meta:max_revisions_entryYThe number of revisions per entries and pages in this site.v2
maxRevisionsTemplatevaluenumbermt_blog_meta.max_revisions_templateYThe number of revisions per templates in this site.v2
moderateCommentsvaluenumbermt_blog.blog_moderate_unreg_commentsY
0
Anyone.
1
No one.
2
Trusted commenters only.
3
Any authenticated commenters.
v2
moderatePingsvaluebooleanmt_blog.blog_moderate_pingsY
true
Hold all TrackBacks for approval before they are published.
false
Do not hold.
v2
modifiedByObject-YThe last modified user of this website.v2
modifiedBy.displayNamevaluestringYThe display name of last modified user.v2
modifiedBy.idvaluenumbermt_blog.blog_modified_byYYThe ID of last modified user.v2
modifiedBy.userpicUrlvaluestringYThe URL of last modified user’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, will be returned empty string.v2
modifiedDatevalueiso 8601 datetimemt_blog.blog_modified_onYThe last modified time for this website.v2
namevaluestringmt_blog.blog_nameThe name for this site. [Update in v2] This property was changed to updatable.v1
newCreatedUserRolesARRAYRole-YAssigned to users that are created in the future on this site.v2
newCreatedUserRole.idvaluenumbermt_role.role_idYYv2
newCreatedUserRole.namevaluestringmt_role.role_nameYYv2
nofollowUrlsvaluebooleanmt_blog_meta.nofollow_urlsY
true
All URLs in comments and TrackBacks will be assigned a ‘nofollow’ link relation.
false
Not assigned.
v2
pageCustomPrefsARRAYstringYYDefault displayed fields of this site’s page. Available value is follows.
title
Title field
text
Body and extended field
category
Category list
excerpt
Excerpt field
keywords
Keyword field
tags
Tags field
feedback
Comment and trackback setting field
assets
Page assets list
customfield_<basename>
Each custom Fields
v2
parentObject---YThe parent website of this blog. If this object is Websites Resource, this object must be null.v2
parent.idvaluenumbermt_blog.blog_parent_id (mt_blog.blog_id)-YThe ID of parent website.v2
parent.namevaluestringmt_blog.blog_name-YThe name of parent website.v2
publishEmptyArchivevaluebooleanmt_blog_meta:publish_empty_archive
true
Category archive without entries is published.
false
Category archive without entries is not published.
v2
pingGooglevaluebooleanmt_blog.blog_ping_googleY
true
Enable sending update ping to Google.
false
Disabled sending update ping to Google.
v2
pingWeblogsvaluebooleanmt_blog.blog_ping_weblogsY
true
Enable sending update ping to weblogs.com.
false
Disabled sending update ping to weblogs.com.
v2
pingOthersvaluestringmt_blog.blog_ping_othersY-Array of update ping services.v2
relativeUrlvaluestringmt_blog.blog_site_url-YThe relative site url of this site.v2
requireCommentEmailsvaluebooleanmt_blog.blog_require_comment_emailsY
true
Require name and E-mail Address for Anonymous Comments.
false
Do not require.
v2
sanitizeSpecvaluestringmt_blog.blog_santize_specYThe limit html tags of this site’s comment. “0” is default.v2
serverOffsetvaluenumbermt_blog.blog_server_offsetThe server offset for this site.v2
sitePathvaluestringmt_blog.blog_site_pathYThe site path for this site. This property only accepts absolute path.v2
siteSubdomainvaluestringmt_blog.blog_site_urlY(Write Only)The subdomain for this site. This is write-only property.v2
smartReplacevaluenumbermt_blog.blog_nwc_smart_replaceYThe punctuation replacement of this site.
0
No substitution.
1
Character entities.
2
ASCII equivalents.
v2
sortOrderPostsvaluestringmt_blog.blog_sort_order_postsYThe default sorting direction for the entry listing. Available value is follows.
ascend>/dt>Ascengin order.
descend
Descending order
v2
sortOrderCommentsvaluestringmt_blog.blog_sort_order_commentsYThe comment order of this site. Available value is follows.
“ascend”
Ascending order
Descending order
v2
smartReplaceFieldsARRAYstringmt_blog.blog_nwc_replace_fieldYReplace fields of this site.v2
statusDefaultvaluestringmt_blog.blog_status_defaultYThe default entry status in this site. Available value is follows.
Pubish
The default status is ‘Published’
Draft
The default status is ‘Unpublished’
v2
themeIdvaluestringmt_blog.blog_theme_idYThe theme ID for this site.v2
timezonevaluenumbermt_blog.mt_server_offset-YThe timezone of this site.v2
updatablevaluebooleanY
true
Current user can update this website.
false
Current user cannot update this website.
v2
urlvaluestringmt_blog.blog_site_urlThe site url of this site. [Update in v2] This property was changed to updatable.v1
useCommentComfirmationvaluebooleanmt_blog.blog_use_comment_confirmationY
true
Each commenter’s browser will be redirected to a comment confirmation page after their comment is accepted.
false
Will not.
v2
useRevisionvaluebooleanmt_blog.blog_use_revisionY
true
Revision history is enabled.
false
Revision history is disabled.
v2
wordsInExcerptvaluenumbermt_blog.blog_words_in_excerptYThe default length for excerpt.v2
        {
          "serverOffset" : "9",
          "themeId" : "rainier",
          "statusDefault" : "Publish",
          "autodiscoverLinks" : false,
          "useRevision" : true,
          "relativeUrl" : "/",
          "entryCustomPrefs" : [
            "title",
            "text",
            "category",
            "excerpt",
            "keywords",
            "tags",
            "feedback",
            "assets",
            "customfield_license_fee",
            "customfield_foo"
          ],
          "archivePath" : "/path/to/document_root/",
          "useCommentConfirmation" : true,
          "url" : "http://example.com/",
          "smartReplaceFields" : [
            "title",
            "text",
            "text_more",
            "keywords",
            "excerpt",
            "tags"
          ],
          "modifiedBy" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "timezone" : "+09:00",
          "daysOrPosts" : "posts",
          "sortOrderPosts" : "descend",
          "name" : "Six Apart Shop",
          "convertParas" : "richtext",
          "description" : "",
          "includeSystem" : "",
          "archiveUrl" : "http://example.com",
          "allowCommentHtml" : true,
          "fileExtension" : "html",
          "smartReplace" : "0",
          "junkFolderExpiry" : "14",
          "publishEmptyArchive" : false,
          "dateLanguage" : "ja",
          "listOnIndex" : "10",
          "pingWeblogs" : true,
          "emailNewComments" : "1",
          "language" : "ja",
          "autolinkUrls" : true,
          "sanitizeSpec" : "0",
          "customFields" : [],
          "emailNewPings" : "1",
          "nofollowUrls" : true,
          "createdBy" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "pingGoogle" : true,
          "convertParasComments" : "1",
          "sitePath" : "/path/to/document_root/",
          "id" : "1",
          "parent" : null,
          "archiveTypePreferred" : "Individual",
          "contentCss" : "{{theme_static}}css/editor.css",
          "junkScoreThreshold" : "0",
          "internalAutodiscovery" : false,
          "createdDate" : "2014-12-28T23:09:45+09:00",
          "class" : "website",
          "moderateComments" : "2",
          "allowCommentsDefault" : true,
          "includeCache" : false,
          "allowCommenterRegist" : true,
          "maxRevisionsEntry" : "20",
          "updatable" : true,
          "requireCommentEmails" : false,
          "ccLicenseImage" : "https://i.creativecommons.org/l/by/4.0/88x31.png",
          "allowComments" : true,
          "allowPingsDefault" : false,
          "pingOthers" : [],
          "dynamicCache" : false,
          "basenameLimit" : "100",
          "modifiedDate" : "2015-03-12T12:16:24+09:00",
          "dynamicConditional" : false,
          "pageCustomPrefs" : [
            "title",
            "text",
            "excerpt",
            "keywords",
            "tags",
            "feedback",
            "assets"
          ],
          "allowPings" : false,
          "commenterAuthenticators" : [
            "MovableType"
          ],
          "host" : "localhost",
          "ccLicenseUrl" : "http://creativecommons.org/licenses/by/4.0/",
          "newCreatedUserRoles" : [],
          "wordsInExcerpt" : "40",
          "sortOrderComments" : "ascend",
          "followAuthLinks" : true,
          "allowUnregComments" : false,
          "maxRevisionsTemplate" : "20",
          "moderatePings" : true,
          "customDynamicTemplates" : "none"
        }

listByUser 

  • Authorization is required.
Retrieve a list of sites by user
/users/:user_id/sites(?limit, offset, sortBy, sortOrder, fields, searchFields, search, includeIds, excludeIds)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of sites.
404Not FoundUser not found.
  • Parameters
  • user_id
    number or 'me' (required) 

    The user ID or the word 'me’.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: name 

    Only ‘name’ is available.

    limit
    number (optional) Default: 25 

    Maximum number of sites to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: name 

    Only ‘name’ is available

    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return sites in descending order.
    ascend
    Return sites in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Sites resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    includeIds
    string (optional) 

    The comma separated ID list of sites to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of sites to exclude from result.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "serverOffset" : "9",
          "themeId" : "rainier",
          "statusDefault" : "Publish",
          "autodiscoverLinks" : false,
          "useRevision" : true,
          "relativeUrl" : "/",
          "entryCustomPrefs" : [
            "title",
            "text",
            "category",
            "excerpt",
            "keywords",
            "tags",
            "feedback",
            "assets",
            "customfield_license_fee",
            "customfield_foo"
          ],
          "archivePath" : "/path/to/document_root/",
          "useCommentConfirmation" : true,
          "url" : "http://example.com/",
          "smartReplaceFields" : [
            "title",
            "text",
            "text_more",
            "keywords",
            "excerpt",
            "tags"
          ],
          "modifiedBy" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "timezone" : "+09:00",
          "daysOrPosts" : "posts",
          "sortOrderPosts" : "descend",
          "name" : "Six Apart Shop",
          "convertParas" : "richtext",
          "description" : "",
          "includeSystem" : "",
          "archiveUrl" : "http://example.com",
          "allowCommentHtml" : true,
          "fileExtension" : "html",
          "smartReplace" : "0",
          "junkFolderExpiry" : "14",
          "publishEmptyArchive" : false,
          "dateLanguage" : "ja",
          "listOnIndex" : "10",
          "pingWeblogs" : true,
          "emailNewComments" : "1",
          "language" : "ja",
          "autolinkUrls" : true,
          "sanitizeSpec" : "0",
          "customFields" : [],
          "emailNewPings" : "1",
          "nofollowUrls" : true,
          "createdBy" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "pingGoogle" : true,
          "convertParasComments" : "1",
          "sitePath" : "/path/to/document_root/",
          "id" : "1",
          "parent" : null,
          "archiveTypePreferred" : "Individual",
          "contentCss" : "{{theme_static}}css/editor.css",
          "junkScoreThreshold" : "0",
          "internalAutodiscovery" : false,
          "createdDate" : "2014-12-28T23:09:45+09:00",
          "class" : "website",
          "moderateComments" : "2",
          "allowCommentsDefault" : true,
          "includeCache" : false,
          "allowCommenterRegist" : true,
          "maxRevisionsEntry" : "20",
          "updatable" : true,
          "requireCommentEmails" : false,
          "ccLicenseImage" : "https://i.creativecommons.org/l/by/4.0/88x31.png",
          "allowComments" : true,
          "allowPingsDefault" : false,
          "pingOthers" : [],
          "dynamicCache" : false,
          "basenameLimit" : "100",
          "modifiedDate" : "2015-03-12T12:16:24+09:00",
          "dynamicConditional" : false,
          "pageCustomPrefs" : [
            "title",
            "text",
            "excerpt",
            "keywords",
            "tags",
            "feedback",
            "assets"
          ],
          "allowPings" : false,
          "commenterAuthenticators" : [
            "MovableType"
          ],
          "host" : "localhost",
          "ccLicenseUrl" : "http://creativecommons.org/licenses/by/4.0/",
          "newCreatedUserRoles" : [],
          "wordsInExcerpt" : "40",
          "sortOrderComments" : "ascend",
          "followAuthLinks" : true,
          "allowUnregComments" : false,
          "maxRevisionsTemplate" : "20",
          "moderatePings" : true,
          "customDynamicTemplates" : "none"
        }
      ]
    }
    

listSites 

New in v2.0: Retrieve sites
/sites(?limit, offset, sortBy, sortOrder, fields, searchFields, search, includeIds, excludeIds)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of sites.
  • Parameters
  • search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: name 

    Only ‘name’ is available.

    limit
    number (optional) Default: 25 

    Maximum number of sites to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: name 

    Only ‘name’ is available

    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return sites in descending order.
    ascend
    Return sites in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Sites resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    includeIds
    string (optional) 

    The comma separated ID list of sites to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of sites to exclude from result.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "serverOffset" : "9",
          "themeId" : "rainier",
          "statusDefault" : "Publish",
          "autodiscoverLinks" : false,
          "useRevision" : true,
          "relativeUrl" : "/",
          "entryCustomPrefs" : [
            "title",
            "text",
            "category",
            "excerpt",
            "keywords",
            "tags",
            "feedback",
            "assets",
            "customfield_license_fee",
            "customfield_foo"
          ],
          "archivePath" : "/path/to/document_root/",
          "useCommentConfirmation" : true,
          "url" : "http://example.com/",
          "smartReplaceFields" : [
            "title",
            "text",
            "text_more",
            "keywords",
            "excerpt",
            "tags"
          ],
          "modifiedBy" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "timezone" : "+09:00",
          "daysOrPosts" : "posts",
          "sortOrderPosts" : "descend",
          "name" : "Six Apart Shop",
          "convertParas" : "richtext",
          "description" : "",
          "includeSystem" : "",
          "archiveUrl" : "http://example.com",
          "allowCommentHtml" : true,
          "fileExtension" : "html",
          "smartReplace" : "0",
          "junkFolderExpiry" : "14",
          "publishEmptyArchive" : false,
          "dateLanguage" : "ja",
          "listOnIndex" : "10",
          "pingWeblogs" : true,
          "emailNewComments" : "1",
          "language" : "ja",
          "autolinkUrls" : true,
          "sanitizeSpec" : "0",
          "customFields" : [],
          "emailNewPings" : "1",
          "nofollowUrls" : true,
          "createdBy" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "pingGoogle" : true,
          "convertParasComments" : "1",
          "sitePath" : "/path/to/document_root/",
          "id" : "1",
          "parent" : null,
          "archiveTypePreferred" : "Individual",
          "contentCss" : "{{theme_static}}css/editor.css",
          "junkScoreThreshold" : "0",
          "internalAutodiscovery" : false,
          "createdDate" : "2014-12-28T23:09:45+09:00",
          "class" : "website",
          "moderateComments" : "2",
          "allowCommentsDefault" : true,
          "includeCache" : false,
          "allowCommenterRegist" : true,
          "maxRevisionsEntry" : "20",
          "updatable" : true,
          "requireCommentEmails" : false,
          "ccLicenseImage" : "https://i.creativecommons.org/l/by/4.0/88x31.png",
          "allowComments" : true,
          "allowPingsDefault" : false,
          "pingOthers" : [],
          "dynamicCache" : false,
          "basenameLimit" : "100",
          "modifiedDate" : "2015-03-12T12:16:24+09:00",
          "dynamicConditional" : false,
          "pageCustomPrefs" : [
            "title",
            "text",
            "excerpt",
            "keywords",
            "tags",
            "feedback",
            "assets"
          ],
          "allowPings" : false,
          "commenterAuthenticators" : [
            "MovableType"
          ],
          "host" : "localhost",
          "ccLicenseUrl" : "http://creativecommons.org/licenses/by/4.0/",
          "newCreatedUserRoles" : [],
          "wordsInExcerpt" : "40",
          "sortOrderComments" : "ascend",
          "followAuthLinks" : true,
          "allowUnregComments" : false,
          "maxRevisionsTemplate" : "20",
          "moderatePings" : true,
          "customDynamicTemplates" : "none"
        }
      ]
    }
    

listSitesByParent 

New in v2.0: Retrieve sites by parent ID
/sites/:site_id/children(?limit, offset, sortBy, sortOrder, fields, searchFields, search, includeIds, excludeIds,)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of sites.
404Not FoundSite not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: name 

    Only ‘name’ is available.

    limit
    number (optional) Default: 25 

    Maximum number of sites to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: name 

    Only ‘name’ is available

    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return sites in descending order.
    ascend
    Return sites in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Sites resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    includeIds
    string (optional) 

    The comma separated ID list of sites to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of sites to exclude from result.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "serverOffset" : "9",
          "themeId" : "rainier",
          "statusDefault" : "Publish",
          "autodiscoverLinks" : false,
          "useRevision" : true,
          "relativeUrl" : "/",
          "entryCustomPrefs" : [
            "title",
            "text",
            "category",
            "excerpt",
            "keywords",
            "tags",
            "feedback",
            "assets",
            "customfield_license_fee",
            "customfield_foo"
          ],
          "archivePath" : "/path/to/document_root/",
          "useCommentConfirmation" : true,
          "url" : "http://example.com/",
          "smartReplaceFields" : [
            "title",
            "text",
            "text_more",
            "keywords",
            "excerpt",
            "tags"
          ],
          "modifiedBy" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "timezone" : "+09:00",
          "daysOrPosts" : "posts",
          "sortOrderPosts" : "descend",
          "name" : "Six Apart Shop",
          "convertParas" : "richtext",
          "description" : "",
          "includeSystem" : "",
          "archiveUrl" : "http://example.com",
          "allowCommentHtml" : true,
          "fileExtension" : "html",
          "smartReplace" : "0",
          "junkFolderExpiry" : "14",
          "publishEmptyArchive" : false,
          "dateLanguage" : "ja",
          "listOnIndex" : "10",
          "pingWeblogs" : true,
          "emailNewComments" : "1",
          "language" : "ja",
          "autolinkUrls" : true,
          "sanitizeSpec" : "0",
          "customFields" : [],
          "emailNewPings" : "1",
          "nofollowUrls" : true,
          "createdBy" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "pingGoogle" : true,
          "convertParasComments" : "1",
          "sitePath" : "/path/to/document_root/",
          "id" : "2",
          "parent" : {
            "id": "1",
            "name": "Parent Website"
          },
          "archiveTypePreferred" : "Individual",
          "contentCss" : "{{theme_static}}css/editor.css",
          "junkScoreThreshold" : "0",
          "internalAutodiscovery" : false,
          "createdDate" : "2014-12-28T23:09:45+09:00",
          "class" : "website",
          "moderateComments" : "2",
          "allowCommentsDefault" : true,
          "includeCache" : false,
          "allowCommenterRegist" : true,
          "maxRevisionsEntry" : "20",
          "updatable" : true,
          "requireCommentEmails" : false,
          "ccLicenseImage" : "https://i.creativecommons.org/l/by/4.0/88x31.png",
          "allowComments" : true,
          "allowPingsDefault" : false,
          "pingOthers" : [],
          "dynamicCache" : false,
          "basenameLimit" : "100",
          "modifiedDate" : "2015-03-12T12:16:24+09:00",
          "dynamicConditional" : false,
          "pageCustomPrefs" : [
            "title",
            "text",
            "excerpt",
            "keywords",
            "tags",
            "feedback",
            "assets"
          ],
          "allowPings" : false,
          "commenterAuthenticators" : [
            "MovableType"
          ],
          "host" : "localhost",
          "ccLicenseUrl" : "http://creativecommons.org/licenses/by/4.0/",
          "newCreatedUserRoles" : [],
          "wordsInExcerpt" : "40",
          "sortOrderComments" : "ascend",
          "followAuthLinks" : true,
          "allowUnregComments" : false,
          "maxRevisionsTemplate" : "20",
          "moderatePings" : true,
          "customDynamicTemplates" : "none"
        }
      ]
    }
    

insertNewWebsite 

New in v2.0: Create a new website.
/sites
  • Authorization is required.

  • This method accepts PUT and POST with __method=PUT.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to create a new website.
404Not FoundSite not found.

Permissions

  • create_website

Request Body Parameters

NameTypeRequiredDefaultDescription
blogObjectYesSingle Sites resource
  • Request  Sites resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth accessToken=<Token>
    Body
    website={"url" : "http://example.com/", "name" : "New Website", "sitePath":"/path/to/document_root/"}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "serverOffset" : 9,
      "themeId" : "rainier",
      "statusDefault" : "Publish",
      "autodiscoverLinks" : false,
      "useRevision" : true,
      "relativeUrl" : "/",
      "entryCustomPrefs" : [
        "title",
        "body",
        "category",
        "tags",
        "feedback",
        "publishing",
        "assets"
      ],
      "archivePath" : "/path/to/document_root/",
      "useCommentConfirmation" : true,
      "url" : "http://example.com/",
      "smartReplaceFields" : [
        "title",
        "text",
        "text_more",
        "keywords",
        "excerpt",
        "tags"
      ],
      "timezone" : "+09:00",
      "daysOrPosts" : "posts",
      "sortOrderPosts" : "descend",
      "convertParas" : "richtext",
      "name" : "New Website",
      "description" : null,
      "includeSystem" : null,
      "archiveUrl" : "http://example.com/",
      "allowCommentHtml" : true,
      "fileExtension" : "html",
      "smartReplace" : 0,
      "junkFolderExpiry" : 14,
      "publishEmptyArchive" : false,
      "dateLanguage" : "ja",
      "listOnIndex" : 10,
      "pingWeblogs" : false,
      "emailNewComments" : 1,
      "language" : "",
      "autolinkUrls" : true,
      "sanitizeSpec" : 0,
      "customFields" : [],
      "emailNewPings" : 1,
      "nofollowUrls" : true,
      "createdBy" : {
        "userpicUrl" : null,
        "id" : "1",
        "displayName" : "Yuji Takayama"
      },
      "pingGoogle" : false,
      "convertParasComments" : 1,
      "sitePath" : "/path/to/document_root/",
      "id" : "10",
      "parent" : null,
      "archiveTypePreferred" : "",
      "contentCss" : null,
      "junkScoreThreshold" : 0,
      "internalAutodiscovery" : false,
      "createdDate" : "2015-03-24T22:03:47+09:00",
      "class" : "website",
      "moderateComments" : 2,
      "allowCommentsDefault" : true,
      "includeCache" : false,
      "allowCommenterRegist" : true,
      "maxRevisionsEntry" : 20,
      "updatable" : true,
      "requireCommentEmails" : false,
      "ccLicenseImage" : "",
      "allowComments" : true,
      "allowPingsDefault" : true,
      "pingOthers" : [],
      "dynamicCache" : false,
      "basenameLimit" : 100,
      "modifiedDate" : "2015-03-24T22:03:47+09:00",
      "dynamicConditional" : false,
      "pageCustomPrefs" : [
        "title",
        "body",
        "category",
        "tags",
        "feedback",
        "publishing",
        "assets"
      ],
      "allowPings" : true,
      "commenterAuthenticators" : [
        "MovableType"
      ],
      "host" : "example.com",
      "ccLicenseUrl" : "",
      "newCreatedUserRoles" : [],
      "wordsInExcerpt" : 40,
      "sortOrderComments" : "ascend",
      "followAuthLinks" : true,
      "allowUnregComments" : false,
      "maxRevisionsTemplate" : 20,
      "moderatePings" : true,
      "customDynamicTemplates" : "none"
    }
    

insertNewBlog 

New in v2.0: Create a new blog.
/sites/:site_id
  • Authorization is required.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to create a new blog.
404Not FoundSite not found.

Permissions

  • create_blog

Request Body Parameters

NameTypeRequiredDefaultDescription
blogObjectYesSingle Sites resource
  • Parameters
  • site_id
    number (required) 

    The site ID.

  • Request  Sites resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth accessToken=<Token>
    Body
    blog={"name":"New Blog", "url":"blog", "sitePath":"blog"}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "serverOffset" : 9,
      "themeId" : "rainier",
      "statusDefault" : "Publish",
      "autodiscoverLinks" : false,
      "useRevision" : true,
      "relativeUrl" : "/blog/",
      "entryCustomPrefs" : [
      "title",
      "body",
      "category",
      "tags",
      "feedback",
      "publishing",
      "assets"
      ],
      "archivePath" : "/path/to/document_root/blog",
      "useCommentConfirmation" : true,
      "url" : "http://example.com/blog/",
      "smartReplaceFields" : [
        "title",
        "text",
        "text_more",
        "keywords",
        "excerpt",
        "tags"
      ],
      "timezone" : "+09:00",
      "daysOrPosts" : "posts",
      "sortOrderPosts" : "descend",
      "convertParas" : "richtext",
      "name" : "New Blog",
      "description" : null,
      "includeSystem" : null,
      "archiveUrl" : "http://example.com/blog/",
      "allowCommentHtml" : true,
      "fileExtension" : "html",
      "smartReplace" : 0,
      "junkFolderExpiry" : 14,
      "publishEmptyArchive" : false,
      "dateLanguage" : "ja",
      "listOnIndex" : 10,
      "pingWeblogs" : false,
      "emailNewComments" : 1,
      "language" : "",
      "autolinkUrls" : true,
      "sanitizeSpec" : 0,
      "customFields" : [],
      "emailNewPings" : 1,
      "nofollowUrls" : true,
      "createdBy" : {
        "userpicUrl" : null,
        "id" : "1",
        "displayName" : "Yuji Takayama"
      },
      "pingGoogle" : false,
      "convertParasComments" : 1,
      "sitePath" : "/path/to/document_root/blog",
      "id" : "9",
      "parent" : {
        "name" : "First Website",
        "id" : "1"
      },
      "archiveTypePreferred" : "",
      "contentCss" : null,
      "junkScoreThreshold" : 0,
      "internalAutodiscovery" : false,
      "createdDate" : "2015-03-24T15:15:56+09:00",
      "class" : "blog",
      "moderateComments" : 2,
      "allowCommentsDefault" : true,
      "includeCache" : false,
      "allowCommenterRegist" : true,
      "maxRevisionsEntry" : "20",
      "updatable" : true,
      "requireCommentEmails" : false,
      "ccLicenseImage" : "",
      "allowComments" : true,
      "allowPingsDefault" : true,
      "pingOthers" : [],
      "dynamicCache" : false,
      "basenameLimit" : 100,
      "modifiedDate" : "2015-03-24T15:15:56+09:00",
      "dynamicConditional" : false,
      "pageCustomPrefs" : [
        "title",
        "body",
        "category",
        "tags",
        "feedback",
        "publishing",
        "assets"
      ],
      "allowPings" : true,
      "commenterAuthenticators" : [
        "MovableType"
      ],
      "host" : "example.com",
      "ccLicenseUrl" : "",
      "newCreatedUserRoles" : [],
      "wordsInExcerpt" : 40,
      "sortOrderComments" : "ascend",
      "followAuthLinks" : true,
      "allowUnregComments" : false,
      "maxRevisionsTemplate" : "20",
      "moderatePings" : true,
      "customDynamicTemplates" : "none"
    }
    

updateSite 

New in v2.0: Update an existing blog or website.
/sites/:site_id
  • Authorization is required.

  • This method accepts PUT and POST with __method=PUT.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to update an existing blog or website.
404Not FoundSite not found.

Permissions

  • edit_blog_config

Request Body Parameters

NameTypeRequiredDefaultDescription
blogObjectYesSingle Sites resource
  • Parameters
  • site_id
    number (required) 

    The site ID.

  • Request  Sites resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth accessToken=<Token>
    Body
    website={"name" : "Our new Website"} or blog={"name" : "Our new Website"}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "serverOffset" : 9,
      "themeId" : "rainier",
      "statusDefault" : "Publish",
      "autodiscoverLinks" : false,
      "useRevision" : true,
      "relativeUrl" : "/",
      "entryCustomPrefs" : [
        "title",
        "body",
        "category",
        "tags",
        "feedback",
        "publishing",
        "assets"
      ],
      "archivePath" : "/path/to/document_root/",
      "useCommentConfirmation" : true,
      "url" : "http://example.com/",
      "smartReplaceFields" : [
        "title",
        "text",
        "text_more",
        "keywords",
        "excerpt",
        "tags"
      ],
      "timezone" : "+09:00",
      "daysOrPosts" : "posts",
      "sortOrderPosts" : "descend",
      "convertParas" : "richtext",
      "name" : "Our new Website",
      "description" : null,
      "includeSystem" : null,
      "archiveUrl" : "http://example.com/",
      "allowCommentHtml" : true,
      "fileExtension" : "html",
      "smartReplace" : 0,
      "junkFolderExpiry" : 14,
      "publishEmptyArchive" : false,
      "dateLanguage" : "ja",
      "listOnIndex" : 10,
      "pingWeblogs" : false,
      "emailNewComments" : 1,
      "language" : "",
      "autolinkUrls" : true,
      "sanitizeSpec" : 0,
      "customFields" : [],
      "emailNewPings" : 1,
      "nofollowUrls" : true,
      "createdBy" : {
        "userpicUrl" : null,
        "id" : "1",
        "displayName" : "Yuji Takayama"
      },
      "pingGoogle" : false,
      "convertParasComments" : 1,
      "sitePath" : "/path/to/document_root/",
      "id" : "10",
      "parent" : null,
      "archiveTypePreferred" : "",
      "contentCss" : null,
      "junkScoreThreshold" : 0,
      "internalAutodiscovery" : false,
      "createdDate" : "2015-03-24T22:03:47+09:00",
      "class" : "website",
      "moderateComments" : 2,
      "allowCommentsDefault" : true,
      "includeCache" : false,
      "allowCommenterRegist" : true,
      "maxRevisionsEntry" : 20,
      "updatable" : true,
      "requireCommentEmails" : false,
      "ccLicenseImage" : "",
      "allowComments" : true,
      "allowPingsDefault" : true,
      "pingOthers" : [],
      "dynamicCache" : false,
      "basenameLimit" : 100,
      "modifiedDate" : "2015-03-24T22:03:47+09:00",
      "dynamicConditional" : false,
      "pageCustomPrefs" : [
        "title",
        "body",
        "category",
        "tags",
        "feedback",
        "publishing",
        "assets"
      ],
      "allowPings" : true,
      "commenterAuthenticators" : [
        "MovableType"
      ],
      "host" : "example.com",
      "ccLicenseUrl" : "",
      "newCreatedUserRoles" : [],
      "wordsInExcerpt" : 40,
      "sortOrderComments" : "ascend",
      "followAuthLinks" : true,
      "allowUnregComments" : false,
      "maxRevisionsTemplate" : 20,
      "moderatePings" : true,
      "customDynamicTemplates" : "none"
    }
    

deleteSite 

New in v2.0: Delete an existing blog or website.
/sites/:site_id
  • Authorization is required.

  • This method accepts DELETE and POST with __method=DELETE.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to delete an existing blog or website.
404Not FoundSite not found.

Permissions

  • delete_website (for website)

  • delete_blog (for blog)

  • Parameters
  • site_id
    number (required) 

    The site ID.

  • Request
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth accessToken=<Token>
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "serverOffset" : 9,
      "themeId" : "rainier",
      "statusDefault" : "Publish",
      "autodiscoverLinks" : false,
      "useRevision" : true,
      "relativeUrl" : "/",
      "entryCustomPrefs" : [
        "title",
        "body",
        "category",
        "tags",
        "feedback",
        "publishing",
        "assets"
      ],
      "archivePath" : "/path/to/document_root/",
      "useCommentConfirmation" : true,
      "url" : "http://example.com/",
      "smartReplaceFields" : [
        "title",
        "text",
        "text_more",
        "keywords",
        "excerpt",
        "tags"
      ],
      "timezone" : "+09:00",
      "daysOrPosts" : "posts",
      "sortOrderPosts" : "descend",
      "convertParas" : "richtext",
      "name" : "Our new Website",
      "description" : null,
      "includeSystem" : null,
      "archiveUrl" : "http://example.com/",
      "allowCommentHtml" : true,
      "fileExtension" : "html",
      "smartReplace" : 0,
      "junkFolderExpiry" : 14,
      "publishEmptyArchive" : false,
      "dateLanguage" : "ja",
      "listOnIndex" : 10,
      "pingWeblogs" : false,
      "emailNewComments" : 1,
      "language" : "",
      "autolinkUrls" : true,
      "sanitizeSpec" : 0,
      "customFields" : [],
      "emailNewPings" : 1,
      "nofollowUrls" : true,
      "createdBy" : {
        "userpicUrl" : null,
        "id" : "1",
        "displayName" : "Yuji Takayama"
      },
      "pingGoogle" : false,
      "convertParasComments" : 1,
      "sitePath" : "/path/to/document_root/",
      "id" : "10",
      "parent" : null,
      "archiveTypePreferred" : "",
      "contentCss" : null,
      "junkScoreThreshold" : 0,
      "internalAutodiscovery" : false,
      "createdDate" : "2015-03-24T22:03:47+09:00",
      "class" : "website",
      "moderateComments" : 2,
      "allowCommentsDefault" : true,
      "includeCache" : false,
      "allowCommenterRegist" : true,
      "maxRevisionsEntry" : 20,
      "updatable" : true,
      "requireCommentEmails" : false,
      "ccLicenseImage" : "",
      "allowComments" : true,
      "allowPingsDefault" : true,
      "pingOthers" : [],
      "dynamicCache" : false,
      "basenameLimit" : 100,
      "modifiedDate" : "2015-03-24T22:03:47+09:00",
      "dynamicConditional" : false,
      "pageCustomPrefs" : [
        "title",
        "body",
        "category",
        "tags",
        "feedback",
        "publishing",
        "assets"
      ],
      "allowPings" : true,
      "commenterAuthenticators" : [
        "MovableType"
      ],
      "host" : "example.com",
      "ccLicenseUrl" : "",
      "newCreatedUserRoles" : [],
      "wordsInExcerpt" : 40,
      "sortOrderComments" : "ascend",
      "followAuthLinks" : true,
      "allowUnregComments" : false,
      "maxRevisionsTemplate" : 20,
      "moderatePings" : true,
      "customDynamicTemplates" : "none"
    }
    

getBlog 

Retrieve a single website/blog by its ID.
/sites/:site_id(?fields)

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to get an existing Site.
404Not FoundSite not found.
  • Parameters
  • site_id
    number (required) 

    The site ID.

    fields
    string (optional) 

    The field list to retrieve as part of the Sites resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "serverOffset" : 9,
      "themeId" : "rainier",
      "statusDefault" : "Publish",
      "autodiscoverLinks" : false,
      "useRevision" : true,
      "relativeUrl" : "/blog/",
      "entryCustomPrefs" : [
      "title",
      "body",
      "category",
      "tags",
      "feedback",
      "publishing",
      "assets"
      ],
      "archivePath" : "/path/to/document_root/blog",
      "useCommentConfirmation" : true,
      "url" : "http://example.com/blog/",
      "smartReplaceFields" : [
        "title",
        "text",
        "text_more",
        "keywords",
        "excerpt",
        "tags"
      ],
      "timezone" : "+09:00",
      "daysOrPosts" : "posts",
      "sortOrderPosts" : "descend",
      "convertParas" : "richtext",
      "name" : "New Blog",
      "description" : null,
      "includeSystem" : null,
      "archiveUrl" : "http://example.com/blog/",
      "allowCommentHtml" : true,
      "fileExtension" : "html",
      "smartReplace" : 0,
      "junkFolderExpiry" : 14,
      "publishEmptyArchive" : false,
      "dateLanguage" : "ja",
      "listOnIndex" : 10,
      "pingWeblogs" : false,
      "emailNewComments" : 1,
      "language" : "",
      "autolinkUrls" : true,
      "sanitizeSpec" : 0,
      "customFields" : [],
      "emailNewPings" : 1,
      "nofollowUrls" : true,
      "createdBy" : {
        "userpicUrl" : null,
        "id" : "1",
        "displayName" : "Yuji Takayama"
      },
      "pingGoogle" : false,
      "convertParasComments" : 1,
      "sitePath" : "/path/to/document_root/blog",
      "id" : "9",
      "parent" : {
        "name" : "First Website",
        "id" : "1"
      },
      "archiveTypePreferred" : "",
      "contentCss" : null,
      "junkScoreThreshold" : 0,
      "internalAutodiscovery" : false,
      "createdDate" : "2015-03-24T15:15:56+09:00",
      "class" : "blog",
      "moderateComments" : 2,
      "allowCommentsDefault" : true,
      "includeCache" : false,
      "allowCommenterRegist" : true,
      "maxRevisionsEntry" : "20",
      "updatable" : true,
      "requireCommentEmails" : false,
      "ccLicenseImage" : "",
      "allowComments" : true,
      "allowPingsDefault" : true,
      "pingOthers" : [],
      "dynamicCache" : false,
      "basenameLimit" : 100,
      "modifiedDate" : "2015-03-24T15:15:56+09:00",
      "dynamicConditional" : false,
      "pageCustomPrefs" : [
        "title",
        "body",
        "category",
        "tags",
        "feedback",
        "publishing",
        "assets"
      ],
      "allowPings" : true,
      "commenterAuthenticators" : [
        "MovableType"
      ],
      "host" : "example.com",
      "ccLicenseUrl" : "",
      "newCreatedUserRoles" : [],
      "wordsInExcerpt" : 40,
      "sortOrderComments" : "ascend",
      "followAuthLinks" : true,
      "allowUnregComments" : false,
      "maxRevisionsTemplate" : "20",
      "moderatePings" : true,
      "customDynamicTemplates" : "none"
    }
    

Stats 

This is the PageStats(byPath) resource.

Property NameTypeData TypeDatabase ColumnPrivateRead OnlyDescriptionVersion
pathvalueStringYThe relative path of the target.v1
pageviewsvalueNumberYThe number of pageviews for the path. This property exists only if request endpoint is "pageviewsForPath".v1
visitsvalueNumberYThe number of visits for the path. This property exists only if request endpoint is "visitsForPath".v1
archiveTypevalueStringmt_fileinfo.fileinfo_archive_typeYThe archive type of the path. This property is null if the path is not managed by MT.v1
entryObject-YThis property is null if “archiveType” is not "Individual".v1
entry.idvalueNumbermt_entry.entry_idYThe ID of entry.v1
authorObject-YThis property is null if “archiveType” is neither “Author” nor "Author-∗".v1
author.idvalueNumbermt_author.author_idYThe ID of author.v1
categoryObject-YThis property is null if “archiveType” is neither “Category” nor "Category-∗".v1
category.idvalueNumbermt_category.category_idYThe ID of category.v1
        {
          "totalResults": 2,
          "items": [
            {
              "entry": null,
              "pageviews": "56",
              "author": null,
              "path": "/",
              "title": "Your site",
              "archiveType": "index",
              "category": null,
              "startDate": null
            },
            {
              "entry": {
                "id": "1198"
              },
              "pageviews": "44",
              "author": null,
              "path": "/2015/03/exapmle.html",
              "title": "Entry title is here",
              "archiveType": "Individual",
              "category": null,
              "startDate": null
            },
          ],
          "totals": {
            "pageviews": "329"
          }
        }

Also, This is the PageStats(byDate) resource.

Property NameTypeData TypeDatabase ColumnPrivateRead OnlyDescriptionVersion
datevalueiso 8601 dateYThe date of the target. The format is "YYYY-MM-DD".v1
pageviewsvalueNumberYThe pageviews for the path. This property exists only if request endpoint is "pageviewsForDate".v1
visitsvalueNumberYThe visits for the path. This property exists only if request endpoint is "visitsForDate".v1
        {
          "totalResults": 6,
          "items": [
            {
              "visits": "1",
              "date": "2015-05-20"
            },
            {
              "visits": "1",
              "date": "2015-05-21"
            },
            {
              "visits": "2",
              "date": "2015-05-22"
            },
            {
              "visits": "1",
              "date": "2015-05-23"
            },
            {
              "visits": "1",
              "date": "2015-05-24"
            },
            {
              "visits": "4",
              "date": "2015-05-25"
            }
          ],
          "totals": {
            "visits": "10"
          }
        }

visitsForPath 

  • Authorization is required.
Retrieve visits count for each path from provider.
/sites/:site_id/stats/path/visits(?startDate, endDate, limit, offset, path)
  • Parameters
  • site_id
    Number (required) 

    The site ID.

    startDate
    String (required) 

    This is an required parameter. Start date of data. The format is "YYYY-MM-DD".

    endDate
    String (required) 

    This is an required parameter. End date of data. The format is "YYYY-MM-DD".

    limit
    Number (optional) 

    This is an optional parameter. Maximum number of paths to retrieve. Default is 10.

    offset
    Number (optional) 

    This is an optional parameter. 0-indexed offset. Default is 0.

    path
    String (optional) 

    This is an optional parameter. The target path of data to retrieve. Default is the path of the current site.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults": 2,
      "items": [
        {
          "entry": null,
          "pageviews": "56",
          "author": null,
          "path": "/",
          "title": "Your site",
          "archiveType": "index",
          "category": null,
          "startDate": null
        },
        {
          "entry": {
            "id": "1198"
          },
          "pageviews": "44",
          "author": null,
          "path": "/2015/03/exapmle.html",
          "title": "Entry title is here",
          "archiveType": "Individual",
          "category": null,
          "startDate": null
        },
      ],
      "totals": {
        "pageviews": "329"
      }
    }
    
  • Response  401
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Unauthorized",
        "code": 401
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Readied provider is not found",
        "code": "404"
      }
    }
    

visitsForDate 

  • Authorization is required.
Retrieve visits count for each date from provider.
/sites/:site_id/stats/date/visits(?startDate, endDate, limit, offset, path)
  • Parameters
  • site_id
    Number (required) 

    The site ID.

    startDate
    String (required) 

    This is an required parameter. Start date of data. The format is "YYYY-MM-DD".

    endDate
    String (required) 

    This is an required parameter. End date of data. The format is "YYYY-MM-DD".

    limit
    Number (optional) 

    This is an optional parameter. Maximum number of paths to retrieve. Default is 10.

    offset
    Number (optional) 

    This is an optional parameter. 0-indexed offset. Default is 0.

    path
    String (optional) 

    This is an optional parameter. The target path of data to retrieve. Default is the path of the current site.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults": 6,
      "items": [
        {
          "visits": "1",
          "date": "2015-05-20"
        },
        {
          "visits": "1",
          "date": "2015-05-21"
        },
        {
          "visits": "2",
          "date": "2015-05-22"
        },
        {
          "visits": "1",
          "date": "2015-05-23"
        },
        {
          "visits": "1",
          "date": "2015-05-24"
        },
        {
          "visits": "4",
          "date": "2015-05-25"
        }
      ],
      "totals": {
        "visits": "10"
      }
    }
    
  • Response  401
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Unauthorized",
        "code": 401
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Readied provider is not found",
        "code": "404"
      }
    }
    

pageviewsForPath 

  • Authorization is required.
Retrieve pageviews count for each path from provider.
/sites/:site_id/stats/path/pageviews(?startDate, endDate, limit, offset, path, uniquePath)
  • Parameters
  • site_id
    Number (required) 

    The site ID.

    startDate
    String (required) 

    This is an required parameter. Start date of data. The format is "YYYY-MM-DD".

    endDate
    String (required) 

    This is an required parameter. End date of data. The format is "YYYY-MM-DD".

    limit
    Number (optional) 

    This is an optional parameter. Maximum number of paths to retrieve. Default is 10.

    offset
    Number (optional) 

    This is an optional parameter. 0-indexed offset. Default is 0.

    path
    String (optional) 

    This is an optional parameter. The target path of data to retrieve. Default is the path of the current site.

    uniquePath
    Boolean (optional) 

    This is an optional parameter. If true is given, the MT can return total pageviews for each uniqueness paths. However, that data does not contains page title because its spec. (Sometimes, Google Analytics will return another pageviews by same path.)

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults": 2,
      "items": [
        {
          "entry": null,
          "pageviews": "56",
          "author": null,
          "path": "/",
          "title": "Your site",
          "archiveType": "index",
          "category": null,
          "startDate": null
        },
        {
          "entry": {
            "id": "1198"
          },
          "pageviews": "44",
          "author": null,
          "path": "/2015/03/exapmle.html",
          "title": "Entry title is here",
          "archiveType": "Individual",
          "category": null,
          "startDate": null
        },
      ],
      "totals": {
        "pageviews": "329"
      }
    }
    
  • Response  401
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Unauthorized",
        "code": 401
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Readied provider is not found",
        "code": "404"
      }
    }
    

pageviewsForDate 

  • Authorization is required.
Retrieve pageviews count for each date from provider.
/sites/:site_id/stats/date/pageviews(?startDate, endDate, limit, offset, path)
  • Parameters
  • site_id
    Number (required) 

    The site ID.

    startDate
    String (required) 

    This is an required parameter. Start date of data. The format is "YYYY-MM-DD".

    endDate
    String (required) 

    This is an required parameter. End date of data. The format is "YYYY-MM-DD".

    limit
    Number (optional) 

    This is an optional parameter. Maximum number of paths to retrieve. Default is 10.

    offset
    Number (optional) 

    This is an optional parameter. 0-indexed offset. Default is 0.

    path
    String (optional) 

    This is an optional parameter. The target path of data to retrieve. Default is the path of the current site.

    uniquePath
    Boolean (optional) 

    This is an optional parameter. If true is given, the MT can return total pageviews for each uniqueness paths. However, that data does not contains page title because its spec. (Sometimes, Google Analytics will return another pageviews by same path.)

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults": 6,
      "items": [
        {
          "visits": "1",
          "date": "2015-05-20"
        },
        {
          "visits": "1",
          "date": "2015-05-21"
        },
        {
          "visits": "2",
          "date": "2015-05-22"
        },
        {
          "visits": "1",
          "date": "2015-05-23"
        },
        {
          "visits": "1",
          "date": "2015-05-24"
        },
        {
          "visits": "4",
          "date": "2015-05-25"
        }
      ],
      "totals": {
        "visits": "10"
      }
    }
    
  • Response  401
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Unauthorized",
        "code": 401
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Readied provider is not found",
        "code": "404"
      }
    }
    

getProvider 

  • Authorization is required.
Retrieve a current effective provider.
/sites/:site_id/stats/provider
  • Parameters
  • site_id
    Number (required) 

    The site ID.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "id": "GoogleAnalytics"
    }
    
  • Response  401
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Unauthorized",
        "code": 401
      }
    }
    

Templates 

This is the Templates resource.

Property NameTypeData TypeDatabase ColumnPrivateRead OnlyDescriptionVersion
archiveTypesARRAYTemplatemapYYThis archive types for this template.v2
archiveType.idvalueNumbermt_templatemap.templatemap_idYYThe ID for this archive type.v2
archiveType.isPreferredvaluebooleanmt_templatemap.templatemap_is_preferredYY
true
This archive type is preferred in all archive types of the requested template.
false
This archive type not is preferred in all archive types of the requested template.
v2
archiveType.fileTemplatevalueStringmt_templatemap.templatemap_file_templateYYThe file template for this archive type.v2
archiveType.archiveTypevalueStringmt_templatemap.templatemap_archive_typeYYThe archive type for this archive type.v2
archiveType.buildTypevalueStringmt_templatemap.templatemap_build_typeYYThe build type for this archive type.v2
archiveType.updatablevaluebooleanYY
true
The user who accessed can update this archive type.
false
The user who accessed cannot update this archive type.
v2
updatablevaluebooleanYY
true
The user who accessed can update this template.
false
The user who accessed cannot update this template.
v2
blogObjectBlogYYThe blog of this template.v2
blog.idvalueNumbermt_template.template_blog_idYYThe ID of the blog that contains this template.v2
buildTypevalueStringmt_template.template_build_typeYThe build type for this template. Available value is follows.
0
never publish this template.
1
publish this template whenever its contents are updated or affected by a change.
2
publish this template when a publish request received.
3
publish this template on demand, but do not publish a file to the file system.
4
publish this template in the background.
5
currently not in use.
v2
createdByObjectUserYYCreated user of this template.v2
createdBy.idvalueNumbermt_template.template_created_byYYThe ID of this template creator.v2
createdBy.displayNamevalueStringmt_author.author_nicknameYYThe display name of this template creator.v2
createdBy.userpicUrlvalueStringmt_author.author_userpic_urlYYThe URL of this template creator’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, will be returned empty string.v2
createdDatevalueiso 8601 datetimemt_template.template_created_onYYCreated date of this template.v2
customFieldsARRAYFieldYYThe list of customfields data of this template.v2
customField.basenamevalueStringmt_field.field_basenameYYThe basename of this customfield.v2
customField.valuevalueStringmt_template_meta.*YThe value of this customfield.v2
idvalueNumbermt_template.template_idYYThe ID for this template.v2
linkToFievalueStringmt_template.template_linked_fileYThe linked output filename for this template.v2
modifiedByObjectUserYYLast modified user of this template.v2
modifiedBy.idvalueNumbermt_template.template_modified_byYYThe ID of this template modifier.v2
modifiedBy.displayNamevalueStringmt_author.author_nicknameYYThe display name of this template modifier.v2
modifiedBy.userpicUrlvalueStringmt_author.author_userpic_urlYYThe URL of this template modifier’s userpic. The userpic modifiedDatevalueiso 8601 datetimemt_template.template_modified_onYYLast modified date of this template.v2
will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, will be returned empty string.v2
namevalueStringmt_template.template_nameYThe name for this template.v2
outputFilevalueStringmt_template.template_outfileYThe output filename for this template.v2
textvalueStringmt_template.template_textYThe text for this template.v2
typevalueStringmt_template.template_typeYThe type for this template.v2
templateTypevalueStringmt_template.template_identifierYThe identifier for this template.v2
            {
              "createdBy": {
                "userpicUrl": null,
                "id": "1",
                "displayName": "Yuji Takayama"
              },
              "name": "HTML Header",
              "updatable": true,
              "blog": {
                "id": "1"
              },
              "text": "    <meta name=\"viewport\" content=\"width=device-width,initial-scale=1\">\n    <link rel=\"stylesheet\" href=\"<$mt:Link template=\"styles\" encode_html=\"1\"$>\">\n    <!--[if lt IE 9]>\n    <link rel=\"stylesheet\" href=\"<$mt:Link template=\"styles_ie\" encode_html=\"1\"$>\">\n    <script src=\"<$mt:SupportDirectoryURL encode_html=\"1\"$>theme_static/rainier/js/html5shiv.js\"></script>\n    <![endif]-->\n    <mt:Assets tag=\"@SITE_FAVICON\" limit=\"1\"><link rel=\"shortcut icon\" href=\"<$mt:AssetURL encode_html=\"1\"$>\"></mt:Assets>\n    <link rel=\"start\" href=\"<$mt:BlogURL encode_html=\"1\"$>\">\n    <link rel=\"alternate\" type=\"application/atom+xml\" title=\"Recent Entries\" href=\"<$mt:Link template=\"feed_recent\"$>\" />\n    <$mt:CanonicalLink$>\n    <$mt:StatsSnippet$>\n",
              "linkToFile": "",
              "createdDate": "2015-05-22T13:19:53+09:00",
              "id": "33",
              "type": "custom",
              "modifiedDate": "2015-05-22T13:19:53+09:00",
              "customFields": []
            }

listTemplates 

new in v2.0: Retrieve a list of templates in the specified site.
/sites/:site_id/templates(?site_id, limit ,offset, sortBy, sortOrder,fields, searchFields, search, includeIds, excludeIds, type)
  • Authorization is required.

Permissions

  • edit_templates
  • Parameters
  • site_id
    number (required) 

    The site ID. If 0 specified, will load from global template in the system.

    search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: label 

    The comma separated list of field names to search.

    limit
    number (optional) Default: 10 

    Maximum number of assets to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: name 
    id
    Sort by the ID of each template.
    name
    Sort by the name of each template.
    created_on
    Sort by the created time of each template.
    modified_on
    Sort by the modified time of each template.
    created_by
    Sort by the ID of user who created each template.
    modified_by
    Sort by the ID of user who modified each template.
    type
    Sort by the type of each template.
    sortOrder
    string (optional) Default: descend 
    descend
    Return templates in descending order. For sorting by date, it means from newest to oldest.
    ascend
    Return templates in ascending order. For sorting by date, it means from oldest to newest.
    fields
    string (optional) 

    The field list to retrieve as part of the Templates resource. The list of field names should be separated by commas. If this parameter is not specified, all fields will be returned.

    includeIds
    string (optional) 

    The comma separated list of template IDs to include in result.

    excludeIds
    string (optional) 

    The comma separated list of template IDSs to exclude from result.

    type
    string (optional) 

    Filter by template type. The list should be separated by commas. (e.g. archive, custom, index, individual, page etc…)

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults": "29",
      "items": [
        {
          "createdBy": {
            "userpicUrl": null,
            "id": "1",
            "displayName": "Yuji Takayama"
          },
          "name": "HTML Header",
          "updatable": true,
          "blog": {
            "id": "1"
          },
          "text": "    <meta name=\"viewport\" content=\"width=device-width,initial-scale=1\">\n    <link rel=\"stylesheet\" href=\"<$mt:Link template=\"styles\" encode_html=\"1\"$>\">\n    <!--[if lt IE 9]>\n    <link rel=\"stylesheet\" href=\"<$mt:Link template=\"styles_ie\" encode_html=\"1\"$>\">\n    <script src=\"<$mt:SupportDirectoryURL encode_html=\"1\"$>theme_static/rainier/js/html5shiv.js\"></script>\n    <![endif]-->\n    <mt:Assets tag=\"@SITE_FAVICON\" limit=\"1\"><link rel=\"shortcut icon\" href=\"<$mt:AssetURL encode_html=\"1\"$>\"></mt:Assets>\n    <link rel=\"start\" href=\"<$mt:BlogURL encode_html=\"1\"$>\">\n    <link rel=\"alternate\" type=\"application/atom+xml\" title=\"Recent Entries\" href=\"<$mt:Link template=\"feed_recent\"$>\" />\n    <$mt:CanonicalLink$>\n    <$mt:StatsSnippet$>\n",
          "linkToFile": "",
          "createdDate": "2015-05-22T13:19:53+09:00",
          "id": "33",
          "type": "custom",
          "modifiedDate": "2015-05-22T13:19:53+09:00",
          "customFields": []
        },
        {
          "outputFile": "mt-theme-scale2.js",
          "createdBy": {
            "userpicUrl": null,
            "id": "1",
            "displayName": "Yuji Takayama"
          },
          "name": "JavaScript - Theme",
          "updatable": true,
          "blog": {
            "id": "1"
          },
          "buildType": "Static",
          "templateType": "javascript_theme",
          "text": "$(function() {\n    $('<select />').appendTo('header [role=\"navigation\"]');\n\n    $('<option />', {\n        'value': '',\n        'text': 'Menu',\n        'selected': 'selected'\n    }).appendTo('header [role=\"navigation\"] > select');\n\n    $('header [role=\"navigation\"] a').each(function() {\n        var el = $(this);\n        $('<option />', {\n            'value': el.attr('href'),\n            'text': el.text()\n        }).appendTo('header [role=\"navigation\"] > select');\n    });\n\n    $('header [role=\"navigation\"] > select, .widget-archive-dropdown select').change(function() {\n        window.location = $(this).find('option:selected').val();\n    });\n});\n",
          "linkToFile": "",
          "type": "index",
          "id": "9",
          "createdDate": "2015-05-22T13:19:53+09:00",
          "modifiedDate": "2015-05-22T13:19:53+09:00",
          "customFields": []
        }
      ]
    }
    
  • Response  401
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Unauthorized",
        "code": 401
      }
    }
    
  • Response  403
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Do not have permission to retrieve the list of templates.",
        "code": "403"
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Site not found",
        "code": "404"
      }
    }
    
  • Response  500
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Some error message is here",
        "code": "500"
      }
    }
    

getTemplate 

new in v2.0: Retrieve single template by its ID.
/sites/:site_id/templates/:template_id(?fields)
  • Authorization is required.

Permissions

  • edit_templates
  • Parameters
  • site_id
    number (required) 

    The site ID. If 0 specified, will load from global template in the system.

    template_id
    number (required) 

    The template ID.

    fields
    string (optional) 

    The field list to retrieve as part of the Templates resource. The list of field names should be separated by commas. If this parameter is not specified, all fields will be returned.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "createdBy": {
        "userpicUrl": null,
        "id": "1",
        "displayName": "Yuji Takayama"
      },
      "name": "HTML Header",
      "updatable": true,
      "blog": {
        "id": "1"
      },
      "text": "    <meta name=\"viewport\" content=\"width=device-width,initial-scale=1\">\n    <link rel=\"stylesheet\" href=\"<$mt:Link template=\"styles\" encode_html=\"1\"$>\">\n    <!--[if lt IE 9]>\n    <link rel=\"stylesheet\" href=\"<$mt:Link template=\"styles_ie\" encode_html=\"1\"$>\">\n    <script src=\"<$mt:SupportDirectoryURL encode_html=\"1\"$>theme_static/rainier/js/html5shiv.js\"></script>\n    <![endif]-->\n    <mt:Assets tag=\"@SITE_FAVICON\" limit=\"1\"><link rel=\"shortcut icon\" href=\"<$mt:AssetURL encode_html=\"1\"$>\"></mt:Assets>\n    <link rel=\"start\" href=\"<$mt:BlogURL encode_html=\"1\"$>\">\n    <link rel=\"alternate\" type=\"application/atom+xml\" title=\"Recent Entries\" href=\"<$mt:Link template=\"feed_recent\"$>\" />\n    <$mt:CanonicalLink$>\n    <$mt:StatsSnippet$>\n",
      "linkToFile": "",
      "createdDate": "2015-05-22T13:19:53+09:00",
      "id": "33",
      "type": "custom",
      "modifiedDate": "2015-05-22T13:19:53+09:00",
      "customFields": []
    }
    
    + Response 401 (application/json)
    
            {
              "error": {
                "message": "Unauthorized",
                "code": 401
              }
            }
    
    + Response 403 (application/json)
    
            {
              "error": {
                "message": "Do not have permission to retrieve the list of templates.",
                "code": "403"
              }
            }
    
    + Response 404 (application/json)
    
            {
              "error": {
                "message": "Site not found / Template not found",
                "code": "404"
              }
            }
    
    + Response 500 (application/json)
    
            {
              "error": {
                "message": "Some error message is here",
                "code": "500"
              }
            }
    

createTemplate 

new in v2.0: Create a new template.
/sites/:site_id/templates
  • Authorization is required.

Permissions

  • edit_templates
  • Parameters
  • site_id
    number (required) 

    The site ID. If 0 specified, will create into the global template in the system.

  • Request  Templates resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    template={ "name": "New Template", "text": "some template code here", "linkToFile": "", "type": "custom" }
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "createdBy": {
        "userpicUrl": null,
        "id": "1",
        "displayName": "Yuji Takayama"
      },
      "name": "New Template",
      "updatable": true,
      "blog": {
        "id": "1"
      },
      "text": "some template code here",
      "linkToFile": "",
      "createdDate": "2015-06-29T16:47:09+09:00",
      "id": "152",
      "type": "custom",
      "modifiedDate": "2015-06-29T16:47:09+09:00",
      "customFields": []
    }
    
  • Response  401
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Unauthorized",
        "code": 401
      }
    }
    
  • Response  403
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Do not have permission to retrieve a template.",
        "code": "403"
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Site not found",
        "code": "404"
      }
    }
    
  • Response  500
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Some error message is here",
        "code": "500"
      }
    }
    

updateTemplate 

new in v2.0: Update a template.
/sites/:site_id/templates/:template_id
  • Authorization is required.

  • This method accepts PUT or POST with __method=PUT.

Permissions

  • edit_templates
  • Parameters
  • site_id
    number (required) 

    The site ID. If 0 specified, will update a global template in the system.

    template_id
    number (required) 

    The template ID.

  • Request  Templates resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    template={ "name": "new template name" }
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "createdBy": {
        "userpicUrl": null,
        "id": "1",
        "displayName": "Yuji Takayama"
      },
      "name": "New Template name",
      "updatable": true,
      "blog": {
        "id": "1"
      },
      "text": "some template code here",
      "linkToFile": "",
      "createdDate": "2015-06-29T16:47:09+09:00",
      "id": "152",
      "type": "custom",
      "modifiedDate": "2015-06-29T16:47:09+09:00",
      "customFields": []
    }
    
  • Response  401
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Unauthorized",
        "code": 401
      }
    }
    
  • Response  403
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Do not have permission to update a template.",
        "code": "403"
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Site not found / Template not found",
        "code": "404"
      }
    }
    
  • Response  405
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Request method is not PUT or 'POST' with __PUT"
        "code": "405"
      }
    }
    
  • Response  500
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Some error message is here",
        "code": "500"
      }
    }
    

deleteTemplate 

new in v2.0: Delete a template.
/sites/:site_id/templates/:template_id
  • Authorization is required.

  • This method accepts DELETE or POST with __method=DELETE.

Permissions

  • edit_templates
  • Parameters
  • site_id
    number (required) 

    The site ID. If 0 specified, delete from global template in the system.

    template_id
    number (required) 

    The template ID.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "createdBy": {
        "userpicUrl": null,
        "id": "1",
        "displayName": "Yuji Takayama"
      },
      "name": "New Template name",
      "updatable": true,
      "blog": {
        "id": "1"
      },
      "text": "some template code here",
      "linkToFile": "",
      "createdDate": "2015-06-29T16:47:09+09:00",
      "id": "152",
      "type": "custom",
      "modifiedDate": "2015-06-29T16:47:09+09:00",
      "customFields": []
    }
    
  • Response  401
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Unauthorized",
        "code": 401
      }
    }
    
  • Response  403
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Do not have permission to delete a template.",
        "code": "403"
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Site not found / Template not found",
        "code": "404"
      }
    }
    
  • Response  405
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Request method is not PUT or 'POST' with __PUT"
        "code": "405"
      }
    }
    
  • Response  500
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Some error message is here",
        "code": "500"
      }
    }
    

publishTemplate 

new in v2.0: Publish a template.
/sites/:site_id/templates/:template_id/publish
  • Authorization is required.

  • Only available for following templates

    • index
    • archive
    • individual
    • page
    • category

Permissions

  • rebuild
  • Parameters
  • site_id
    number (required) 

    The site ID

    template_id
    number (required) 

    The template ID.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status" : "success"
    }
    
  • Response  400
  • Headers
    Content-Type: application/json
    Body
    {
      "error" : {
        "message" : "Cannot publish [template type] template.",
        "code": "400"
      }
    }
    
  • Response  403
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Do not have permission to publish a template.",
        "code": "403"
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Site not found / Template not found",
        "code": "404"
      }
    }
    
  • Response  500
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Some error message is here",
        "code": "500"
      }
    }
    

refreshTemplate 

new in v2.0: Reset template text to theme default or tempalte_set default.
/sites/:site_id/templates/:template_id/refresh
  • Authorization is required.

Permissions

  • edit_templates
  • Parameters
  • site_id
    number (required) 

    The site ID. If 0 specified, refresh a global template in the system.

    template_id
    number (required) 

    The template ID.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "messages": [
        "「New Template name」を初期化します。"
      ],
      "status": "success"
    }
    
  • Response  403
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Do not have permission to refresh a template.",
        "code": "403"
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Site not found / Template not found",
        "code": "404"
      }
    }
    
  • Response  500
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Some error message is here",
        "code": "500"
      }
    }
    

refreshTemplateForSite 

new in v2.0: Reset all templates in the site.
/sites/:site_id/refresh_templates(?refresh_type)
  • Authorization is required.

Permissions

  • edit_templates
  • Parameters
  • site_id
    number (required) 

    The site ID. If 0 specified, refresh a global template in the system.

    refresh_type
    string (optional) Default: refresh 

    The type of refresh mode.

    refresh
    Refresh all templates. However, A template that created by user will never refreshed and never removed from a site.
    clean
    Refresh all templates. In this mode, A template that created by user will removed from a site.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status": "success"
    }
    
  • Response  403
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Do not have permission to refresh templates of the request site.",
        "code": "403"
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Site not found",
        "code": "404"
      }
    }
    
  • Response  500
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Some error message is here",
        "code": "500"
      }
    }
    

cloneTemplate 

new in v2.0: Make a clone of a template.
/sites/:site_id/templates/:template_id/clone
  • Authorization is required.

Permissions

  • edit_templates
  • Parameters
  • site_id
    number (required) 

    The site ID. If 0 specified, refresh a global template in the system.

    template_id
    number (required) 

    The template ID.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status": "success"
    }
    
  • Response  403
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Do not have permission to clone a template.",
        "code": "403"
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Site not found / Template not found",
        "code": "404"
      }
    }
    
  • Response  500
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Some error message is here",
        "code": "500"
      }
    }
    

previewTemplate 

new in v2.0: Make a preview for a template.
/sites/:site_id/templates/preview(?raw)
  • Authorization is required.

  • This endpoint is available in Movable Type 6.1.2 or later.

Permissions

  • edit_templates
  • Parameters
  • site_id
    number (required) 

    The site ID.

    raw
    number (optional) 

    If specify “1”, will be returned preview contents.

  • Request  Templates resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    template={ "name": "New Template", "text": "some template code here", "type": "custom" }
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status": "success",
      "preview": "http://example.com/index.html"
    }
    
  • Response  403
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Do not have permission to get template preview.",
        "code": "403"
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Site not found",
        "code": "404"
      }
    }
    
  • Response  500
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Some error message is here",
        "code": "500"
      }
    }
    

previewTemplateById 

new in v2.0: Make a preview for a template with existing data.
/sites/:site_id/templates/:template_id/preview(?raw)
  • Authorization is required.

  • This endpoint is available in Movable Type 6.1.2 or later.

  • Only available for following templates

    • index
    • archive
    • individual
    • page
    • category
    • template parameter is required. If you just want to get preview template from existing data, you should provide template parameter with empty json.

Permissions

  • edit_templates
  • Parameters
  • site_id
    number (required) 

    The site ID.

    template_id
    number (required) 

    The template ID.

    raw
    number (optional) 

    If specify “1”, will be returned preview contents.

  • Request  Templates resource
  • Headers
    Content-Type: application/x-www-form-urlencoded
    Body
    template={}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status": "success",
      "preview": "http://example.com/index.html"
    }
    
  • Response  403
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Do not have permission to get template preview.",
        "code": "403"
      }
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Site not found / Template not found",
        "code": "404"
      }
    }
    
  • Response  500
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "message": "Some error message is here",
        "code": "500"
      }
    }
    

Themes 

This is the Themes resource. The Themes resource is not stored in the database.

Property NameTypeData TypeDatabase ColumnPrivateRead OnlyDescriptionVersion
authorLinkvaluestring-YYThe author link of this theme.v2
authorNamevaluestring-YYThe author name of this theme.v2
currentvalueboolean-YYDEPRECATAD
descriptionvaluestring-YYThe description for this theme.v2
idvaluestring-YYThe ID for this theme.v2
inUsevalueboolean-YYThis property is displayed only in system scope.
true
This theme is in used by any site.
false
This theme is not in use.
v2
labelvaluestring-YYThe label for this theme.v2
uninstallablevalueboolean-YY
true
This theme is able to uninstall.
false
This theme is not able to uninstall.
v2
versionvaluestring-YYThe version number for this theme.v2
    {
      "authorName": "Six Apart Ltd.",
      "authorLink": "http://www.movabletype.org/",
      "version": "1.14",
      "description": "\"Rainier\" is a customizable Responsive Web Design theme, designed for blogs. In addition to multi-device viewing support, provided by Media Query (CSS), Movable Type functions make customizing navigational contents as well as image elements, such as logos, headers, very simple.",
      "uninstallable": false,
      "inUse": true,
      "id": "rainier",
      "label": "Rainier"
    }

listThemes 

New in v2.0: Retrieve a list of themes.
/themes
  • Authentication is required

Permissions

  • manage_themes
  • Request
  • Headers
    X-MT-Authorization: MTAuth accessToken=<Token>
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults": 9,
      "items": [
        {
          "authorName": "Six Apart Ltd.",
          "authorLink": "http://www.movabletype.org/",
          "version": "1.14",
          "description": "\"Rainier\" is a customizable Responsive Web Design theme, designed for blogs. In addition to multi-device viewing support, provided by Media Query (CSS), Movable Type functions make customizing navigational contents as well as image elements, such as logos, headers, very simple.",
          "uninstallable": false,
          "inUse": true,
          "id": "rainier",
          "label": "Rainier"
        },
        {
          "authorName": "Six Apart Ltd.",
          "authorLink": "http://www.movabletype.org/",
          "version": "1.3",
          "description": "Create a blog portal that aggregates contents from several blogs in one website.",
          "uninstallable": false,
          "inUse": false,
          "label": "Classic Website",
          "id": "classic_website"
        },
        {
          "authorName": "Six Apart Ltd.",
          "authorLink": "http://www.sixapart.com/",
          "version": "1.11",
          "description": "Professional designed, well structured and easily adaptable web site. You can customize default pages, footer and top navigation easily.",
          "uninstallable": false,
          "inUse": false,
          "label": "Professional Website",
          "id": "professional_website"
        },
        {
          "authorName": "Six Apart, Ltd",
          "authorLink": "http://www.sixapart.com/",
          "version": "1.44",
          "description": "Eiger is a customizable Responsive Web Design theme, designed for blogs and corporate websites. In addition to multi-device viewing support, provided via Media Query (CSS), Movable Type functions make customizing navigational contents as well as image elements, such as logos, headers or banners, very simple.",
          "uninstallable": false,
          "inUse": false,
          "label": "Eiger",
          "id": "eiger"
        },
        {
          "authorName": "Six Apart Ltd.",
          "authorLink": "http://www.movabletype.org/",
          "version": "1.3",
          "description": "Pico is a microblogging theme, designed for keeping things simple to handle frequent updates. To put the focus on content we've moved the sidebars below the list of posts.",
          "uninstallable": false,
          "inUse": false,
          "label": "Pico",
          "id": "pico"
        },
        {
          "authorName": "Six Apart Ltd.",
          "authorLink": "http://www.movabletype.org/",
          "version": "1.3",
          "description": "A traditional blogging design that comes with plenty of styles and a selection of 2 column / 3 column layouts. Best for use in standard blog publishing applications.",
          "uninstallable": false,
          "inUse": false,
          "label": "Classic Blog",
          "id": "classic_blog"
        },
        {
          "authorName": "Six Apart Ltd.",
          "authorLink": "http://www.sixapart.com/",
          "version": "1.01",
          "description": "Increase reader engagement - deploy features to your website that make it easier for your readers to engage with your content and your company.",
          "uninstallable": false,
          "inUse": false,
          "label": "Community Blog",
          "id": "mt_community_blog"
        },
        {
          "authorName": "Six Apart Ltd.",
          "authorLink": "http://www.sixapart.com/",
          "version": "1.01",
          "description": "Create forums where users can post topics and responses to topics.",
          "uninstallable": false,
          "inUse": false,
          "label": "Community Forum",
          "id": "mt_community_forum"
        },
        {
          "authorName": "Six Apart Ltd.",
          "authorLink": "http://www.sixapart.com/",
          "version": "1.11",
          "description": "Create a blog as a part of structured website. This works best with Professional Website theme.",
          "uninstallable": false,
          "inUse": false,
          "label": "Professional Blog",
          "id": "professional_blog"
        }
      ]
    }
    

getTheme 

New in v2.0: Retrieve a single theme by its ID.
/themes/:theme_id
  • Authentication is required

Permissions

  • manage_themes
  • Parameters
  • theme_id
    string (required) 

    The theme ID.

  • Request
  • Headers
    X-MT-Authorization: MTAuth accessToken=<Token>
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "authorName": "Six Apart Ltd.",
      "authorLink": "http://www.movabletype.org/",
      "version": "1.14",
      "description": "\"Rainier\" is a customizable Responsive Web Design theme, designed for blogs. In addition to multi-device viewing support, provided by Media Query (CSS), Movable Type functions make customizing navigational contents as well as image elements, such as logos, headers, very simple.",
      "uninstallable": false,
      "inUse": false,
      "id": "rainier",
      "label": "Rainier"
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "code": 404,
        "message": "Theme not found"
      }
    }
    

applyThemeToSite 

New in v2.0: Apply a theme to site.
/sites/:site_id/themes/:theme_id/apply
  • Authentication is required

Permissions

  • manage_themes
  • Parameters
  • site_id
    number (required) 

    The site ID.

    theme_id
    string (required) 

    The theme ID.

  • Request
  • Headers
    X-MT-Authorization: MTAuth accessToken=<Token>
  • Response  200
  • Headers
    Content-Type: appication/json
    Body
    {
      "status": "success"
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "code": 404,
        "message": "Theme not found"
      }
    }
    

uninstall_theme 

Uninstall a specified theme from the MT.
/themes/:theme_id
  • Authentication is required

  • When successful, you can take Themes Resource that was deleted. However, this theme is already removed from the Movable Type. You cannot apply this theme to.

Permissions

  • manage_themes
  • Parameters
  • theme_id
    string (required) 

    The theme ID.

  • Request
  • Headers
    X-MT-Authorization: MTAuth accessToken=<Token>
  • Response  200
  • Headers
    Content-Type: appication/json
    Body
    {
      "authorName": null,
      "authorLink": "",
      "version": "1.0",
      "description": "",
      "uninstallable": true,
      "inUse": false,
      "id": "theme_from_test",
      "label": "Theme from Rainier"
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "code": 404,
        "message": "Theme not found"
      }
    }
    

exportSiteTheme 

New in v2.0: Export site's theme.
/sites/:site_id/export_theme
  • Authentication is required

  • This endpoint will export current theme elements of specified site into theme directory.

Permissions

  • manage_themes
  • Parameters
  • site_id
    number (required) 

    The site ID.

  • Request
  • Headers
    X-MT-Authorization: MTAuth accessToken=<Token>
  • Response  200
  • Headers
    Content-Type: appication/json
    Body
    {
      "status": "success"
    }
    
  • Response  404
  • Headers
    Content-Type: application/json
    Body
    {
      "error": {
        "code": 404,
        "message": "Theme not found"
      }
    }
    

Users 

This is the Users resource.

Property NameTypeData TypeDatabase ColumnPrivateRead OnlyDescriptionVersion
createdByObjectUser-YYCreated user of this user.v2
createdBy.displayNamevaluestringmt_author.author_nicknameYYThe display name of this user creator.v2
createdBy.idvaluenumbermt_author.author_created_byYYThe ID of this user creator.v2
createdBy.userpicUrlvaluestringmt_author.author_userpic_urlYThe URL of this user creator’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, will be returned empty string.v2
createdDatevalueiso 8601 datetimemt_author.author_created_on-YCreated date of this user.v2
customFieldsvalueField--YThe list of customfields data of this user.v2
customField.basenamevaluestringmt_field.field_basename-YThe basename of this customfield.v2
customField.valuevaluestringmt_author_meta.*--The value of this customfield.v2
dateFormatvaluestringmt_author.author_date_formatYThe date formatting for this user.v2
displayNamevaluestringmt_author.author_nicknameThe public display name for this user.v1
emailvaluestringmt_author.author_emailYThe email address for this user.v1
idvaluenumbermt_author.author_idYYThe unique ID for this user.v1
isSuperuservaluebooleanYY
true
This user have permission for system administration.
false
This user does not have permission for system administration.
v2
languagevaluestringmt_author.author_preferred_languageThe preferred language for this user.
Available values
  • de
  • en-us
  • es
  • fr
  • nl
  • ja
v1
lockedOutvaluebooleanmt_author.author_locked_out_timeYY
true
This user is currently locked out.
false
This user is not locked out.
v2
modifiedByObjectUser--YLast modified user of this user.v2
modifiedBy.displayNamevaluestringmt_author.author_nickname-YThe display name of this user modifier.v2
modifiedBy.idvaluenumbermt_author.author_modified_by-YThe ID of this user modifier.v2
modifiedBy.userpicUrlvaluestringmt_author.author_userpic_url-YThe URL of this user modifier’s userpic. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, will be returned empty string.v2
modifiedDatevalueiso 8601 datetimemt_author.author_modified_on-YLast modified date of this user.v2
namevaluestringmt_author.author_nameThe account name for this user. [update in v2] This column was changed to updatable from v2.v1
passwordvaluestringmt_author.author_passwordYWrite OnlyThe password for this user. This property is write only.v2
updatablevaluebooleanY
true
The user who accessed can update this user.
false
The user who accessed cannot update this user.
v1
urlvaluestringmt_author.author_urlThe web site URL for this user.v1
userpicUrlvaluestringYThe profile photo URL for this user. The userpic will be made by UserpicThumbnailSize and UserpicAllowRect settings. If user does not set own userpic, will be returned empty string.v1
statusvaluestringmt_author.author_statusYThe status for this user. Available value is follows.
Active
The status is active. The user can do anything within his/her permissions.
Disabled
The status is disabled. The user cannot do anything.
Pending
The status is pending. The user is waiting for approval by the administrator. Therefore, this user cannot do anything.
v2
systemPermissionsARRAYstring-Y-The list of system permissions which this user have. Only system administrator can get this propertyv2
tagDelimitervaluestringmt_author.author_entry_prefsYThe tag delimiter character for this user. Available value is follow.
comma
Separator character is single comma.
space
Separator character is single space
v2
textFormatvaluestringmt_author.author_text_formatYThe text formatting for this user.v2
    {
      "status" : "Active",
      "createdBy" : {
        "userpicUrl" : null,
        "id" : "1",
        "displayName" : "Yuji Takayama"
      },
      "updatable" : true,
      "lockedOut" : false,
      "isSuperuser" : true,
      "dateFormat" : "relative",
      "systemPermissions" : [
        "administer",
        "create_website",
        "create_blog",
        "edit_templates",
        "manage_plugins",
        "view_log"
      ],
      "email" : "ytakayama@sixapart.com",
      "userpicUrl" : null,
      "url" : "",
      "id" : "1",
      "tagDelimiter" : "comma",
      "displayName" : "Yuji Takayama",
      "modifiedBy" : {
        "userpicUrl" : null,
        "id" : "1",
        "displayName" : "Yuji Takayama"
      },
      "modifiedDate" : "2015-03-26T17:12:18+09:00",
      "language" : "en-us",
      "name" : "takayama",
      "textFormat" : "0",
      "createdDate" : "2015-03-23T14:53:52+09:00",
      "customFields" : []
    }

listUsers 

New in v2.0: Retrieve a list of users in the specified site.
/users(?search, searchFields, limit, offset, sortBy, sortOrder, fields, includeIds, excludeIds, status, lockout)
  • Authentication is required if want to include non-active users. Also, want to get private properties.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to retrieve the list of users.

Permissions

  • administer
    • for retrieve non-active users
    • for read private properties
  • Parameters
  • search
    string (optional) 

    Search query.

    searchFields
    string (optional) Default: name,displayName,email,url 

    The comma separated field name list to search.

    limit
    number (optional) Default: 10 

    Maximum number of users to retrieve.

    offset
    number (optional) Default: 0 

    0-indexed offset.

    sortBy
    string (optional) Default: name 

    The field name for sort. You can specify one of following values

    • id
    • name

    sortOrder
    string (optional) Default: descend 
    descend
    (default) Return users in descending order.
    ascend
    Return users in ascending order.
    fields
    string (optional) 

    The field list to retrieve as part of the Users resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

    includeIds
    string (optional) 

    The comma separated ID list of users to include to result.

    excludeIds
    string (optional) 

    The comma separated ID list of users to exclude from result.

    status
    string (optional) 

    Filter by users’s status.

    active
    status is Active
    disabled
    status is Disabled.
    pending
    status is Pending

    lockout
     (required) 

    Filter by user’s lockout status.

    locked_out
    Locked out user only
    not_locked_out
    Not locked out user only

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "totalResults" : 1,
      "items" : [
        {
          "status" : "Active",
          "createdBy" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "updatable" : true,
          "lockedOut" : false,
          "isSuperuser" : true,
          "dateFormat" : "relative",
          "systemPermissions" : [
            "administer",
            "create_website",
            "create_blog",
            "edit_templates",
            "manage_plugins",
            "view_log"
          ],
          "email" : "ytakayama@sixapart.com",
          "userpicUrl" : null,
          "url" : "",
          "id" : "1",
          "tagDelimiter" : "comma",
          "displayName" : "Yuji Takayama",
          "modifiedBy" : {
            "userpicUrl" : null,
            "id" : "1",
            "displayName" : "Yuji Takayama"
          },
          "modifiedDate" : "2015-03-26T17:12:18+09:00",
          "language" : "en-us",
          "name" : "takayama",
          "textFormat" : "0",
          "createdDate" : "2015-03-23T14:53:52+09:00",
          "customFields" : []
        }
      ]
    }
    

createUser 

New in v2.0: Create a new user.
/users
  • Authentication is required.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to create a new user.

Permissions

  • administer

Request Body Parameters

NameTypeRequiredDefaultDescription
entryObjectYesSingle Entries resource
  • Parameters
  • site_id
    number (required) 

    The site ID.

  • Request
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth accessToken=<Token>
    Body
    user={"email" : "aikawa@example.com","displayName" : "Ichiro Aikawa","name" : "aikawa","password":"password"}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status" : "Active",
      "createdBy" : {
        "userpicUrl" : null,
        "id" : "1",
        "displayName" : "Yuji Takayama"
      },
      "updatable" : true,
      "lockedOut" : false,
      "isSuperuser" : false,
      "dateFormat" : "relative",
      "systemPermissions" : [],
      "email" : "aikawa@example.com",
      "userpicUrl" : null,
      "url" : null,
      "id" : "2",
      "tagDelimiter" : "comma",
      "displayName" : "Ichiro Aikawa",
      "modifiedDate" : "2015-03-27T10:45:43+09:00",
      "language" : "ja",
      "name" : "aikawa",
      "textFormat" : 0,
      "createdDate" : "2015-03-27T10:45:43+09:00",
      "customFields" : []
    }
    

getUser 

Retrieve a single user by its own ID.
/users/:user_id(?fields)
  • Authentication is required if want to get non-active user or want to get private properties.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to get the user.
404Not FoundUser not found.

Permissions

  • administer
  • Parameters
  • user_id
    number or the word 'me' (required) 

    The user ID.

    fields
    string (optional) 

    The field list to retrieve as part of the Users resource. That list should be separated by comma. If this parameter is not specified, All fields will be returned.

  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status" : "Active",
      "createdBy" : {
        "userpicUrl" : null,
        "id" : "1",
        "displayName" : "Yuji Takayama"
      },
      "updatable" : true,
      "lockedOut" : false,
      "isSuperuser" : true,
      "dateFormat" : "relative",
      "systemPermissions" : [
        "administer",
        "create_website",
        "create_blog",
        "edit_templates",
        "manage_plugins",
        "view_log"
      ],
      "email" : "ytakayama@sixapart.com",
      "userpicUrl" : null,
      "url" : "",
      "id" : "1",
      "tagDelimiter" : "comma",
      "displayName" : "Yuji Takayama",
      "modifiedBy" : {
        "userpicUrl" : null,
        "id" : "1",
        "displayName" : "Yuji Takayama"
      },
      "modifiedDate" : "2015-03-26T17:12:18+09:00",
      "language" : "en-us",
      "name" : "takayama",
      "textFormat" : "0",
      "createdDate" : "2015-03-23T14:53:52+09:00",
      "customFields" : []
    }
    

updateUser 

Update oneself or another one's user data.
/users/:user_id
  • Authentication is required.

  • This method accepts PUT and POST with __method=PUT.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to update user.
404Not FoundUser not found.
405Method Not AllowedRequest method is not ‘PUT’ or ‘POST’ with ‘__method=PUT’

Permissions

  • administer
    • If you want to update another one’s or non-active user.
  • Parameters
  • user_id
    number or the word 'me' (required) 

    The user ID.

  • Request
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth accessToken=<Token>
    Body
    user={"displayName": "New Name"}
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status" : "Active",
      "createdBy" : {
        "userpicUrl" : null,
        "id" : "1",
        "displayName" : "Yuji Takayama"
      },
      "updatable" : true,
      "lockedOut" : false,
      "isSuperuser" : false,
      "dateFormat" : "relative",
      "systemPermissions" : [],
      "email" : "aikawa@example.com",
      "userpicUrl" : null,
      "url" : null,
      "id" : "2",
      "tagDelimiter" : "comma",
      "displayName" : "New Name",
      "modifiedDate" : "2015-03-27T10:45:43+09:00",
      "language" : "ja",
      "name" : "aikawa",
      "textFormat" : "0",
      "createdDate" : "2015-03-27T10:45:43+09:00",
      "customFields" : []
    }
    

deleteUser 

New in v2.0: Delete user.
/users/:user_id
  • Authentication is required.

  • This method accepts DELETE and POST with __method=DELETE.

  • Cannot delete oneself. Also, cannot delete system administrator user.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to delete user.
404Not FoundUser not found.
405Method Not AllowedRequest method is not ‘DELETE’ or ‘POST’ with ‘__method=DELETE’

Permissions

  • administer
  • Parameters
  • user_id
    number (required) 

    The user ID.

  • Request
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth accessToken=<Token>
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status" : "Active",
      "createdBy" : {
        "userpicUrl" : null,
        "id" : "1",
        "displayName" : "Yuji Takayama"
      },
      "updatable" : true,
      "lockedOut" : false,
      "isSuperuser" : false,
      "dateFormat" : "relative",
      "systemPermissions" : [],
      "email" : "aikawa@example.com",
      "userpicUrl" : null,
      "url" : null,
      "id" : "2",
      "tagDelimiter" : "comma",
      "displayName" : "New Name",
      "modifiedDate" : "2015-03-27T10:45:43+09:00",
      "language" : "ja",
      "name" : "aikawa",
      "textFormat" : "0",
      "createdDate" : "2015-03-27T10:45:43+09:00",
      "customFields" : []
    }
    

unlockUser 

Unlock user account.
/users/:user_id/unlock
  • Authentication is required.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to unlock user.
404Not FoundUser not found.

Permissions

  • administer
  • Parameters
  • user_id
    number (required) 

    The user ID.

  • Request
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth accessToken=<Token>
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status": "success"
    }
    

recoverPasswordForUser 

Send the link for password recovery to specified user by email.
/users/:user_id/recover_password
  • Authentication is required.

Status Code

CodeStatusDescription
200OKNo Errors.
403ForbiddenDo not have permission to send password recovery mail.
404Not FoundUser not found.

Permissions

  • administer
  • Parameters
  • user_id
    number (required) 

    The user ID.

  • Request
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth accessToken=<Token>
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status": "success",
      "message": <Result message>
    }
    

recoverPassword 

Send the link for password recovery to specified email.
/recover_password
  • This method always returns successful code if it does not found a user, because security reason.

  • Authentication is not required.

Status Code

CodeStatusDescription
200OKNo Errors.

Permissions

  • administer
  • Parameters
  • user_id
    number (required) 

    The user ID.

  • Request
  • Headers
    Content-Type: application/x-www-form-urlencoded
    X-MT-Authorization: MTAuth accessToken=<Token>
    Body
    email=<Email address for user>&name=<Name for user>
    
  • Response  200
  • Headers
    Content-Type: application/json
    Body
    {
      "status": "success",
      "message": <Result message>
    }
    

Generated by aglio on 01 Jul 2015