Skip to content
A Python client to access the Emploi Store Dev API: https://www.emploi-store-dev.fr
Branch: master
Clone or download

README.md

Emploi Store Dev is a platform setup by Pôle Emploi, the French unemployment agency, to share their public data.

This is a Python client library for their API.

The library is in emploi_store and works both in Python 2 and Python 3. Usage information and required environment variables is documented in the library's docstring.

Examples on how to use it is are in:

  • example.py for a server using multiple calls to the API.
  • csv_example.py for a simpele download of a CSV from the API.

Installation

The library is released on PyPi thus can be installed with pip:

pip install python-emploi-store

That's all, then you just need to use:

import emploi_store

in your code.

API Key

This client library doesn't provide direct access to the data. To use it, you need to get a client ID and client secret from Emploi Store Dev.

As documented on their website you need to:

  • Sign-in or create a new account
  • Go to your dashboard
  • Add an application, check Oui to the question Utilisation de l’API Pôle emploi and agree to the terms of use
  • The client ID and secret are then available as Identifiant client and Clé secrète

Development

If you want to contribute, make sure to send us a Pull Request with tests. To setup a test environment we generally use Docker to isolate the tests.

  • In a terminal, start a container and set the dev environment. Note that you need one environment for Python 2 and another for Python 3. You can have several ran in parallel if needed.
docker run --rm -it -v $(pwd):/work/:ro -w /work/ python:3 bash
pip install .[dev]
  • Run the tests, and automatically re-run them when files are changed:
nosetests --with-watch
  • Now you can edit the files and monitor the terminal.

  • To stop watching the tests, hit Ctrl-C in the terminal. Then to exit the Docker container, hit Ctrl-D.

Release

To release a new version of the library:

  • Make sure the Changelog file is up to date.
  • Update the version number in setup.py.
  • Tag the code with git.
  • Build and upload the package to PyPi:
python setup.py sdist upload
You can’t perform that action at this time.