camera.getMetadata

Returns file metadata given its URI. The image header lists the Exif and XMP fields. This command was deprecated in API level 2.

Parameters

  • fileUri: URI of the target file. Manufacturers decide whether to use absolute or relative URIs. Clients may treat this as an opaque identifier.

Results

  • metadata: Exif (including GPS information), Photo Sphere XMP in JSON format. Does not include image or thumbnail.

Errors

  • missingParameter: fileUri is not specified.
  • invalidParameterName: The input parameter name is unrecognized.
  • invalidParameterValue: The input parameter is recognized, but its value is invalid; for example, the fileUri doesn't exist, or its data type is incorrect.

Command I/O

Command Input
{
    "parameters": {
        "fileUri": "file URI"
    }
}
Command Output
{
    "results": {
        "exif": {
            ...
            "ImageWidth": 2000,
            "ImageLength": 1000,
            ...
        },
        "xmp": {
            "ProjectionType": "equirectangular",
        "UsePanoramaViewer": true,
            ...
        }
    }
}
Command Output (Error)
{
    "error": {
        "code": "invalidParameterValue",
        "message": "Parameter fileUri doesn't exist."
    }
}