Giter Club home page Giter Club logo

sdk-php-leboncoin's Introduction

SDK PHP LEBONCOIN

Build Status

SDK du plus célèbre site entre particuliers en France

  • Recherche d'annonces via plusieurs paramètres
    • Mot clé
    • Titre seulement
    • Catégorie
    • Localisations
    • Le tri par prix ou temps (ascendant, descendant)
    • Seulement les professionnels ou particuliers
    • Indiquer la page de recherche
  • Rechercher toutes les annonces d'un utilisateur
  • (A venir) Rechercher toutes les annonces par rapport a des coordonnées GPS
  • Connexion de l'utilisateur
    • Récuperer toutes les informations du compte
    • Rechercher toutes ses annonces
    • Gérer le compte

Installation

composer require absmoca/leboncoin

Documentation

Pour commencer

require __DIR__ . '/vendor/autoload.php';

use Absmoca\Leboncoin;

Récuperer les annonces

$params = array(
    "query" => "Oeuvre d'art"
);

$lbc = new Leboncoin();
$annonces = $lbc->getAnnonces($params);

Options

$params = array(
    "query" => "Oeuvre d'art",
    "title_only" => true,
    "category" => Leboncoin::searchCategory("Décoration")->id,
    "location" => array(
        Leboncoin::searchLocation("Montpellier", true),
        Leboncoin::searchLocation("Paris", true)
    ),
    "sortby" => array("price" => "desc"),
    "particuliers" => false
);

Limiter le nombre de résultats

$lbc = new Leboncoin();
$lbc->setResultLimit(10);

Annonces d'un utilisateur

$params = array(
    "sortby" => array("price" => "asc")
);

$lbc = new Leboncoin();
$annonces = $lbc->getAnnoncesUser("a2db2eb9-6330-4ad7-9442-a1SJ09c9f236", $params);

Récupérer une annonce

$lbc = new Leboncoin();
$annonce = $lbc->getAnnonce(1512169842);

Connexion au compte

$lbc = new Leboncoin();
$lbc->login('[email protected]', 'pasSworD1289');

Cauquil Thomas | https://thomascauquil.fr

Written with StackEdit.

sdk-php-leboncoin's People

Contributors

et3rnel avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.