A lib to use MyDelivengo API
Project description
pydelivengo
pydelivengo is a Python library using the MyDelivengo API
Documentation
PyDelivengo : https://alexandriagroup.github.io/pydelivengo/
MyDelivengo (La Poste API documentation) : http://www.assistance-mydelivengo.fr/api/
You can find the list of parameters for each function into this documentation.
How to use
api = PyDelivengo(api_authorization="your_mydelivengo_api_key") api.get_user_info() # Get your user info api.get_envois() # get all your "envois" api.get_pli(11437479, print_pdf=True) # Get the "pli" with ID 11437479 and generate PDF to print api.get_depots(params={'date[from]':'30/11/2017'}) # Get the "depots" from November 30th
Looks to MyDelivengo documentation to see all parameters.
Tools
Decode and save PDF from API
An example for decode and save the Base64 Encoded String return by the MyDelivengo API:
import os from base64 import decodebytes with open(os.path.expanduser('path/test.pdf'), 'wb') as f: f.write(decodebytes(api_data.encode('ascii')))
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Filename, size | File type | Python version | Upload date | Hashes |
---|---|---|---|---|
Filename, size pydelivengo-1.4-py3-none-any.whl (5.2 kB) | File type Wheel | Python version py3 | Upload date | Hashes View |
Close
Hashes for pydelivengo-1.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a57e06d91629a48607d5b08c4b0d9788cb19e61dfd94b991c67fb9b6c3ded95c |
|
MD5 | 3cd171d5fb433e9007b628c65d71a9b4 |
|
BLAKE2-256 | 988d49bc4342b2765dded0819e2248f01f0dd0b4e92061c70975f3d7b4840328 |