facebook

package
v0.0.0-...-fbea8a0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 14, 2014 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	GraphHost = "graph.facebook.com"
	AuthUrl   = "https://graph.facebook.com/oauth/authorize"
	TokenUrl  = "https://graph.facebook.com/oauth/access_token"
)

Variables

This section is empty.

Functions

func Init

func Init(client_id, client_secret, redirect_url string, options map[string]string) *auth.Auth

Types

type Data

type Data struct {
	Data []Item `json:"data"`
}

type Graph

type Graph struct {
	AccessToken string
}

func (*Graph) GetConnections

func (g *Graph) GetConnections(path string) ([]Item, error)

func (*Graph) GetObject

func (g *Graph) GetObject(object string) (*Profile, error)

type Item

type Item struct {
	Id   string `json:"id"`
	Name string `json:"name"`
}

type Profile

type Profile struct {
	Id                  string  `json:"id"`
	Username            string  `json:"username"`
	Name                string  `json:"name"`
	FirstName           string  `json:"first_name"`
	LastName            string  `json:"last_name"`
	Link                string  `json:"link"`
	Gender              string  `json:"gender"`
	Timezone            float32 `json:"timezone"`
	Locale              string  `json:"locale"`
	Verified            bool    `json:"verified"`
	UpdatedTime         string  `json:"updated_time"`
	Hometown            Item    `json:"hometown"`
	Location            Item    `json:"location"`
	Sports              []Item  `json:"sports"`
	FavoriteTeams       []Item  `json:"favourite_teams"`
	Languages           []Item  `json:"languages"`
	InspirationalPeople []Item  `json:"inspirational_people"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL