Versions in this module Expand all Collapse all v1 v1.0.0 May 8, 2015 Changes in this version + func BaseURI(baseURI string) option + func Bool(value bool) *bool + func SetHTTPClient(httpClient interfaces.HTTPClient) option + func TraceHTTP(trace bool) option + type Admin struct + Email string + ID json.Number + Name string + Type string + func (a Admin) IsNobodyAdmin() bool + func (a Admin) String() string + type AdminAPI struct + type AdminList struct + Admins []Admin + type AdminRepository interface + type AdminService struct + Repository AdminRepository + func (c *AdminService) List() (AdminList, error) + type Client struct + APIKey string + AdminRepository AdminRepository + Admins AdminService + AppID string + Companies CompanyService + CompanyRepository CompanyRepository + ContactRepository ContactRepository + Contacts ContactService + EventRepository EventRepository + Events EventService + HTTPClient interfaces.HTTPClient + SegmentRepository SegmentRepository + Segments SegmentService + TagRepository TagRepository + Tags TagService + UserRepository UserRepository + Users UserService + func NewClient(appID, apiKey string) *Client + func (c *Client) Option(opts ...option) (previous option) + type Company struct + CompanyID string + CreatedAt int32 + CustomAttributes map[string]interface{} + ID string + LastRequestAt int32 + MonthlySpend int32 + Name string + Plan *Plan + RemoteCreatedAt int32 + Remove *bool + Segments *SegmentList + SessionCount int32 + Tags *TagList + UpdatedAt int32 + UserCount int32 + func (c Company) String() string + type CompanyAPI struct + type CompanyIdentifiers struct + CompanyID string + ID string + Name string + type CompanyList struct + Companies []Company + Pages PageParams + type CompanyRepository interface + type CompanyService struct + Repository CompanyRepository + func (c *CompanyService) FindByCompanyID(companyID string) (Company, error) + func (c *CompanyService) FindByID(id string) (Company, error) + func (c *CompanyService) FindByName(name string) (Company, error) + func (c *CompanyService) List(params PageParams) (CompanyList, error) + func (c *CompanyService) ListBySegment(segmentID string, params PageParams) (CompanyList, error) + func (c *CompanyService) ListByTag(tagID string, params PageParams) (CompanyList, error) + func (c *CompanyService) Save(user *Company) (Company, error) + type Contact struct + Avatar *UserAvatar + Companies *CompanyList + CreatedAt int32 + CustomAttributes map[string]interface{} + Email string + ID string + LastRequestAt int32 + LastSeenIP string + LocationData *LocationData + Name string + NewSession *bool + Segments *SegmentList + SessionCount int32 + SocialProfiles *SocialProfileList + Tags *TagList + UnsubscribedFromEmails *bool + UpdateLastRequestAt *bool + UpdatedAt int32 + UserAgentData string + UserID string + func (c Contact) String() string + type ContactAPI struct + type ContactList struct + Contacts []Contact + Pages PageParams + type ContactRepository interface + type ContactService struct + Repository ContactRepository + func (c *ContactService) Convert(contact *Contact, user *User) (User, error) + func (c *ContactService) Create(contact *Contact) (Contact, error) + func (c *ContactService) Delete(contact *Contact) (Contact, error) + func (c *ContactService) FindByID(id string) (Contact, error) + func (c *ContactService) FindByUserID(userID string) (Contact, error) + func (c *ContactService) List(params PageParams) (ContactList, error) + func (c *ContactService) ListByEmail(email string, params PageParams) (ContactList, error) + func (c *ContactService) ListBySegment(segmentID string, params PageParams) (ContactList, error) + func (c *ContactService) ListByTag(tagID string, params PageParams) (ContactList, error) + func (c *ContactService) Update(contact *Contact) (Contact, error) + type Event struct + CreatedAt int32 + Email string + EventName string + Metadata map[string]interface{} + UserID string + func (e Event) String() string + type EventAPI struct + type EventRepository interface + type EventService struct + Repository EventRepository + func (e *EventService) Save(event *Event) error + type IntercomError interface + Error func() string + GetCode func() string + GetMessage func() string + GetStatusCode func() int + type LocationData struct + CityName string + ContinentCode string + CountryCode string + CountryName string + Latitude float64 + Longitude float64 + PostalCode string + RegionName string + Timezone string + func (l LocationData) String() string + type PageParams struct + Page int32 + PerPage int32 + TotalPages int32 + type Plan struct + ID string + Name string + func (p Plan) String() string + type Segment struct + CreatedAt int32 + ID string + Name string + PersonType SegmentPersonType + UpdatedAt int32 + func (s Segment) String() string + type SegmentAPI struct + type SegmentList struct + Segments []Segment + type SegmentPersonType int + const CONTACT + const USER + func (segmentPersonType SegmentPersonType) String() string + type SegmentRepository interface + type SegmentService struct + Repository SegmentRepository + func (t *SegmentService) Find(id string) (Segment, error) + func (t *SegmentService) List() (SegmentList, error) + type SocialProfile struct + ID string + Name string + URL string + Username string + func (s SocialProfile) String() string + type SocialProfileList struct + SocialProfiles []SocialProfile + type Tag struct + ID string + Name string + func (t Tag) String() string + type TagAPI struct + type TagList struct + Tags []Tag + type TagRepository interface + type TagService struct + Repository TagRepository + func (t *TagService) Delete(id string) error + func (t *TagService) List() (TagList, error) + func (t *TagService) Save(tag *Tag) (Tag, error) + func (t *TagService) Tag(taggingList *TaggingList) (Tag, error) + type Tagging struct + CompanyID string + Email string + ID string + Untag *bool + UserID string + type TaggingList struct + Companies []Tagging + Name string + Users []Tagging + type User struct + Anonymous *bool + Avatar *UserAvatar + Companies *CompanyList + CreatedAt int32 + CustomAttributes map[string]interface{} + Email string + ID string + LastRequestAt int32 + LastSeenIP string + LastSeenUserAgent string + LocationData *LocationData + Name string + NewSession *bool + Pseudonym string + RemoteCreatedAt int32 + Segments *SegmentList + SessionCount int32 + SignedUpAt int32 + SocialProfiles *SocialProfileList + Tags *TagList + UnsubscribedFromEmails *bool + UpdateLastRequestAt *bool + UpdatedAt int32 + UserAgentData string + UserID string + func (u User) String() string + type UserAPI struct + type UserAvatar struct + ImageURL string + func (a UserAvatar) String() string + type UserCompany struct + ID string + Name string + Remove *bool + type UserIdentifiers struct + Email string + ID string + UserID string + type UserList struct + Pages PageParams + Users []User + type UserRepository interface + type UserService struct + Repository UserRepository + func (u *UserService) Delete(id string) (User, error) + func (u *UserService) FindByEmail(email string) (User, error) + func (u *UserService) FindByID(id string) (User, error) + func (u *UserService) FindByUserID(userID string) (User, error) + func (u *UserService) List(params PageParams) (UserList, error) + func (u *UserService) ListBySegment(segmentID string, params PageParams) (UserList, error) + func (u *UserService) ListByTag(tagID string, params PageParams) (UserList, error) + func (u *UserService) Save(user *User) (User, error)