@aws-sdk/client-chatbot 3.699.0 → 3.700.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -63,6 +63,18 @@ declare const AssociateToConfigurationCommand_base: {
63
63
  * <p>Base exception class for all service exceptions from Chatbot service.</p>
64
64
  *
65
65
  * @public
66
+ * @example Associate a custom action to a configuration
67
+ * ```javascript
68
+ * // Associate a custom action to a channel configuration, allowing it to be used in that channel
69
+ * const input = {
70
+ * "ChatConfiguration": "arn:aws:chatbot::1234567890:chat-configuration/slack-channel/my-channel",
71
+ * "Resource": "arn:aws:chatbot::1234567890:custom-action/my-custom-action"
72
+ * };
73
+ * const command = new AssociateToConfigurationCommand(input);
74
+ * await client.send(command);
75
+ * // example id: example-1
76
+ * ```
77
+ *
66
78
  */
67
79
  export declare class AssociateToConfigurationCommand extends AssociateToConfigurationCommand_base {
68
80
  /** @internal type navigation helper, not in runtime. */
@@ -97,6 +97,51 @@ declare const CreateCustomActionCommand_base: {
97
97
  * <p>Base exception class for all service exceptions from Chatbot service.</p>
98
98
  *
99
99
  * @public
100
+ * @example Create an alias that invokes a Lambda function
101
+ * ```javascript
102
+ * // Creates an alias that invokes a Lambda function from chat channels. You can use this alias by entering 'run invoke', after which you're prompted for the function name.
103
+ * const input = {
104
+ * "ActionName": "my-custom-action",
105
+ * "AliasName": "invoke",
106
+ * "Definition": {
107
+ * "CommandText": "lambda invoke $functionName"
108
+ * }
109
+ * };
110
+ * const command = new CreateCustomActionCommand(input);
111
+ * const response = await client.send(command);
112
+ * /* response ==
113
+ * {
114
+ * "CustomActionArn": "arn:aws:chatbot::1234567890:custom-action/my-custom-action"
115
+ * }
116
+ * *\/
117
+ * // example id: example-1
118
+ * ```
119
+ *
120
+ * @example Create a custom action to list alarms
121
+ * ```javascript
122
+ * // Creates a button on all Cloudwatch notifications that lists alarms in the ‘ALARM’ state.
123
+ * const input = {
124
+ * "ActionName": "describe-alarms",
125
+ * "Attachments": [
126
+ * {
127
+ * "ButtonText": "List alarms",
128
+ * "NotificationType": "CloudWatch"
129
+ * }
130
+ * ],
131
+ * "Definition": {
132
+ * "CommandText": "cloudwatch describe-alarms --state-value ALARM"
133
+ * }
134
+ * };
135
+ * const command = new CreateCustomActionCommand(input);
136
+ * const response = await client.send(command);
137
+ * /* response ==
138
+ * {
139
+ * "CustomActionArn": "arn:aws:chatbot::1234567890:custom-action/describe-alarms"
140
+ * }
141
+ * *\/
142
+ * // example id: example-2
143
+ * ```
144
+ *
100
145
  */
101
146
  export declare class CreateCustomActionCommand extends CreateCustomActionCommand_base {
102
147
  /** @internal type navigation helper, not in runtime. */
@@ -65,6 +65,17 @@ declare const DeleteCustomActionCommand_base: {
65
65
  * <p>Base exception class for all service exceptions from Chatbot service.</p>
66
66
  *
67
67
  * @public
68
+ * @example Delete a custom action
69
+ * ```javascript
70
+ * //
71
+ * const input = {
72
+ * "CustomActionArn": "arn:aws:chatbot::1234567890:custom-action/my-custom-action"
73
+ * };
74
+ * const command = new DeleteCustomActionCommand(input);
75
+ * await client.send(command);
76
+ * // example id: example-1
77
+ * ```
78
+ *
68
79
  */
69
80
  export declare class DeleteCustomActionCommand extends DeleteCustomActionCommand_base {
70
81
  /** @internal type navigation helper, not in runtime. */
@@ -63,6 +63,18 @@ declare const DisassociateFromConfigurationCommand_base: {
63
63
  * <p>Base exception class for all service exceptions from Chatbot service.</p>
64
64
  *
65
65
  * @public
66
+ * @example Disassociate a custom action from a configuration
67
+ * ```javascript
68
+ * //
69
+ * const input = {
70
+ * "ChatConfiguration": "arn:aws:chatbot::1234567890:chat-configuration/slack-channel/my-channel",
71
+ * "Resource": "arn:aws:chatbot::1234567890:custom-action/my-custom-action"
72
+ * };
73
+ * const command = new DisassociateFromConfigurationCommand(input);
74
+ * await client.send(command);
75
+ * // example id: example-1
76
+ * ```
77
+ *
66
78
  */
67
79
  export declare class DisassociateFromConfigurationCommand extends DisassociateFromConfigurationCommand_base {
68
80
  /** @internal type navigation helper, not in runtime. */
@@ -90,6 +90,28 @@ declare const GetCustomActionCommand_base: {
90
90
  * <p>Base exception class for all service exceptions from Chatbot service.</p>
91
91
  *
92
92
  * @public
93
+ * @example Get a custom action
94
+ * ```javascript
95
+ * //
96
+ * const input = {
97
+ * "CustomActionArn": "arn:aws:chatbot::1234567890:custom-action/my-custom-action"
98
+ * };
99
+ * const command = new GetCustomActionCommand(input);
100
+ * const response = await client.send(command);
101
+ * /* response ==
102
+ * {
103
+ * "CustomAction": {
104
+ * "ActionName": "my-custom-action",
105
+ * "CustomActionArn": "arn:aws:chatbot::1234567890:custom-action/my-custom-action",
106
+ * "Definition": {
107
+ * "CommandText": "lambda invoke $functionName"
108
+ * }
109
+ * }
110
+ * }
111
+ * *\/
112
+ * // example id: example-1
113
+ * ```
114
+ *
93
115
  */
94
116
  export declare class GetCustomActionCommand extends GetCustomActionCommand_base {
95
117
  /** @internal type navigation helper, not in runtime. */
@@ -62,6 +62,26 @@ declare const ListAssociationsCommand_base: {
62
62
  * <p>Base exception class for all service exceptions from Chatbot service.</p>
63
63
  *
64
64
  * @public
65
+ * @example List custom actions associated with a configuration
66
+ * ```javascript
67
+ * //
68
+ * const input = {
69
+ * "ChatConfiguration": "arn:aws:chatbot::1234567890:chat-configuration/slack-channel/my-channel"
70
+ * };
71
+ * const command = new ListAssociationsCommand(input);
72
+ * const response = await client.send(command);
73
+ * /* response ==
74
+ * {
75
+ * "Associations": [
76
+ * {
77
+ * "Resource": "arn:aws:chatbot::1234567890:custom-action/my-custom-action"
78
+ * }
79
+ * ]
80
+ * }
81
+ * *\/
82
+ * // example id: example-1
83
+ * ```
84
+ *
65
85
  */
66
86
  export declare class ListAssociationsCommand extends ListAssociationsCommand_base {
67
87
  /** @internal type navigation helper, not in runtime. */
@@ -68,6 +68,22 @@ declare const ListCustomActionsCommand_base: {
68
68
  * <p>Base exception class for all service exceptions from Chatbot service.</p>
69
69
  *
70
70
  * @public
71
+ * @example List custom actions
72
+ * ```javascript
73
+ * //
74
+ * const input = {};
75
+ * const command = new ListCustomActionsCommand(input);
76
+ * const response = await client.send(command);
77
+ * /* response ==
78
+ * {
79
+ * "CustomActions": [
80
+ * "arn:aws:chatbot::1234567890:custom-action/my-custom-action"
81
+ * ]
82
+ * }
83
+ * *\/
84
+ * // example id: example-1
85
+ * ```
86
+ *
71
87
  */
72
88
  export declare class ListCustomActionsCommand extends ListCustomActionsCommand_base {
73
89
  /** @internal type navigation helper, not in runtime. */
@@ -87,6 +87,25 @@ declare const UpdateCustomActionCommand_base: {
87
87
  * <p>Base exception class for all service exceptions from Chatbot service.</p>
88
88
  *
89
89
  * @public
90
+ * @example Update the command definition of an existing action
91
+ * ```javascript
92
+ * // Updates the command text of a custom action without altering the existing alias name or attachment criteria
93
+ * const input = {
94
+ * "CustomActionArn": "arn:aws:chatbot::1234567890:custom-action/my-custom-action",
95
+ * "Definition": {
96
+ * "CommandText": "lambda invoke MyNewFunction"
97
+ * }
98
+ * };
99
+ * const command = new UpdateCustomActionCommand(input);
100
+ * const response = await client.send(command);
101
+ * /* response ==
102
+ * {
103
+ * "CustomActionArn": "arn:aws:chatbot::1234567890:custom-action/my-custom-action"
104
+ * }
105
+ * *\/
106
+ * // example id: example-1
107
+ * ```
108
+ *
90
109
  */
91
110
  export declare class UpdateCustomActionCommand extends UpdateCustomActionCommand_base {
92
111
  /** @internal type navigation helper, not in runtime. */
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-chatbot",
3
3
  "description": "AWS SDK for JavaScript Chatbot Client for Node.js, Browser and React Native",
4
- "version": "3.699.0",
4
+ "version": "3.700.0",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "tsc -p tsconfig.cjs.json",