Skip to content

A Bucket List is a list of things that one has not done, and intends on doing before he/she 'kicks the bucket'. The application provides a platform where one can list and track such activities.

License

Notifications You must be signed in to change notification settings

e-liyai/cp2-bucketlist

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

44 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status Coverage Status Code Health license PyPI Codacy Badge

Bucketlist

Bucketlist is a Flask API application that helps individuals keep track of that elusive white whale. The application allows users to list activities they'd like to do before they die. This API provides endpoints facilitating registration, login, create and manage bucket lists and their items.

Installation

Clone this repo:

$ git clone https://github.com/https://github.com/Andela-eugene/cp2-bucketlist.git

Change into the bucketlist directory:

$ cd bucketlist

Create the bucketlist vitual environment:

Click on this guide. The link will guide you create and activate the virtual environment

Install the required packages:

$ pip install -r requirements.txt

Set the required environment keys

$ export BUCKETLIST_SECRET_KEY="any_random_string"
$ export BUCKETLIST_SQLALCHEMY_DATABASE_URI='url_of_the_main_bucketlist_database'
$ export TEST_BUCKETLIST_SQLALCHEMY_DATABASE_URI='url_of_the_test_bucketlist_database'

Application Configuration

The run environment associated with the application can either be development, testing or production. The environment dictate how the application will run. This environments are setup in the config.py file.

Usage

Run python manage.py runserver.

Test API

Use an API Client such as Postman or Insomnia to test the endpoints.

API Endpoints

Actions Description Requires Authentication
POST auth/login Log a user in False
POST auth/register Register a new user False
POST api/v1/bucketlists/ Create a new bucketlist True
GET api/v1/bucketlists/ List all created bucketlists True
GET api/v1/bucketlists/<string:bucket_id> get single bucketlist True
PUT api/v1/bucketlists/<string:bucket_id> update single bucketlist True
DELETE api/v1/bucketlists/<string:bucket_id> Delete a single bucketlist True
POST api/v1/bucketlists/<string:bucket_id>/items Create a new item in a bucketlist True
PUT api/v1/bucketlists/update-item/<string:item_id> Update an item in a bucketlist True
DELETE api/v1/bucketlists/items/<string:item_id> Delete an item in a bucketlist True
GET /api/v1/bucketlists/items/<string:bucket_id> Get items in a bucketlist True
GET api/v1/users/ Get all users True
GET api/v1/user/<string:user_id> Get a single user True
PUT api/v1/user/<string:user_id> Update a user True
DELETE api/v1/delete_user/<string:user_id> Delete a user True

Built With...

License

The MIT License (MIT)

Copyright (c) 2017 Eugene Liyai.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

About

A Bucket List is a list of things that one has not done, and intends on doing before he/she 'kicks the bucket'. The application provides a platform where one can list and track such activities.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages