From 2534bf761c6c14923ef21ced9028ef6c118f1fed Mon Sep 17 00:00:00 2001 From: Yasuhiro Matsumoto Date: Thu, 13 Apr 2017 16:48:45 +0900 Subject: [PATCH] add README.md --- README.md | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..fb4e906 --- /dev/null +++ b/README.md @@ -0,0 +1,35 @@ +# go-mastodon + +***EXPERIMENTAL*** + +## Usage + +```go +c := mastodon.NewClient(&mastodon.Config{ + Server: "https://mstdn.jp", + ClientID: "client-id", + ClientSecret: "client-secret", +}) +err := c.Authenticate("your-username", "your-password") +if err != nil { + log.Fatal(err) +} +timeline, err := c.GetTimeline("/api/v1/timelines/home") +if err != nil { + log.Fatal(err) +} +``` + +## Installation + +``` +$ go get github.com/mattn/go-mastodon +``` + +## License + +MIT + +## Author + +Yasuhiro Matsumoto (a.k.a. mattn)