---
title: 'PiGlow API: one small snap for humanity…'
description: Victor Palau created a very nice blog post around the PiGlow. With his
  permission we are reproducing it here. My first steps into snappifying, I have publish
  a RestApi for PiGlow (glowapi 0.1.2). I though it might be a good first step and
  mildly useful for people wanting to set up build notifications, twitter mentions,  […]
url: https://canonical.com/blog/piglow-api-one-small-snap-for-humanity?format=md
---

1. [Blog](https://canonical.com/blog)
2. Article

---

[Maarten Ectors](https://canonical.com/blog/author/maarten-ectors "More about Maarten Ectors")

16 October 2015

# PiGlow API: one small snap for humanity…

[code](https://canonical.com/blog/tag/code)
[developers](https://canonical.com/blog/tag/developers)
[example](https://canonical.com/blog/tag/example)
[makers](https://canonical.com/blog/tag/makers)
[piglow](https://canonical.com/blog/tag/piglow)
[Ubuntu Core](https://canonical.com/blog/tag/ubuntu-core)

---

Share the article

*Victor Palau created a very nice blog post around the PiGlow. With his permission we are reproducing it here.*

My first steps into snappifying, I have publish a RestApi for PiGlow (glowapi 0.1.2). I though it might be a good first step and mildly useful for people wanting to set up build notifications, twitter mentions, whatever you fancy!

You can find it in the webdm store…
Code is here:<https://code.launchpad.net/~vtuson/+junk/glowapi>

And here is how it works:
PiGlow Api exposes PiGlow in your board port 8000, so you can easy accessing by POST in port 8000.

remeber to do the hardware assign, something like: sudo snappy hw-assign glowapi.vtuson /dev/i2c-1

### **API calls , method POST:**

***v1/flare***
turns all the leds on to max brightness
**v1/on**
turns all the leds on to med brigthness
***v1/clear***
turns off all leds
***v1/legs/:id***
turns all the leds in a leg (:id) to a given brightness
(if not specify it uses a default setting)
parms: intensity , range 0 to 1
eg: <http://localhost:8000/v1/legs/1?intensity=0.3>
***v1/legs/:id/colors/:colid***
turns on one led (colid) in a leg (:id) to a given brightness
(if not specify it uses a default setting)
parms: intensity , range 0 to 1
eg: <http://localhost:8000/v1/legs/1/colors/green?intensity=0.3>
***v1/colors/:colid***
turn on all leds for a color across all legs
if not specify it uses a default setting)
parms: intensity , range 0 to 1
eg: <http://localhost:8000/v1/colors/green?intensity=0.3>

**ID ranges**
legs range : 0 – 2
colors:
green
white
blue
yellow
orange
red

[Get in touch

Interested in running Ubuntu in your organization?](https://ubuntu.com/about/contact-us/form)

## Sign up for our newsletter

Get the latest Canonical news and updates in your inbox.

Work email:

\*I agree to receive information about Canonical's
products and services.

By submitting this form, I confirm that I have read and agree to [Canonical's Privacy Policy](https://canonical.com/legal/dataprivacy).

Sign up

## Share on

---

## Related posts

[### So you need to add microcontrollers to your fleet: now what?](https://canonical.com/blog/microcontrollers-ubuntu-core-golioth)

Your Ubuntu Core fleet is running beautifully. OTA updates roll out in minutes. Every device is strictly confined, cryptographically attested, and carrying a 10 to 15 year long...

[Jonathan Beri](https://canonical.com/blog/author/jmberi)

18 June 2026

[### A look into Ubuntu Core 26: Building a local AI inference appliance in a virtual machine](https://canonical.com/blog/ubuntu-core-26-ai-box)

Welcome to this blog series which explores innovative uses of Ubuntu Core. Throughout this series, Canonical’s Engineers will show what you can build with this Core 26 release,...

[Gabriel Aguiar Noury](https://canonical.com/blog/author/g-aguiar-noury)

16 June 2026

[### A look into Ubuntu Core 26: Deploying AI models on Renesas RZ/V series for production](https://canonical.com/blog/ubuntu-core-26-ai-renesas)

Welcome to this blog series which explores innovative uses of Ubuntu Core. Throughout this series, Canonical’s Engineers will show what you can build with our releases,...

[Gabriel Aguiar Noury](https://canonical.com/blog/author/g-aguiar-noury)

4 June 2026

[### A look into Ubuntu Core 26: Cloud-powered edge computing with AWS IoT Greengrass and Azure IoT Edge](https://canonical.com/blog/ubuntu-core-26-cloud-integration)

Welcome to this blog series which explores innovative uses of Ubuntu Core. Throughout this series, Canonical’s Engineers will show what you can build with this Core 26 release,...

[Gabriel Aguiar Noury](https://canonical.com/blog/author/g-aguiar-noury)

20 May 2026
