Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

olx-scraper

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

olx-scraper

Unofficial OLX Client API / Scraper

  • 1.0.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
decreased by-100%
Maintainers
1
Weekly downloads
 
Created
Source


OLX Unofficial Client API

License: GPL-3.0 license npm versionOpen Source Love svg2

Unofficial Scraper API for OLX.CO.ID

Installation

You can install the package using npm or Yarn:

npm install olx-scraper

or

yarn add olx-scraper

Usage

Logging in

To log in to OLX:

const { OLXClient } = require("olx-scraper");
const client = new OLXClient('your-email@example.com', 'your-password');

client.loginOLX().then(response => {
    console.log(response);
}).catch(error => {
    console.error(error);
});

Fetching User Data

Retrieve user data from OLX by user ID:

client.getUserData(userId, cookie).then(userData => {
    console.log(userData);
}).catch(error => {
    console.error(error);
});

Getting Categories

Get a list of categories available on OLX:

client.getCategory().then(categories => {
    console.log(categories);
}).catch(error => {
    console.error(error);
});

Searching by Category

Search for listings in a specific category:

client.searchbyCategory(categoryId, locationId).then(searchResults => {
    console.log(searchResults);
}).catch(error => {
    console.error(error);
});

Searching for Locations

Search for locations on OLX:

client.searchLocation('location-query').then(locations => {
    console.log(locations);
}).catch(error => {
    console.error(error);
});

Keywords

FAQs

Package last updated on 27 Nov 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc