Skip to content

Commit fbec847

Browse files
author
awstools
committed
feat(clients): update command documentation examples as of 2024-12-16
1 parent 8afc56c commit fbec847

File tree

3 files changed

+49
-0
lines changed

3 files changed

+49
-0
lines changed

clients/client-servicediscovery/src/commands/DeleteServiceAttributesCommand.ts

+14
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,20 @@ export interface DeleteServiceAttributesCommandOutput extends DeleteServiceAttri
6464
* <p>Base exception class for all service exceptions from ServiceDiscovery service.</p>
6565
*
6666
* @public
67+
* @example DeleteServiceAttributes example
68+
* ```javascript
69+
* // Example: Delete service attribute by providing attribute key and service ID
70+
* const input = {
71+
* "Attributes": [
72+
* "port"
73+
* ],
74+
* "ServiceId": "srv-e4anhexample0004"
75+
* };
76+
* const command = new DeleteServiceAttributesCommand(input);
77+
* await client.send(command);
78+
* // example id: example-delete-service-attributes-1587416462902
79+
* ```
80+
*
6781
*/
6882
export class DeleteServiceAttributesCommand extends $Command
6983
.classBuilder<

clients/client-servicediscovery/src/commands/GetServiceAttributesCommand.ts

+21
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,27 @@ export interface GetServiceAttributesCommandOutput extends GetServiceAttributesR
6868
* <p>Base exception class for all service exceptions from ServiceDiscovery service.</p>
6969
*
7070
* @public
71+
* @example GetServiceAttributes Example
72+
* ```javascript
73+
* // This example gets the attributes for a specified service.
74+
* const input = {
75+
* "ServiceId": "srv-e4anhexample0004"
76+
* };
77+
* const command = new GetServiceAttributesCommand(input);
78+
* const response = await client.send(command);
79+
* /* response ==
80+
* {
81+
* "ServiceAttributes": {
82+
* "Attributes": {
83+
* "port": "80"
84+
* },
85+
* "ServiceArn": "arn:aws:servicediscovery:us-west-2:123456789012:service/srv-e4anhexample0004"
86+
* }
87+
* }
88+
* *\/
89+
* // example id: get-service-attributes-example-1590117234294
90+
* ```
91+
*
7192
*/
7293
export class GetServiceAttributesCommand extends $Command
7394
.classBuilder<

clients/client-servicediscovery/src/commands/UpdateServiceAttributesCommand.ts

+14
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,20 @@ export interface UpdateServiceAttributesCommandOutput extends UpdateServiceAttri
6767
* <p>Base exception class for all service exceptions from ServiceDiscovery service.</p>
6868
*
6969
* @public
70+
* @example UpdateServiceAttributes Example
71+
* ```javascript
72+
* // This example submits a request to update the specified service to add a port attribute with the value 80.
73+
* const input = {
74+
* "Attributes": {
75+
* "port": "80"
76+
* },
77+
* "ServiceId": "srv-e4anhexample0004"
78+
* };
79+
* const command = new UpdateServiceAttributesCommand(input);
80+
* await client.send(command);
81+
* // example id: update-service-attributes-example-1590117830880
82+
* ```
83+
*
7084
*/
7185
export class UpdateServiceAttributesCommand extends $Command
7286
.classBuilder<

0 commit comments

Comments
 (0)