Skip to content

Commit 26fec88

Browse files
author
awstools
committed
feat(client-bedrock-agent): This release adds the Agent Lifecycle Paused State feature to Amazon Bedrock agents. By using an agent's alias, you can temporarily suspend agent operations during maintenance, updates, or other situations.
1 parent a741c9e commit 26fec88

File tree

8 files changed

+131
-33
lines changed

8 files changed

+131
-33
lines changed

clients/client-bedrock-agent/src/commands/CreateAgentAliasCommand.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@ export interface CreateAgentAliasCommandOutput extends CreateAgentAliasResponse,
8484
* // failureReasons: [ // FailureReasons
8585
* // "STRING_VALUE",
8686
* // ],
87+
* // aliasInvocationState: "ACCEPT_INVOCATIONS" || "REJECT_INVOCATIONS",
8788
* // },
8889
* // };
8990
*

clients/client-bedrock-agent/src/commands/GetAgentAliasCommand.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ export interface GetAgentAliasCommandOutput extends GetAgentAliasResponse, __Met
7373
* // failureReasons: [ // FailureReasons
7474
* // "STRING_VALUE",
7575
* // ],
76+
* // aliasInvocationState: "ACCEPT_INVOCATIONS" || "REJECT_INVOCATIONS",
7677
* // },
7778
* // };
7879
*

clients/client-bedrock-agent/src/commands/ListAgentAliasesCommand.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ export interface ListAgentAliasesCommandOutput extends ListAgentAliasesResponse,
5757
* // agentAliasStatus: "CREATING" || "PREPARED" || "FAILED" || "UPDATING" || "DELETING" || "DISSOCIATED", // required
5858
* // createdAt: new Date("TIMESTAMP"), // required
5959
* // updatedAt: new Date("TIMESTAMP"), // required
60+
* // aliasInvocationState: "ACCEPT_INVOCATIONS" || "REJECT_INVOCATIONS",
6061
* // },
6162
* // ],
6263
* // nextToken: "STRING_VALUE",

clients/client-bedrock-agent/src/commands/UpdateAgentAliasCommand.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ export interface UpdateAgentAliasCommandOutput extends UpdateAgentAliasResponse,
4646
* provisionedThroughput: "STRING_VALUE",
4747
* },
4848
* ],
49+
* aliasInvocationState: "ACCEPT_INVOCATIONS" || "REJECT_INVOCATIONS",
4950
* };
5051
* const command = new UpdateAgentAliasCommand(input);
5152
* const response = await client.send(command);
@@ -81,6 +82,7 @@ export interface UpdateAgentAliasCommandOutput extends UpdateAgentAliasResponse,
8182
* // failureReasons: [ // FailureReasons
8283
* // "STRING_VALUE",
8384
* // ],
85+
* // aliasInvocationState: "ACCEPT_INVOCATIONS" || "REJECT_INVOCATIONS",
8486
* // },
8587
* // };
8688
*

clients/client-bedrock-agent/src/models/models_0.ts

