Package com.bandwidth.sdk.model
Class TransferCompleteCallback
- java.lang.Object
-
- com.bandwidth.sdk.model.TransferCompleteCallback
-
@Generated("org.openapitools.codegen.languages.JavaClientCodegen") public class TransferCompleteCallback extends Object
This event is sent to the transferCompleteUrl of the A-leg's <Transfer> verb when the transferred call (B-leg) completes. In a simultaneous ringing scenario, only one B-leg succeeds and this event corresponds to that successful leg. If none of the calls were answered, the transferComplete event corresponds to one of the legs.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
TransferCompleteCallback.CustomTypeAdapterFactory
-
Field Summary
Fields Modifier and Type Field Description static HashSet<String>
openapiFields
static HashSet<String>
openapiRequiredFields
static String
SERIALIZED_NAME_ACCOUNT_ID
static String
SERIALIZED_NAME_ANSWER_TIME
static String
SERIALIZED_NAME_APPLICATION_ID
static String
SERIALIZED_NAME_CALL_ID
static String
SERIALIZED_NAME_CALL_URL
static String
SERIALIZED_NAME_CAUSE
static String
SERIALIZED_NAME_DIRECTION
static String
SERIALIZED_NAME_ENQUEUED_TIME
static String
SERIALIZED_NAME_ERROR_ID
static String
SERIALIZED_NAME_ERROR_MESSAGE
static String
SERIALIZED_NAME_EVENT_TIME
static String
SERIALIZED_NAME_EVENT_TYPE
static String
SERIALIZED_NAME_FROM
static String
SERIALIZED_NAME_START_TIME
static String
SERIALIZED_NAME_TAG
static String
SERIALIZED_NAME_TO
static String
SERIALIZED_NAME_TRANSFER_CALLER_ID
static String
SERIALIZED_NAME_TRANSFER_TO
-
Constructor Summary
Constructors Constructor Description TransferCompleteCallback()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description TransferCompleteCallback
accountId(String accountId)
TransferCompleteCallback
answerTime(OffsetDateTime answerTime)
TransferCompleteCallback
applicationId(String applicationId)
TransferCompleteCallback
callId(String callId)
TransferCompleteCallback
callUrl(String callUrl)
TransferCompleteCallback
cause(String cause)
TransferCompleteCallback
direction(CallDirectionEnum direction)
TransferCompleteCallback
enqueuedTime(OffsetDateTime enqueuedTime)
boolean
equals(Object o)
TransferCompleteCallback
errorId(String errorId)
TransferCompleteCallback
errorMessage(String errorMessage)
TransferCompleteCallback
eventTime(OffsetDateTime eventTime)
TransferCompleteCallback
eventType(String eventType)
TransferCompleteCallback
from(String from)
static TransferCompleteCallback
fromJson(String jsonString)
Create an instance of TransferCompleteCallback given an JSON stringString
getAccountId()
The user account associated with the call.Map<String,Object>
getAdditionalProperties()
Return the additional (undeclared) property.Object
getAdditionalProperty(String key)
Return the additional (undeclared) property with the specified name.OffsetDateTime
getAnswerTime()
Time the call was answered, in ISO 8601 format.String
getApplicationId()
The id of the application associated with the call.String
getCallId()
The call id associated with the event.String
getCallUrl()
The URL of the call associated with the event.String
getCause()
Reason the call failed - hangup, busy, timeout, cancel, rejected, callback-error, invalid-bxml, application-error, account-limit, node-capacity-exceeded, error, or unknown.CallDirectionEnum
getDirection()
Get directionOffsetDateTime
getEnqueuedTime()
(optional) If call queueing is enabled and this is an outbound call, time the call was queued, in ISO 8601 format.String
getErrorId()
Bandwidth's internal id that references the error event.String
getErrorMessage()
Text explaining the reason that caused the call to fail in case of errors.OffsetDateTime
getEventTime()
The approximate UTC date and time when the event was generated by the Bandwidth server, in ISO 8601 format.String
getEventType()
The event type, value can be one of the following: answer, bridgeComplete, bridgeTargetComplete, conferenceCreated, conferenceRedirect, conferenceMemberJoin, conferenceMemberExit, conferenceCompleted, conferenceRecordingAvailable, disconnect, dtmf, gather, initiate, machineDetectionComplete, recordingComplete, recordingAvailable, redirect, transcriptionAvailable, transferAnswer, transferComplete, transferDisconnect.String
getFrom()
The provided identifier of the caller: can be a phone number in E.164 format (e.g.OffsetDateTime
getStartTime()
Time the call was started, in ISO 8601 format.String
getTag()
(optional) The tag specified on call creation.String
getTo()
The phone number that received the call, in E.164 format (e.g.String
getTransferCallerId()
The phone number used as the from field of the B-leg call, in E.164 format (e.g.String
getTransferTo()
The phone number used as the to field of the B-leg call, in E.164 format (e.g.int
hashCode()
TransferCompleteCallback
putAdditionalProperty(String key, Object value)
Set the additional (undeclared) property with the specified name and value.void
setAccountId(String accountId)
void
setAnswerTime(OffsetDateTime answerTime)
void
setApplicationId(String applicationId)
void
setCallId(String callId)
void
setCallUrl(String callUrl)
void
setCause(String cause)
void
setDirection(CallDirectionEnum direction)
void
setEnqueuedTime(OffsetDateTime enqueuedTime)
void
setErrorId(String errorId)
void
setErrorMessage(String errorMessage)
void
setEventTime(OffsetDateTime eventTime)
void
setEventType(String eventType)
void
setFrom(String from)
void
setStartTime(OffsetDateTime startTime)
void
setTag(String tag)
void
setTo(String to)
void
setTransferCallerId(String transferCallerId)
void
setTransferTo(String transferTo)
TransferCompleteCallback
startTime(OffsetDateTime startTime)
TransferCompleteCallback
tag(String tag)
TransferCompleteCallback
to(String to)
String
toJson()
Convert an instance of TransferCompleteCallback to an JSON stringString
toString()
TransferCompleteCallback
transferCallerId(String transferCallerId)
TransferCompleteCallback
transferTo(String transferTo)
static void
validateJsonElement(com.google.gson.JsonElement jsonElement)
Validates the JSON Element and throws an exception if issues found
-
-
-
Field Detail
-
SERIALIZED_NAME_EVENT_TYPE
public static final String SERIALIZED_NAME_EVENT_TYPE
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_EVENT_TIME
public static final String SERIALIZED_NAME_EVENT_TIME
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_ACCOUNT_ID
public static final String SERIALIZED_NAME_ACCOUNT_ID
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_APPLICATION_ID
public static final String SERIALIZED_NAME_APPLICATION_ID
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_FROM
public static final String SERIALIZED_NAME_FROM
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_TO
public static final String SERIALIZED_NAME_TO
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_DIRECTION
public static final String SERIALIZED_NAME_DIRECTION
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_CALL_ID
public static final String SERIALIZED_NAME_CALL_ID
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_CALL_URL
public static final String SERIALIZED_NAME_CALL_URL
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_ENQUEUED_TIME
public static final String SERIALIZED_NAME_ENQUEUED_TIME
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_START_TIME
public static final String SERIALIZED_NAME_START_TIME
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_ANSWER_TIME
public static final String SERIALIZED_NAME_ANSWER_TIME
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_TAG
public static final String SERIALIZED_NAME_TAG
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_TRANSFER_CALLER_ID
public static final String SERIALIZED_NAME_TRANSFER_CALLER_ID
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_TRANSFER_TO
public static final String SERIALIZED_NAME_TRANSFER_TO
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_CAUSE
public static final String SERIALIZED_NAME_CAUSE
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_ERROR_MESSAGE
public static final String SERIALIZED_NAME_ERROR_MESSAGE
- See Also:
- Constant Field Values
-
SERIALIZED_NAME_ERROR_ID
public static final String SERIALIZED_NAME_ERROR_ID
- See Also:
- Constant Field Values
-
-
Method Detail
-
eventType
public TransferCompleteCallback eventType(String eventType)
-
getEventType
@Nullable public String getEventType()
The event type, value can be one of the following: answer, bridgeComplete, bridgeTargetComplete, conferenceCreated, conferenceRedirect, conferenceMemberJoin, conferenceMemberExit, conferenceCompleted, conferenceRecordingAvailable, disconnect, dtmf, gather, initiate, machineDetectionComplete, recordingComplete, recordingAvailable, redirect, transcriptionAvailable, transferAnswer, transferComplete, transferDisconnect.- Returns:
- eventType
-
setEventType
public void setEventType(String eventType)
-
eventTime
public TransferCompleteCallback eventTime(OffsetDateTime eventTime)
-
getEventTime
@Nullable public OffsetDateTime getEventTime()
The approximate UTC date and time when the event was generated by the Bandwidth server, in ISO 8601 format. This may not be exactly the time of event execution.- Returns:
- eventTime
-
setEventTime
public void setEventTime(OffsetDateTime eventTime)
-
accountId
public TransferCompleteCallback accountId(String accountId)
-
getAccountId
@Nullable public String getAccountId()
The user account associated with the call.- Returns:
- accountId
-
setAccountId
public void setAccountId(String accountId)
-
applicationId
public TransferCompleteCallback applicationId(String applicationId)
-
getApplicationId
@Nullable public String getApplicationId()
The id of the application associated with the call.- Returns:
- applicationId
-
setApplicationId
public void setApplicationId(String applicationId)
-
from
public TransferCompleteCallback from(String from)
-
getFrom
@Nullable public String getFrom()
The provided identifier of the caller: can be a phone number in E.164 format (e.g. +15555555555) or one of Private, Restricted, Unavailable, or Anonymous.- Returns:
- from
-
setFrom
public void setFrom(String from)
-
to
public TransferCompleteCallback to(String to)
-
getTo
@Nullable public String getTo()
The phone number that received the call, in E.164 format (e.g. +15555555555).- Returns:
- to
-
setTo
public void setTo(String to)
-
direction
public TransferCompleteCallback direction(CallDirectionEnum direction)
-
getDirection
@Nullable public CallDirectionEnum getDirection()
Get direction- Returns:
- direction
-
setDirection
public void setDirection(CallDirectionEnum direction)
-
callId
public TransferCompleteCallback callId(String callId)
-
getCallId
@Nullable public String getCallId()
The call id associated with the event.- Returns:
- callId
-
setCallId
public void setCallId(String callId)
-
callUrl
public TransferCompleteCallback callUrl(String callUrl)
-
getCallUrl
@Nullable public String getCallUrl()
The URL of the call associated with the event.- Returns:
- callUrl
-
setCallUrl
public void setCallUrl(String callUrl)
-
enqueuedTime
public TransferCompleteCallback enqueuedTime(OffsetDateTime enqueuedTime)
-
getEnqueuedTime
@Nullable public OffsetDateTime getEnqueuedTime()
(optional) If call queueing is enabled and this is an outbound call, time the call was queued, in ISO 8601 format.- Returns:
- enqueuedTime
-
setEnqueuedTime
public void setEnqueuedTime(OffsetDateTime enqueuedTime)
-
startTime
public TransferCompleteCallback startTime(OffsetDateTime startTime)
-
getStartTime
@Nullable public OffsetDateTime getStartTime()
Time the call was started, in ISO 8601 format.- Returns:
- startTime
-
setStartTime
public void setStartTime(OffsetDateTime startTime)
-
answerTime
public TransferCompleteCallback answerTime(OffsetDateTime answerTime)
-
getAnswerTime
@Nullable public OffsetDateTime getAnswerTime()
Time the call was answered, in ISO 8601 format.- Returns:
- answerTime
-
setAnswerTime
public void setAnswerTime(OffsetDateTime answerTime)
-
tag
public TransferCompleteCallback tag(String tag)
-
getTag
@Nullable public String getTag()
(optional) The tag specified on call creation. If no tag was specified or it was previously cleared, this field will not be present.- Returns:
- tag
-
setTag
public void setTag(String tag)
-
transferCallerId
public TransferCompleteCallback transferCallerId(String transferCallerId)
-
getTransferCallerId
@Nullable public String getTransferCallerId()
The phone number used as the from field of the B-leg call, in E.164 format (e.g. +15555555555) or one of Restricted, Anonymous, Private, or Unavailable.- Returns:
- transferCallerId
-
setTransferCallerId
public void setTransferCallerId(String transferCallerId)
-
transferTo
public TransferCompleteCallback transferTo(String transferTo)
-
getTransferTo
@Nullable public String getTransferTo()
The phone number used as the to field of the B-leg call, in E.164 format (e.g. +15555555555).- Returns:
- transferTo
-
setTransferTo
public void setTransferTo(String transferTo)
-
cause
public TransferCompleteCallback cause(String cause)
-
getCause
@Nullable public String getCause()
Reason the call failed - hangup, busy, timeout, cancel, rejected, callback-error, invalid-bxml, application-error, account-limit, node-capacity-exceeded, error, or unknown.- Returns:
- cause
-
setCause
public void setCause(String cause)
-
errorMessage
public TransferCompleteCallback errorMessage(String errorMessage)
-
getErrorMessage
@Nullable public String getErrorMessage()
Text explaining the reason that caused the call to fail in case of errors.- Returns:
- errorMessage
-
setErrorMessage
public void setErrorMessage(String errorMessage)
-
errorId
public TransferCompleteCallback errorId(String errorId)
-
getErrorId
@Nullable public String getErrorId()
Bandwidth's internal id that references the error event.- Returns:
- errorId
-
setErrorId
public void setErrorId(String errorId)
-
putAdditionalProperty
public TransferCompleteCallback putAdditionalProperty(String key, Object value)
Set the additional (undeclared) property with the specified name and value. If the property does not already exist, create it otherwise replace it.- Parameters:
key
- name of the propertyvalue
- value of the property- Returns:
- the TransferCompleteCallback instance itself
-
getAdditionalProperties
public Map<String,Object> getAdditionalProperties()
Return the additional (undeclared) property.- Returns:
- a map of objects
-
getAdditionalProperty
public Object getAdditionalProperty(String key)
Return the additional (undeclared) property with the specified name.- Parameters:
key
- name of the property- Returns:
- an object
-
validateJsonElement
public static void validateJsonElement(com.google.gson.JsonElement jsonElement) throws IOException
Validates the JSON Element and throws an exception if issues found- Parameters:
jsonElement
- JSON Element- Throws:
IOException
- if the JSON Element is invalid with respect to TransferCompleteCallback
-
fromJson
public static TransferCompleteCallback fromJson(String jsonString) throws IOException
Create an instance of TransferCompleteCallback given an JSON string- Parameters:
jsonString
- JSON string- Returns:
- An instance of TransferCompleteCallback
- Throws:
IOException
- if the JSON string is invalid with respect to TransferCompleteCallback
-
toJson
public String toJson()
Convert an instance of TransferCompleteCallback to an JSON string- Returns:
- JSON string
-
-