-
Notifications
You must be signed in to change notification settings - Fork 1
/
contact_with_email.go
38 lines (32 loc) · 971 Bytes
/
contact_with_email.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
package legend
import (
"net/url"
)
type ContactWithEmailResultModel struct {
ContactId int64
// ExpiryDate DateTime
FirstName string
IsFreeMembership bool
IsProspect bool
LastName string
LinkedStatus string
MemberNumber string
MemberStatus string
Mobile string
Phone string
PostCode string
// ProspectCreationDate DateTime
ProspectId int64
ProspectStatus string
}
// A prospect is assumed as active if it has not been contacted for last few months.
// 'Number of months' is a configurable setting in Legend.
func (this *ApiClient) GetContactWithEmail(email, firstName, lastName string) (target []ContactWithEmailResultModel, err error) {
params := url.Values{}
params.Add("Email", email)
params.Add("FirstName", firstName)
params.Add("LastName", lastName)
params.Add("RetrieveMembers", "true")
err = this.GetApiRequest("/Joining/ContactWithEmail", params, &target)
return
}