CCDV-F practice › Applications & Integration · Question 43 of 92
Applications & Integration
A response comes back with stop_reason of 'refusal'. What should production code do?
Show answer and explanation
Answer: B — Handle it explicitly and log it, rather than treating it as a completed answer
Each stop_reason branch exists because a distinct production failure lives there. A refusal is an explicit, loggable outcome — blindly parsing it or retrying the same request unchanged both ignore what actually happened.
Keep going
More Applications & Integration questions
- A team is choosing between calling Claude directly and going through a third-party…
- A product spec says: 'Clinicians must be able to upload a scanned referral letter and…
- A requirement states claim data may not leave the hospital network, and separately that…
- A team wants to know whether their prompt cache is actually working. What is evidence…
- Which of these belongs in version control alongside application code? Select the TWO…