URLベースの HTTP または HTTPS リクエストを送信すると、Image Search API オペレーションを呼び出すことができます。 各 URL にはリクエストパラメーターを含める必要があります。 このトピックでは、HTTP または HTTPS リクエストの構文について説明し、Image Search のエンドポイントを提供します。
エンドポイント
リージョン | Region | パブリックエンドポイント | VPC エンドポイント |
---|---|---|---|
中国 (上海) | cn-shanghai | imagesearch.cn-shanghai.aliyuncs.com | imagesearch-vpc.cn-shanghai.aliyuncs.com |
シンガポール | ap-southeast-1 | imagesearch.ap-southeast-1.aliyuncs.com | imagesearch-vpc.ap-southeast-1.aliyuncs.com |
中国 (香港) | cn-hongkong | imagesearch.cn-hongkong.aliyuncs.com | imagesearch-vpc.cn-hongkong.aliyuncs.com |
日本 (東京) | ap-northeast-1 | imagesearch.ap-northeast-1.aliyuncs.com | imagesearch-vpc.ap-northeast-1.aliyuncs.com |
ドイツ (フランクフルト) | eu-central-1 | imagesearch.eu-central-1.aliyuncs.com | imagesearch-vpc.eu-central-1.aliyuncs.com |
注
- 中国サイト (aliyun.com) では、
中国 (上海)
のみを選択できます。 - 仮想プライベートクラウド (VPC) エンドポイントを使用して、同じ VPC 内の ECS インスタンスから Image Search API を呼び出すことができます。
- VPC エンドポイントを使用して、Image Search API を呼び出す場合、パブリック帯域幅を消費する必要はありません。 詳細については、「VPCエンドポイントを使用して、Image Search API を呼び出す」をご参照ください。
通信プロトコル
HTTP または HTTPS プロトコルでリクエストを送信できます。 セキュリティ強化のため、HTTPS でのリクエスト送信を推奨します。
メソッド
HTTP POST リクエストを送信できます。
リクエストパラメーター
すべてのリクエストに、共通のリクエストパラメーターと操作固有のリクエストパラメータが含まれていることを確認してください。
文字エンコーディング
リクエストとレスポンスはUTF-8
でエンコードされます。
VPCエンドポイントを使用して、Image Search API を呼び出す
SDK V3:
# Use a VPC endpoint
authConfig.endpoint = "imagesearch-vpc.cn-shanghai.aliyuncs.com";
# Add a configuration item
authConfig.endpointType = "internal";
SDK earlier than V3:
IClientProfile profile = DefaultProfile.getProfile("cn-shanghai", <accessKey>, <accessSecret>);
# Use a VPC endpoint
DefaultProfile.addEndpoint("cn-shanghai", "ImageSearch", "imagesearch-vpc.cn-shanghai.aliyuncs.com");
this.client = new DefaultAcsClient(profile);