Documentation Index
Fetch the complete documentation index at: https://docs.wetrocloud.com/llms.txt
Use this file to discover all available pages before exploring further.
Endpoints
| Endpoint | Method | Description |
|---|
/v1/extract/ | POST | Extract structured data from any website using AI-powered extraction with custom JSON schemas. |
Extract specific information from any web page and receive it in a structured JSON format that matches your requirements.
Request Parameters:
| Parameter | Type | Required | Description |
|---|
link | String | Yes | The URL of the website to extract data from |
prompt | String | Yes | Instructions describing what data to extract |
json_schema | Array | No | The structure defining your desired output format. If not provided, returns plain text |
delay | Integer | No | Delay in seconds before extraction (useful for dynamic content). Default: 0 |
Example Request:
import requests
import json
url = "https://api.wetrocloud.com/v1/extract/"
headers = {
"Content-Type": "application/json",
"Authorization": "Token <api_key>"
}
payload = {
"link": "https://theweek.com/news/people/954994/billionaires-richest-person-in-the-world",
"prompt": "Extract the names and networth of Billionares in the article",
"json_schema": [
{"name": "string"},
{"networth": "number"}
],
"delay": 2
}
response = requests.post(url, headers=headers, data=json.dumps(payload))
print(response.json())
Response Format (Structured Output):
{
"response": [
{
"name": "Elon Musk",
"networth": "$462 billion"
},
{
"name": "Larry Ellison",
"networth": "$340 billion"
}
// ... more results
],
"success": true
}
Response Format (Plain Text - when json_schema is omitted):
{
"response": "Here are the names and net worths of the billionaires listed in the article:\n\n1. **Elon Musk:** $462 billion\n2. **Larry Ellison:** $340 billion...",
"success": true
}
| Field | Type | Description |
|---|
response | Array or String | Extracted data matching your JSON schema (array) or plain text (string) if no schema provided |
success | Boolean | Indicates whether the extraction was successful |
Status Codes:
200 OK - Request successful
400 Bad Request - Invalid parameters or malformed JSON schema
401 Unauthorized - Invalid or missing API key
404 Not Found - URL not accessible
Error Response:
{
"error": "Error message describing what went wrong",
"success": false
}