AWS Certified Solutions Architect - Professional free question 6 / 10 · Domain 3: Cost-Optimized Architecture Design
A team uses Amazon Bedrock through the Chat Completions API. Several teams call through a shared role, and the calling code cannot be changed. You want to see Bedrock cost by role and by team in Cost Explorer. The operations staff is small and does not want more resources to manage. Which method is correct?
- Use IAM principal attribution, which records the caller identity; if you tag the roles, you can also aggregate by tag
- Do not use session tags with a shared role, because a role tag has priority over a session tag; use role tags only
- Cost Explorer shows the cost of each request as it is, so aggregate the cost per prompt by team
- Create an application inference profile and specify it as the inference target of the Chat Completions API
Show the answer and explanation
Answer: A
Why this is correct
IAM principal attribution means that when an IAM user or role makes an inference request, Amazon Bedrock records the caller's identity. This flows into Cost Explorer and CUR 2.0, where you can filter and group cost by identity. It works with the Chat Completions API and other APIs, and it needs no change to the calling code. If you tag the roles, you can add axes such as team or cost center. With a shared role, you can pass session tags when the role is assumed to distinguish users, and a session tag value overrides a principal tag value with the same key.
Why the other options are wrong
"Create an application inference profile and specify it as the inference target of the Chat Completions API" … The Application inference profiles page (cost-mgmt-application-inference-profiles) says they are not supported by the Responses and Chat Completions APIs: a request to those APIs that names an application inference profile as its inference target is rejected with a 400 error. The calling code also cannot be changed here.
"Cost Explorer shows the cost of each request as it is, so aggregate the cost per prompt by team" … The finest grain is per usage type per day. It does not produce per-request cost. For per-prompt detail, you need request metadata or logs.
"Do not use session tags with a shared role, because a role tag has priority over a session tag; use role tags only" … When a session tag and a principal tag share the same key, the session tag value overrides the principal tag value. Session tags are the way to distinguish users of a shared role.
Key point
To see cost by role or team without changing calling code, use IAM principal attribution. The grain is per usage type per day, not per request.