Skip to content

Commit

Permalink
Merge pull request #244 from 10up/feature/update-computer-vision-api
Browse files Browse the repository at this point in the history
Update to v3.1 of the Computer Vision Analyze API
  • Loading branch information
jeffpaul authored Oct 26, 2020
2 parents abf82ae + ed651e5 commit 403907e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion includes/Classifai/Providers/Azure/ComputerVision.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class ComputerVision extends Provider {
/**
* @var string URL fragment to the analyze API endpoint
*/
protected $analyze_url = 'vision/v1.0/analyze';
protected $analyze_url = 'vision/v3.1/analyze';

/**
* ComputerVision constructor.
Expand Down
2 changes: 1 addition & 1 deletion includes/Classifai/Providers/Azure/SmartCropping.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class SmartCropping {
*
* @var string
*/
const API_PATH = 'vision/v2.0/generateThumbnail/';
const API_PATH = 'vision/v3.1/generateThumbnail/';

/**
* ComputerVisition settings.
Expand Down
2 changes: 1 addition & 1 deletion tests/Classifai/Providers/Azure/SmartCroppingTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ public function test_get_cropped_thumbnail() {
*/
public function test_get_api_url() {
$this->assertEquals(
'my-api-url.com/vision/v2.0/generateThumbnail/',
'my-api-url.com/vision/v3.1/generateThumbnail/',
$this->get_smart_cropping()->get_api_url()
);
}
Expand Down

0 comments on commit 403907e

Please sign in to comment.