Faqs
FAQ related APIs
特定のFAQをユーザーが選択したものとして処理することができます。
Optional: Email of the agent to use for this request
Optional: Email address to associate with the user
Optional: User ID to identify or create a user
選択したいQ&AのID
Q&A検索結果のID
選択されたQ&A
無効なQ&AQです(?)
POST /webapi/faq/select_answer HTTP/1.1
Host: backend-ja.alli.ai
API-KEY: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 29
{
"id": "text",
"hashId": "text"
}
{
"result": "text"
}
このAPIを使用すると、Q&Aナレッジベースから最も関連性の高い質問と回答のペアを見つけることができます。
Optional: Email of the agent to use for this request
Optional: Email address to associate with the user
Optional: User ID to identify or create a user
デフォルト値はtrueです。このオプションをfalseに設定すると、指定されたクエリに対して答えがない場合、自動的にQ&A登録候補にクエリが登録されません。
ANDまたはORのいずれかを選択します。
すべてのハッシュタグを含む結果を返したい場合はANDを選択します。
少なくとも1つのハッシュタグを含む結果を返したい場合はORを選択します。
表示したいすべてのハッシュタグの配列。
返される結果の最大数。
質問内容。
html またはテキストの場合。テキストの場合、返り値はプレーンテキストになります。html の場合、html を返します。異なるフォントサイズや色などのスタイルがある html を使用する場合、html を使用できます。単にテキストとして答えを得たい場合は、テキストを使用できます。デフォルト値は html です。
APIは、Q&Aデータから最も関連性の高い質問と回答を見つけます。
POST /webapi/faq HTTP/1.1
Host: backend-ja.alli.ai
API-KEY: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 122
{
"autoRegisterCandidates": true,
"hashtagsOperator": "AND",
"hashtags": [
"text"
],
"maxResults": 1,
"query": "text",
"format": "html"
}
APIは、Q&Aデータから最も関連性の高い質問と回答を見つけます。
{
"result": [
{
"confidence": 1,
"effectiveConfidence": 1,
"question": "text",
"answer": "text",
"id": "text",
"hashtags": [
"text"
],
"lastUpdatedDate": "2025-08-16",
"agentFeedback": {
"positiveCount": 1,
"negativeCount": 1
},
"userFeedback": {
"positiveCount": 1,
"negativeCount": 1
}
}
],
"count": 1,
"hashId": "text"
}
シングルQ&Aのすべての詳細を取得する方法です。
The id of the FAQ you are looking for.
The format of the answer value for this FAQ. Default is HTML.
Optional: Email of the agent to use for this request
Optional: Email address to associate with the user
Optional: User ID to identify or create a user
FAQの詳細を正常に取得しました。
FAQが見つかりません
GET /webapi/single_faq HTTP/1.1
Host: backend-ja.alli.ai
API-KEY: YOUR_API_KEY
Accept: */*
{
"result": {
"question": "text",
"similar_questions": [
"text"
],
"answer": "text",
"id": "text",
"userFeedback": {
"positiveCount": 1,
"negativeCount": 1
},
"agentFeedback": {
"positiveCount": 1,
"negativeCount": 1
},
"lastUpdatedDate": "2025-08-16",
"createdDate": "2025-08-16",
"hashtags": [
"text"
],
"statusOnAt": "2025-08-16T20:45:39.919Z",
"statusOffAt": "2025-08-16T20:45:39.919Z",
"folder": "text",
"agentEditor": [
"text"
],
"agentViewer": [
"text"
],
"allowOtherAgentsView": true,
"allowOtherUsersView": true
}
}
ナレッジベースのQ&Aを一覧表示できます。
Offset allows you to specify the ranking number of the first item on the page.
0
Limit allows you to set the number of objects returned on one page. The maximum and the default value is 1000.
1000
If your answers contain styled html, such as different font size or color, you can use html to get answers in html format. If you simply want to get answers as a text, you can use the text.
html
Possible values: Optional: Email of the agent to use for this request
Optional: Email address to associate with the user
Optional: User ID to identify or create a user
OK
GET /webapi/faqs HTTP/1.1
Host: backend-ja.alli.ai
API-KEY: YOUR_API_KEY
Accept: */*
OK
{
"offset": 1,
"count": 1,
"total_count": 1,
"results": [
{
"id": "text",
"question": "text",
"answer": "text",
"hashtags": [
"text"
],
"userFeedback": {
"positiveCount": 1,
"negativeCount": 1
},
"agentFeedback": {
"positiveCount": 1,
"negativeCount": 1
},
"lastUpdatedDate": "2025-08-16",
"createdDate": "2025-08-16"
}
]
}
ナレッジベース内のQ&Aの検索およびフィルタリングができます。
Optional: Email of the agent to use for this request
Optional: Email address to associate with the user
Optional: User ID to identify or create a user
リストをフィルターするためのキーワード検索クエリ。以下の方法で高度な検索が可能です。を使用できます。ANDの場合は"TERM1 TERM2"、ORの場合は"TERM1 OR TERM2"、完全一致の場合は"TERM"を使用します。
Trueの場合、有効になっているQ&Aのみが一覧表示されます。Falseの場合、無効になっているQ&Aのみが一覧表示されます。
リストをフィルタリングするためのハッシュタグ。複数のハッシュタグを追加できます。
「AND」の場合、ハッシュタグのフィルターは複数のハッシュタグに対してANDロジックで機能します。「OR」の場合、ORロジックで機能します。
Trueの場合、リストには管理者によって作成されたQ&Aのみが含まれます。Falseの場合、他のQ&Aのみが含まれます。createdByAgent、answeredByMrc、autoGenerated、editedByAgentのフィルターは相互排他であり、それらのうち2つ以上が使用される場合はORロジックが適用されます。
正しければ、リストにはアップロードされたドキュメントから自動的に抽出された回答のみが含まれるQ&Aが含まれます。間違っていれば、その他のQ&Aのみが含まれます。
Trueの場合、リストには自動生成されたQ&Aのみが含まれます。Falseの場合、他のQ&Aのみが含まれます。
Trueの場合、リストには登録後にエージェントによって編集されたQ&Aのみが含まれます。Falseの場合、他のQ&Aのみが含まれます。
回答に異なるフォントサイズや文字色などのスタイル付きHTMLが含まれている場合、HTML形式で取得することでスタイルが反映された回答を得ることができます。スタイルなしのプレーンなテキストとして回答を取得したい場合は、テキスト形式を使用できます。デフォルト値はHTMLです。
オフセットを使用すると、ページ上の最初の項目の順位番号を指定できます。
1ページに返されるオブジェクトの数を設定します。最大値およびデフォルト値は1000です。
OK
POST /webapi/faqs HTTP/1.1
Host: backend-ja.alli.ai
API-KEY: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 202
{
"searchTerm": "text",
"isUsed": true,
"hashtags": [
"text"
],
"hashtagsOperator": "and",
"createdByAgent": true,
"answeredByMrc": true,
"autoGenerated": true,
"editedByAgent": true,
"format": "html",
"offset": 1,
"limit": 1
}
OK
{
"offset": 1,
"count": 1,
"total_count": 1,
"results": [
{
"id": "text",
"question": "text",
"answer": "text",
"hashtags": [
"text"
],
"userFeedback": {
"positiveCount": 1,
"negativeCount": 1
},
"agentFeedback": {
"positiveCount": 1,
"negativeCount": 1
},
"lastUpdatedDate": "2025-08-16",
"createdDate": "2025-08-16"
}
]
}
新規のQ&Aの追加や既存のQ&Aの更新ができます。
Optional: Email of the agent to use for this request
Optional: Email address to associate with the user
Optional: User ID to identify or create a user
Q&Aの質問部分
類似質問
Q&Aの答えの部分です。同じ質問が既にナレッジベースにに存在する場合、答えが置き換えられます。
Q&Aにハッシュタグを追加します。
Q&AのON/OFFを設定します。ONにすると、登録したQ&Aが有効になります。
Q&Aのメモ
OK
POST /webapi/register_faq HTTP/1.1
Host: backend-ja.alli.ai
API-KEY: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 192
{
"question": "text",
"similarQuestions": [
"text"
],
"answer": "text",
"hashtags": [
"text"
],
"status": true,
"memo": "text",
"target_folder_id": "text",
"allowOtherAgentsView": true,
"allowOtherUsersView": true
}
OK
{
"result": {
"status": "text",
"id": "text"
},
"errors": "text"
}
既存のQ&Aを更新できます。
Optional: Email of the agent to use for this request
Optional: Email address to associate with the user
Optional: User ID to identify or create a user
更新するQ&AのID
Q&Aの質問部分
類似質問
Q&Aの答えの部分
Q&Aにハッシュタグを追加
Q&AのON/OFFを切り替えます。ONにすると、Q&Aが有効になります。
OK
PUT /webapi/register_faq HTTP/1.1
Host: backend-ja.alli.ai
API-KEY: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 191
{
"id": "text",
"question": "text",
"similar_questions": [
"text"
],
"answer": "text",
"hashtags": [
"text"
],
"status": true,
"target_folder_id": "text",
"allowOtherAgentsView": true,
"allowOtherUsersView": true
}
OK
{
"result": {
"status": "text",
"id": "text"
},
"errors": "text"
}
このAPIを使用してQ&Aを削除できます。
Optional: Email of the agent to use for this request
Optional: Email address to associate with the user
Optional: User ID to identify or create a user
削除したいQ&AのID。
FAQが正常に削除されました。
Q&Aデータが見つかりません
POST /webapi/delete_faq HTTP/1.1
Host: backend-ja.alli.ai
API-KEY: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 13
{
"id": "text"
}
{
"result": {
"status": "text"
},
"errors": "text"
}
このAPIを使用することで、tsv、csv、xlsx、zip形式で複数のQ&Aをアップロードすることができます。
Optional: Email of the agent to use for this request
Optional: Email address to associate with the user
Optional: User ID to identify or create a user
ローカルに保存されているQ&Aファイルの場所。xlsx、tsv、csv、およびzipファイルがサポートされています。
FAQファイルのアップロードに成功しました。
Invalid Parameter
POST /webapi/upload_faq_file HTTP/1.1
Host: backend-ja.alli.ai
API-KEY: YOUR_API_KEY
Content-Type: multipart/form-data
Accept: */*
Content-Length: 17
{
"file": "binary"
}
{
"result": "text",
"notUploaded": [
{
"question": "text",
"state": "text"
}
]
}
This API lets you give or cancel feedback given to a Q&A pair for a search query.
Optional: Email of the agent to use for this request
Optional: Email address to associate with the user
Optional: User ID to identify or create a user
Your API key can be found in your dashboard Settings menu, under the General tab.
The query you want to give or cancel feedback for, toward the Q&A.
The ID for the Q&A you want to give or cancel feedback for the query. It is created whenever a Q&A search happens and bound to the query and the Q&A pair. It can be retrieved using the Q&A API above.
When the value is true, positive feedback is given to the Q&A for the query. When it's false, negative feedback is given. When it's null, it cancels the feedback.
Feedback submitted successfully
POST /webapi/faq_feedback HTTP/1.1
Host: backend-ja.alli.ai
API-KEY: text
Content-Type: application/json
Accept: */*
Content-Length: 46
{
"query": "text",
"id": "text",
"isPositive": true
}
Feedback submitted successfully
{
"result": {
"faqTrainSearchResult": {
"faq": {
"id": "text"
},
"agentFeedback": {
"positiveCount": 1,
"negativeCount": 1
}
}
},
"errors": {}
}
過去に行われたQ&A検索の履歴を、REST APIおよびAlliダッシュボードを通じて参照します。
A limit on the number of results to show (used for pagination)
In the list of all results, the index from which to start listing results (used for pagination)
The latest date from which you want to get history (dates should be in the form YYYY-MM-DD)
The earliest date from which you want to get history (dates should be in the form YYYY-MM-DD)
Can either be DESC (meaning latest queries come first), or ASC (meaning earliest queries come first)
The term that should have appeared in the query
Optional: Email of the agent to use for this request
Optional: Email address to associate with the user
Optional: User ID to identify or create a user
正常に取得されました。
GET /webapi/faq_histories HTTP/1.1
Host: backend-ja.alli.ai
API-KEY: YOUR_API_KEY
Accept: */*
正常に取得されました。
{
"result": {
"histories": [
{
"agent": {
"id": "text"
},
"question": "text",
"answers": [
{
"faq": {
"id": "text"
},
"effectiveConfidence": 1,
"confidence": 1
}
]
}
],
"count": 1
},
"errors": {}
}
このAPIを使用すると、ナレッジベースの未回答の質問リストを取得できます。対象のQ&AははQ&A登録候補(Candidates)と呼ばれます。
Hashtag array if you want to limit the search scope to the given hashtags
Search query to filter the candidates to see. You can use operators to run advanced searches. "TERM1 TERM2" for AND, "TERM1 OR TERM2" for OR, and "TERM" for exact match.
How to order the candidates. You can use ATTRIBUTE_[DESC or ASC] format. ATTRIBUTE can be FREQUENCY or CREATED_AT.
Status of the candidates to see. It can be ALL or ACTIVE or ARCHIVED.
offset allows you to specify the ranking number of the first item on the page.
limit allows you to set the number of objects returned on one page. The maximum value is 100.
Optional: Email of the agent to use for this request
Optional: Email address to associate with the user
Optional: User ID to identify or create a user
正常に取得しました。
GET /webapi/faq_candidates HTTP/1.1
Host: backend-ja.alli.ai
API-KEY: YOUR_API_KEY
Accept: */*
正常に取得しました。
{
"result": {
"faqCandidates": [
{
"id": "text",
"frequency": 1,
"textAnswer": "text",
"state": "text",
"createdAt": 1,
"questions": [
{
"id": "text",
"question": "text",
"frequency": 1,
"history": {
"id": "text"
}
}
]
}
],
"count": 1
},
"errors": {}
}
特定の日付範囲におけるFAQ検索のの日ごとの件数。
Optional: Email of the agent to use for this request
Optional: Email address to associate with the user
Optional: User ID to identify or create a user
照会する日付範囲の終了日をYYYY-MM-DD形式で指定します。
照会する日付範囲の終了日をYYYY-MM-DD形式で指定します。
日毎のFAQ検索件数を正常に取得しました。
GET /webapi/faq_daily_count HTTP/1.1
Host: backend-ja.alli.ai
API-KEY: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 37
{
"startDate": "text",
"endDate": "text"
}
日毎のFAQ検索件数を正常に取得しました。
{
"result": {
"dailyTotalCount": [
{
"date": "text",
"count": 1
}
],
"state": "text",
"campaignCount": 1
},
"errors": {}
}
最も頻繁に質問されるQ&Aの分析情報。
Optional: Email of the agent to use for this request
Optional: Email address to associate with the user
Optional: User ID to identify or create a user
最も頻繁に質問されるQ&Aの上位N。Nの最大値は20です。Nには1、5、10、または20を使用してください。
クエリする日付範囲の開始をYYYY-MM-DD形式で指定します。
YYYY-MM-DD形式でクエリを行う日付範囲の終了。
FAQアナリティクスの取得に成功しました。
GET /webapi/faq_daily_analytics HTTP/1.1
Host: backend-ja.alli.ai
API-KEY: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 46
{
"topN": 1,
"startDate": "text",
"endDate": "text"
}
FAQアナリティクスの取得に成功しました。
{
"result": {
"faqDailyAnalytics": [
{
"totalCount": 1,
"totalShownCount": 1,
"selectedRatio": 1,
"faq": {
"id": "text",
"question": "text"
},
"stats": [
{
"date": "text",
"selectedCount": 1
}
]
}
]
},
"errors": {}
}
システムに新しいQ&A候補者を登録します。
Optional: Email of the agent to use for this request
Optional: Email address to associate with the user
Optional: User ID to identify or create a user
登録したいすべてのクエリのリスト
候補者が正常に登録されました。
POST /webapi/add_faq_candidates HTTP/1.1
Host: backend-ja.alli.ai
API-KEY: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 20
{
"queries": [
"text"
]
}
候補者が正常に登録されました。
{
"result": {
"candidates": [
{
"id": "text"
}
]
},
"errors": {}
}
Was this helpful?