0.01
No commit activity in last 3 years
No release in over 3 years
Sinesp Client gem.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
 Dependencies

Development

~> 1.13
~> 10.0
~> 3.0

Runtime

~> 0.16.3
 Project Readme

Ruby Sinesp Client

Build Status

This gem provides a client for searching vehicle data based on the license plate from Sinesp database. This data is publicly available at https://www.sinesp.gov.br/sinesp-cidadao. The gem just makes it easier to fetch results, through the same endpoint used by the mobile app.

For a python version, please check this: https://github.com/victor-torres/sinesp-client

Installation

Add this line to your application's Gemfile:

gem 'sinesp_client'

And then execute:

$ bundle

Or install it yourself as:

$ gem install sinesp_client

Usage

require "sinesp_client"
SinespClient.search 'ABC1234'

Returns a hash with basic vehicle data.

Limitations

Sinesp seems to block connections originated from outside of Brazil. TODO: make the gem work with proxy.

Development

After checking out the repo, run bin/setup to install dependencies. Then, run rake spec to run the tests. You can also run bin/console for an interactive prompt that will allow you to experiment.

To install this gem onto your local machine, run bundle exec rake install.

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/fabianoarruda/sinesp_client.

License

The gem is available as open source under the terms of the MIT License.