0.0
No commit activity in last 3 years
No release in over 3 years
all you need is an item title and you can scrape posts from craigslist
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
 Dependencies

Runtime

>= 1.6.7.1, ~> 1.6
 Project Readme

Craigslister

Build Status Dependency Status Code Climate Test Coverage Gem Version

Scrape Craigslist for Posts.

RubyGems

gem install craigslister

Bundler

gem 'craigslister'

Client

require 'craigslister'

client = Craigslister.new(
  item: 'Couch',
  area: 'austin', # optional (defaults to 'sfbay')
  section: 'mca', # optional (defaults to 'sss')
  low:  500,      # optional
  high: 2000,     # optional
)

The area and section parameters must be valid Craigslist url query strings.

Areas

Area Query
SF bay area 'sfbay'
austin 'austin'
mendincino county 'mendocino'

Sections

Section Query
motorcycles 'mca'
cars & trucks 'cta'
appliances 'ppa'

If you are unsure of what your local area query param may be it can be found in the browser when you navigate to craigslist, the same can be done with section. 'https://sfbay.craigslist.org/search/cta?query=chevy%20chevelle'. Here 'sfbay' would be the area (SF bay area), and 'cta' would be the section (cars & trucks).

Posts

Post objects are instantiated with the data scraped from a single page of a Craigslist post.

# Post objects are instantiated with the data scraped from a single posting on Craigslist
couches = client.posts

# They have various attributes containing relevant post data
couch = couches[0]
couch.title
couch.image
couch.price
couch.location
couch.url
couch.description