AYLIEN's officially supported Go client library for accessing Text API
Go
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
LICENSE
README.md
classify.go
combined.go
concepts.go
entities.go
extract.go
hashtags.go
images.go
language.go
microformats.go
related.go
sentiment.go
summarize.go
textapi.go
textapi_test.go

README.md

About

This is the Go client library for AYLIEN's APIs. If you haven't already done so, you will need to sign up.

Installation

To install, simply use go get:

$ go get github.com/AYLIEN/aylien_textapi_go

See the Developers Guide for additional documentation.

Example

package main

import (
    "fmt"
    textapi "github.com/AYLIEN/aylien_textapi_go"
)

func main() {
    auth := textapi.Auth{"YourApplicationId", "YourApplicationKey"}
    client, err := textapi.NewClient(auth, true)
    if err != nil {
        panic(err)
    }
    params := &textapi.SentimentParams{Text: "John is a very good football player!"}
    sentiment, err := client.Sentiment(params)
    if err != nil {
        panic(err)
    }
    fmt.Printf("%v\n", sentiment)
}