Skip to content
Unofficial Wunderlist API client library and CLI, written in go/golang.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
bin
cmd/wl
integration_tests
logger
oauth
vendor
.gitignore
.travis.yml
LICENSE
README.md
client.go
file.go
file_preview.go
folder.go
folder_revision.go
glide.lock
glide.yaml
list.go
list_task_count.go
membership.go
note.go
position.go
reminder.go
root.go
subtask.go
task.go
task_comment.go
upload.go
user.go
webhook.go
wundergo.go

README.md

DEPRECATED

This repository is unmaintained and deprecated. Use at your own risk; it is likely no longer functional.

wl

Unofficial Wunderlist API client library and CLI, written in golang.

Copyright © 2014-2016, Robert Dimsdale. Licensed under the MIT License.

Why?

  • The library provides access to all of the endpoints documented in the official API docs, plus additional useful methods like inbox and delete-all-tasks.
  • The CLI is written in golang, which results in an statically-compiled CLI.

Library

Install the library with:

go get gopkg.in/robdimsdale/wl.v1

or

go get github.com/robdimsdale/wl

Usage

Create an instance of wl.Client using e.g. oauth.NewClient() as follows:

import (
  "fmt"

  "github.com/robdimsdale/wl"
  "github.com/robdimsdale/wl/logger"
  "github.com/robdimsdale/wl/oauth"
)

func main() {
  client := oauth.NewClient(
    "my_access_token",
    "my_client_id",
    wl.APIURL,
    logger.NewLogger(logger.INFO),
  )

  // Ignore error
  inbox, _ := client.Inbox()
  fmt.Printf("Inbox: %v\n", inbox)
}

Supported Golang versions

The code is tested against the latest patch versions of the most recent minor and the previous minor versions of golang.

Branches

The develop branch is where active development takes place; it is not guaranteed that any given commit will be stable.

The master branch points to a stable commit. All tests should pass.

CLI Binary

A CLI is provided with support for some utility functions (e.g. list all tasks, delete all folders).

Installation

Binaries are available on the releases page for various operating systems and architectures.

Download the binary and place in the PATH.

OSX

A homebrew tap is available; install the binary with:

brew tap robdimsdale/tap
brew install wl

Usage

Access token and client id are required. Provide them via flags (--accessToken and --clientID) or with environment variables (WL_ACCESS_TOKEN or WL_CLIENT_ID)

$ wl inbox --accessToken my_access_token --clientID my_client_id
id: 123456789
title: inbox
created_at: 2014-08-29T19:45:34.98Z
list_type: inbox
revision: 53538
type: list
public: false

$ WL_ACCESS_TOKEN=my_access_token WL_CLIENT_ID=my_client_id wl create-task --list-id 123456789 --title "some new title"
id: 987654321
[...]
list_id: 123456789
title: some new title
completed: false

Development

Go dependencies

The library has no dependencies.

The CLI binary vendors its dependencies in the vendor directory according to the golang specification.

Running the tests

Running the tests will require ginkgo.

Execute the unit tests with:

./scripts/unit-tests

The integration tests require the following environment variables to be set: WL_CLIENT_ID and WL_ACCESS_TOKEN. Values for these are obtained via the method documented at https://developer.wunderlist.com/documentation/concepts/authorization.

In the cloned directory run the following command:

WL_CLIENT_ID=my_client_id WL_ACCESS_TOKEN=my_access_token ./scripts/integration_tests

Project administration

Tracker

CI

You can’t perform that action at this time.