Question 420
A shared workflow expects a numeric spending cap but the agent passes currency text with symbols. What should the agent developer implement to resolve this specific gap?
Explanation
Correct Answer
This is the most suitable change because numeric approvals cannot rely on ambiguous free-text coercion. The key design choice is to convert and validate currency/decimal values before policy comparison. Confirm it through this outcome: Boundary tests at the cap make identical decisions independent of formatting.
Incorrect Answers
This would be more appropriate for a different problem: A field-service agent flow must escalate hardware repairs over a cost cap rather than approve them automatically. That problem calls for: Compare the quoted cost with the configured threshold and route high values for approval. The present case instead requires a solution because numeric approvals cannot rely on ambiguous free-text coercion.
This would be more appropriate for a different problem: A service request flow receives a ticket ID and customer ID as text but downstream actions require validated structured inputs. That problem calls for: Define explicit input parameters, types and validation before invoking the connector. The present case instead requires a solution because numeric approvals cannot rely on ambiguous free-text coercion.
This would be more appropriate for a different problem: A flow sends sensitive attachments to a public email address when an approval field is blank. That problem calls for: Fail closed on empty recipient and validate destinations against authorized approvers. The present case instead requires a solution because numeric approvals cannot rely on ambiguous free-text coercion.