Sent to a tool’s web_hook_url (or the SWAIG defaults.web_hook_url) when an
amazon_bedrock agent calls one of your functions.
Your endpoint runs the function and returns a JSON object with a response string (the result the
agent reads next) and, optionally, an action — a single object or an array — telling the agent
what to do.
Bedrock agents send a different payload from ai agents. Notably
content_type is text/json rather than text/swaig, argument carries no substituted value,
there is no version, description, or argument_desc, and the call’s timing and caller fields
are named differently. Write your handler against this payload, not the
AI SWAIG tool webhook.
The ID of the AI session on the call. Matches call_id for Bedrock agents.
The name of your Bedrock application. Defaults to bedrock.
The agent’s current global_data. An empty object when you seeded none.
The content type of the request body. Always text/json.
How the body is delivered. Always agent.function for a function call.
The kind of conversation the agent is running. Always voice.
What the request is asking of you. Always fetch_conversation for a function call; the
end-of-call conversation report sends post_conversation instead.
The token that scopes meta_data. This is the meta_data_token you set on the function, or an
MD5 of the function’s name when you did not set one.
Metadata scoped to meta_data_token. An empty object when the function has none yet.
When the call was answered, as a Unix timestamp in microseconds. 0 when it never was.
When the call ended, as a Unix timestamp in microseconds. 0 while the call is still up.
Per-response performance metrics for the session so far. Included once the agent has any.