Class RCSBusinessMessaging.Phones.AgentMessages.Create
- java.lang.Object
-
- java.util.AbstractMap<java.lang.String,java.lang.Object>
-
- com.google.api.client.util.GenericData
-
- com.google.api.client.googleapis.services.AbstractGoogleClientRequest<T>
-
- com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest<T>
-
- com.google.api.services.rcsbusinessmessaging.v1.RCSBusinessMessagingRequest<AgentMessage>
-
- com.google.api.services.rcsbusinessmessaging.v1.RCSBusinessMessaging.Phones.AgentMessages.Create
-
- All Implemented Interfaces:
java.lang.Cloneable,java.util.Map<java.lang.String,java.lang.Object>
- Enclosing class:
- RCSBusinessMessaging.Phones.AgentMessages
public class RCSBusinessMessaging.Phones.AgentMessages.Create extends RCSBusinessMessagingRequest<AgentMessage>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.api.client.util.GenericData
com.google.api.client.util.GenericData.Flags
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedCreate(java.lang.String parent, AgentMessage content)Sends a message from the agent to a user.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetAgentId()Optional.java.lang.StringgetMessageId()The unique ID of the message, assigned by the agent.java.lang.StringgetParent()" phones/{E.164}", where {E.164} is the user's phone number in E.164 format.RCSBusinessMessaging.Phones.AgentMessages.Createset(java.lang.String parameterName, java.lang.Object value)RCSBusinessMessaging.Phones.AgentMessages.Createset$Xgafv(java.lang.String $Xgafv)V1 error format.RCSBusinessMessaging.Phones.AgentMessages.CreatesetAccessToken(java.lang.String accessToken)OAuth access token.RCSBusinessMessaging.Phones.AgentMessages.CreatesetAgentId(java.lang.String agentId)Optional.RCSBusinessMessaging.Phones.AgentMessages.CreatesetAlt(java.lang.String alt)Data format for response.RCSBusinessMessaging.Phones.AgentMessages.CreatesetCallback(java.lang.String callback)JSONPRCSBusinessMessaging.Phones.AgentMessages.CreatesetFields(java.lang.String fields)Selector specifying which fields to include in a partial response.RCSBusinessMessaging.Phones.AgentMessages.CreatesetKey(java.lang.String key)API key.RCSBusinessMessaging.Phones.AgentMessages.CreatesetMessageId(java.lang.String messageId)The unique ID of the message, assigned by the agent.RCSBusinessMessaging.Phones.AgentMessages.CreatesetOauthToken(java.lang.String oauthToken)OAuth 2.0 token for the current user.RCSBusinessMessaging.Phones.AgentMessages.CreatesetParent(java.lang.String parent)"phones/{E.164}", where {E.164} is the user's phone number in E.164 format.RCSBusinessMessaging.Phones.AgentMessages.CreatesetPrettyPrint(java.lang.Boolean prettyPrint)Returns response with indentations and line breaks.RCSBusinessMessaging.Phones.AgentMessages.CreatesetQuotaUser(java.lang.String quotaUser)Available to use for quota purposes for server-side applications.RCSBusinessMessaging.Phones.AgentMessages.CreatesetUploadProtocol(java.lang.String uploadProtocol)Upload protocol for media (e.g.RCSBusinessMessaging.Phones.AgentMessages.CreatesetUploadType(java.lang.String uploadType)Legacy upload protocol for media (e.g.-
Methods inherited from class com.google.api.services.rcsbusinessmessaging.v1.RCSBusinessMessagingRequest
get$Xgafv, getAbstractGoogleClient, getAccessToken, getAlt, getCallback, getFields, getKey, getOauthToken, getPrettyPrint, getQuotaUser, getUploadProtocol, getUploadType, setDisableGZipContent, setRequestHeaders
-
Methods inherited from class com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest
getJsonContent, newExceptionOnError, queue
-
Methods inherited from class com.google.api.client.googleapis.services.AbstractGoogleClientRequest
buildHttpRequest, buildHttpRequestUrl, buildHttpRequestUsingHead, checkRequiredParameter, execute, executeAndDownloadTo, executeAsInputStream, executeMedia, executeMediaAndDownloadTo, executeMediaAsInputStream, executeUnparsed, executeUsingHead, getDisableGZipContent, getHttpContent, getLastResponseHeaders, getLastStatusCode, getLastStatusMessage, getMediaHttpDownloader, getMediaHttpUploader, getRequestHeaders, getRequestMethod, getResponseClass, getUriTemplate, initializeMediaDownload, initializeMediaUpload, queue
-
Methods inherited from class com.google.api.client.util.GenericData
clone, entrySet, get, getClassInfo, getUnknownKeys, put, putAll, remove, setUnknownKeys
-
Methods inherited from class java.util.AbstractMap
clear, containsKey, containsValue, equals, hashCode, isEmpty, keySet, size, toString, values
-
-
-
-
Constructor Detail
-
Create
protected Create(java.lang.String parent, AgentMessage content)Sends a message from the agent to a user. The user must be RCS enabled and reachable by the RBM platform in order for the agent to successfully send a message. When the message has been successfully sent, the call returns with no error. Otherwise, the agent receives an error code. If the user is online, the RBM platform delivers the message right away. Otherwise, the RBM platform queues the message and delivered it when the user is next online. The RBM platform ignores any agent message sent with an ID that was used by an earlier message or event sent from the same agent. Agent messages can be revoked between the time that they are sent and the time that they are delivered. Create a request for the method "agentMessages.create". This request holds the parameters needed by the the rcsbusinessmessaging server. After setting any optional parameters, call theAbstractGoogleClientRequest.execute()method to invoke the remote operation.RCSBusinessMessaging.initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)must be called to initialize this instance immediately after invoking the constructor.- Parameters:
parent- "phones/{E.164}", where {E.164} is the user's phone number in E.164 format. For example, with the US phone number +1-222-333-4444, the value would be phones/+12223334444, and the resulting endpoint would be https://rcsbusinessmessaging.googleapis.com/v1/phones/+12223334444/agentMessages.content- theAgentMessage- Since:
- 1.13
-
-
Method Detail
-
set$Xgafv
public RCSBusinessMessaging.Phones.AgentMessages.Create set$Xgafv(java.lang.String $Xgafv)
Description copied from class:RCSBusinessMessagingRequestV1 error format.- Overrides:
set$Xgafvin classRCSBusinessMessagingRequest<AgentMessage>
-
setAccessToken
public RCSBusinessMessaging.Phones.AgentMessages.Create setAccessToken(java.lang.String accessToken)
Description copied from class:RCSBusinessMessagingRequestOAuth access token.- Overrides:
setAccessTokenin classRCSBusinessMessagingRequest<AgentMessage>
-
setAlt
public RCSBusinessMessaging.Phones.AgentMessages.Create setAlt(java.lang.String alt)
Description copied from class:RCSBusinessMessagingRequestData format for response.- Overrides:
setAltin classRCSBusinessMessagingRequest<AgentMessage>
-
setCallback
public RCSBusinessMessaging.Phones.AgentMessages.Create setCallback(java.lang.String callback)
Description copied from class:RCSBusinessMessagingRequestJSONP- Overrides:
setCallbackin classRCSBusinessMessagingRequest<AgentMessage>
-
setFields
public RCSBusinessMessaging.Phones.AgentMessages.Create setFields(java.lang.String fields)
Description copied from class:RCSBusinessMessagingRequestSelector specifying which fields to include in a partial response.- Overrides:
setFieldsin classRCSBusinessMessagingRequest<AgentMessage>
-
setKey
public RCSBusinessMessaging.Phones.AgentMessages.Create setKey(java.lang.String key)
Description copied from class:RCSBusinessMessagingRequestAPI key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.- Overrides:
setKeyin classRCSBusinessMessagingRequest<AgentMessage>
-
setOauthToken
public RCSBusinessMessaging.Phones.AgentMessages.Create setOauthToken(java.lang.String oauthToken)
Description copied from class:RCSBusinessMessagingRequestOAuth 2.0 token for the current user.- Overrides:
setOauthTokenin classRCSBusinessMessagingRequest<AgentMessage>
-
setPrettyPrint
public RCSBusinessMessaging.Phones.AgentMessages.Create setPrettyPrint(java.lang.Boolean prettyPrint)
Description copied from class:RCSBusinessMessagingRequestReturns response with indentations and line breaks.- Overrides:
setPrettyPrintin classRCSBusinessMessagingRequest<AgentMessage>
-
setQuotaUser
public RCSBusinessMessaging.Phones.AgentMessages.Create setQuotaUser(java.lang.String quotaUser)
Description copied from class:RCSBusinessMessagingRequestAvailable to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.- Overrides:
setQuotaUserin classRCSBusinessMessagingRequest<AgentMessage>
-
setUploadType
public RCSBusinessMessaging.Phones.AgentMessages.Create setUploadType(java.lang.String uploadType)
Description copied from class:RCSBusinessMessagingRequestLegacy upload protocol for media (e.g. "media", "multipart").- Overrides:
setUploadTypein classRCSBusinessMessagingRequest<AgentMessage>
-
setUploadProtocol
public RCSBusinessMessaging.Phones.AgentMessages.Create setUploadProtocol(java.lang.String uploadProtocol)
Description copied from class:RCSBusinessMessagingRequestUpload protocol for media (e.g. "raw", "multipart").- Overrides:
setUploadProtocolin classRCSBusinessMessagingRequest<AgentMessage>
-
getParent
public java.lang.String getParent()
" phones/{E.164}", where {E.164} is the user's phone number in E.164 format. For example, with the " US phone number +1-222-333-4444, the value would be phones/+12223334444, and the resulting " endpoint would be " https://rcsbusinessmessaging.googleapis.com/v1/phones/+12223334444/agentMessages. "
-
setParent
public RCSBusinessMessaging.Phones.AgentMessages.Create setParent(java.lang.String parent)
"phones/{E.164}", where {E.164} is the user's phone number in E.164 format. For example, with the US phone number +1-222-333-4444, the value would be phones/+12223334444, and the resulting endpoint would be https://rcsbusinessmessaging.googleapis.com/v1/phones/+12223334444/agentMessages.
-
getMessageId
public java.lang.String getMessageId()
The unique ID of the message, assigned by the agent. This must be a UUID, as defined in https://tools.ietf.org/html/rfc4122. The RBM platform ignores any agent message sent with an ID that was used by an earlier message or event sent from the same agent.
-
setMessageId
public RCSBusinessMessaging.Phones.AgentMessages.Create setMessageId(java.lang.String messageId)
The unique ID of the message, assigned by the agent. This must be a UUID, as defined in https://tools.ietf.org/html/rfc4122. The RBM platform ignores any agent message sent with an ID that was used by an earlier message or event sent from the same agent.
-
getAgentId
public java.lang.String getAgentId()
Optional. The agent's unique identifier. Defined by RCS Business Messaging.
-
setAgentId
public RCSBusinessMessaging.Phones.AgentMessages.Create setAgentId(java.lang.String agentId)
Optional. The agent's unique identifier. Defined by RCS Business Messaging.
-
set
public RCSBusinessMessaging.Phones.AgentMessages.Create set(java.lang.String parameterName, java.lang.Object value)
- Overrides:
setin classRCSBusinessMessagingRequest<AgentMessage>
-
-