jerkins

package module
v0.0.0-...-ea0460e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 22, 2017 License: MIT Imports: 12 Imported by: 0

README

jerkins

An Alexa skill to manage office365 calendars. This project is currently in the conception phase right now, so there's really nothing to see here yet.

feature brainstorm
MVP: What is my next meeting?
  • wire up local development environment for Alexa skill
  • figure out how to query next meeting with api, do it in go
  • make Alexa answer next meeting with hardcoded access token
  • link Alexa account to office365 account with oauth, use it
  • hosting: host app build pipeline on ecs how keith is doing it
Other Skill Features
  • When is my next meeting?
  • When is my next meeting with (x)
  • Set up (meeting type) meeting with (x) (asap/this week/next week), book a room/ x's office.
  • Reserve (some time, an hour, etc) (today, this week, next week) for (x), invite X, book room Y
  • link multiple accounts, allow different office occupants to identify themselves and make appointments as themselves.
local development

set up your $GOPATH and clone the repo:

export GOPATH="$HOME/dev/funtastic/branches/gopath"
git clone git@github.com:froderick/jerkins.git $GOPATH/src/github.com/froderick/jerkins

run the skill server locally:

cd $GOPATH/src/github.com/froderick/jerkins
go get
go build cmd/server/*
./jerkins

set up localtunnel so alexa can reach it:

npm install -g localtunnel
lt --port 8000

lt will print out the public https url your skill server is exposed on:

your url is: https://${something}.localtunnel.me

Documentation

Overview

Everything that's not alexa-related goes here for now.

Index

Constants

View Source
const (
	GraphBaseUrl = "https://graph.microsoft.com/"
	EventsApi    = GraphBaseUrl + "v1.0/me/events/?"
)
View Source
const (
	DateTimeFormat = "2006-01-02T15:04:05.0000000"
)
View Source
const (
	TOKEN_PATH = "token.json"
)

Variables

This section is empty.

Functions

func Client

func Client() (*http.Client, error)

func ContainsAttendee

func ContainsAttendee(event EventSummary, name string) bool

func LoadToken

func LoadToken() (*oauth2.Token, error)

func OAuthConfig

func OAuthConfig() *oauth2.Config

func QueryEventsPage

func QueryEventsPage(client *http.Client, url string) *events

func SaveToken

func SaveToken(t *oauth2.Token) error

func TestIntentHandler

func TestIntentHandler(echoReq *alexa.EchoRequest, echoResp *alexa.EchoResponse)

Types

type Attendee

type Attendee struct {
	Email  Email
	Status Status
}

type Email

type Email struct {
	Address string
	Name    string
}

type EventSummary

type EventSummary struct {
	Start     time.Time
	End       time.Time
	Attendees []Attendee
	Subject   string
}

func QueryAllFutureEvents

func QueryAllFutureEvents(client *http.Client) ([]EventSummary, error)

func QueryEvents

func QueryEvents(client *http.Client, query string) ([]EventSummary, error)

type Status

type Status struct {
	Response string
	Time     string
}

Directories

Path Synopsis
cmd
calendars
Here I'm experimenting with fetching calendar data.
Here I'm experimenting with fetching calendar data.
server
The main entrypoint for the alexa skill server.
The main entrypoint for the alexa skill server.
xml

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL