Skip to content

Latest commit

 

History

History
44 lines (31 loc) · 642 Bytes

README.md

File metadata and controls

44 lines (31 loc) · 642 Bytes

Nanoleaf Go API

Nanoleaf API made in Go (GoLang)

Contents

Installation

$ go get github.com/adnanbrq/nanoleaf

Usage

package main

import (
  "github.com/adnanbrq/nanoleaf"
  "os"
)

func main() {
  url := os.Getenv("nanoleaf_url")
  nano := nanoleaf.NewNanoleaf(url)

  if err := nano.Identity.Flash(); err != nil {
		panic(err)
  }
  
  if err := nano.Effects.Set("Flames"); err != nil {
    panic(err)
  }
}

Dependencies