001/* 002 * Copyright 2024 Vonage 003 * 004 * Licensed under the Apache License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.apache.org/licenses/LICENSE-2.0 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 */ 016package com.vonage.client.conversations; 017 018import com.fasterxml.jackson.annotation.JsonProperty; 019import com.vonage.client.JsonableBaseObject; 020import java.net.URI; 021 022/** 023 * Represents the main attributes of a conversation. 024 */ 025public class BaseConversation extends JsonableBaseObject { 026 String id, name, displayName; 027 URI imageUrl; 028 ConversationTimestamp timestamp; 029 030 protected BaseConversation() { 031 } 032 033 /** 034 * Unique identifier for this conversation. 035 * 036 * @return The conversation ID as a string. 037 */ 038 @JsonProperty("id") 039 public String getId() { 040 return id; 041 } 042 043 /** 044 * Internal conversation name. Must be unique. 045 * 046 * @return The conversation name, or {@code null} if unespecified. 047 */ 048 @JsonProperty("name") 049 public String getName() { 050 return name; 051 } 052 053 /** 054 * The public facing name of the conversation. 055 * 056 * @return The display name, or {@code null} if unespecified. 057 */ 058 @JsonProperty("display_name") 059 public String getDisplayName() { 060 return displayName; 061 } 062 063 /** 064 * An image URL that you associate with the conversation. 065 * 066 * @return The image URL, or {@code null} if unspecified. 067 */ 068 @JsonProperty("image_url") 069 public URI getImageUrl() { 070 return imageUrl; 071 } 072 073 /** 074 * Timestamps for this conversation. 075 * 076 * @return The timestamps object, or {@code null} if unknown. 077 */ 078 @JsonProperty("timestamp") 079 public ConversationTimestamp getTimestamp() { 080 return timestamp; 081 } 082}