File tree Expand file tree Collapse file tree 4 files changed +17
-1
lines changed
intercom-java/src/main/java/io/intercom/api Expand file tree Collapse file tree 4 files changed +17
-1
lines changed Original file line number Diff line number Diff line change @@ -447,6 +447,7 @@ ConversationCollection openForAdmin = Conversation.list(params);
447447Admin admin = new Admin (). setId(" 1" );
448448AdminReply adminReply = new AdminReply (admin);
449449adminReply. setBody(" These apples are healthsome" );
450+ adminReply. setAttachmentUrls(new String []{" http://www.example.com/attachment.jpg" }); // optional - list of attachments
450451Conversation . reply(" 66" , adminReply);
451452
452453// admin close
@@ -459,6 +460,7 @@ Conversation.reply("66", adminReply);
459460User user1 = new User (). setId(" 5310d8e8598c9a0b24000005" );
460461UserReply userReply = new UserReply (user1);
461462userReply. setBody(" Mighty fine shindig" );
463+ userReply. setAttachmentUrls(new String []{" http://www.example.com/attachment.jpg" }); // optional - list of attachments
462464System . out. println(MapperSupport . objectMapper(). writeValueAsString(userReply));
463465Conversation . reply(" 66" , userReply);
464466```
Original file line number Diff line number Diff line change @@ -46,6 +46,11 @@ public String getAdminID() {
4646 public String getAssigneeID () {
4747 return reply .getAssigneeID ();
4848 }
49+
50+ @ JsonProperty ("attachment_urls" )
51+ private String [] getAttachmentUrls () {
52+ return reply .getAttachmentUrls ();
53+ }
4954 }
5055
5156 @ JsonProperty ("assignee_id" )
Original file line number Diff line number Diff line change @@ -32,7 +32,11 @@ public Reply<T> setBody(String body) {
3232 this .body = body ;
3333 return this ;
3434 }
35-
35+
36+ public String [] getAttachmentUrls () {
37+ return attachmentUrls ;
38+ }
39+
3640 public Reply <T > setAttachmentUrls (String [] attachmentUrls ) {
3741 this .attachmentUrls = attachmentUrls ;
3842 return this ;
Original file line number Diff line number Diff line change @@ -51,6 +51,11 @@ public String getUserID() {
5151 public String getEmail () {
5252 return reply .getFrom ().getEmail ();
5353 }
54+
55+ @ JsonProperty ("attachment_urls" )
56+ private String [] getAttachmentUrls () {
57+ return reply .getAttachmentUrls ();
58+ }
5459 }
5560
5661 public UserReply (User user ) {
You can’t perform that action at this time.
0 commit comments