openapi-directory
Version:
Building & bundling https://github.com/APIs-guru/openapi-directory for easy use from JS
1 lines • 44.3 kB
JSON
{"openapi":"3.0.0","info":{"description":"The Computer Vision API provides state-of-the-art algorithms to process images and return information. For example, it can be used to determine if an image contains mature content, or it can be used to find all the faces in an image. It also has other features like estimating dominant and accent colors, categorizing the content of images, and describing an image with complete English sentences. Additionally, it can also intelligently generate images thumbnails for displaying large images effectively.","title":"Computer Vision","version":"1.0","x-apisguru-categories":["cloud"],"x-logo":{"url":"https://assets.onestore.ms/cdnfiles/onestorerolling-1606-01000/shell/v3/images/logo/microsoft.png"},"x-origin":[{"format":"swagger","url":"https://raw.githubusercontent.com/Azure/azure-rest-api-specs/master/specification/cognitiveservices/data-plane/ComputerVision/stable/v1.0/ComputerVision.json","version":"2.0"}],"x-providerName":"azure.com","x-serviceName":"cognitiveservices-ComputerVision","x-tags":["Azure","Microsoft"]},"security":[{"apim_key":[]}],"paths":{"/analyze":{"post":{"description":"This operation extracts a rich set of visual features based on the image content. Two input methods are supported -- (1) Uploading an image or (2) specifying an image URL. Within your request, there is an optional parameter to allow you to choose which features to return. By default, image categories are returned in the response.","operationId":"AnalyzeImage","parameters":[{"$ref":"#/components/parameters/VisualFeatures"},{"description":"A string indicating which domain-specific details to return. Multiple values should be comma-separated. Valid visual feature types include:Celebrities - identifies celebrities if detected in the image.","in":"query","name":"details","required":false,"style":"form","explode":false,"schema":{"type":"array","items":{"enum":["Celebrities","Landmarks"],"type":"string","x-ms-enum":{"modelAsString":false,"name":"Details"},"nullable":false}},"examples":{"Successful Analyze with Url request":{"value":"Celebrities"}}},{"$ref":"#/components/parameters/ServiceLanguage"}],"requestBody":{"$ref":"#/components/requestBodies/AnalyzeImageImageurl"},"responses":{"200":{"description":"The response include the extracted features in JSON format.Here is the definitions for enumeration typesClipartTypeNon-clipart = 0, ambiguous = 1, normal-clipart = 2, good-clipart = 3.LineDrawingTypeNon-LineDrawing = 0,LineDrawing = 1.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImageAnalysis"},"examples":{"Successful Analyze with Url request":{"$ref":"#/components/examples/Successful_Analyze_with_Url_request"}}}}},"default":{"description":"Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}},"/describe":{"post":{"description":"This operation generates a description of an image in human readable language with complete sentences. The description is based on a collection of content tags, which are also returned by the operation. More than one description can be generated for each image. Descriptions are ordered by their confidence score. All descriptions are in English. Two input methods are supported -- (1) Uploading an image or (2) specifying an image URL.A successful response will be returned in JSON. If the request failed, the response will contain an error code and a message to help understand what went wrong.","operationId":"DescribeImage","parameters":[{"description":"Maximum number of candidate descriptions to be returned. The default is 1.","in":"query","name":"maxCandidates","required":false,"schema":{"type":"string","default":"1"},"examples":{"Successful Describe request":{"value":"1"}}},{"$ref":"#/components/parameters/ServiceLanguage"}],"requestBody":{"$ref":"#/components/requestBodies/AnalyzeImageImageurl"},"responses":{"200":{"description":"Image description object.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImageDescription"},"examples":{"Successful Describe request":{"$ref":"#/components/examples/Successful_Describe_request"}}}}},"default":{"description":"Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}},"/generateThumbnail":{"post":{"description":"This operation generates a thumbnail image with the user-specified width and height. By default, the service analyzes the image, identifies the region of interest (ROI), and generates smart cropping coordinates based on the ROI. Smart cropping helps when you specify an aspect ratio that differs from that of the input image. A successful response contains the thumbnail image binary. If the request failed, the response contains an error code and a message to help determine what went wrong.","operationId":"GenerateThumbnail","parameters":[{"description":"Width of the thumbnail. It must be between 1 and 1024. Recommended minimum of 50.","in":"query","name":"width","required":true,"schema":{"type":"integer","minimum":1,"maximum":1023},"examples":{"Successful Generate Thumbnail request":{"value":"500"}}},{"description":"Height of the thumbnail. It must be between 1 and 1024. Recommended minimum of 50.","in":"query","name":"height","required":true,"schema":{"type":"integer","minimum":1,"maximum":1023},"examples":{"Successful Generate Thumbnail request":{"value":"500"}}},{"description":"Boolean flag for enabling smart cropping.","in":"query","name":"smartCropping","required":false,"schema":{"type":"boolean","default":false},"examples":{"Successful Generate Thumbnail request":{"value":true}}}],"requestBody":{"$ref":"#/components/requestBodies/AnalyzeImageImageurl"},"responses":{"200":{"description":"The generated thumbnail in binary format.","content":{"application/octet-stream":{"schema":{"type":"string","format":"binary"},"examples":{"Successful Generate Thumbnail request":{"$ref":"#/components/examples/Successful_Generate_Thumbnail_request"}}}}},"default":{"description":"Error response.","content":{"application/octet-stream":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}},"/models":{"get":{"description":"This operation returns the list of domain-specific models that are supported by the Computer Vision API. Currently, the API only supports one domain-specific model: a celebrity recognizer. A successful response will be returned in JSON. If the request failed, the response will contain an error code and a message to help understand what went wrong.","operationId":"ListModels","responses":{"200":{"description":"List of available domain models.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListModelsResult"},"examples":{"Successful List Domains request":{"$ref":"#/components/examples/Successful_List_Domains_request"}}}}},"default":{"description":"Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}},"/models/{model}/analyze":{"post":{"description":"This operation recognizes content within an image by applying a domain-specific model. The list of domain-specific models that are supported by the Computer Vision API can be retrieved using the /models GET request. Currently, the API only provides a single domain-specific model: celebrities. Two input methods are supported -- (1) Uploading an image or (2) specifying an image URL. A successful response will be returned in JSON. If the request failed, the response will contain an error code and a message to help understand what went wrong.","operationId":"AnalyzeImageByDomain","parameters":[{"description":"The domain-specific content to recognize.","in":"path","name":"model","required":true,"schema":{"type":"string"}},{"$ref":"#/components/parameters/ServiceLanguage"}],"requestBody":{"$ref":"#/components/requestBodies/AnalyzeImageImageurl"},"responses":{"200":{"description":"Analysis result based on the domain model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DomainModelResults"},"examples":{"Successful Domain Model analysis request":{"$ref":"#/components/examples/Successful_Domain_Model_analysis_request"}}}}},"default":{"description":"Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}},"/ocr":{"post":{"description":"Optical Character Recognition (OCR) detects printed text in an image and extracts the recognized characters into a machine-usable character stream. Upon success, the OCR results will be returned. Upon failure, the error code together with an error message will be returned. The error code can be one of InvalidImageUrl, InvalidImageFormat, InvalidImageSize, NotSupportedImage, NotSupportedLanguage, or InternalServerError.","operationId":"RecognizePrintedText","parameters":[{"$ref":"#/components/parameters/DetectOrientation"},{"$ref":"#/components/parameters/OcrLanguage"}],"requestBody":{"$ref":"#/components/requestBodies/AnalyzeImageImageurl"},"responses":{"200":{"description":"The OCR results in the hierarchy of region/line/word. The results include text, bounding box for regions, lines and words.textAngleThe angle, in degrees, of the detected text with respect to the closest horizontal or vertical direction. After rotating the input image clockwise by this angle, the recognized text lines become horizontal or vertical. In combination with the orientation property it can be used to overlay recognition results correctly on the original image, by rotating either the original image or recognition results by a suitable angle around the center of the original image. If the angle cannot be confidently detected, this property is not present. If the image contains text at different angles, only part of the text will be recognized correctly.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OcrResult"},"examples":{"Successful Ocr request":{"$ref":"#/components/examples/Successful_Ocr_request"}}}}},"default":{"description":"Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}},"/recognizeText":{"post":{"description":"Recognize Text operation. When you use the Recognize Text interface, the response contains a field called 'Operation-Location'. The 'Operation-Location' field contains the URL that you must use for your Get Handwritten Text Operation Result operation.","operationId":"RecognizeText","parameters":[{"$ref":"#/components/parameters/HandwritingBoolean"}],"requestBody":{"$ref":"#/components/requestBodies/AnalyzeImageImageurl"},"responses":{"202":{"description":"The service has accepted the request and will start processing later. It will return Accepted immediately and include an Operation-Location header. Client side should further query the operation status using the URL specified in this header. The operation ID will expire in 48 hours.","headers":{"Operation-Location":{"description":"URL to query for status of the operation. The operation ID will expire in 48 hours. ","schema":{"type":"string"}}}},"default":{"description":"Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}},"/tag":{"post":{"description":"This operation generates a list of words, or tags, that are relevant to the content of the supplied image. The Computer Vision API can return tags based on objects, living beings, scenery or actions found in images. Unlike categories, tags are not organized according to a hierarchical classification system, but correspond to image content. Tags may contain hints to avoid ambiguity or provide context, for example the tag 'cello' may be accompanied by the hint 'musical instrument'. All tags are in English.","operationId":"TagImage","parameters":[{"$ref":"#/components/parameters/ServiceLanguage"}],"requestBody":{"$ref":"#/components/requestBodies/AnalyzeImageImageurl"},"responses":{"200":{"description":"Image tags object.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TagResult"},"examples":{"Successful Tag request":{"$ref":"#/components/examples/Successful_Tag_request"}}}}},"default":{"description":"Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}},"/textOperations/{operationId}":{"get":{"description":"This interface is used for getting text operation result. The URL to this interface should be retrieved from 'Operation-Location' field returned from Recognize Text interface.","operationId":"GetTextOperationResult","parameters":[{"description":"Id of the text operation returned in the response of the 'Recognize Handwritten Text'","in":"path","name":"operationId","required":true,"schema":{"type":"string"},"examples":{"Successful Domain Model analysis request":{"value":"49a36324-fc4b-4387-aa06-090cfbf0064f"}}}],"responses":{"200":{"description":"Returns the operation status.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TextOperationResult"},"examples":{"Successful Domain Model analysis request":{"$ref":"#/components/examples/Successful_Domain_Model_analysis_request"}}}}},"default":{"description":"Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}},"/analyze#overload=stream":{"post":{"description":"This operation extracts a rich set of visual features based on the image content.","operationId":"AnalyzeImageInStream","parameters":[{"$ref":"#/components/parameters/VisualFeatures"},{"description":"A string indicating which domain-specific details to return. Multiple values should be comma-separated. Valid visual feature types include:Celebrities - identifies celebrities if detected in the image.","in":"query","name":"details","required":false,"schema":{"type":"string","enum":["Celebrities","Landmarks"]},"examples":{"Successful Analyze with Url request":{"value":"Celebrities"}}},{"$ref":"#/components/parameters/ServiceLanguage"}],"requestBody":{"$ref":"#/components/requestBodies/AnalyzeImageInStreamImage"},"responses":{"200":{"description":"The response include the extracted features in JSON format. Here is the definitions for enumeration types clipart = 0, ambiguous = 1, normal-clipart = 2, good-clipart = 3. Non-LineDrawing = 0,LineDrawing = 1.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImageAnalysis"},"examples":{"Successful Analyze with Url request":{"$ref":"#/components/examples/Successful_Analyze_with_Url_request"}}}}},"default":{"description":"Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}},"/describe#overload=stream":{"post":{"description":"This operation generates a description of an image in human readable language with complete sentences. The description is based on a collection of content tags, which are also returned by the operation. More than one description can be generated for each image. Descriptions are ordered by their confidence score. All descriptions are in English. Two input methods are supported -- (1) Uploading an image or (2) specifying an image URL.A successful response will be returned in JSON. If the request failed, the response will contain an error code and a message to help understand what went wrong.","operationId":"DescribeImageInStream","parameters":[{"description":"Maximum number of candidate descriptions to be returned. The default is 1.","in":"query","name":"maxCandidates","required":false,"schema":{"type":"string","default":"1"},"examples":{"Successful Describe request":{"value":"1"}}},{"$ref":"#/components/parameters/ServiceLanguage"}],"requestBody":{"$ref":"#/components/requestBodies/AnalyzeImageInStreamImage"},"responses":{"200":{"description":"Image description object.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImageDescription"},"examples":{"Successful Describe request":{"$ref":"#/components/examples/Successful_Describe_request"}}}}},"default":{"description":"Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}},"/generateThumbnail#overload=stream":{"post":{"description":"This operation generates a thumbnail image with the user-specified width and height. By default, the service analyzes the image, identifies the region of interest (ROI), and generates smart cropping coordinates based on the ROI. Smart cropping helps when you specify an aspect ratio that differs from that of the input image. A successful response contains the thumbnail image binary. If the request failed, the response contains an error code and a message to help determine what went wrong.","operationId":"GenerateThumbnailInStream","parameters":[{"description":"Width of the thumbnail. It must be between 1 and 1024. Recommended minimum of 50.","in":"query","name":"width","required":true,"schema":{"type":"integer","minimum":1,"maximum":1023},"examples":{"Successful Generate Thumbnail request":{"value":"500"}}},{"description":"Height of the thumbnail. It must be between 1 and 1024. Recommended minimum of 50.","in":"query","name":"height","required":true,"schema":{"type":"integer","minimum":1,"maximum":1023},"examples":{"Successful Generate Thumbnail request":{"value":"500"}}},{"description":"Boolean flag for enabling smart cropping.","in":"query","name":"smartCropping","required":false,"schema":{"type":"boolean","default":false},"examples":{"Successful Generate Thumbnail request":{"value":true}}}],"requestBody":{"$ref":"#/components/requestBodies/AnalyzeImageInStreamImage"},"responses":{"200":{"description":"The generated thumbnail in binary format.","content":{"application/octet-stream":{"schema":{"type":"string","format":"binary"},"examples":{"Successful Generate Thumbnail request":{"$ref":"#/components/examples/Successful_Generate_Thumbnail_request"}}}}},"default":{"description":"Error response.","content":{"application/octet-stream":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}},"/models/{model}/analyze#overload=stream":{"post":{"description":"This operation recognizes content within an image by applying a domain-specific model. The list of domain-specific models that are supported by the Computer Vision API can be retrieved using the /models GET request. Currently, the API only provides a single domain-specific model: celebrities. Two input methods are supported -- (1) Uploading an image or (2) specifying an image URL. A successful response will be returned in JSON. If the request failed, the response will contain an error code and a message to help understand what went wrong.","operationId":"AnalyzeImageByDomainInStream","parameters":[{"description":"The domain-specific content to recognize.","in":"path","name":"model","required":true,"schema":{"type":"string"}},{"$ref":"#/components/parameters/ServiceLanguage"}],"requestBody":{"$ref":"#/components/requestBodies/AnalyzeImageInStreamImage"},"responses":{"200":{"description":"Analysis result based on the domain model","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DomainModelResults"},"examples":{"Successful Domain Model analysis request":{"$ref":"#/components/examples/Successful_Domain_Model_analysis_request"}}}}},"default":{"description":"Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}},"/ocr#overload=stream":{"post":{"description":"Optical Character Recognition (OCR) detects printed text in an image and extracts the recognized characters into a machine-usable character stream. Upon success, the OCR results will be returned. Upon failure, the error code together with an error message will be returned. The error code can be one of InvalidImageUrl, InvalidImageFormat, InvalidImageSize, NotSupportedImage, NotSupportedLanguage, or InternalServerError.","operationId":"RecognizePrintedTextInStream","parameters":[{"$ref":"#/components/parameters/OcrLanguage"},{"$ref":"#/components/parameters/DetectOrientation"}],"requestBody":{"$ref":"#/components/requestBodies/AnalyzeImageInStreamImage"},"responses":{"200":{"description":"The OCR results in the hierarchy of region/line/word. The results include text, bounding box for regions, lines and words. The angle, in degrees, of the detected text with respect to the closest horizontal or vertical direction. After rotating the input image clockwise by this angle, the recognized text lines become horizontal or vertical. In combination with the orientation property it can be used to overlay recognition results correctly on the original image, by rotating either the original image or recognition results by a suitable angle around the center of the original image. If the angle cannot be confidently detected, this property is not present. If the image contains text at different angles, only part of the text will be recognized correctly.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OcrResult"},"examples":{"Successful Ocr request":{"$ref":"#/components/examples/Successful_Ocr_request"}}}}},"default":{"description":"Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}},"/recognizeText#overload=stream":{"post":{"description":"Recognize Text operation. When you use the Recognize Text interface, the response contains a field called 'Operation-Location'. The 'Operation-Location' field contains the URL that you must use for your Get Handwritten Text Operation Result operation.","operationId":"RecognizeTextInStream","parameters":[{"$ref":"#/components/parameters/HandwritingBoolean"}],"requestBody":{"content":{"application/octet-stream":{"schema":{"format":"file","type":"object"}}},"description":"An image stream.","required":true,"x-ms-parameter-location":"method"},"responses":{"202":{"description":"The service has accepted the request and will start processing later.","headers":{"Operation-Location":{"description":"URL to query for status of the operation. The operation ID will expire in 48 hours. ","schema":{"type":"string"}}}},"default":{"description":"Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}},"/tag#overload=stream":{"post":{"description":"This operation generates a list of words, or tags, that are relevant to the content of the supplied image. The Computer Vision API can return tags based on objects, living beings, scenery or actions found in images. Unlike categories, tags are not organized according to a hierarchical classification system, but correspond to image content. Tags may contain hints to avoid ambiguity or provide context, for example the tag 'cello' may be accompanied by the hint 'musical instrument'. All tags are in English.","operationId":"TagImageInStream","parameters":[{"$ref":"#/components/parameters/ServiceLanguage"}],"requestBody":{"$ref":"#/components/requestBodies/AnalyzeImageInStreamImage"},"responses":{"200":{"description":"Image tags object.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TagResult"},"examples":{"Successful Tag request":{"$ref":"#/components/examples/Successful_Tag_request"}}}}},"default":{"description":"Error response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ComputerVisionError"}}}}}}}},"servers":[{"url":"https://azure.local/vision/v1.0"},{"url":"https://{AzureRegion}.api.cognitive.microsoft.com/vision/v1.0","variables":{"AzureRegion":{"description":"Supported Azure regions for Cognitive Services endpoints","enum":["westus","westeurope","southeastasia","eastus2","westcentralus","westus2","eastus","southcentralus","northeurope","eastasia","australiaeast","brazilsouth","canadacentral","centralindia","uksouth","japaneast"],"x-ms-enum":{"modelAsString":false,"name":"AzureRegions"},"x-ms-parameter-location":"client","x-ms-skip-url-encoding":true,"default":"westus"}}}],"components":{"examples":{"Successful_Analyze_with_Url_request":{"value":{"adult":{"adultScore":0.0934349000453949,"isAdultContent":false,"isRacyContent":false,"racyScore":0.06861349195241928},"categories":[{"name":"abstract_","score":0.00390625},{"detail":{"celebrities":[{"confidence":0.999028444,"faceRectangle":{"height":248,"left":597,"top":162,"width":248},"name":"Satya Nadella"}],"landmarks":[{"confidence":0.9978346,"name":"Forbidden City"}]},"name":"people_","score":0.83984375}],"color":{"accentColor":"873B59","dominantColorBackground":"Brown","dominantColorForeground":"Brown","dominantColors":["Brown","Black"],"isBWImg":false},"description":{"captions":[{"confidence":0.48293603002174407,"text":"Satya Nadella sitting on a bench"}],"tags":["person","man","outdoor","window","glasses"]},"faces":[{"age":44,"faceRectangle":{"height":250,"left":593,"top":160,"width":250},"gender":"Male"}],"imageType":{"clipArtType":0,"lineDrawingType":0},"metadata":{"format":"Jpeg","height":1000,"width":1500},"requestId":"0dbec5ad-a3d3-4f7e-96b4-dfd57efe967d","tags":[{"confidence":0.9897908568382263,"name":"person"},{"confidence":0.9449388980865479,"name":"man"},{"confidence":0.938492476940155,"name":"outdoor"},{"confidence":0.8951393961906433,"name":"window"}]}},"Successful_Describe_request":{"value":{"description":{"captions":[{"confidence":0.48293603002174407,"text":"Satya Nadella sitting on a bench"},{"confidence":0.4003700681542283,"text":"Satya Nadella is sitting on a bench"},{"confidence":0.38035155997373377,"text":"Satya Nadella sitting in front of a building"}],"tags":["person","man","outdoor","window","glasses"]},"metadata":{"format":"Jpeg","height":1000,"width":1500},"requestId":"ed2de1c6-fb55-4686-b0da-4da6e05d283f"}},"Successful_Generate_Thumbnail_request":{"value":"{Binary}"},"Successful_List_Domains_request":{"value":{"models":[{"categories":["people_"],"name":"celebrities"},{"categories":["building_"],"name":"landmarks"}]}},"Successful_Domain_Model_analysis_request":{"value":{"metadata":{"format":"Jpeg","height":1000,"width":1500},"requestId":"f0027b4b-dc0d-4082-9228-1545ed246b03","result":{"celebrities":[{"confidence":0.999028444,"faceRectangle":{"height":248,"left":597,"top":162,"width":248},"name":"Satya Nadella"}]}}},"Successful_Ocr_request":{"value":{"language":"en","orientation":"Up","regions":[{"boundingBox":"462,379,497,258","lines":[{"boundingBox":"462,379,497,74","words":[{"boundingBox":"462,379,41,73","text":"A"},{"boundingBox":"523,379,153,73","text":"GOAL"},{"boundingBox":"694,379,265,74","text":"WITHOUT"}]},{"boundingBox":"565,471,289,74","words":[{"boundingBox":"565,471,41,73","text":"A"},{"boundingBox":"626,471,150,73","text":"PLAN"},{"boundingBox":"801,472,53,73","text":"IS"}]},{"boundingBox":"519,563,375,74","words":[{"boundingBox":"519,563,149,74","text":"JUST"},{"boundingBox":"683,564,41,72","text":"A"},{"boundingBox":"741,564,153,73","text":"WISH"}]}]}],"textAngle":-2.0000000000000338}},"Successful_Tag_request":{"value":{"metadata":{"format":"Jpeg","height":400,"width":400},"requestId":"1ad0e45e-b7b4-4be3-8042-53be96103337","tags":[{"confidence":0.9999997615814209,"name":"grass"},{"confidence":0.9999706745147705,"name":"outdoor"},{"confidence":0.9992897510528564,"name":"sky"},{"confidence":0.9964632391929626,"name":"building"},{"confidence":0.9927980303764343,"name":"house"},{"confidence":0.8226802945137024,"name":"lawn"},{"confidence":0.6412225365638733,"name":"green"},{"confidence":0.31403225660324097,"name":"residential"}]}}},"parameters":{"DetectOrientation":{"description":"Whether detect the text orientation in the image. With detectOrientation=true the OCR service tries to detect the image orientation and correct it before further processing (e.g. if it's upside-down). ","in":"query","name":"detectOrientation","required":true,"x-ms-parameter-location":"method","schema":{"type":"boolean","default":true},"examples":{"Successful Ocr request":{"value":"true"}}},"HandwritingBoolean":{"description":"If 'true' is specified, handwriting recognition is performed. If this parameter is set to 'false' or is not specified, printed text recognition is performed.","in":"query","name":"detectHandwriting","required":false,"x-ms-parameter-location":"method","schema":{"type":"boolean","default":false}},"OcrLanguage":{"description":"The BCP-47 language code of the text to be detected in the image. The default value is 'unk'","in":"query","name":"language","required":false,"x-ms-enum":{"modelAsString":false,"name":"OcrLanguages"},"x-ms-parameter-location":"method","x-nullable":false,"schema":{"type":"string","enum":["unk","zh-Hans","zh-Hant","cs","da","nl","en","fi","fr","de","el","hu","it","ja","ko","nb","pl","pt","ru","es","sv","tr","ar","ro","sr-Cyrl","sr-Latn","sk"],"default":"unk"},"examples":{"Successful Ocr request":{"value":"en"}}},"ServiceLanguage":{"description":"The desired language for output generation. If this parameter is not specified, the default value is "en".Supported languages:en - English, Default. es - Spanish, ja - Japanese, pt - Portuguese, zh - Simplified Chinese.","in":"query","name":"language","required":false,"x-ms-parameter-location":"method","x-nullable":false,"schema":{"type":"string","enum":["en","es","ja","pt","zh"],"default":"en"},"examples":{"Successful Analyze with Url request":{"value":"en"}}},"VisualFeatures":{"description":"A string indicating what visual feature types to return. Multiple values should be comma-separated. Valid visual feature types include:Categories - categorizes image content according to a taxonomy defined in documentation. Tags - tags the image with a detailed list of words related to the image content. Description - describes the image content with a complete English sentence. Faces - detects if faces are present. If present, generate coordinates, gender and age. ImageType - detects if image is clipart or a line drawing. Color - determines the accent color, dominant color, and whether an image is black&white.Adult - detects if the image is pornographic in nature (depicts nudity or a sex act). Sexually suggestive content is also detected.","in":"query","name":"visualFeatures","required":false,"x-ms-parameter-location":"method","style":"form","explode":false,"schema":{"type":"array","items":{"enum":["ImageType","Faces","Adult","Categories","Color","Tags","Description"],"type":"string","x-ms-enum":{"modelAsString":false,"name":"VisualFeatureTypes"},"nullable":false}},"examples":{"Successful Analyze with Url request":{"value":"Categories,Adult,Tags,Description,Faces,Color,ImageType"}}}},"requestBodies":{"AnalyzeImageInStreamImage":{"content":{"application/octet-stream":{"schema":{"format":"file","type":"object"}},"multipart/form-data":{"schema":{"format":"file","type":"object"}}},"description":"An image stream.","required":true,"x-ms-parameter-location":"method"},"AnalyzeImageImageurl":{"content":{"application/json":{"schema":{"properties":{"url":{"description":"Publicly reachable URL of an image","type":"string"}},"required":["url"],"type":"object"}}},"description":"A JSON document with a URL pointing to the image that is to be analyzed.","required":true,"x-ms-client-flatten":true,"x-ms-parameter-location":"method"}},"securitySchemes":{"apim_key":{"in":"header","name":"Ocp-Apim-Subscription-Key","type":"apiKey"}},"schemas":{"AdultInfo":{"description":"An object describing whether the image contains adult-oriented content and/or is racy.","properties":{"adultScore":{"description":"Score from 0 to 1 that indicates how much of adult content is within the image.","format":"double","type":"number","nullable":false},"isAdultContent":{"description":"A value indicating if the image contains adult-oriented content.","type":"boolean","nullable":false},"isRacyContent":{"description":"A value indicating if the image is race.","type":"boolean","nullable":false},"racyScore":{"description":"Score from 0 to 1 that indicates how suggestive is the image.","format":"double","type":"number","nullable":false}},"type":"object"},"BoundingBox":{"items":{"type":"integer","nullable":false},"type":"array"},"Category":{"description":"An object describing identified category.","properties":{"detail":{"$ref":"#/components/schemas/CategoryDetail"},"name":{"description":"Name of the category.","type":"string"},"score":{"description":"Scoring of the category.","format":"double","type":"number"}},"type":"object"},"CategoryDetail":{"description":"An object describing additional category details.","properties":{"celebrities":{"description":"An array of celebrities if any identified.","items":{"$ref":"#/components/schemas/CelebritiesModel"},"type":"array"}},"type":"object"},"CelebritiesModel":{"description":"An object describing possible celebrity identification.","properties":{"confidence":{"description":"Level of confidence ranging from 0 to 1.","format":"double","type":"number"},"faceRectangle":{"$ref":"#/components/schemas/FaceRectangle"},"name":{"description":"Name of the celebrity.","type":"string"}},"type":"object"},"CelebrityResults":{"description":"List of celebrities recognized in the image.","properties":{"celebrities":{"items":{"$ref":"#/components/schemas/CelebritiesModel"},"type":"array"},"metadata":{"$ref":"#/components/schemas/ImageMetadata"},"requestId":{"description":"Id of the REST API request.","type":"string"}},"type":"object"},"ColorInfo":{"description":"An object providing additional metadata describing color attributes.","properties":{"accentColor":{"description":"Possible accent color.","type":"string"},"dominantColorBackground":{"description":"Possible dominant background color.","type":"string"},"dominantColorForeground":{"description":"Possible dominant foreground color.","type":"string"},"dominantColors":{"description":"An array of possible dominant colors.","items":{"type":"string"},"type":"array"},"isBWImg":{"description":"A value indicating if the image is black and white.","type":"boolean"}},"type":"object"},"ComputerVisionError":{"properties":{"code":{"description":"The error code.","enum":["InvalidImageUrl","InvalidImageFormat","InvalidImageSize","NotSupportedVisualFeature","NotSupportedImage","InvalidDetails","NotSupportedLanguage","BadArgument","FailedToProcess","Timeout","InternalServerError","Unspecified","StorageException"],"type":"string","x-ms-enum":{"modelAsString":false,"name":"ComputerVisionErrorCodes"}},"message":{"description":"A message explaining the error reported by the service.","type":"string"},"requestId":{"description":"A unique request identifier.","type":"string"}},"required":["code","message"],"type":"object"},"DomainModelResults":{"description":"Result of image analysis using a specific domain model including additional metadata.","properties":{"metadata":{"$ref":"#/components/schemas/ImageMetadata"},"requestId":{"description":"Id of the REST API request.","type":"string"},"result":{"description":"Model-specific response","type":"object","x-ms-client-flatten":true}},"type":"object"},"FaceDescription":{"description":"An object describing a face identified in the image.","properties":{"age":{"description":"Possible age of the face.","type":"integer"},"faceRectangle":{"$ref":"#/components/schemas/FaceRectangle"},"gender":{"description":"Possible gender of the face.","enum":["Male","Female"],"type":"string","x-ms-enum":{"modelAsString":false,"name":"Gender-"}}},"type":"object"},"FaceRectangle":{"description":"An object describing face rectangle.","properties":{"height":{"description":"Height measured from the top-left point of the face.","type":"integer"},"left":{"description":"X-coordinate of the top left point of the face.","type":"integer"},"top":{"description":"Y-coordinate of the top left point of the face.","type":"integer"},"width":{"description":"Width measured from the top-left point of the face.","type":"integer"}},"type":"object"},"ImageAnalysis":{"description":"Result of AnalyzeImage operation.","properties":{"adult":{"$ref":"#/components/schemas/AdultInfo"},"categories":{"description":"An array indicating identified categories.","items":{"$ref":"#/components/schemas/Category"},"type":"array"},"color":{"$ref":"#/components/schemas/ColorInfo"},"description":{"$ref":"#/components/schemas/ImageDescriptionDetails"},"faces":{"description":"An array of possible faces within the image.","items":{"$ref":"#/components/schemas/FaceDescription"},"type":"array"},"imageType":{"$ref":"#/components/schemas/ImageType"},"metadata":{"$ref":"#/components/schemas/ImageMetadata"},"requestId":{"description":"Id of the request for tracking purposes.","type":"string"},"tags":{"description":"A list of tags with confidence level.","items":{"$ref":"#/components/schemas/ImageTag"},"type":"array"}},"type":"object"},"ImageCaption":{"description":"An image caption, i.e. a brief description of what the image depicts.","properties":{"confidence":{"description":"The level of confidence the service has in the caption","format":"double","type":"number"},"text":{"description":"The text of the caption","type":"string"}},"type":"object"},"ImageDescription":{"description":"A collection of content tags, along with a list of captions sorted by confidence level, and image metadata.","properties":{"description":{"$ref":"#/components/schemas/ImageDescriptionDetails"}},"type":"object"},"ImageDescriptionDetails":{"description":"A collection of content tags, along with a list of captions sorted by confidence level, and image metadata.","properties":{"captions":{"description":"A list of captions, sorted by confidence level.","items":{"$ref":"#/components/schemas/ImageCaption"},"type":"array"},"metadata":{"$ref":"#/components/schemas/ImageMetadata"},"requestId":{"description":"Id of the REST API request.","type":"string"},"tags":{"description":"A collection of image tags.","items":{"type":"string"},"type":"array"}},"type":"object"},"ImageMetadata":{"description":"Image metadata","properties":{"format":{"description":"Image format","type":"string"},"height":{"description":"Image height","format":"int32","type":"integer"},"width":{"description":"Image width","format":"int32","type":"integer"}},"type":"object"},"ImageTag":{"description":"An image caption, i.e. a brief description of what the image depicts.","properties":{"confidence":{"description":"The level of confidence the service has in the caption","format":"double","type":"number"},"name":{"description":"The tag value","type":"string"}},"type":"object"},"ImageType":{"description":"An object providing possible image types and matching confidence levels.","properties":{"clipArtType":{"description":"Confidence level that the image is a clip art.","type":"number"},"lineDrawingType":{"description":"Confidence level that the image is a line drawing.","type":"number"}},"type":"object"},"LandmarkResults":{"description":"List of landmarks recognized in the image.","properties":{"landmarks":{"items":{"description":"A landmark recognized in the image","properties":{"confidence":{"description":"Confidence level for the landmark recognition.","format":"double","type":"number"},"name":{"description":"Name of the landmark.","type":"string"}},"type":"object"},"type":"array"},"metadata":{"$ref":"#/components/schemas/ImageMetadata"},"requestId":{"description":"Id of the REST API request.","type":"string"}},"type":"object"},"Line":{"properties":{"boundingBox":{"$ref":"#/components/schemas/BoundingBox"},"text":{"type":"string"},"words":{"items":{"$ref":"#/components/schemas/Word"},"type":"array"}},"type":"object"},"ListModelsResult":{"description":"Result of the List Domain Models operation.","properties":{"models":{"description":"An array of supported models.","items":{"$ref":"#/components/schemas/ModelDescription"},"readOnly":true,"type":"array"}},"type":"object"},"ModelDescription":{"description":"An object describing supported model by name and categories.","properties":{"categories":{"items":{"type":"string"},"type":"array"},"name":{"type":"string"}},"type":"object"},"OcrLine":{"description":"An object describing a single recognized line of text.","properties":{"boundingBox":{"description":"Bounding box of a recognized line. The four integers represent the x-coordinate of the left edge, the y-coordinate of the top edge, width, and height of the bounding box, in the coordinate system of the input image, after it has been rotated around its center according to the detected text angle (see textAngle property), with the origin at the top-left corner, and the y-axis pointing down.","type":"string"},"words":{"description":"An array of objects, where each object represents a recognized word.","items":{"$ref":"#/components/schemas/OcrWord"},"type":"array"}},"type":"object"},"OcrRegion":{"description":"A region consists of multiple lines (e.g. a column of text in a multi-column document).","properties":{"boundingBox":{"description":"Bounding box of a recognized region. The four integers represent the x-coordinate of the left edge, the y-coordinate of the top edge, width, and height of the bounding box, in the coordinate system of the input image, after it has been rotated around its center according to the detected text angle (see textAngle property), with the origin at the top-left corner, and the y-axis pointing down.","type":"string"},"lines":{"items":{"$ref":"#/components/schemas/OcrLine"},"type":"array"}},"type":"object"},"OcrResult":{"properties":{"language":{"description":"The BCP-47 language code of the text in the image.","type":"string"},"orientation":{"description":"Orientation of the text recognized in the image. The value (up,down,left, or right) refers to the direction that the top of the recognized text is facing, after the image has been rotated around its center according to the detected text angle (see textAngle property).","type":"string"},"regions":{"description":"An array of objects, where each object represents a region of recognized text.","items":{"$ref":"#/components/schemas/OcrRegion"},"type":"array"},"textAngle":{"description":"The angle, in degrees, of the detected text with respect to the closest horizontal or vertical direction. After rotating the input image clockwise by this angle, the recognized text lines become horizontal or vertical. In combination with the orientation property it can be used to overlay recognition results correctly on the original image, by rotating either the original image or recognition results by a suitable angle around the center of the original image. If the angle cannot be confidently detected, this property is not present. If the image contains text at different angles, only part of the text will be recognized correctly.","format":"double","type":"number"}},"type":"object"},"OcrWord":{"description":"Information on a recognized word.","properties":{"boundingBox":{"description":"Bounding box of a recognized word. The four integers represent the x-coordinate of the left edge, the y-coordinate of the top edge, width, and height of the bounding box, in the coordinate system of the input image, after it has been rotated around its center according to the detected text angle (see textAngle property), with the origin at the top-left corner, and the y-axis pointing down.","type":"string"},"text":{"description":"String value of a recognized word.","type":"string"}},"type":"object"},"RecognitionResult":{"properties":{"lines":{"items":{"$ref":"#/components/schemas/Line"},"type":"array"}},"type":"object"},"ServiceLanguage":{"type":"string"},"TagResult":{"description":"The results of a image tag operation, including any tags and image metadata.","properties":{"metadata":{"$ref":"#/components/schemas/ImageMetadata"},"requestId":{"description":"Id of the REST API request.","type":"string"},"tags":{"description":"A list of tags with confidence level.","items":{"$ref":"#/components/schemas/ImageTag"},"type":"array"}},"type":"object"},"TextOperationResult":{"properties":{"recognitionResult":{"$ref":"#/components/schemas/RecognitionResult"},"status":{"description":"Status of the text operation.","enum":["Not Started","Running","Failed","Succeeded"],"type":"string","x-ms-enum":{"modelAsString":false,"name":"TextOperationStatusCodes"},"nullable":false}},"type":"object"},"Word":{"properties":{"boundingBox":{"$ref":"#/components/schemas/BoundingBox"},"text":{"type":"string"}},"type":"object"}}}}