Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding missing user fields #131

Merged
merged 2 commits into from
Aug 9, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions src/Intercom/Clients/UsersClient.cs
Original file line number Diff line number Diff line change
@@ -445,9 +445,15 @@ private String Transform(User user)
last_seen_ip = user.last_seen_ip,
custom_attributes = user.custom_attributes,
new_session = user.new_session,
user_agent_data = user.user_agent_data,
last_seen_user_agent = user.user_agent_data,
last_request_at = user.last_request_at,
unsubscribed_from_emails = user.unsubscribed_from_emails
unsubscribed_from_emails = user.unsubscribed_from_emails,
referrer = user.referrer,
utm_campaign = user.utm_campaign,
utm_content = user.utm_content,
utm_medium = user.utm_medium,
utm_source = user.utm_source,
utm_term = user.utm_term
};

return JsonConvert.SerializeObject(body,
5 changes: 3 additions & 2 deletions src/Intercom/Data/Contact.cs
Original file line number Diff line number Diff line change
@@ -11,7 +11,8 @@ namespace Intercom.Data
{
public class Contact : User
{
public string app_id { get; set; }
public object remote_created_at { get; set; }
public Contact()
{
}
}
}
11 changes: 11 additions & 0 deletions src/Intercom/Data/User.cs
Original file line number Diff line number Diff line change
@@ -34,6 +34,17 @@ public class User : Model
public List<Segment> segments { get; set; }
[JsonConverter(typeof(ListJsonConverter))]
public List<Tag> tags { get; set; }
public string app_id { get; set; }
public long? remote_created_at { get; set; }
public string referrer { get; set; }
public string utm_campaign { get; set; }
public string utm_content { get; set; }
public string utm_medium { get; set; }
public string utm_source { get; set; }
public string utm_term { get; set; }
public bool marked_email_as_spam { get; set; }
public bool has_hard_bounced { get; set; }
public string last_seen_user_agent { get; set; }

public User()
{