Class SmsSendResult
java.lang.Object
com.azure.communication.sms.models.SmsSendResult
The SmsSendResult model.
-
Constructor Summary
ConstructorDescriptionSmsSendResult
(String to, String messageId, int httpStatusCode, boolean isSuccessful, String errorMessage) Constructor to wrap the smsSendResponseItem -
Method Summary
Modifier and TypeMethodDescriptionGet the errorMessage property: Optional error message in case of 4xx/5xx/repeatable errors.int
Get the httpStatusCode property: HTTP Status code.Get the messageId property: The identifier of the outgoing Sms message.getTo()
Get the to property: The recipient's phone number in E.164 format.boolean
Get the successful property: Indicates if the message is processed successfully or not.
-
Constructor Details
-
SmsSendResult
public SmsSendResult(String to, String messageId, int httpStatusCode, boolean isSuccessful, String errorMessage) Constructor to wrap the smsSendResponseItem- Parameters:
to
- The recipient's phone number in E.164 format.messageId
- The identifier of the outgoing Sms message. Only present if message processed.httpStatusCode
- The httpStatusCode property: HTTP Status code.isSuccessful
- The successful property: Indicates if the message is processed successfully or not.errorMessage
- Optional error message in case of 4xx/5xx/repeatable errors.
-
-
Method Details
-
getTo
Get the to property: The recipient's phone number in E.164 format.- Returns:
- the to value.
-
getMessageId
Get the messageId property: The identifier of the outgoing Sms message. Only present if message processed.- Returns:
- the messageId value.
-
getHttpStatusCode
public int getHttpStatusCode()Get the httpStatusCode property: HTTP Status code.- Returns:
- the httpStatusCode value.
-
isSuccessful
public boolean isSuccessful()Get the successful property: Indicates if the message is processed successfully or not.- Returns:
- the successful value.
-
getErrorMessage
Get the errorMessage property: Optional error message in case of 4xx/5xx/repeatable errors.- Returns:
- the errorMessage value.
-