Lines changed: 54 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -472,7 +472,7 @@ export interface CreateAgentActionGroupRequest {
472472
* Computer use is a new Anthropic Claude model capability (in beta) available with Anthropic Claude 3.7 Sonnet and Claude 3.5 Sonnet v2 only.
473473
* When operating computer use functionality, we recommend taking additional security precautions,
474474
* such as executing computer actions in virtual environments with restricted data access and limited internet connectivity.
475-
* For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agent-computer-use.html">Configure an Amazon Bedrock Agent to complete tasks with computer use tools</a>.
475+
* For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-computer-use.html">Configure an Amazon Bedrock Agent to complete tasks with computer use tools</a>.
476476
* </p>
477477
* </important>
478478
* <ul>
@@ -500,7 +500,7 @@ export interface CreateAgentActionGroupRequest {
500500
* <p>The configuration settings for a computer use action.</p>
501501
* <important>
502502
* <p>
503-
* Computer use is a new Anthropic Claude model capability (in beta) available with Anthropic Claude 3.7 Sonnet and Claude 3.5 Sonnet v2 only. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agent-computer-use.html">Configure an Amazon Bedrock Agent to complete tasks with computer use tools</a>.
503+
* Computer use is a new Anthropic Claude model capability (in beta) available with Anthropic Claude 3.7 Sonnet and Claude 3.5 Sonnet v2 only. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-computer-use.html">Configure an Amazon Bedrock Agent to complete tasks with computer use tools</a>.
504504
* </p>
505505
* </important>
506506
* @public
@@ -597,7 +597,7 @@ export interface AgentActionGroup {
597597
* <p>The configuration settings for a computer use action.</p>
598598
* <important>
599599
* <p>
600-
* Computer use is a new Anthropic Claude model capability (in beta) available with Claude 3.7 Sonnet and Claude 3.5 Sonnet v2 only. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agent-computer-use.html">Configure an Amazon Bedrock Agent to complete tasks with computer use tools</a>.
600+
* Computer use is a new Anthropic Claude model capability (in beta) available with Claude 3.7 Sonnet and Claude 3.5 Sonnet v2 only. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-computer-use.html">Configure an Amazon Bedrock Agent to complete tasks with computer use tools</a>.
601601
* </p>
602602
* </important>
603603
* @public
@@ -967,7 +967,7 @@ export interface UpdateAgentActionGroupRequest {
967967
* Computer use is a new Anthropic Claude model capability (in beta) available with Anthropic Claude 3.7 Sonnet and Claude 3.5 Sonnet v2 only.
968968
* When operating computer use functionality, we recommend taking additional security precautions,
969969
* such as executing computer actions in virtual environments with restricted data access and limited internet connectivity.
970-
* For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agent-computer-use.html">Configure an Amazon Bedrock Agent to complete tasks with computer use tools</a>.
970+
* For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-computer-use.html">Configure an Amazon Bedrock Agent to complete tasks with computer use tools</a>.
971971
* </p>
972972
* </important>
973973
* <ul>
@@ -996,7 +996,7 @@ export interface UpdateAgentActionGroupRequest {
996996
* <p>The configuration settings for a computer use action.</p>
997997
* <important>
998998
* <p>
999-
* Computer use is a new Anthropic Claude model capability (in beta) available with Claude 3.7 Sonnet and Claude 3.5 Sonnet v2 only. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agent-computer-use.html">Configure an Amazon Bedrock Agent to complete tasks with computer use tools</a>.
999+
* Computer use is a new Anthropic Claude model capability (in beta) available with Claude 3.7 Sonnet and Claude 3.5 Sonnet v2 only. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-computer-use.html">Configure an Amazon Bedrock Agent to complete tasks with computer use tools</a>.
10001000
* </p>
10011001
* </important>
10021002
* @public
@@ -1316,7 +1316,7 @@ export interface PromptConfiguration {
13161316
* <ul>
13171317
* <li>
13181318
* <p>
1319-
* <code>PRE_PROCESSING</code> – <code>ENABLED</code>
1319+
* <code>PRE_PROCESSING</code> – <code>DISABLED</code>
13201320
* </p>
13211321
* </li>
13221322
* <li>
@@ -1627,6 +1627,26 @@ export const AgentAliasStatus = {
16271627
*/
16281628
export type AgentAliasStatus = (typeof AgentAliasStatus)[keyof typeof AgentAliasStatus];
16291629

1630+
/**
1631+
* @public
1632+
* @enum
1633+
*/
1634+
export const AliasInvocationState = {
1635+
/**
1636+
* Agent is actively processing requests
1637+
*/
1638+
ACCEPT_INVOCATIONS: "ACCEPT_INVOCATIONS",
1639+
/**
1640+
* Agent is paused and will not accept new requests
1641+
*/
1642+
REJECT_INVOCATIONS: "REJECT_INVOCATIONS",
1643+
} as const;
1644+
1645+
/**
1646+
* @public
1647+
*/
1648+
export type AliasInvocationState = (typeof AliasInvocationState)[keyof typeof AliasInvocationState];
1649+
16301650
/**
16311651
* <p>Contains details about an alias of an agent.</p>
16321652
* @public
@@ -1724,6 +1744,15 @@ export interface AgentAlias {
17241744
* @public
17251745
*/
17261746
failureReasons?: string[] | undefined;
1747+
1748+
/**
1749+
* <p>The invocation state for the agent alias. If the agent alias is running,
1750+
* the value is <code>ACCEPT_INVOCATIONS</code>. If the agent alias is paused,
1751+
* the value is <code>REJECT_INVOCATIONS</code>. Use the <code>UpdateAgentAlias</code> operation
1752+
* to change the invocation state.</p>
1753+
* @public
1754+
*/
1755+
aliasInvocationState?: AliasInvocationState | undefined;
17271756
}
17281757

17291758
/**
@@ -1772,6 +1801,15 @@ export interface AgentAliasSummary {
17721801
* @public
17731802
*/
17741803
updatedAt: Date | undefined;
1804+
1805+
/**
1806+
* <p>The invocation state for the agent alias. If the agent alias is running,
1807+
* the value is <code>ACCEPT_INVOCATIONS</code>. If the agent alias is paused,
1808+
* the value is <code>REJECT_INVOCATIONS</code>. Use the <code>UpdateAgentAlias</code> operation
1809+
* to change the invocation state.</p>
1810+
* @public
1811+
*/
1812+
aliasInvocationState?: AliasInvocationState | undefined;
17751813
}
17761814

17771815
/**
@@ -3050,6 +3088,16 @@ export interface UpdateAgentAliasRequest {
30503088
* @public
30513089
*/
30523090
routingConfiguration?: AgentAliasRoutingConfigurationListItem[] | undefined;
3091+
3092+
/**
3093+
* <p>The invocation state for the agent alias. To pause the agent alias, set the value to
3094+
* <code>REJECT_INVOCATIONS</code>. To start the agent alias running again, set the value to
3095+
* <code>ACCEPT_INVOCATIONS</code>. Use the <code>GetAgentAlias</code>, or
3096+
* <code>ListAgentAliases</code>, operation to get the invocation state of an agent
3097+
* alias.</p>
3098+
* @public
3099+
*/
3100+
aliasInvocationState?: AliasInvocationState | undefined;
30533101
}
30543102

30553103
/**
@@ -9163,24 +9211,6 @@ export interface IngestionJobStatistics {
91639211
numberOfDocumentsFailed?: number | undefined;
91649212
}
91659213

9166-
/**
9167-
* @public
9168-
* @enum
9169-
*/
9170-
export const IngestionJobStatus = {
9171-
COMPLETE: "COMPLETE",
9172-
FAILED: "FAILED",
9173-
IN_PROGRESS: "IN_PROGRESS",
9174-
STARTING: "STARTING",
9175-
STOPPED: "STOPPED",
9176-
STOPPING: "STOPPING",
9177-
} as const;
9178-
9179-
/**
9180-
* @public
9181-
*/
9182-
export type IngestionJobStatus = (typeof IngestionJobStatus)[keyof typeof IngestionJobStatus];
9183-
91849214
/**
91859215
* @internal
91869216
*/

clients/client-bedrock-agent/src/models/models_1.ts

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ import {
2323
FlowValidation,
2424
FlowValidationFilterSensitiveLog,
2525
IngestionJobStatistics,
26-
IngestionJobStatus,
2726
InlineCodeFlowNodeConfiguration,
2827
InlineCodeFlowNodeConfigurationFilterSensitiveLog,
2928
InputFlowNodeConfiguration,
@@ -48,6 +47,24 @@ import {
4847
StorageFlowNodeConfiguration,
4948
} from "./models_0";
5049

50+
/**
51+
* @public
52+
* @enum
53+
*/
54+
export const IngestionJobStatus = {
55+
COMPLETE: "COMPLETE",
56+
FAILED: "FAILED",
57+
IN_PROGRESS: "IN_PROGRESS",
58+
STARTING: "STARTING",
59+
STOPPED: "STOPPED",
60+
STOPPING: "STOPPING",
61+
} as const;
62+
63+
/**
64+
* @public
65+
*/
66+
export type IngestionJobStatus = (typeof IngestionJobStatus)[keyof typeof IngestionJobStatus];
67+
5168
/**
5269
* <p>Contains details about a data ingestion job. Data sources are ingested into a knowledge base so that Large Language Models (LLMs) can use your data.</p>
5370
* <p>This data type is used in the following API operations:</p>
@@ -4047,7 +4064,10 @@ export namespace FlowNodeConfiguration {
40474064
* <code>LoopInput</code> - The entry point node for the loop. This node receives inputs from nodes outside the loop and from previous loop iterations.</p>
40484065
* </li>
40494066
* <li>
4050-
* <p>Body nodes - These can be </p>
4067+
* <p>Body nodes - The processing nodes that execute within each loop iteration.
4068+
* These can be nodes for handling data in your flow, such as a prompt or Lambda
4069+
* function nodes. Some node types aren't supported inside a DoWhile loop body. For
4070+
* more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_LoopIncompatibleNodeTypeFlowValidationDetails.html">LoopIncompatibleNodeTypeFlowValidationDetails</a>.</p>
40514071
* </li>
40524072
* <li>
40534073
* <p>

clients/client-bedrock-agent/src/protocols/Aws_restJson1.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1791,6 +1791,7 @@ export const se_UpdateAgentAliasCommand = async (
17911791
body = JSON.stringify(
17921792
take(input, {
17931793
agentAliasName: [],
1794+
aliasInvocationState: [],
17941795
description: [],
17951796
routingConfiguration: (_) => _json(_),
17961797
})
@@ -4780,6 +4781,7 @@ const de_AgentAlias = (output: any, context: __SerdeContext): AgentAlias => {
47804781
agentAliasName: __expectString,
47814782
agentAliasStatus: __expectString,
47824783
agentId: __expectString,
4784+
aliasInvocationState: __expectString,
47834785
clientToken: __expectString,
47844786
createdAt: (_: any) => __expectNonNull(__parseRfc3339DateTimeWithOffset(_)),
47854787
description: __expectString,
@@ -4836,6 +4838,7 @@ const de_AgentAliasSummary = (output: any, context: __SerdeContext): AgentAliasS
48364838
agentAliasId: __expectString,
48374839
agentAliasName: __expectString,
48384840
agentAliasStatus: __expectString,
4841+
aliasInvocationState: __expectString,
48394842
createdAt: (_: any) => __expectNonNull(__parseRfc3339DateTimeWithOffset(_)),
48404843
description: __expectString,
48414844
routingConfiguration: _json,

0 commit comments

Comments
 (0)