APIAPI reference
Accounts
Your own accounts on the sites some operations need: connect, list, read, remove.
Connect an account
POST
https://api.lobstr.io/v2/accountsConnect one of your accounts on a site, from the cookies of a browser logged in to it. The site checks them at once; the account is kept only once it accepted them.
Bodysite"leboncoin" | "x"requiredcookiesobject | object[]requiredThe site's cookies from a browser where you are logged in: {name: value}, or a cookie editor's export (a list of {name, value, domain}).
countrystringThe country you use the account from (FR, US). Left out, the country of the IP this call comes from: right from your browser, wrong from a server elsewhere, where you say it. A site of one country sets its own.
201: The account, connected. 200: The same login connected again: its session replaced, its id kept.
object"account"requiredidstringrequiredacc_...
site"leboncoin" | "x"requirednamestringrequiredThe login as the site shows it.
status"ok" | "paused" | "expired"requiredok: ready. paused: the site slowed it down; it comes back by itself at
paused_until. expired: the site logged it out; connect it again.countrystring | nullISO 3166-1 alpha-2: its calls go out from an IP of this country and no other. Null for a site of one country, which sets it.
paused_untilstring | nullcreated_atstringlast_used_atstring | nullAnything else answers an error.
curl -X POST https://api.lobstr.io/v2/accounts \ -H "Authorization: Bearer $LOBSTR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "site": "x", "cookies": { "auth_token": "...", "ct0": "..." }, "country": "FR" }'
List your accounts
GET
https://api.lobstr.io/v2/accountsYour connected accounts.
ParameterssitestringqueryOnly this site's accounts.
object"list"requiredhas_morebooleanrequireddataAccount[]requiredAnything else answers an error.
curl https://api.lobstr.io/v2/accounts \ -H "Authorization: Bearer $LOBSTR_API_KEY"
Read an account
GET
https://api.lobstr.io/v2/accounts/{account_id}One of your connected accounts.
Parametersaccount_idstringpathrequiredobject"account"requiredidstringrequiredacc_...
site"leboncoin" | "x"requirednamestringrequiredThe login as the site shows it.
status"ok" | "paused" | "expired"requiredok: ready. paused: the site slowed it down; it comes back by itself at
paused_until. expired: the site logged it out; connect it again.countrystring | nullISO 3166-1 alpha-2: its calls go out from an IP of this country and no other. Null for a site of one country, which sets it.
paused_untilstring | nullcreated_atstringlast_used_atstring | nullAnything else answers an error.
curl https://api.lobstr.io/v2/accounts/acc_7Hq2Kd9mX4pL \ -H "Authorization: Bearer $LOBSTR_API_KEY"
Remove an account
DELETE
https://api.lobstr.io/v2/accounts/{account_id}Remove one of your accounts, its session with it.
Parametersaccount_idstringpathrequiredobject"account"requiredidstringrequireddeletedtruerequiredAnything else answers an error.
curl -X DELETE https://api.lobstr.io/v2/accounts/acc_7Hq2Kd9mX4pL \ -H "Authorization: Bearer $LOBSTR_API_KEY"