mixpanel

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Feb 20, 2015 License: Apache-2.0 Imports: 11 Imported by: 0

README

mixpanel

-- import "github.com/Clever/redshifter/mixpanel"

Usage

func StringOrJSONMarshal
func StringOrJSONMarshal(value interface{}) (string, error)

StringOrJSONMarshal returns a string value for an object to be used in URL strings. Compare this to json.Marshal which wraps a string with quotes which breaks URL params.

type Export
type Export struct {
}

Export is a struct to perform mixpanel export operations.

func NewExport
func NewExport() *Export

NewExport returns a pointer to an Export object initialized using API key and API secret provided in flags.

func (*Export) Request
func (m *Export) Request(method string, params map[string]interface{}) ([]byte, error)

Request performs a request on the export endpoint of the mixpanel API. Returns the raw bytes received in the response.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func StringOrJSONMarshal

func StringOrJSONMarshal(value interface{}) (string, error)

StringOrJSONMarshal returns a string value for an object to be used in URL strings. Compare this to json.Marshal which wraps a string with quotes which breaks URL params.

Types

type Export

type Export struct {
	// contains filtered or unexported fields
}

Export is a struct to perform mixpanel export operations.

func NewExport

func NewExport() *Export

NewExport returns a pointer to an Export object initialized using API key and API secret provided in flags.

func (*Export) Request

func (m *Export) Request(method string, params map[string]interface{}) ([]byte, error)

Request performs a request on the export endpoint of the mixpanel API. Returns the raw bytes received in the response.

Jump to

Keyboard shortcuts

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