https://github.com/nathan-osman/go-seapi
Stack Exchange API client for Go
https://github.com/nathan-osman/go-seapi
api golang stack-exchange
Last synced: 3 months ago
JSON representation
Stack Exchange API client for Go
- Host: GitHub
- URL: https://github.com/nathan-osman/go-seapi
- Owner: nathan-osman
- License: mit
- Created: 2017-03-14T02:00:44.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2017-03-14T18:18:50.000Z (over 9 years ago)
- Last Synced: 2024-12-31T19:16:03.479Z (over 1 year ago)
- Topics: api, golang, stack-exchange
- Language: Go
- Size: 3.91 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
## go-seapi
[](https://godoc.org/github.com/nathan-osman/go-seapi)
[](http://opensource.org/licenses/MIT)
This package provides a simple way to access the Stack Exchange API.
### Example
This example fetches a list of recent questions on Stack Overflow and displays their titles:
package main
import (
"log"
"fmt"
"github.com/nathan-osman/go-seapi"
)
func main() {
v, err := seapi.NewRequest("/questions").Site("stackoverflow").Do()
if err != nil {
log.Fatal(err)
}
for _, i := range v.List("items") {
fmt.Println(i.String("title"))
}
}