Skip to content

FunctionResult

Source code in docs_src/capo_bedrock_agent_runtime/types/function_result.py
class FunctionResult(TypedDict, closed=True):
    action_group: "str"
    """<p>The action group that the function belongs to.</p>"""
    confirmation_state: NotRequired[
        "capo_bedrock_agent_runtime.types.confirmation_state.ConfirmationState"
    ]
    """<p>Contains the user confirmation information about the function that was called.</p>"""
    function: NotRequired["str"]
    """<p>The name of the function that was called.</p>"""
    response_body: NotRequired[
        "capo_bedrock_agent_runtime.types.response_body.ResponseBody"
    ]
    """<p>The response from the function call using the parameters. The response might be returned directly or from the Lambda function. Specify <code>TEXT</code> or <code>IMAGES</code>. The key of the object is the content type. You can only specify one type. If you specify <code>IMAGES</code>, you can specify only one image. You can specify images only when the function in the <code>returnControlInvocationResults</code> is a computer use action. 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>.</p>"""
    response_state: NotRequired[
        "capo_bedrock_agent_runtime.types.response_state.ResponseState"
    ]
    """<p>Controls the final response state returned to end user when API/Function execution failed. When this state is FAILURE, the request would fail with dependency failure exception. When this state is REPROMPT, the API/function response will be sent to model for re-prompt</p>"""
    agent_id: NotRequired["str"]
    """<p>The agent's ID.</p>"""

action_group instance-attribute

action_group: str

The action group that the function belongs to.

agent_id instance-attribute

agent_id: NotRequired[str]

The agent's ID.

confirmation_state instance-attribute

confirmation_state: NotRequired[ConfirmationState]

Contains the user confirmation information about the function that was called.

function instance-attribute

function: NotRequired[str]

The name of the function that was called.

response_body instance-attribute

response_body: NotRequired[ResponseBody]

The response from the function call using the parameters. The response might be returned directly or from the Lambda function. Specify TEXT or IMAGES. The key of the object is the content type. You can only specify one type. If you specify IMAGES, you can specify only one image. You can specify images only when the function in the returnControlInvocationResults is a computer use action. For more information, see Configure an Amazon Bedrock Agent to complete tasks with computer use tools.

response_state instance-attribute

response_state: NotRequired[ResponseState]

Controls the final response state returned to end user when API/Function execution failed. When this state is FAILURE, the request would fail with dependency failure exception. When this state is REPROMPT, the API/function response will be sent to model for re-prompt