Panels and Endpoints

Hey folks, hope all is well tonight. Lets get right to the updates!

Color Panels

I spoke with my supplier today and we are good to go for the colored panels. I most likely will not have the remaining color samples until the end of the week. At that point I will take some pics and send them out in an update. From there you will have access to a form to update your order with your panel selection. If you're happy with white panels you can simply ignore this, no need to update any info.

API Endpoints

I've started uploading a bunch of endpoints to the github. These are currently just tiny stand-alone Flask apps. I will be combining them into a single Flask app over the next couple of days.

Flask is a Python Micro Framework that simplifies API creation and lots of other common development tasks.

An endpoint at it's most basic is just a URL. You can hit that URL to get some data or start an action. More importantly, you can write other software to utilize those URLs for all kinds of integrations and new functionality.

Here is an example showing the endpoint that gets a user's Brew Settings:

  By appending the userId to this endpoint's URL, you can get all of that user's brew settings.

By appending the userId to this endpoint's URL, you can get all of that user's brew settings.

And here is the app's response:

  Easy peasy data retrieval!

Easy peasy data retrieval!

Now I know that doesn't look very pretty but this response is only meant to be read by other bits of code. And since it's all formatted as JSON it is super easy to integrate into other applications. 

Once you have some brew settings you can then send a brewSettingId to the startBrewing endpoint and Mugsy will start making your coffee with those settings.

  Add a settings ID and make some robot coffee!

Add a settings ID and make some robot coffee!

So, this obviously make it super easy for Mugsy to control itself. But more importantly, it opens up Mugsy's functionality to any other piece of code or application. From having your phone's GPS trigger a fresh cup when you get home from work all the way to having Mugsy know when that baby monitor starts screaming at 4 AM. The possibilities are literally endless. Literally. For real.

These types of niche integrations will not be ready to go right when you first get your Mugsy. But by giving our users and developers these tools, new functionality will be coming out constantly. I really can't wait to see what people come up with once their brains start storming.

The endpoints are available on the GitHub athttps://github.com/margyle/MugsyDev/tree/master/endpoints

These endpoint files are only half of the equation and each require a specific function to work correctly.  I'll be continually uploading endpoints and functions over the next 48 hours. I have also added a 'Helpers' directory. This will have one off scripts and hacks that may not have their own endpoint just yet.

OK, thats it for now. I am almost done with the disk images as well, just need to finish up the first boot Wifi config to simplify getting Mugsy on your home's network. next update will be on Wednesday!

Cheers,

-m 

MComment