{
    "openapi": "3.0.0",
    "info": {
        "title": "图片元数据 - API文档",
        "version": "1.0.0",
        "description": "此接口可读取图片exif元数据信息，包含快门、器材名称、型号、光圈、感光度、焦距、GPS等等几十项数据。"
    },
    "servers": [
        {
            "url": "https:\/\/apis.tianapi.com"
        }
    ],
    "paths": {
        "\/imgexif\/index": {
            "get": {
                "summary": "图片元数据",
                "tags": [
                    "图片元数据"
                ],
                "description": "查询图片全部原始的exit信息",
                "parameters": [
                    {
                        "name": "key",
                        "in": "query",
                        "description": "API密钥",
                        "required": true,
                        "schema": {
                            "type": "string",
                            "description": "API密钥"
                        }
                    },
                    {
                        "name": "mode",
                        "in": "query",
                        "description": "模式，1原始数值、2转换结果",
                        "required": false,
                        "schema": {
                            "type": "int",
                            "example": 2,
                            "description": "模式，1原始数值、2转换结果"
                        }
                    },
                    {
                        "name": "imgurl",
                        "in": "query",
                        "description": "图片URL",
                        "required": true,
                        "schema": {
                            "type": "string",
                            "example": "https:\/\/www.tianapi.com\/static\/img\/ocr\/exif.jpg",
                            "description": "图片URL"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "成功响应",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "Make": {
                                            "type": "string",
                                            "example": "HUAWEI",
                                            "description": "制造商"
                                        },
                                        "Flash": {
                                            "type": "string",
                                            "example": "闪光灯未闪光",
                                            "description": "闪光灯"
                                        },
                                        "Model": {
                                            "type": "string",
                                            "example": "TAS-AL00",
                                            "description": "型号"
                                        },
                                        "Author": {
                                            "type": "string",
                                            "example": "0",
                                            "description": "作者"
                                        },
                                        "IsColor": {
                                            "type": "string",
                                            "example": "是",
                                            "description": "是否彩色"
                                        },
                                        "Contrast": {
                                            "type": "string",
                                            "example": "普通",
                                            "description": "对比度"
                                        },
                                        "DateTime": {
                                            "type": "string",
                                            "example": "2023:04:12 02:18:54",
                                            "description": "最后修改时间"
                                        },
                                        "FileSize": {
                                            "type": "string",
                                            "example": "1770kb",
                                            "description": "文件大小"
                                        },
                                        "Sharpness": {
                                            "type": "string",
                                            "example": "普通",
                                            "description": "清晰度"
                                        },
                                        "Saturation": {
                                            "type": "string",
                                            "example": "普通",
                                            "description": "饱和度"
                                        },
                                        "GPSLatitude": {
                                            "type": "string",
                                            "example": "31\/1,19\/1,15590057\/1000000",
                                            "description": "纬度"
                                        },
                                        "LightSource": {
                                            "type": "string",
                                            "example": "日光灯",
                                            "description": "光源"
                                        },
                                        "ExposureMode": {
                                            "type": "string",
                                            "example": "自动",
                                            "description": "曝光模式"
                                        },
                                        "ExposureTime": {
                                            "type": "string",
                                            "example": "25000000\/1000000000秒",
                                            "description": "曝光时间"
                                        },
                                        "FileDateTime": {
                                            "type": "string",
                                            "example": "0",
                                            "description": "文件修改时间"
                                        },
                                        "GPSLongitude": {
                                            "type": "string",
                                            "example": "121\/1,15\/1,39825439\/1000000",
                                            "description": "经度"
                                        },
                                        "WhiteBalance": {
                                            "type": "string",
                                            "example": "自动",
                                            "description": "白平衡"
                                        },
                                        "GPSLatitudeRef": {
                                            "type": "string",
                                            "example": "N",
                                            "description": "南北纬"
                                        },
                                        "ApertureFNumber": {
                                            "type": "string",
                                            "example": "f\/1.8",
                                            "description": "光圈数"
                                        },
                                        "DateTimeOriginal": {
                                            "type": "string",
                                            "example": "2023:04:12 02:18:54",
                                            "description": "拍摄时间"
                                        },
                                        "DateTimeDigitized": {
                                            "type": "string",
                                            "example": "2023:04:12 02:18:54",
                                            "description": "数字化时间"
                                        }
                                    }
                                },
                                "example": {
                                    "msg": "success",
                                    "code": 200,
                                    "result": {
                                        "Exif": "IMAGETYPE_JPEG",
                                        "Make": "HUAWEI",
                                        "Flash": "闪光灯未闪光",
                                        "Model": "TAS-AL00",
                                        "FNumber": "180\/100",
                                        "IsColor": "是",
                                        "Contrast": "普通",
                                        "DateTime": "2023:04:12 02:18:54",
                                        "FileSize": "1770kb",
                                        "MimeType": "image\/jpeg",
                                        "Software": "TAS-AL00 3.0.0.202(C00E191R5P8)",
                                        "SceneType": "其他",
                                        "Sharpness": "普通",
                                        "ColorSpace": "sRGB",
                                        "FileSource": "其他",
                                        "Saturation": "普通",
                                        "SubSecTime": "219374",
                                        "Compression": "jpeg压缩",
                                        "ExifVersion": "0210",
                                        "FocalLength": "5580\/1000毫米",
                                        "GPSAltitude": "0\/100",
                                        "GPSLatitude": "31\/1,19\/1,15590057\/1000000",
                                        "LightSource": "日光灯",
                                        "XResolution": "72\/1",
                                        "YResolution": "72\/1",
                                        "ExposureMode": "自动",
                                        "ExposureTime": "25000000\/1000000000秒",
                                        "FileDateTime": "无",
                                        "GPSDateStamp": "2023:04:11",
                                        "GPSLongitude": "121\/1,15\/1,39825439\/1000000",
                                        "GPSTimeStamp": "18\/1,18\/1,54\/1",
                                        "MeteringMode": "评估",
                                        "WhiteBalance": "自动",
                                        "SectionsFound": "ANY_TAG,IFD0,THUMBNAIL,EXIF,GPS,INTEROP",
                                        "SensingMethod": "单色区传感器",
                                        "CustomRendered": "手动",
                                        "ExifImageWidth": 2736,
                                        "GPSAltitudeRef": "",
                                        "GPSLatitudeRef": "N",
                                        "ResolutionUnit": "英寸",
                                        "ApertureFNumber": "f\/1.8",
                                        "ExifImageLength": 3648,
                                        "ExposureProgram": "程序控制",
                                        "FlashPixVersion": "0100",
                                        "GPSLongitudeRef": "E",
                                        "ISOSpeedRatings": 400,
                                        "DateTimeOriginal": "2023:04:12 02:18:54",
                                        "DigitalZoomRatio": "100\/100",
                                        "Exif_IFD_Pointer": 286,
                                        "MaxApertureValue": "169\/100",
                                        "YCbCrPositioning": "像素阵列的中心",
                                        "ByteOrderMotorola": "是",
                                        "DateTimeDigitized": "2023:04:12 02:18:54",
                                        "ExposureBiasValue": "0\/10电子伏特",
                                        "SubSecTimeOriginal": "219374",
                                        "SubSecTimeDigitized": "219374",
                                        "SubjectDistanceRange": "未知",
                                        "FocalLengthIn35mmFilm": "27毫米",
                                        "InterOperabilityIndex": "R98",
                                        "JPEGInterchangeFormat": 1612,
                                        "SceneCaptureTypeVVVVV": "自动",
                                        "CompressedBitsPerPixel": "95\/100",
                                        "InteroperabilityOffset": 1226,
                                        "ComponentsConfiguration": "",
                                        "InterOperabilityVersion": "0100",
                                        "JPEGInterchangeFormatLength": 18135
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "post": {
                "summary": "图片元数据",
                "tags": [
                    "图片元数据"
                ],
                "description": "查询图片全部原始的exit信息",
                "requestBody": {
                    "content": {
                        "application\/x-www-form-urlencoded": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "key": {
                                        "type": "string",
                                        "description": "API密钥"
                                    },
                                    "mode": {
                                        "type": "int",
                                        "example": 2,
                                        "description": "模式，1原始数值、2转换结果"
                                    },
                                    "imgurl": {
                                        "type": "string",
                                        "example": "https:\/\/www.tianapi.com\/static\/img\/ocr\/exif.jpg",
                                        "description": "图片URL"
                                    }
                                },
                                "required": [
                                    "key",
                                    "imgurl"
                                ]
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "成功响应",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "Make": {
                                            "type": "string",
                                            "example": "HUAWEI",
                                            "description": "制造商"
                                        },
                                        "Flash": {
                                            "type": "string",
                                            "example": "闪光灯未闪光",
                                            "description": "闪光灯"
                                        },
                                        "Model": {
                                            "type": "string",
                                            "example": "TAS-AL00",
                                            "description": "型号"
                                        },
                                        "Author": {
                                            "type": "string",
                                            "example": "0",
                                            "description": "作者"
                                        },
                                        "IsColor": {
                                            "type": "string",
                                            "example": "是",
                                            "description": "是否彩色"
                                        },
                                        "Contrast": {
                                            "type": "string",
                                            "example": "普通",
                                            "description": "对比度"
                                        },
                                        "DateTime": {
                                            "type": "string",
                                            "example": "2023:04:12 02:18:54",
                                            "description": "最后修改时间"
                                        },
                                        "FileSize": {
                                            "type": "string",
                                            "example": "1770kb",
                                            "description": "文件大小"
                                        },
                                        "Sharpness": {
                                            "type": "string",
                                            "example": "普通",
                                            "description": "清晰度"
                                        },
                                        "Saturation": {
                                            "type": "string",
                                            "example": "普通",
                                            "description": "饱和度"
                                        },
                                        "GPSLatitude": {
                                            "type": "string",
                                            "example": "31\/1,19\/1,15590057\/1000000",
                                            "description": "纬度"
                                        },
                                        "LightSource": {
                                            "type": "string",
                                            "example": "日光灯",
                                            "description": "光源"
                                        },
                                        "ExposureMode": {
                                            "type": "string",
                                            "example": "自动",
                                            "description": "曝光模式"
                                        },
                                        "ExposureTime": {
                                            "type": "string",
                                            "example": "25000000\/1000000000秒",
                                            "description": "曝光时间"
                                        },
                                        "FileDateTime": {
                                            "type": "string",
                                            "example": "0",
                                            "description": "文件修改时间"
                                        },
                                        "GPSLongitude": {
                                            "type": "string",
                                            "example": "121\/1,15\/1,39825439\/1000000",
                                            "description": "经度"
                                        },
                                        "WhiteBalance": {
                                            "type": "string",
                                            "example": "自动",
                                            "description": "白平衡"
                                        },
                                        "GPSLatitudeRef": {
                                            "type": "string",
                                            "example": "N",
                                            "description": "南北纬"
                                        },
                                        "ApertureFNumber": {
                                            "type": "string",
                                            "example": "f\/1.8",
                                            "description": "光圈数"
                                        },
                                        "DateTimeOriginal": {
                                            "type": "string",
                                            "example": "2023:04:12 02:18:54",
                                            "description": "拍摄时间"
                                        },
                                        "DateTimeDigitized": {
                                            "type": "string",
                                            "example": "2023:04:12 02:18:54",
                                            "description": "数字化时间"
                                        }
                                    }
                                },
                                "example": {
                                    "msg": "success",
                                    "code": 200,
                                    "result": {
                                        "Exif": "IMAGETYPE_JPEG",
                                        "Make": "HUAWEI",
                                        "Flash": "闪光灯未闪光",
                                        "Model": "TAS-AL00",
                                        "FNumber": "180\/100",
                                        "IsColor": "是",
                                        "Contrast": "普通",
                                        "DateTime": "2023:04:12 02:18:54",
                                        "FileSize": "1770kb",
                                        "MimeType": "image\/jpeg",
                                        "Software": "TAS-AL00 3.0.0.202(C00E191R5P8)",
                                        "SceneType": "其他",
                                        "Sharpness": "普通",
                                        "ColorSpace": "sRGB",
                                        "FileSource": "其他",
                                        "Saturation": "普通",
                                        "SubSecTime": "219374",
                                        "Compression": "jpeg压缩",
                                        "ExifVersion": "0210",
                                        "FocalLength": "5580\/1000毫米",
                                        "GPSAltitude": "0\/100",
                                        "GPSLatitude": "31\/1,19\/1,15590057\/1000000",
                                        "LightSource": "日光灯",
                                        "XResolution": "72\/1",
                                        "YResolution": "72\/1",
                                        "ExposureMode": "自动",
                                        "ExposureTime": "25000000\/1000000000秒",
                                        "FileDateTime": "无",
                                        "GPSDateStamp": "2023:04:11",
                                        "GPSLongitude": "121\/1,15\/1,39825439\/1000000",
                                        "GPSTimeStamp": "18\/1,18\/1,54\/1",
                                        "MeteringMode": "评估",
                                        "WhiteBalance": "自动",
                                        "SectionsFound": "ANY_TAG,IFD0,THUMBNAIL,EXIF,GPS,INTEROP",
                                        "SensingMethod": "单色区传感器",
                                        "CustomRendered": "手动",
                                        "ExifImageWidth": 2736,
                                        "GPSAltitudeRef": "",
                                        "GPSLatitudeRef": "N",
                                        "ResolutionUnit": "英寸",
                                        "ApertureFNumber": "f\/1.8",
                                        "ExifImageLength": 3648,
                                        "ExposureProgram": "程序控制",
                                        "FlashPixVersion": "0100",
                                        "GPSLongitudeRef": "E",
                                        "ISOSpeedRatings": 400,
                                        "DateTimeOriginal": "2023:04:12 02:18:54",
                                        "DigitalZoomRatio": "100\/100",
                                        "Exif_IFD_Pointer": 286,
                                        "MaxApertureValue": "169\/100",
                                        "YCbCrPositioning": "像素阵列的中心",
                                        "ByteOrderMotorola": "是",
                                        "DateTimeDigitized": "2023:04:12 02:18:54",
                                        "ExposureBiasValue": "0\/10电子伏特",
                                        "SubSecTimeOriginal": "219374",
                                        "SubSecTimeDigitized": "219374",
                                        "SubjectDistanceRange": "未知",
                                        "FocalLengthIn35mmFilm": "27毫米",
                                        "InterOperabilityIndex": "R98",
                                        "JPEGInterchangeFormat": 1612,
                                        "SceneCaptureTypeVVVVV": "自动",
                                        "CompressedBitsPerPixel": "95\/100",
                                        "InteroperabilityOffset": 1226,
                                        "ComponentsConfiguration": "",
                                        "InterOperabilityVersion": "0100",
                                        "JPEGInterchangeFormatLength": 18135
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}