From e5846c03ba06f8feea66a78bc2fde8c3fbf602e6 Mon Sep 17 00:00:00 2001 From: Lyra Date: Sun, 7 Feb 2021 14:44:28 +0100 Subject: [PATCH] Attempt to fix LeBonCoinBridge --- bridges/LeBonCoinBridge.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/bridges/LeBonCoinBridge.php b/bridges/LeBonCoinBridge.php index fc1432e3..372ff25c 100644 --- a/bridges/LeBonCoinBridge.php +++ b/bridges/LeBonCoinBridge.php @@ -352,12 +352,14 @@ class LeBonCoinBridge extends BridgeAbstract { public function collectData(){ - $url = 'https://api.leboncoin.fr/finder/search/'; + $url = 'https://api.leboncoin.fr/api/adfinder/v1/search'; $data = $this->buildRequestJson(); $header = array( - 'User-Agent: LBC;Android;Null;Null;Null;Null;Null;Null;Null;Null', + 'User-Agent: LBC;Android;10;SAMSUNG;phone;0aaaaaaaaaaaaaaa;wifi;8.24.3.8;152437;0', 'Content-Type: application/json', + 'X-LBC-CC: 7', + 'Accept: application/json,application/hal+json', 'Content-Length: ' . strlen($data), 'api_key: ' . self::$LBC_API_KEY );