엔진 기능 목록
현재 API 계약에 따른 엔진, 대체 입력 방식, 크레딧 과금, 지원 국가를 확인합니다.
GET
/
v1
/
capabilities
Engine capabilities
curl --request GET \
--url https://api.querying.ai/v1/capabilitiesimport requests
url = "https://api.querying.ai/v1/capabilities"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.querying.ai/v1/capabilities', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.querying.ai/v1/capabilities",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.querying.ai/v1/capabilities"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.querying.ai/v1/capabilities")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.querying.ai/v1/capabilities")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"engines": [
{
"taskType": "PERPLEXITY",
"aliases": [
"<string>"
],
"endpoint": "/v1/async/task",
"credits": 1,
"input": {
"required": [
"<string>"
],
"optional": [
"<string>"
],
"oneOf": [
{
"required": [
"<string>"
],
"not": {
"anyOf": [
{
"required": [
"<string>"
]
}
]
}
}
]
},
"location": true,
"uule": true,
"countries": {
"policy": "all_except",
"unsupported": [
{
"country": "CN",
"cause": "no_proxy_route"
}
]
},
"example": {},
"metering": {
"mode": "usage",
"creditsMeaning": "legacy_fallback",
"hold": {
"basis": "resolved_input",
"baseCredits": 1,
"perCitationCredits": 1,
"perAnswerKCharsCredits": 1,
"formula": "<string>"
},
"settlement": {
"basis": "measured_usage",
"cappedByHold": true,
"unusedHoldReleased": true,
"missingUsage": "credits"
}
}
}
]
}
}대체 입력
input.required는 모든 입력 방식에 필요한 필드입니다. input.optional은 그 밖에 허용되는 필드입니다. input.oneOf가 있으면 공통 필수 필드와 함께 그 조건 중 정확히 하나를 만족해야 합니다.
COMMERCE_SERP:site와 함께query또는url중 하나를 보냅니다. URL 방식은site: "qoo10"으로 Qoo10 상점 페이지를 읽습니다.CITATION_ANALYSIS:answer와citations를 보내거나taskId를 보냅니다.taskId를 보내면 서버가 저장된 답변·출처·검색어를 읽으므로answer·citations·queries는 생략합니다.
endpoint 필드가 제출 경로를 알려줍니다. Citation Analysis는 여기에 표시된 전용 endpoint로 제출합니다.
Citation Analysis 과금
CITATION_ANALYSIS의 숫자형 credits는 호환성을 위해 25를 유지합니다. 사용량 정보가 없는 저장 결과에 적용하는 대체 차감액입니다. 예약량과 최종 차감액은 가변 과금 계약을 따릅니다.
metering.mode는 usage이고 metering.creditsMeaning은 legacy_fallback입니다. metering.hold의 계수로 예약량을 계산합니다.
baseCredits + perCitationCredits * max(1, citations.length)
+ perAnswerKCharsCredits * ceil(answer.length / 1000)
20, 12, 80입니다. 출처 1개와 UTF-16 단위 길이 1~1,000인 답변은 112크레딧을 예약합니다. 출처 수에는 cited: false인 검색 결과도 포함합니다. taskId를 사용하면 저장된 답변과 출처 목록을 기준으로 계산합니다.
예약량이 사용 가능한 잔액보다 크면 잔액이 50크레딧 이상일 때 잔액 전체를 대신 예약하고, 50크레딧 미만이면 402 INSUFFICIENT_CREDITS를 반환합니다. 최종 차감액은 실제로 예약한 양을 넘지 않습니다.
metering.settlement는 실제 사용량을 예약량 안에서 차감하고 남은 잔액을 반환합니다. 사용량 정보가 없으면 missingUsage: "credits"에 따라 기존 숫자형 값을 적용합니다. 요청과 결과는 Citation Analysis를 참고하세요.⌘I
Engine capabilities
curl --request GET \
--url https://api.querying.ai/v1/capabilitiesimport requests
url = "https://api.querying.ai/v1/capabilities"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.querying.ai/v1/capabilities', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.querying.ai/v1/capabilities",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.querying.ai/v1/capabilities"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.querying.ai/v1/capabilities")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.querying.ai/v1/capabilities")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"engines": [
{
"taskType": "PERPLEXITY",
"aliases": [
"<string>"
],
"endpoint": "/v1/async/task",
"credits": 1,
"input": {
"required": [
"<string>"
],
"optional": [
"<string>"
],
"oneOf": [
{
"required": [
"<string>"
],
"not": {
"anyOf": [
{
"required": [
"<string>"
]
}
]
}
}
]
},
"location": true,
"uule": true,
"countries": {
"policy": "all_except",
"unsupported": [
{
"country": "CN",
"cause": "no_proxy_route"
}
]
},
"example": {},
"metering": {
"mode": "usage",
"creditsMeaning": "legacy_fallback",
"hold": {
"basis": "resolved_input",
"baseCredits": 1,
"perCitationCredits": 1,
"perAnswerKCharsCredits": 1,
"formula": "<string>"
},
"settlement": {
"basis": "measured_usage",
"cappedByHold": true,
"unusedHoldReleased": true,
"missingUsage": "credits"
}
}
}
]
}
}