~thrrgilag/woodstock

woodstock/README.md -rw-r--r-- 1.1 KiB
62b10b5cMorgan McMillian Update for new project location and module name 3 months ago

#woodstock

A client library for pnut.io written in Go

source code - issue tracker - releases - mailing list

#Installation

go get mcmillian.dev/go/woodstock

#Examples

New post

package main

import (
    "fmt"
    "net/url"
    "mcmillian.dev/go/woodstock"
)

func main() {
    client := woodstock.NewClient("<ClientID>","")
    client.SetAccessToken("<AccessToken>")
    text := "Hello pnut.io"
    v := url.Values{}
    v.Set("text", text)
    post, err := client.Post(v)
    if err != nil {
        fmt.Println(err)
    }
    fmt.Println(post.Data.Content.Text)
}

#Contributing

You can open issues and merge requests to this project on GitLab. Patches can also be submitted to the mailing list. For general discussion please join my public chat room at #dev.