# Operation Trousers

We're trying to help educate people about shorts, because they're important. The end result us a simple and informative webpage, coupled with beautiful visualizations from real data. Come check it out!

![Men In Shorts](https://res.cloudinary.com/devpost/image/fetch/s--fsMpZYq7--/c_limit,f_auto,fl_lossy,q_auto:eco,w_900/http://ak-hdl.buzzfed.com/static/2014-08/1/5/enhanced/webdr08/enhanced-buzz-wide-15634-1406883700-16.jpg)
## Inspiration

After our initial hack failed, and with only 12 hours of time remaining, we decided to create a proof-of-concept that was achievable in the time remaining. As Twilio was a sponsor, we had the idea of using SMS to control a video game. We created Hackermon to demonstrate how this technology has potential, and as a proof-of-concept of more practical uses.

## What it does

Controlled entirely via SMS, two players can select a knockoff Pokemon and fight each other, with the ability to block or attack. The game is turn based, and has checks to ensure the person texting the API is the correct person, so cheating is effectively impossible.

## How we built it

The backend is built with Node.js and Express.js, with SMS controls made possible with Twilio's API. The frontend is built in HTML, CSS, JavaScript and jQuery and uses AJAX to constantly poll the backend for updates.

## Challenges we ran into

Sleep deprivation was a major challenge that affected us. Trying to focus on learning a new API and developing with a new framework was very challenging after being awake for 22 hours. However, having to prototype something so rapidly was very rewarding - we had to carefully prioritise and cut features in order to create a demoable product in time.

## What we learned

Our initial idea for a project involved using Facebook's Instant Game API. We discovered that many of Facebook's APIs aren't as documented as we expected, and some of their post-Cambridge Analytica security features can cause major unexpected issues.

This was the first time we'd ever used the Twilio API, and it was great to learn how powerful the platform is. Initially, we'd never had to handle getting requests from the backend to the frontend in Node.js before, so managing to get this to work consistently was amazing - even though we know it's not done in the most efficient way.

## What's next for Hackermon

While the game itself is only a basic proof-of-concept, the mechanic of using SMS to control a game has many applications. For example, a quiz webapp used in university classes could accept inputs via SMS rather than requiring students to download a clunky and badly designed app.
## Inspiration

Have you ever wanted to search something, but aren't connected to the internet? Data plans too expensive, but you really need to figure something out online quick? Us too, and that's why we created an application that allows you to search the internet without being connected.

## What it does

Text your search queries to (705) 710-3709, and the application will text back the results of your query.

Not happy with the first result? Specify a result using the `--result [number]` flag.

Want to save the URL to view your result when you are connected to the internet? Send your query with `--url` to get the url of your result.

Send `--help` to see a list of all the commands.

## How we built it

Built on a **Nodejs** backend, we leverage **Twilio** to send and receive text messages. When receiving a text message, we send this information using **RapidAPI**'s **Bing Search API**.

Our backend is **dockerized** and deployed continuously using **GitHub Actions** onto a **Google Cloud Run** server. Additionally, we make use of **Google Cloud's Secret Manager** to not expose our API Keys to the public.

Internally, we use a domain registered with **domain.com** to point our text messages to our server.

## Challenges we ran into

Our team is very inexperienced with Google Cloud, Docker and GitHub Actions so it was a challenge needing to deploy our app to the internet. We recognized that without deploying, we would could not allow anybody to demo our application.

* There was a lot of configuration with permissions, and service accounts that had a learning curve. Accessing our secrets from our backend, and ensuring that the backend is authenticated to access the secrets was a huge challenge.

We also have varying levels of skill with JavaScript. It was a challenge trying to understand each other's code and collaborating efficiently to get this done.

## Accomplishments that we're proud of

We honestly think that this is a really cool application. It's very practical, and we can't find any solutions like this that exist right now. There was not a moment where we dreaded working on this project.

This is the most well planned project that we've all made for a hackathon. We were always aware how our individual tasks contribute to the to project as a whole. When we felt that we were making an important part of the code, we would pair program together which accelerated our understanding.

Continuously deploying is awesome! Not having to click buttons to deploy our app was really cool, and it really made our testing in production a lot easier. It also reduced a lot of potential user errors when deploying.

## What we learned

Planning is very important in the early stages of a project. We could not have collaborated so well together, and separated the modules that we were coding the way we did without planning.

Hackathons are much more enjoyable when you get a full night sleep :D.

## What's next for NoData

In the future, we would love to use AI to better suit the search results of the client. Some search results have a very large scope right now.

We would also like to have more time to write some tests and have better error handling.