Generate a pre-signed export URL
curl --request GET \
--url https://portal.webless.ai/query-data \
--header 'x-api-key: <api-key>'const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://portal.webless.ai/query-data', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://portal.webless.ai/query-data"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text){
"presigned_url": "https://webless-client-data.s3.us-west-1.amazonaws.com/athena-results/QUERY_ID.csv?X-Amz-..."
}{
"detail": "<string>",
"error": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"detail": "<string>",
"error": "<string>"
}Data API
Query data
Triggers a data export for the given company and date range.
GET
/
query-data
Generate a pre-signed export URL
curl --request GET \
--url https://portal.webless.ai/query-data \
--header 'x-api-key: <api-key>'const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://portal.webless.ai/query-data', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://portal.webless.ai/query-data"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text){
"presigned_url": "https://webless-client-data.s3.us-west-1.amazonaws.com/athena-results/QUERY_ID.csv?X-Amz-..."
}{
"detail": "<string>",
"error": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"detail": "<string>",
"error": "<string>"
}The
presigned_url returned by this endpoint is not always ready immediately.
Poll it with Range: bytes=0-0 every 10 seconds until it returns 200 or
206, then download the full file.Authorizations
Query Parameters
Your client code.
Inclusive start date in YYYY-MM-DD format.
Inclusive end date in YYYY-MM-DD format.
Response
Accepted. The export is being prepared.
Example:
"https://webless-client-data.s3.us-west-1.amazonaws.com/athena-results/QUERY_ID.csv?X-Amz-..."
Was this page helpful?