Add Movable Type's Data API Endpoints and Resources for MT::Asset Object.
Authorization is required If you specified DataAPIAssetsRequiresLogin 1 in mt-config.cgi
This method accepts GET only.
GET https://your-host/your-mt-api.cgi/v1/sites/{blog_id}/assets
GET https://your-host/your-mt-api.cgi/v1/sites/{blog_id}/assets/image
GET https://your-host/your-mt-api.cgi/v1/sites/{blog_id}/assets/video
GET https://your-host/your-mt-api.cgi/v1/sites/{blog_id}/assets/audio
- search(string) : This is an optional parameter. Search query.
- searchFields(string) : This is an optional parameter. The comma separated field name list to search. Default is 'label,description,file_name'
- limit(unsigned integer) : This is an optional parameter. Maximum number of assets to retrieve. Default is 10.
- offset(unsigned integer) : This is an optional parameter. 0-indexed offset. Default is 0.
- sortBy(string) : This is an optional parameter(Default: modified_on).
- sortOrder(string) : This is an optional parameter(Default: descend).
- totalResults : The total number of assets found that by the requesst.
- items : An array of assets resource.
Authorization is required If you specified DataAPIAssetsRequiresLogin 1 in mt-config.cgi
This method accepts GET only.
GET https://your-host/your-mt-api.cgi/v1/sites/{blog_id}/assets/{asset_id}
Authorization is required
This method accepts PUT and POST with __method=PUT.
POST https://your-host/your-mt-api.cgi/v1/sites/{blog_id}/assets/{asset_id}
- asset : An Asset resource for update(JSON)(optional).
- file: file data to overwrite(optional).
Authorization is required
This method accepts DELETE and POST with __method=DELETE.
DELETE https://your-host/your-mt-api.cgi/v1/sites/{blog_id}/assets/{asset_id}
See https://github.com/movabletype/Documentation/wiki/data-api-resource-assets
- icon_url : Icon's URL or Thumbnail URL(string).
- image_width : Width of Image file(integer).
- image_height : Height of Image file(integer).