Skip to main content
POST
/
v1
/
squids
/
{squid_hash}
Link Account to Squid
curl --request POST \
  --url https://api.lobstr.io/v1/squids/{squid_hash} \
  --header 'Authorization: <authorization>' \
  --header 'Content-Type: <content-type>' \
  --data '
{
  "accounts": [
    {}
  ]
}
'

Documentation Index

Fetch the complete documentation index at: https://docs.lobstr.io/llms.txt

Use this file to discover all available pages before exploring further.

Some scrapers require a connected platform account to run (LinkedIn, Facebook, Sales Navigator, etc.). Link one or more accounts to a squid by passing their hash IDs in the accounts array when updating the squid.
Only scrapers that require authentication have an accounts field. For public scrapers (Google Maps, Trustpilot, etc.) this field is ignored.

Headers

Authorization
string
required
Your API authentication token. Value: Token YOUR_API_KEY
Content-Type
string
required
Request body format. Value: application/json

Path Parameters

squid_hash
string
required
The hash of the squid to update

Body Parameters

accounts
array
required
Array of account hash strings to link to the squid. Pass an empty array [] or null to remove all linked accounts. Each hash must correspond to an account of the correct type for the scraper.

How to find your account hash

Use List Accounts to retrieve your connected accounts and their id (hash) values:
curl -X GET "https://api.lobstr.io/v1/accounts" \
  -H "Authorization: Token YOUR_API_KEY"
The id field in each account object is the hash you pass in the accounts array.

Code Examples

curl -X POST "https://api.lobstr.io/v1/squids/YOUR_SQUID_HASH" \
  -H "Authorization: Token YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "accounts": ["YOUR_ACCOUNT_HASH"]
  }'

Response

200
{
  "name": "LinkedIn Leads Scraper (1)",
  "concurrency": 1,
  "accounts": ["YOUR_ACCOUNT_HASH"]
}

Removing linked accounts

Pass an empty array to unlink all accounts from a squid:
curl -X POST "https://api.lobstr.io/v1/squids/YOUR_SQUID_HASH" \
  -H "Authorization: Token YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"accounts": []}'

Errors

ErrorCause
AccountDoesNotExistOne of the account hashes was not found or doesn’t belong to you
InvalidParamTypeaccounts is not an array, or contains non-string values