{"action":"created","issue":{"url":"https://api.github.com/repos/sendgrid/sendgrid-java/issues/207","repository_url":"https://api.github.com/repos/sendgrid/sendgrid-java","labels_url":"https://api.github.com/repos/sendgrid/sendgrid-java/issues/207/labels{/name}","comments_url":"https://api.github.com/repos/sendgrid/sendgrid-java/issues/207/comments","events_url":"https://api.github.com/repos/sendgrid/sendgrid-java/issues/207/events","html_url":"https://github.com/sendgrid/sendgrid-java/issues/207","id":244416257,"number":207,"title":"+Problem with updating Contact from Api","user":{"login":"elalaj","id":30322568,"avatar_url":"https://avatars3.githubusercontent.com/u/30322568?v=4","gravatar_id":"","url":"https://api.github.com/users/elalaj","html_url":"https://github.com/elalaj","followers_url":"https://api.github.com/users/elalaj/followers","following_url":"https://api.github.com/users/elalaj/following{/other_user}","gists_url":"https://api.github.com/users/elalaj/gists{/gist_id}","starred_url":"https://api.github.com/users/elalaj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/elalaj/subscriptions","organizations_url":"https://api.github.com/users/elalaj/orgs","repos_url":"https://api.github.com/users/elalaj/repos","events_url":"https://api.github.com/users/elalaj/events{/privacy}","received_events_url":"https://api.github.com/users/elalaj/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-07-20T16:03:53Z","updated_at":"2017-07-20T16:10:23Z","closed_at":null,"body":"## I am trying to update custom fields of a contact with this json i send from java program:\r\n```json\r\n[\r\n  {\r\n    \"email\": \"endrti.lalaj1992@gmail.com\",\r\n    \"first_name\": \"Endrit\",\r\n    \"last_name\": \"Lalaj\",\r\n    \"created_At\": \"Thu Jul 20 17:41:43 CEST 2017\",\r\n    \"custom_fields\": [\r\n      {\r\n        \"name\": \"home_town\",\r\n        \"value\": \"New York\"\r\n      }\r\n    ]\r\n  }\r\n]\r\n```\r\n\r\n## ,but i get this error message from response:\r\n```json\r\n{\r\n  \"error_count\": 1,\r\n  \"error_indices\": [\r\n    0\r\n  ],\r\n  \"errors\": [\r\n    {\r\n      \"error_indices\": [\r\n        0\r\n      ],\r\n      \"message\": \"The following parameters are not custom fields or reserved fields: [custom_fields]\"\r\n    }\r\n  ],\r\n  \"new_count\": 0,\r\n  \"persisted_recipients\": [\r\n    \r\n  ],\r\n  \"unmodified_indices\": [\r\n    \r\n  ],\r\n  \"updated_count\": 0\r\n}\r\n```\r\n\r\n\r\n## This json works for me when update Contacs without custom fields:\r\n```json\r\n[\r\n  {\r\n    \"email\": \"endrti.lalaj1992@gmail.com\",\r\n    \"first_name\": \"Endrit\",\r\n    \"last_name\": \"Lalaj\",\r\n    \"created_At\": \"Thu Jul 20 17:41:43 CEST 2017\"\r\n  }\r\n]\r\n```\r\nI use the same class to get Contact from SendGrid as i use to update Contact to SendGrid and no errors occur\r\n\r\n* sendgrid-java Version: sendgrid-java-3.1.0-jar\r\n* Java Version: 1.7.0_80\r\n\r\nI am looking forward to your solution.\r\nThanks in advanced!"},"comment":{"url":"https://api.github.com/repos/sendgrid/sendgrid-java/issues/comments/316752531","html_url":"https://github.com/sendgrid/sendgrid-java/issues/207#issuecomment-316752531","issue_url":"https://api.github.com/repos/sendgrid/sendgrid-java/issues/207","id":316752531,"user":{"login":"thinkingserious","id":146695,"avatar_url":"https://avatars0.githubusercontent.com/u/146695?v=4","gravatar_id":"","url":"https://api.github.com/users/thinkingserious","html_url":"https://github.com/thinkingserious","followers_url":"https://api.github.com/users/thinkingserious/followers","following_url":"https://api.github.com/users/thinkingserious/following{/other_user}","gists_url":"https://api.github.com/users/thinkingserious/gists{/gist_id}","starred_url":"https://api.github.com/users/thinkingserious/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thinkingserious/subscriptions","organizations_url":"https://api.github.com/users/thinkingserious/orgs","repos_url":"https://api.github.com/users/thinkingserious/repos","events_url":"https://api.github.com/users/thinkingserious/events{/privacy}","received_events_url":"https://api.github.com/users/thinkingserious/received_events","type":"User","site_admin":false},"created_at":"2017-07-20T16:10:23Z","updated_at":"2017-07-20T16:10:23Z","body":"Hello @elalaj,\r\n\r\nIt looks like this might be what you want: https://sendgrid.com/docs/API_Reference/Web_API_v3/Marketing_Campaigns/contactdb.html#Create-a-Custom-Field-POST\r\n\r\nWith Best Regards,\r\n\r\nElmer"}}
{"actor":{"display_login":"thinkingserious"}}