/AWS1/IF_CNT=>STARTEMAILCONTACT()¶
About StartEmailContact¶
Creates an inbound email contact and initiates a flow to start the email contact for the customer. Response of this API provides the ContactId of the email contact created.
Method Signature¶
METHODS /AWS1/IF_CNT~STARTEMAILCONTACT
IMPORTING
!IV_INSTANCEID TYPE /AWS1/CNTINSTANCEID OPTIONAL
!IO_FROMEMAILADDRESS TYPE REF TO /AWS1/CL_CNTEMAILADDRESSINFO OPTIONAL
!IV_DESTINATIONEMAILADDRESS TYPE /AWS1/CNTEMAILADDRESS OPTIONAL
!IV_DESCRIPTION TYPE /AWS1/CNTDESCRIPTION OPTIONAL
!IT_REFERENCES TYPE /AWS1/CL_CNTREFERENCE=>TT_CONTACTREFERENCES OPTIONAL
!IV_NAME TYPE /AWS1/CNTNAME OPTIONAL
!IO_EMAILMESSAGE TYPE REF TO /AWS1/CL_CNTINBOUNDEMAILCONT OPTIONAL
!IO_ADDITIONALRECIPIENTS TYPE REF TO /AWS1/CL_CNTINBOUNDADDLRECIP00 OPTIONAL
!IT_ATTACHMENTS TYPE /AWS1/CL_CNTEMAILATTACHMENT=>TT_EMAILATTACHMENTS OPTIONAL
!IV_CONTACTFLOWID TYPE /AWS1/CNTCONTACTFLOWID OPTIONAL
!IV_RELATEDCONTACTID TYPE /AWS1/CNTCONTACTID OPTIONAL
!IT_ATTRIBUTES TYPE /AWS1/CL_CNTATTRIBUTES_W=>TT_ATTRIBUTES OPTIONAL
!IT_SEGMENTATTRIBUTES TYPE /AWS1/CL_CNTSEGMENTATTRVALUE=>TT_SEGMENTATTRIBUTES OPTIONAL
!IV_CLIENTTOKEN TYPE /AWS1/CNTCLIENTTOKEN OPTIONAL
RETURNING
VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_cntstrtemailcontact01
RAISING
/AWS1/CX_CNTACCESSDENIEDEX
/AWS1/CX_CNTIDEMPOTENCYEX
/AWS1/CX_CNTINTERNALSERVICEEX
/AWS1/CX_CNTINVALIDREQUESTEX
/AWS1/CX_CNTRESOURCENOTFOUNDEX
/AWS1/CX_CNTSERVICEQUOTAEXCDEX
/AWS1/CX_CNTTHROTTLINGEX
/AWS1/CX_CNTCLIENTEXC
/AWS1/CX_CNTSERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
iv_instanceid TYPE /AWS1/CNTINSTANCEID /AWS1/CNTINSTANCEID¶
The identifier of the Amazon Connect instance. You can find the instance ID in the Amazon Resource Name (ARN) of the instance.
io_fromemailaddress TYPE REF TO /AWS1/CL_CNTEMAILADDRESSINFO /AWS1/CL_CNTEMAILADDRESSINFO¶
The email address of the customer.
iv_destinationemailaddress TYPE /AWS1/CNTEMAILADDRESS /AWS1/CNTEMAILADDRESS¶
The email address associated with the Amazon Connect instance.
io_emailmessage TYPE REF TO /AWS1/CL_CNTINBOUNDEMAILCONT /AWS1/CL_CNTINBOUNDEMAILCONT¶
The email message body to be sent to the newly created email.
Optional arguments:¶
iv_description TYPE /AWS1/CNTDESCRIPTION /AWS1/CNTDESCRIPTION¶
A description of the email contact.
it_references TYPE /AWS1/CL_CNTREFERENCE=>TT_CONTACTREFERENCES TT_CONTACTREFERENCES¶
A formatted URL that is shown to an agent in the Contact Control Panel (CCP). Emails can have the following reference types at the time of creation:
URL|NUMBER|STRING|DATE.EMAIL_MESSAGE|ATTACHMENTare not a supported reference type during email creation.
iv_name TYPE /AWS1/CNTNAME /AWS1/CNTNAME¶
The name of a email that is shown to an agent in the Contact Control Panel (CCP).
io_additionalrecipients TYPE REF TO /AWS1/CL_CNTINBOUNDADDLRECIP00 /AWS1/CL_CNTINBOUNDADDLRECIP00¶
The additional recipients address of the email.
it_attachments TYPE /AWS1/CL_CNTEMAILATTACHMENT=>TT_EMAILATTACHMENTS TT_EMAILATTACHMENTS¶
List of S3 presigned URLs of email attachments and their file name.
iv_contactflowid TYPE /AWS1/CNTCONTACTFLOWID /AWS1/CNTCONTACTFLOWID¶
The identifier of the flow for initiating the emails. To see the ContactFlowId in the Amazon Connect admin website, on the navigation menu go to Routing, Flows. Choose the flow. On the flow page, under the name of the flow, choose Show additional flow information. The ContactFlowId is the last part of the ARN, shown here in bold:
arn:aws:connect:us-west-2:xxxxxxxxxxxx:instance/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/contact-flow/846ec553-a005-41c0-8341-xxxxxxxxxxxx
iv_relatedcontactid TYPE /AWS1/CNTCONTACTID /AWS1/CNTCONTACTID¶
The contactId that is related to this contact. Linking emails together by using
RelatedContactIDcopies over contact attributes from the related email contact to the new email contact. All updates to user-defined attributes in the new email contact are limited to the individual contact ID. There are no limits to the number of contacts that can be linked by usingRelatedContactId.
it_attributes TYPE /AWS1/CL_CNTATTRIBUTES_W=>TT_ATTRIBUTES TT_ATTRIBUTES¶
A custom key-value pair using an attribute map. The attributes are standard Amazon Connect attributes, and can be accessed in flows just like any other contact attributes.
There can be up to 32,768 UTF-8 bytes across all key-value pairs per contact. Attribute keys can include only alphanumeric, dash, and underscore characters.
it_segmentattributes TYPE /AWS1/CL_CNTSEGMENTATTRVALUE=>TT_SEGMENTATTRIBUTES TT_SEGMENTATTRIBUTES¶
A set of system defined key-value pairs stored on individual contact segments using an attribute map. The attributes are standard Amazon Connect attributes. They can be accessed in flows.
Attribute keys can include only alphanumeric, -, and _.
This field can be used to show channel subtype, such as
connect:Guide.To set contact expiry, a
ValueMapmust be specified containing the integer number of minutes the contact will be active for before expiring, withSegmentAttributeslike {"connect:ContactExpiry": {"ValueMap" : { "ExpiryDuration": { "ValueInteger":135}}}}.
iv_clienttoken TYPE /AWS1/CNTCLIENTTOKEN /AWS1/CNTCLIENTTOKEN¶
A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs.
RETURNING¶
oo_output TYPE REF TO /aws1/cl_cntstrtemailcontact01 /AWS1/CL_CNTSTRTEMAILCONTACT01¶
Domain /AWS1/RT_ACCOUNT_ID Primitive Type NUMC
Examples¶
Syntax Example¶
This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.
DATA(lo_result) = lo_client->startemailcontact(
io_additionalrecipients = new /aws1/cl_cntinboundaddlrecip00(
it_ccaddresses = VALUE /aws1/cl_cntemailaddressinfo=>tt_emailaddressrecipientlist(
(
new /aws1/cl_cntemailaddressinfo(
iv_displayname = |string|
iv_emailaddress = |string|
)
)
)
it_toaddresses = VALUE /aws1/cl_cntemailaddressinfo=>tt_emailaddressrecipientlist(
(
new /aws1/cl_cntemailaddressinfo(
iv_displayname = |string|
iv_emailaddress = |string|
)
)
)
)
io_emailmessage = new /aws1/cl_cntinboundemailcont(
io_rawmessage = new /aws1/cl_cntinboundrawmessage(
it_headers = VALUE /aws1/cl_cntemailheaders_w=>tt_emailheaders(
(
VALUE /aws1/cl_cntemailheaders_w=>ts_emailheaders_maprow(
value = new /aws1/cl_cntemailheaders_w( |string| )
key = |string|
)
)
)
iv_body = |string|
iv_contenttype = |string|
iv_subject = |string|
)
iv_messagesourcetype = |string|
)
io_fromemailaddress = new /aws1/cl_cntemailaddressinfo(
iv_displayname = |string|
iv_emailaddress = |string|
)
it_attachments = VALUE /aws1/cl_cntemailattachment=>tt_emailattachments(
(
new /aws1/cl_cntemailattachment(
iv_filename = |string|
iv_s3url = |string|
)
)
)
it_attributes = VALUE /aws1/cl_cntattributes_w=>tt_attributes(
(
VALUE /aws1/cl_cntattributes_w=>ts_attributes_maprow(
key = |string|
value = new /aws1/cl_cntattributes_w( |string| )
)
)
)
it_references = VALUE /aws1/cl_cntreference=>tt_contactreferences(
(
VALUE /aws1/cl_cntreference=>ts_contactreferences_maprow(
key = |string|
value = new /aws1/cl_cntreference(
iv_arn = |string|
iv_status = |string|
iv_statusreason = |string|
iv_type = |string|
iv_value = |string|
)
)
)
)
it_segmentattributes = VALUE /aws1/cl_cntsegmentattrvalue=>tt_segmentattributes(
(
VALUE /aws1/cl_cntsegmentattrvalue=>ts_segmentattributes_maprow(
value = new /aws1/cl_cntsegmentattrvalue(
it_valuelist = VALUE /aws1/cl_cntsegmentattrvalue=>tt_segmentattributevaluelist(
(
new /aws1/cl_cntsegmentattrvalue(
it_valuemap = VALUE /aws1/cl_cntsegmentattrvalue=>tt_segmentattributevaluemap(
(
VALUE /aws1/cl_cntsegmentattrvalue=>ts_segmentattrvaluemap_maprow(
value = new /aws1/cl_cntsegmentattrvalue(
iv_valuearn = |string|
iv_valueinteger = 123
iv_valuestring = |string|
)
key = |string|
)
)
)
iv_valuearn = |string|
iv_valueinteger = 123
iv_valuestring = |string|
)
)
)
it_valuemap = VALUE /aws1/cl_cntsegmentattrvalue=>tt_segmentattributevaluemap(
(
VALUE /aws1/cl_cntsegmentattrvalue=>ts_segmentattrvaluemap_maprow(
value = new /aws1/cl_cntsegmentattrvalue(
it_valuelist = VALUE /aws1/cl_cntsegmentattrvalue=>tt_segmentattributevaluelist(
(
new /aws1/cl_cntsegmentattrvalue(
iv_valuearn = |string|
iv_valueinteger = 123
iv_valuestring = |string|
)
)
)
iv_valuearn = |string|
iv_valueinteger = 123
iv_valuestring = |string|
)
key = |string|
)
)
)
iv_valuearn = |string|
iv_valueinteger = 123
iv_valuestring = |string|
)
key = |string|
)
)
)
iv_clienttoken = |string|
iv_contactflowid = |string|
iv_description = |string|
iv_destinationemailaddress = |string|
iv_instanceid = |string|
iv_name = |string|
iv_relatedcontactid = |string|
).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lv_contactid = lo_result->get_contactid( ).
ENDIF.