Metadata-Version: 2.0
Name: addok-csv
Version: 1.0.0rc1
Summary: Add CSV support to your Addok instance.
Home-page: https://github.com/etalab/addok-csv
Author: Yohan Boniface
Author-email: yohan.boniface@data.gouv.fr
License: WTFPL
Keywords: addok geocoding csv plugin
Platform: UNKNOWN
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Topic :: Scientific/Engineering :: GIS
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.4
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
Requires-Dist: addok
Requires-Dist: falcon-multipart (==0.1.0)
Provides-Extra: test
Requires-Dist: pytest; extra == 'test'

# Addok plugin add CSV geocoding endpoints

## Install

    pip install addok-csv

## API

This plugin adds the following endpoints:


- /search/csv
- /reverse/csv

### Query parameters

- data: the CSV file to process
- delimiter (optional): the CSV delimiter (`,` or `;`); if not given, we try to
  guess
- quote (optional): CSV quote
- encoding (optional): the encoding of the file (default to 'utf-8-sig')
- columns (multiple): the columns, ordered, to be used for geocoding; if no
  column is given, all columns will be used
- with_bom: if true, and if the encoding if utf-8, the returned CSV will contain
  a BOM (for Excel users…)
- lat/lon (optional): center to bias the search

Any filter can be passed as `key=value` querystring, where `key` is the filter
name and `value` is the column name containing the filter value for each row.
For example, if there is a column "code_insee" and we want to use it for
"citycode" filtering, we would pass `citycode=code_insee` as query string
parameter.

## Config

- CSV_ENCODING: default encoding to open CSV files (default: 'utf-8-sig')


