Update Squid
curl --request POST \
--url https://api.lobstr.io/v1/squids/{squid_hash} \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>' \
--data '
{
"name": "<string>",
"is_active": true,
"concurrency": 123,
"to_complete": true,
"export_unique_results": true,
"no_line_breaks": true,
"run_notify": "<string>",
"cron_expression": "<string>",
"timezone": "<string>"
}
'import requests
url = "https://api.lobstr.io/v1/squids/{squid_hash}"
payload = {
"name": "<string>",
"is_active": True,
"concurrency": 123,
"to_complete": True,
"export_unique_results": True,
"no_line_breaks": True,
"run_notify": "<string>",
"cron_expression": "<string>",
"timezone": "<string>"
}
headers = {
"Authorization": "<authorization>",
"Content-Type": "<content-type>"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<authorization>', 'Content-Type': '<content-type>'},
body: JSON.stringify({
name: '<string>',
is_active: true,
concurrency: 123,
to_complete: true,
export_unique_results: true,
no_line_breaks: true,
run_notify: '<string>',
cron_expression: '<string>',
timezone: '<string>'
})
};
fetch('https://api.lobstr.io/v1/squids/{squid_hash}', 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.lobstr.io/v1/squids/{squid_hash}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'is_active' => true,
'concurrency' => 123,
'to_complete' => true,
'export_unique_results' => true,
'no_line_breaks' => true,
'run_notify' => '<string>',
'cron_expression' => '<string>',
'timezone' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: <content-type>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.lobstr.io/v1/squids/{squid_hash}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"is_active\": true,\n \"concurrency\": 123,\n \"to_complete\": true,\n \"export_unique_results\": true,\n \"no_line_breaks\": true,\n \"run_notify\": \"<string>\",\n \"cron_expression\": \"<string>\",\n \"timezone\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<authorization>")
req.Header.Add("Content-Type", "<content-type>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.lobstr.io/v1/squids/{squid_hash}")
.header("Authorization", "<authorization>")
.header("Content-Type", "<content-type>")
.body("{\n \"name\": \"<string>\",\n \"is_active\": true,\n \"concurrency\": 123,\n \"to_complete\": true,\n \"export_unique_results\": true,\n \"no_line_breaks\": true,\n \"run_notify\": \"<string>\",\n \"cron_expression\": \"<string>\",\n \"timezone\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.lobstr.io/v1/squids/{squid_hash}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<authorization>'
request["Content-Type"] = '<content-type>'
request.body = "{\n \"name\": \"<string>\",\n \"is_active\": true,\n \"concurrency\": 123,\n \"to_complete\": true,\n \"export_unique_results\": true,\n \"no_line_breaks\": true,\n \"run_notify\": \"<string>\",\n \"cron_expression\": \"<string>\",\n \"timezone\": \"<string>\"\n}"
response = http.request(request)
puts response.read_bodySquid
Update Squid
Update squid settings including parameters, concurrency, scheduling, and delivery integrations
POST
/
v1
/
squids
/
{squid_hash}
Update Squid
curl --request POST \
--url https://api.lobstr.io/v1/squids/{squid_hash} \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>' \
--data '
{
"name": "<string>",
"is_active": true,
"concurrency": 123,
"to_complete": true,
"export_unique_results": true,
"no_line_breaks": true,
"run_notify": "<string>",
"cron_expression": "<string>",
"timezone": "<string>"
}
'import requests
url = "https://api.lobstr.io/v1/squids/{squid_hash}"
payload = {
"name": "<string>",
"is_active": True,
"concurrency": 123,
"to_complete": True,
"export_unique_results": True,
"no_line_breaks": True,
"run_notify": "<string>",
"cron_expression": "<string>",
"timezone": "<string>"
}
headers = {
"Authorization": "<authorization>",
"Content-Type": "<content-type>"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<authorization>', 'Content-Type': '<content-type>'},
body: JSON.stringify({
name: '<string>',
is_active: true,
concurrency: 123,
to_complete: true,
export_unique_results: true,
no_line_breaks: true,
run_notify: '<string>',
cron_expression: '<string>',
timezone: '<string>'
})
};
fetch('https://api.lobstr.io/v1/squids/{squid_hash}', 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.lobstr.io/v1/squids/{squid_hash}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'is_active' => true,
'concurrency' => 123,
'to_complete' => true,
'export_unique_results' => true,
'no_line_breaks' => true,
'run_notify' => '<string>',
'cron_expression' => '<string>',
'timezone' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: <content-type>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.lobstr.io/v1/squids/{squid_hash}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"is_active\": true,\n \"concurrency\": 123,\n \"to_complete\": true,\n \"export_unique_results\": true,\n \"no_line_breaks\": true,\n \"run_notify\": \"<string>\",\n \"cron_expression\": \"<string>\",\n \"timezone\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<authorization>")
req.Header.Add("Content-Type", "<content-type>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.lobstr.io/v1/squids/{squid_hash}")
.header("Authorization", "<authorization>")
.header("Content-Type", "<content-type>")
.body("{\n \"name\": \"<string>\",\n \"is_active\": true,\n \"concurrency\": 123,\n \"to_complete\": true,\n \"export_unique_results\": true,\n \"no_line_breaks\": true,\n \"run_notify\": \"<string>\",\n \"cron_expression\": \"<string>\",\n \"timezone\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.lobstr.io/v1/squids/{squid_hash}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<authorization>'
request["Content-Type"] = '<content-type>'
request.body = "{\n \"name\": \"<string>\",\n \"is_active\": true,\n \"concurrency\": 123,\n \"to_complete\": true,\n \"export_unique_results\": true,\n \"no_line_breaks\": true,\n \"run_notify\": \"<string>\",\n \"cron_expression\": \"<string>\",\n \"timezone\": \"<string>\"\n}"
response = http.request(request)
puts response.read_bodyThis endpoint updates an existing squid’s settings using its hash ID. You can configure crawler parameters, execution settings, scheduling, notifications, and data delivery integrations.
Squid Settings
string
Display name for the squid. Example:
"My Custom Squid"boolean
Enable (true) or disable (false) the squid. Example:
trueinteger
Number of concurrent tasks to run simultaneously (1-20). Example:
2boolean
Stop after all tasks complete (true) or run until credits exhausted (false). Example:
falseboolean
Export only unique results, removing duplicates. Example:
trueboolean
Remove newlines from exported data. Example:
truestring
Notification preference: null (no notifications), “on_success”, or “on_error”. Example:
"on_success"string
Cron expression for scheduling automated runs. Example:
"0 10 * * *"string
Timezone identifier for schedule execution. Example:
"Europe/Paris"Headers
string
required
Your API authentication token. Value:
Token YOUR_API_KEYstring
required
Must be application/json. Value:
application/jsonQuery Parameters
string
required
The unique identifier (hash) of the squid to update. Example:
e86b29c032024b66aff529e1d43c2bd7The params object structure depends on the crawler. Use Get Crawler Parameters endpoint to see available options before updating.
Optional function parameters (in params.functions) cost extra credits per row. Check the crawler details for pricing.
Setting is_active to false will prevent the squid from running. Use this to temporarily pause a squid without deleting it.
You can update just one field at a time - send only the fields you want to change. Other settings remain unchanged.
Use cron_expression and timezone to schedule recurring runs. Common patterns: ‘0 9 * * *’ (daily at 9am), ‘0 0 * * 0’ (weekly on Sunday).
Code Examples
curl -X POST "https://api.lobstr.io/v1/squids/e86b29c032024b66aff529e1d43c2bd7" \
-H "Authorization: Token YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Updated Squid Name",
"concurrency": 2,
"is_active": true,
"params": {
"max_results": 150,
"functions": {
"extract_emails_from_website": true,
"collect_business_details": true,
"fetch_business_images": false
},
"ratings": "4.0+",
"country": "United States",
"language": "English (United States)"
},
"run_notify": "on_success"
}'
import requests
squid_id = "e86b29c032024b66aff529e1d43c2bd7"
url = f"https://api.lobstr.io/v1/squids/{squid_id}"
headers = {
"Authorization": "Token YOUR_API_KEY",
"Content-Type": "application/json"
}
payload = {
"name": "Updated Squid Name",
"concurrency": 2,
"is_active": True,
"params": {
"max_results": 150,
"functions": {
"extract_emails_from_website": True,
"collect_business_details": True,
"fetch_business_images": False
},
"ratings": "4.0+",
"country": "United States",
"language": "English (United States)"
},
"run_notify": "on_success"
}
response = requests.post(url, headers=headers, json=payload)
result = response.json()
print(f"Squid updated successfully!")
print(f"Name: {result['name']}")
print(f"Concurrency: {result.get('concurrency', 'N/A')}")
print(f"Notifications: {result.get('run_notify', 'None')}")
Response
200
{
"name": "Updated Squid Name",
"no_line_breaks": true,
"is_active": true,
"params": {
"max_results": 150,
"functions": {
"extract_emails_from_website": true,
"collect_business_details": true,
"fetch_business_images": false
},
"ratings": "4.0+",
"country": "United States",
"language": "English (United States)"
},
"to_complete": false,
"run_notify": "on_success",
"export_unique_results": true
}
⌘I