The Scenario
An e-commerce company wants to let their AI support bot issue refunds via the Stripe API for orders under R500, but only if the package is proven lost by the courier API. This is high risk. If the AI hallucinates, it costs the company money.
The Brief
Design the secure, multi-step workflow required to safely allow an AI to trigger a financial transaction.
Deliverables
- The architecture flow: User Query -> AI Intent -> Courier API Check -> Rule Evaluation -> Stripe API Action
- The "Rules Engine" prompt (the separate prompt that evaluates the courier data against the R500 rule before approving the action)
- The fail-safe mechanisms (What happens if the courier API is down? What if the order is R501?)
Submission Guidance
Never let one LLM prompt handle user intent and financial execution simultaneously. You must design a deterministic rules engine (or a separate strict LLM judge) to authorize the transaction.
Submit Your Work
Your submission is graded against the rubric on the right. If you pass, you get a public Badge URL you can share on LinkedIn. There is no draft save, so work offline first and paste your finished response here.