Giter Site home page Giter Site logo

naramispresso's Introduction


Naramispresso

Grouped Nespresso Purchase Ordering Framework

Installation

Clone this repository using the following command:

git clone https://github.com/jguillon/naramispresso.git

Setting up the form

Create a Typeform account and create a personal token for the Typeform API. This token will be used once hereafter.

Automatically generate a Naramispresso form by running the following command:

curl --request POST \
     --url https://api.typeform.com/forms \
     --data @naramispresso/typeform.json \
     --header 'Authorization: Bearer <YOUR_PERSONAL_TOKEN>'

Check your Typeform admin panel to see if the form has been successfully created. Save the form id or URL, as it will be useful for sharing it.

Note that the form may not be up-to-date according to the original Nespresso(R) marcket (especially the limited editions section). Make sure of it before sharing it. Plus, it will be empty of any image, you may want to manually add some by using the ones in the img/ folder.

Setting up the mail service provider

Use the following command to copy parameters.template.json in the parameters.json file:

cd naramispresso
cp parameters.template.json parameters.json

Then fill in all the field with your personal information.

If you are using your Gmail account to send emails, follow these instructions to allow naramispresso to use it and optionally get an app-specific password.

Usage

Orders summary

Enter the following command to summurize the orders present in the Typeform's .csv file. The resulting output will allow you to easilly make your grouped order on https://www.nespresso.com.

./naramispresso.py <CSV_FILE>

Sending bills

Once you've done the order, you can send the bill to everyone using the following command:

./naramispresso.py <CSV_FILE> --send --date '<RECEPTION_DATE>'

Note that you must specify the reception date using the --date '<RECEPTION_DATE>' parameter.

Custom the form

If you want to add extra coffee brands to the form, you can. The only requirement is to include its price as a decimal number in the question such as, for example "AMAZING COFFE (42,00โ‚ฌ / 10 Units)". You could have simply put 32987,203838, it would have worked, but no one will know which coffee brand you were talking about.

To-do

  • Use Typeform's API to automatically read the latest orders

naramispresso's People

Contributors

jguillon avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.