What is Claude and when should you use it?
Compare Claude chat, Claude Code, and the Claude API, then test one source-grounded exercise before choosing an interface.
Learn what to try in Claude chat, when to use the API, and how to verify your first response before adding streaming.
Paste the sentence “The export test passed on 14 May. A rollout date is pending approval.” into Claude and ask it to return the test date and the rollout date separately. Specify that an unconfirmed date should be written as pending.
The expected response is 14 May for the test date and pending for rollout. If Claude puts 14 May in both fields, clarify which event each field describes. The exercise isolates the behavior you want before you add application code.
The Messages API is the interface for sending prompts from code. To get started, use the model ID available to your account, a small output budget, and a user message with the same sample sentence. Keep credentials on the server or in your development process environment. The browser only needs the response your application chooses to show.
Capture errors and inspect the response text before using it. In this example you can compare two short lines. For a response that feeds software, validate the result before passing it on.
Streaming can render text as it arrives. Test it using the same sample and compare the final text with a normal request. Handle a stream that stops partway through so your app can tell the reader that the response is incomplete.
Compare Claude chat, Claude Code, and the Claude API, then test one source-grounded exercise before choosing an interface.
Create development API access, provide a credential securely to a Python process, and verify one Messages API response.
Build a Python Messages API request with conversational context, inspect text and token usage, and handle status errors.
Render text increments from the Claude API, check the final stop reason, and handle interrupted output.