openapi-sdk-php
openapi-sdk-php copied to clipboard
DTS API does not follow the shared region setting defined in DefaultClient
- PHP 版本: 7.4 (via Homebrew)
- 平台:MacOS
- 产品名称:Dts
- 产品版本:1.8.1074
-
API:
Dts::v20200101()->describeDtsJobs
Received error as following:
↘ Caused by [AlibabaCloud\Client\Exception\ServerException#400] MissingRegion: Region is mandatory for this action. RequestId: B830AAD3-3191-5EF2-A6B3-C44931386BF2 POST "http://dts.aliyuncs.com" 400
Pure Code:
AlibabaCloud::accessKeyClient($getAccessKeyId, $getAccessKeySecret)
->regionId($regionId)
->asDefaultClient();
// error in next request call!
$response = Dts::v20200101()->describeDtsJobs([])
->withJobType('SYNC')
->withPageNumber(1)
->withPageSize(30)
->request();