Inspiration

We have a problem! We have a new generation of broke philanthropists.

The majority of students do not have a lot of spare cash so it can be challenging for them to choose between investing in their own future or the causes that they believe in to build a better future for others.

On the other hand, large companies have the capital needed to make sizeable donations but many of these acts go unnoticed or quickly forgotten.

What it does

What if I told you that there is a way to support your favourite charities while also saving money? Students no longer need to choose between investing and donating!

Giving tree changes how we think about investing. Giving tree focuses on a charity driven investment model providing the ability to indulge in philanthropy while still supporting your future financially.

We created a platform that connects students to companies that make donations to the charities that they are interested in. Students will be able to support charities they believe in by investing in companies that are driven to make donations to such causes.

Our mission is to encourage students to invest in companies that financially support the same causes they believe in. Students will be able to not only learn more about financial planning but also help support various charities and services.

How we built it

Backend

The backend of this application was built using python. In the backend, we were able to overcome one of our largest obstacles, that this concept has never been done before! We really struggled finding a database or API that would provide us with information on what companies were donating to which charities.

So, how did we overcome this? We wanted to avoid having to manually input the data we needed as this was not a sustainable solution. Additionally, we needed a way to get data dynamically. As time passes, companies will continue to donate and we needed recent and topical data.

Giving Tree overcomes these obstacles using a 4 step process:

  1. Using a google search API, search for articles about companies donating to a specified category or charity.
  2. Identify all the nouns in the header of the search result.
  3. Using the nouns, look for companies with data in Yahoo Finance that have a strong likeness to the noun.
  4. Get the financial data of the company mentioned in the article and return the financial data to the user.

This was one of our greatest accomplishments of this project. We were able to overcome and obstacle that almost made us want to do a different project. Although the algorithm can occasionally produce false positives, it works more often than not and allows for us to have a self-sustaining platform to build off of.

Flask

```shell script $ touch application.py

from flask import Flask application = Flask(name) @application.route('/') def hello_world(): return 'Hello World'

```shell script
$ export FLASK_APP="application.py"
$ flask run

Now runs locally:
http://127.0.0.1:5000/

AWS Elastic Beanstalk

Create a Web Server Environment: ```shell script AWS -> Services -> Elastic beanstalk Create New Application called hack-western-8 using Python Create New Environment called hack-western-8-env using Web Server Environment

### AWS CodePipeline

Link to Github for Continuous Deployment:
```shell script
Services -> Developer Tools -> CodePipeline
Create Pipeline called hack-western-8
GitHub Version 2 -> Connect to Github
Connection Name -> Install a New App -> Choose Repo Name -> Skip Build Stage -> Deploy to AWS Elastic Beanstalk

This link is no longer local:
http://hack-western-8-env.eba-a5injkhs.us-east-1.elasticbeanstalk.com/

AWS Route 53

Register a Domain: ```shell script Route 53 -> Registered Domains -> Register Domain -> hack-western-8.com -> Check Route 53 -> Hosted zones -> Create Record -> Route Traffic to IPv4 Address -> Alias -> Elastic Beanstalk -> hack-western-8-env -> Create Records Create another record but with alias www.

Now we can load the website using:<br/>
[hack-western-8.com](http://hack-western-8.com)<br/>
www.hack-western-8.com<br/>
http://hack-western-8.com<br/>
http://www.hack-western-8.com<br/>
Note that it says "Not Secure" beside the link<br/>

### AWS Certificate Manager

Add SSL to use HTTPS: 
```shell script
AWS Certificate Manager -> Request a Public Certificate -> Domain Name "hack-western-8.com" and "*.hack-western-8.com" -> DNS validation -> Request
$ dig +short CNAME -> No Output? -> Certificate -> Domains -> Create Records in Route 53
Elastic Beanstalk -> Environments -> Configuration -> Capacity -> Enable Load Balancing
Load balancer -> Add listener -> Port 443 -> Protocol HTTPS -> SSL certificate -> Save -> Apply

Now we can load the website using:
https://hack-western-8.com
https://www.hack-western-8.com
Note that there is a lock icon beside the link to indicate that we are using a SSL certificate so we are secure

Challenges we ran into

The most challenging part of the project was connecting the charities to the companies. We allowed the user to either type the charity name or choose a category that they would like to support. Once we knew what charity they are interested in, we could use this query to scrape information concerning donations from various companies and then display the stock information related to those companies. We were able to successfully complete this query and we can display the donations made by various companies in the command line, however further work would need to be done in order to display all of this information on the website. Despite these challenges, the current website is a great prototype and proof of concept!

Accomplishments that we're proud of

We were able to successfully use the charity name or category to scrape information concerning donations from various companies. We not only tested our code locally, but also deployed this website on AWS using Elastic Beanstalk. We created a unique domain for the website and we made it secure through a SSL certificate.

What we learned

We learned how to connect Flask to AWS, how to design an eye-catching website, how to create a logo using Photoshop and how to scrape information using APIs.

We also learned about thinking outside the box. To find the data we needed we approached the problem from several different angles. We looked for ways to see what companies were giving to charities, where charities were receiving their money, how to minimize false positives in our search algorithm, and how to overcome seemingly impossible obstacles.

What's next for Giving Tree

Currently, students have 6 categories they can choose from, in the future we would be able to divide them into more specific sub-categories in order to get a better query and find charities that more closely align with their interests.

Health - Medical Research - Mental Health - Physical Health - Infectious Diseases

Environment - Ocean Conservation - Disaster Relief - Natural Resources - Rainforest Sustainability - Global Warming

Human Rights - Women's Rights - Children

Community Development - Housing - Poverty - Water - Sanitation - Hunger

Education - Literacy - After School Programs - Scholarships

Animals - Animal Cruelty - Animal Health - Wildlife Habitats

We would also want to connect the front and back end.

Built With

Share this project:

Updates