From MediaWiki.org
Jump to navigation Jump to search

Returns file information for stashed files. Although it appears under its own key, stashimageinfo, rather than the pages key like other property modules, the output of this module is otherwise identical to that of API:Imageinfo.


  • siifilekey: The filekey(s) to search for, as returned by API:Upload. 1.18+
  • siisessionkey: The sessionkey(s) to search for, as returned by API:Upload. (deprecated in 1.18)
  • siiprop: Which properties to get for each revision: (Default: timestamp|url)
    • timestamp: The time and date of the revision.
    • canonicaltitle: The canonical title of the image file. 1.23+
    • url: URLs of the image and its description page.
    • size: The image's size in bytes, plus width and height. A page count is also returned if the image is in a format that supports multiple pages.
    • dimensions: (Alias for size)
    • sha1: The image's SHA-1 hash.
    • mime: The image's MIME type.
    • thumbmime: The image thumbnail's MIME type (for use with the iiurl parameters).
    • metadata: Exif metadata for the image, if available. See File metadata handling for information on file metadata handling in MediaWiki.
    • commonmetadata: Generic metadata for the file format, if available. 1.23+
    • extmetadata: HTML metadata from extensions which implement the GetExtendedMetadata hook. Also contains most of metadata, but in a somewhat standardized format. 1.23+
    • bitdepth: The bit depth of the image.
  • siiurlwidth: If iiprop=url is set, a URL to an image scaled to this width will be returned as well in thumburl along with thumbwidth and thumbheight. Old versions of images can't be scaled.
  • siiurlheight: Similar to iiurlwidth.
  • siiurlparam: The thumb parameter string. Allows optional specification of other parameters than width and height (like page number for PDFs). Format of the field varies with image format. PDF uses a format like page<number>-<width>px (e.g., page3-140px). Generally the part before the filename in the url of a thumbnail. 1.18+

prop=stashimageinfo (sii)

(main | query | stashimageinfo)

Returns file information for stashed files.


Key that identifies a previous upload that was stashed temporarily.

Separate values with | or alternative. Maximum number of values is 50 (500 for bots).

Alias for siifilekey, for backward compatibility.

Separate values with | or alternative. Maximum number of values is 50 (500 for bots).

Which file information to get:

Adds timestamp for the uploaded version.
Adds the canonical title of the file.
Gives URL to the file and the description page.
Adds the size of the file in bytes and the height, width and page count (if applicable).
Alias for size.
Adds SHA-1 hash for the file.
Adds MIME type of the file.
Adds MIME type of the image thumbnail (requires url and param siiurlwidth).
Lists Exif metadata for the version of the file.
Lists file format generic metadata for the version of the file.
Lists formatted metadata combined from multiple sources. Results are HTML formatted.
Adds the bit depth of the version.
Adds whether the file is on the MediaWiki:Bad image list
Values (separate with | or alternative): timestamp, canonicaltitle, url, size, dimensions, sha1, mime, thumbmime, metadata, commonmetadata, extmetadata, bitdepth, badfile
Default: timestamp|url

If siiprop=url is set, a URL to an image scaled to this width will be returned.

For performance reasons if this option is used, no more than 50 scaled images will be returned.

Type: integer
Default: -1

Similar to siiurlwidth.

Type: integer
Default: -1

A handler specific parameter string. For example, PDFs might use page15-100px. siiurlwidth must be used and be consistent with siiurlparam.

Default: (empty)