Reference example
# Fixed reference example. Playground inputs do not update this sample.
curl --request GET \
--url 'https://api.aisa.one/apis/v1/crawl4ai/web-answer?q=who+founded+stripe' \
--header 'Authorization: Bearer <token>'curl --request GET \
--url https://api.aisa.one/apis/v1/crawl4ai/web-answer \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.aisa.one/apis/v1/crawl4ai/web-answer"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.aisa.one/apis/v1/crawl4ai/web-answer', 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.aisa.one/apis/v1/crawl4ai/web-answer",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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.aisa.one/apis/v1/crawl4ai/web-answer"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.aisa.one/apis/v1/crawl4ai/web-answer")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/crawl4ai/web-answer")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_bodyCrawl4AI
Answer a question from the web, prose or JSON
<!-- aisa-pricing:start -->
Usage-based billing; Default request estimate: $0.00215 USD (not a fixed price). Declared unit rate: $0.000001 USD per provider_credit. Account-specific pricing and final settlement may differ.
<!-- aisa-pricing:end -->
GET
https://api.aisa.one
/
apis
/
v1
/
crawl4ai
/
web-answer
Reference example
# Fixed reference example. Playground inputs do not update this sample.
curl --request GET \
--url 'https://api.aisa.one/apis/v1/crawl4ai/web-answer?q=who+founded+stripe' \
--header 'Authorization: Bearer <token>'curl --request GET \
--url https://api.aisa.one/apis/v1/crawl4ai/web-answer \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.aisa.one/apis/v1/crawl4ai/web-answer"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.aisa.one/apis/v1/crawl4ai/web-answer', 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.aisa.one/apis/v1/crawl4ai/web-answer",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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.aisa.one/apis/v1/crawl4ai/web-answer"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.aisa.one/apis/v1/crawl4ai/web-answer")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/crawl4ai/web-answer")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_bodyRequest contract
- Method and path: GET /apis/v1/crawl4ai/web-answer
- Availability: enabled
- Request URL template:
https://api.aisa.one/apis/v1/crawl4ai/web-answer - deep: query; optional
- gl: query; optional
- hl: query; optional
- nocache: query; optional
- q: query; required
- schema: query; optional
- Runtime facts: 102772a80982304b0cf359bdefff2d1b9160ce5843b51886185c5510345905f9
{
"operationId": "crawl4ai.web-answer",
"method": "GET",
"path": "/apis/v1/crawl4ai/web-answer",
"servers": [
{
"url": "https://api.aisa.one"
}
],
"parameters": [
{
"name": "deep",
"in": "query",
"required": false,
"schema": {
"type": "integer",
"default": 1,
"enum": [
0,
1
],
"description": "1 reads pages and writes an answer when the web has none; 0 returns only the web's own direct answer, else answered false"
}
},
{
"name": "gl",
"in": "query",
"required": false,
"schema": {
"type": "string",
"description": "search country, e.g. us"
}
},
{
"name": "hl",
"in": "query",
"required": false,
"schema": {
"type": "string",
"description": "search language, e.g. en"
}
},
{
"name": "nocache",
"in": "query",
"required": false,
"schema": {
"type": "integer",
"enum": [
1
],
"description": "1 skips every cache"
}
},
{
"name": "q",
"in": "query",
"required": true,
"schema": {
"type": "string",
"description": "the question or prompt, up to 4,000 characters; say the shape you want inside it, e.g. 'answer with JSON only: {...}'",
"examples": [
"who founded stripe"
]
}
},
{
"name": "schema",
"in": "query",
"required": false,
"schema": {
"type": "string",
"description": "a JSON Schema object as a JSON string, up to 4,000 bytes; the answer is then JSON of exactly that shape (parse answer.text)"
}
}
],
"security": [
{
"bearerAuth": []
}
],
"x-aisa-status": "enabled",
"x-aisa-pricing": {
"cost_contract": "response_units",
"customer_multiplier": 1.0,
"customer_pricing": "provider_cost_multiplier",
"default_request_estimate_usd": 0.00215,
"estimate_source": "profile_seed",
"evidence_source": "response_header",
"unit": "provider_credit",
"unit_rate_usd": 1e-06
},
"components": {
"securitySchemes": {
"bearerAuth": {
"scheme": "bearer",
"type": "http"
}
}
}
}
Cost and request rules
Usage-based billing; Default request estimate: $0.00215 USD (not a fixed price). Declared unit rate: $0.000001 USD per provider_credit. Account-specific pricing and final settlement may differ. Published reference values are not an account-specific quote or a settled charge. For endpoints supporting X-AISA-Cost-Mode: quote, obtain a free quote for your exact request before execution; reconcile the settled cost with response metadata and Usage Logs. USD amounts use 1,000,000 integer micro-USD per dollar.- Default request reference estimate (USD): 0.00215
- Declared unit rate (USD): 1e-06
- Billing unit: provider_credit
- Cost contract: response_units
- Published reference multiplier: 1.0
- Settlement evidence source: response_header
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Query Parameters
1 reads pages and writes an answer when the web has none; 0 returns only the web's own direct answer, else answered false
Available options:
0, 1 search country, e.g. us
search language, e.g. en
1 skips every cache
Available options:
1 the question or prompt, up to 4,000 characters; say the shape you want inside it, e.g. 'answer with JSON only: {...}'
Example:
"who founded stripe"
a JSON Schema object as a JSON string, up to 4,000 bytes; the answer is then JSON of exactly that shape (parse answer.text)
Response
Successful response