--- title: "自動完成検索" slug: "analytics-cloudsearch-searchautocomplete" updated: 2026-09-17T09:57:29Z published: 2026-09-17T09:57:29Z canonical: "api.ncloud-docs.com/analytics-cloudsearch-searchautocomplete" --- > ## Documentation Index > Fetch the complete documentation index at: https://api.ncloud-docs.com/llms.txt > Use this file to discover all available pages before exploring further. # 自動完成検索 [自動完成設定](/docs/ja/analytics-cloudsearch-putautocomplete)以降、該当リクエストを使用できます。 リクエストした検索語の自動完成インデックスを検索します。 GET、POSTリクエストをサポートします。二つのリクエストが同じであり、選択的に利用できます。 ## GET Request ``` GET https://cloudsearch.apigw.ntruss.com/CloudSearch/real/v1/domain/{name}/document/search/autocomplete ``` ## リクエスト ### リクエストパラメータ | パラメータ名 | 必須 | タイプ | 制約事項 | 説明 | | --- | --- | --- | --- | --- | | name | Yes | string | 検索設定されているDomain | 検索しようとするDomain名 | | type | Yes | string | term, section | 検索しようとするタイプ term:インデックス単位の自動完成検索section: セクション単位の自動完成検索 | | query | Yes | string | | 検索語 | ## レスポンス ### レスポンスボディ | フィールド名 | 必須 | タイプ | 説明 | 備考 | | --- | --- | --- | --- | --- | | type | Yes | string | 自動完成検索リクエストタイプ | | | item_count | Yes | number | 自動完成検索結果個数 | | | items | Yes | Array[string] | 自動完成検索結果 | | ### レスポンスStatus | HTTP Status | Desc | | --- | --- | | 200 | OK(検索完了) | | 400 | Bad Request | | 401 | Unauthorized | | 403 | Forbidden | | 404 | Not Found | | 500 | Internal Server Error | ## 例示 ### リクエスト例示 ``` GET /cloudsearch/api/v1/domain/abcdef/document/search/autocomplete?type=section&query=%E3%85%8E HTTP/1.1 Host: cloudsearch.apigw.ntruss.com accept:application/json x-ncp-apigw-signature-v2: cDwtHuQeGmwWyNmwlN6XIGA66zge4iMXvfoDQNna05g= x-ncp-apigw-timestamp: 1545817618751 x-ncp-iam-access-key: teGTwtcSEGA7fu28BGGi ``` ### レスポンス例示 ``` { "type": "section", "item_count": 1, "items": [ "2018 Toyota Camry Hybrid" ] } ``` ## POST Request ``` POST https://cloudsearch.apigw.ntruss.com/CloudSearch/real/v1/domain/{name}/document/search/autocomplete ``` ## リクエスト ### リクエストパラメータ | パラメータ名 | 必須 | タイプ | 制約事項 | 説明 | | --- | --- | --- | --- | --- | | name | Yes | string | 検索設定されているDomain | 検索しようとするDomain名 | ### リクエストボディ | パラメータ名 | 必須 | タイプ | 制約事項 | 説明 | | --- | --- | --- | --- | --- | | AutocompleteSearchQuery | Yes | [AutocompleteSearchQuery](/docs/ja/common-apidatatype-csautocompletesearchquery) | | 自動完成検索問い合わせ | ## レスポンス ### レスポンスボディ | フィールド名 | 必須 | タイプ | 説明 | 備考 | | --- | --- | --- | --- | --- | | type | Yes | string | 自動完成検索リクエストタイプ | | | item_count | Yes | number | 自動完成検索結果個数 | | | items | Yes | Array[string] | 自動完成検索結果 | | ### レスポンスStatus | HTTP Status | Desc | | --- | --- | | 200 | OK(検索完了) | | 400 | Bad Request | | 401 | Unauthorized | | 403 | Forbidden | | 404 | Not Found | | 500 | Internal Server Error | ## 例示 ### リクエスト例示 ``` POST /CloudSearch/real/v1/domain/abcdef/document/search/autocomplete HTTP/1.1 Host: cloudsearch.apigw.ntruss.com accept:application/json x-ncp-apigw-signature-v2: cDwtHuQeGmwWyNmwlN6XIGA66zge4iMXvfoDQNna05g= x-ncp-apigw-timestamp: 1545817618751 x-ncp-iam-access-key: teGTwtcSEGA7fu28BGGi { "query": "h", // "ㅎ" → ”h”に変更 "type": "term" } ``` ### レスポンス例示 ``` { "type": "term", "item_count": 2, "items": [ "Hyundai", "Hybrid" ] } ```