/AWS1/CL_DOG=>ADDNOTIFICATIONCHANNEL()
¶
About AddNotificationChannel¶
Adds a notification channel to DevOps Guru. A notification channel is used to notify you about important DevOps Guru events, such as when an insight is generated.
If you use an Amazon SNS topic in another account, you must attach a policy to it that grants DevOps Guru permission to send it notifications. DevOps Guru adds the required policy on your behalf to send notifications using Amazon SNS in your account. DevOps Guru only supports standard SNS topics. For more information, see Permissions for Amazon SNS topics.
If you use an Amazon SNS topic that is encrypted by an Amazon Web Services Key Management Service customer-managed key (CMK), then you must add permissions to the CMK. For more information, see Permissions for Amazon Web Services KMS–encrypted Amazon SNS topics.
Method Signature¶
IMPORTING¶
Required arguments:¶
io_config
TYPE REF TO /AWS1/CL_DOGNOTIFCHANNELCONFIG
/AWS1/CL_DOGNOTIFCHANNELCONFIG
¶
A
NotificationChannelConfig
object that specifies what type of notification channel to add. The one supported notification channel is Amazon Simple Notification Service (Amazon SNS).
RETURNING¶
oo_output
TYPE REF TO /aws1/cl_dogaddnotifchannelrsp
/AWS1/CL_DOGADDNOTIFCHANNELRSP
¶
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->/aws1/if_dog~addnotificationchannel(
io_config = new /aws1/cl_dognotifchannelconfig(
io_filters = new /aws1/cl_dognotiffilterconfig(
it_messagetypes = VALUE /aws1/cl_dognotifmsgtypes_w=>tt_notificationmessagetypes(
( new /aws1/cl_dognotifmsgtypes_w( |string| ) )
)
it_severities = VALUE /aws1/cl_doginsightseveritie00=>tt_insightseverities(
( new /aws1/cl_doginsightseveritie00( |string| ) )
)
)
io_sns = new /aws1/cl_dogsnschannelconfig( |string| )
)
).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lv_notificationchannelid = lo_result->get_id( ).
ENDIF.