Skip to content

sxslex/tabela_fipe

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

45 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

tabela_fipe

Join the chat at https://gitter.im/sxslex/tabela_fipe https://travis-ci.org/sxslex/tabela_fipe.svg?branch=master

Simple access library of data from the "Table Fipe".

Vehicle information: Manufacturer, Model, Vehicle, versions and prices.

Installing

For install sxtools, run on terminal:

$ [sudo] cd tabela_fipe
$ [sudo] python setup.py install

Using sxtools

from tabela_fipe import TabelaFipe

tab_fipe = TabelaFipe()

info = tab_fipe.get_modelo(mod_codigofipe='006008-9')

print('Marca: ' + info['mar_text'])
print('Modelo: ' + info['mod_text'])
print('Categoria: ' + info['mod_categoria'])
print('Versoes: ')
for ver in info['versoes']:
    print(
        '\t%s a %s custa %.2f reais ' % (
            ver['ano'],
            ver['combustivel'],
            ver['valor']
        )
    )

Development

Pull requests are very welcomed! Make sure your patches are well tested.

Running the tests

All you need is:

$ nosetests -dsv --with-yanc --with-coverage --cover-package tabela_fipe tests/*.py

About

See information of vehicles

Resources

License

Stars

Watchers

Forks

Packages

No packages published