# CCDV-F Practice: Applications & Integration | YAID

> 20 free CCDV-F practice questions on applications and integration (33.1% of the exam), with study notes and explanations.

Source: https://youraidept.com/network/ccdv-f-practice-questions/applications-and-integration

CCDV-F domain drill

# CCDV-F practice questions: Applications and integration.

20 original questions on Applications and integration, which carries 33.1% of the Claude Certified Developer – Foundations exam per the published guide. Study notes first, then the questions with an explanation for each. When this domain feels solid, take [the timed CCDV-F practice exam](https://youraidept.com/network/ccdv-f-practice-exam) and check the domain breakdown.

## What to know about Applications and integration

- The Messages API: request shape, message roles, system prompt placement, max_tokens, and what each stop_reason means (end_turn, max_tokens, tool_use, stop_sequence).
- Streaming responses and how to handle partial content and tool-use blocks as they arrive.
- Multimodal inputs: images and PDFs as content blocks, and the Files API for reusing uploads.
- Structured output: JSON via tool definitions or structured outputs, and validating what comes back.
- The Batch API for high-volume, non-urgent work at lower cost.
- Errors, rate limits, and retries: status codes, exponential backoff, and idempotent design for anything that writes.
- Prompt caching mechanics: cache breakpoints, minimum lengths, and ordering stable content first.

## Applications and integration questions

All domains (20) Applications and integration (20)

Applications and integration

A response comes back with stop_reason set to max_tokens. What happened?

- The output reached the max_tokens limit and was cut off before the model finished
- The input exceeded the context window and the request was rejected with a 400
- The model reached the natural end of its turn, so the text is complete as returned
- The model emitted a tool_use block and is waiting for a tool_result from your code

Check answer

### Show answer

Answer: The output reached the max_tokens limit and was cut off before the model finished. max_tokens means truncation: the output hit the cap you set. Raise the limit or continue the response. end_turn is the natural finish, and an oversized input fails before any stop_reason is produced.

Applications and integration

A response has stop_reason tool_use. What must your code do next?

- Execute the requested tool, append a tool_result block with the matching id, and call the model again
- Retry the same request with tool_choice set to none so the model answers in plain text
- Return the text blocks to the user, since the API already executed the tool on the server side before responding
- Wait for the model's next message, which will carry the tool_result once execution finishes

Check answer

### Show answer

Answer: Execute the requested tool, append a tool_result block with the matching id, and call the model again. tool_use hands control to your code. You run the tool, return the result in a tool_result block, and let the model continue. Client tools are not executed server-side, and the model cannot produce a tool_result on its own.

Applications and integration

Users should see the answer appear as it is generated. What do you use?

- Set stream to true and render content_block_delta events as they arrive
- Poll the messages endpoint with the message id until a status field reports completion
- Submit the request through the Message Batches API and read results as they land
- Lower max_tokens so each response returns quickly enough to feel incremental

Check answer

### Show answer

Answer: Set stream to true and render content_block_delta events as they arrive. Streaming delivers partial content as server-sent events; your client renders the deltas. There is no polling status for a synchronous message, and batches add latency rather than remove it.

Applications and integration

You have 20,000 documents to classify overnight, with no latency requirement, and cost matters. Best choice?

- Submit them through the Message Batches API and collect results when the batch completes
- Send 20,000 synchronous requests through a worker pool sized to your rate limit
- Concatenate all the documents into one request with a large max_tokens and split the output back apart by document
- Stream each request so results can be written to disk as the tokens arrive

Check answer

### Show answer

Answer: Submit them through the Message Batches API and collect results when the batch completes. Batches trade latency for lower cost and are built for large, non-urgent workloads. A worker pool works but pays full price, and one giant request runs into context and output limits.

Applications and integration

Every request includes the same 30,000-token reference manual followed by a short question. How do you cut cost?

- Upload the manual through the Files API so its tokens are billed once instead of per request
- Send the question first and the manual second so the model reads the task before the context
- Put a cache_control breakpoint on the manual block so the prefix is reused across requests
- Lower temperature and max_tokens so each request generates fewer billable output tokens

Check answer

### Show answer

Answer: Put a cache_control breakpoint on the manual block so the prefix is reused across requests. Prompt caching reuses a stable prefix. The manual is the prefix; the question changes each time and comes after the breakpoint. Files API uploads still count as input tokens on every request that references them.

Applications and integration

Your integration starts receiving HTTP 429 responses. What is the right client behavior?

- Rotate to a second API key from the same organization so requests keep flowing
- Treat 429 as a transient server fault and fail the request back to the user
- Retry immediately in a tight loop, since the limit clears as soon as the window rolls over
- Back off exponentially with jitter and honor the retry-after header when it is present

Check answer

### Show answer

Answer: Back off exponentially with jitter and honor the retry-after header when it is present. 429 is rate limiting. Exponential backoff with jitter spreads retries; retry-after tells you how long to wait. Limits apply at the organization level, so swapping keys does not help.

Applications and integration

Which fields are required in a Messages API request?

- model, messages, and system
- model, messages, and temperature
- model, messages, and max_tokens
- model, max_tokens, and stream

Check answer

### Show answer

Answer: model, messages, and max_tokens. Every request names the model, provides messages, and sets max_tokens. system, temperature, and stream are optional.

Applications and integration

Where does the system prompt go in a Messages API request?

- As a text block at the start of the first user message
- As the first entry in messages with role set to system
- In the top-level system parameter of the request
- In the metadata object alongside the user_id

Check answer

### Show answer

Answer: In the top-level system parameter of the request. The Messages API takes the system prompt as a top-level parameter. messages only accepts user and assistant roles, so a system role entry is rejected.

Applications and integration

A response's content array contains a text block followed by a tool_use block. What does that mean?

- The model wrote some text, then requested a tool call; you run it and return a tool_result
- The response was truncated by max_tokens while writing the tool arguments
- Two parallel responses were merged; keep the tool_use block and drop the text
- The model finished its turn with end_turn; the tool_use block is a suggestion your code may ignore

Check answer

### Show answer

Answer: The model wrote some text, then requested a tool call; you run it and return a tool_result. Content blocks can mix text and tool_use; tool_use hands control to your code and the stop_reason will be tool_use. Truncation would show stop_reason max_tokens instead.

Applications and integration

Your app sends an image for analysis. How is it included?

- As a file uploaded through the Files API and referenced from the tools array by its file id
- As a data URL pasted into the text of the user message
- As an image content block, with a base64 or URL source, inside a user message
- As an image block inside the system parameter next to the instructions

Check answer

### Show answer

Answer: As an image content block, with a base64 or URL source, inside a user message. Images are content blocks in the user turn with a source of type base64 or url. The system parameter and the tools array do not carry images.

Applications and integration

What does stop_reason end_turn tell you?

- The model finished its turn naturally and is not waiting on anything
- The model stopped at a stop sequence you supplied in the request
- The output was cut off because the response reached max_tokens
- The model paused a long-running server tool turn and you should call again

Check answer

### Show answer

Answer: The model finished its turn naturally and is not waiting on anything. end_turn is the normal completion signal. A custom stop sequence reports stop_sequence, and a paused server tool turn reports pause_turn.

Applications and integration

A streaming response is interrupted midway. What should a robust client do?

- Render the partial text as the final answer, since deltas are already committed
- Detect the missing message_stop event, then retry or mark the partial output as incomplete
- Send a follow-up request with stop_reason set to resume so the model continues
- Fall back to non-streaming requests for the rest of the session so the failure does not recur

Check answer

### Show answer

Answer: Detect the missing message_stop event, then retry or mark the partial output as incomplete. Streams can drop; a complete stream ends with message_stop. Handle incompleteness explicitly. stop_reason is a response field, not something you can send.

Applications and integration

You need consistent structured data from many documents. Which approach is most robust?

- Define a tool with a JSON schema for the fields, force it with tool_choice, and validate the arguments
- Extract the values from free text with regular expressions tuned on sample documents
- Ask for a markdown table in the prompt, set temperature to 0, and split each returned row on the pipe character
- Set temperature to 0 and ask for JSON, trusting the output to be well formed

Check answer

### Show answer

Answer: Define a tool with a JSON schema for the fields, force it with tool_choice, and validate the arguments. Schema-enforced tool arguments give reliable structure; validation catches the rest. Temperature 0 makes output steadier but does not guarantee valid JSON.

Applications and integration

Which header carries your credential when calling the API directly?

- Authorization with a Bearer token
- anthropic-version with the key appended
- x-api-key with the key as its value
- x-anthropic-token with the key as its value

Check answer

### Show answer

Answer: x-api-key with the key as its value. The Anthropic API authenticates with the x-api-key header. anthropic-version is a separate required header that pins the API version.

Applications and integration

A request returns HTTP 400 with an invalid_request_error. Most likely cause?

- The request exceeded the rate limit for your organization's tier
- The model is overloaded and the request should be retried later
- The API key is valid but the organization lacks permission for the requested model
- A malformed body, such as a missing required field or an unsupported parameter

Check answer

### Show answer

Answer: A malformed body, such as a missing required field or an unsupported parameter. 400s are client-side shape problems. Rate limits are 429, permission problems are 403, and overload is 529.

Applications and integration

What is the Files API useful for?

- Caching a document so later requests skip input token billing for it
- Storing conversation history server-side so you send only new turns
- Uploading a document once and referencing it by file id across many requests
- Attaching a document to a Message Batch so every request inside that batch can read it

Check answer

### Show answer

Answer: Uploading a document once and referencing it by file id across many requests. Upload once, reference by id. Referenced files still count as input tokens; skipping repeated billing is what prompt caching does.

Applications and integration

A batch job finished but some requests show errors. What should your code do?

- Retry the batch at a smaller size so fewer requests time out
- Read each request's result, retry the failed ones, and treat the batch as non-atomic
- Cancel the batch and resubmit every request, since partially failed batches are not billed at all
- Treat the whole batch as failed and raise an error for the caller to handle

Check answer

### Show answer

Answer: Read each request's result, retry the failed ones, and treat the batch as non-atomic. Batches report per-request outcomes; handle them individually. Successful requests in a partially failed batch are billed and their results are valid.

Applications and integration

You want to count tokens before sending a large prompt to avoid exceeding limits. Which capability?

- The token counting endpoint, which returns input tokens for a prompt
- The count_tokens flag on the messages request
- An estimate from character count divided by four
- The usage field on the streaming message_start event, which reports input tokens early

Check answer

### Show answer

Answer: The token counting endpoint, which returns input tokens for a prompt. Token counting lets you budget before you send. message_start usage arrives only after the request is accepted, and there is no count_tokens flag on messages.

Applications and integration

Which SDK pattern avoids re-implementing the tool loop by hand?

- Streaming with a callback that executes tools inline
- A tool runner or agent helper provided by the SDK
- Wrapping the messages call in a retry decorator
- Setting tool_choice to auto so the API runs the tools itself

Check answer

### Show answer

Answer: A tool runner or agent helper provided by the SDK. SDK helpers manage the tool-call loop for you. tool_choice auto only lets the model decide whether to call a tool; execution is still your job.

Applications and integration

A multi-turn app appends every response to the history. After 50 turns the requests fail. What is the fix?

- Raise max_tokens so the model has room to answer the longer thread
- Trim or summarize older turns to stay inside the context window
- Add a cache_control breakpoint so cached turns are excluded from the limit
- Switch to a model with extended thinking to handle the longer input

Check answer

### Show answer

Answer: Trim or summarize older turns to stay inside the context window. History grows; manage it. Cached tokens still occupy the context window, and max_tokens only limits output.

## Next

- [Timed CCDV-F practice exam](https://youraidept.com/network/ccdv-f-practice-exam): 53 questions in 120 minutes, scored against the 720 pass mark.
- [All CCDV-F practice questions](https://youraidept.com/network/ccdv-f-practice-questions) with a domain filter.
- [The CCDV-F exam page](https://youraidept.com/network/ccdv-f): format, weights, registration, study path.

### Other CCDV-F domains

- [Model selection and optimization (10 questions)](https://youraidept.com/network/ccdv-f-practice-questions/model-selection-and-optimization)
- [Agents and workflows (9 questions)](https://youraidept.com/network/ccdv-f-practice-questions/agents-and-workflows)
- [Prompt and context engineering (7 questions)](https://youraidept.com/network/ccdv-f-practice-questions/prompt-and-context-engineering)
- [Tools and MCPs (6 questions)](https://youraidept.com/network/ccdv-f-practice-questions/tools-and-mcps)

## FAQ

### How much of the CCDV-F exam is applications and integration? +

33.1% of the marks, per the published CCDV-F exam guide. The full domain list with weights is on the CCDV-F exam page.

### Are these real CCDV-F exam questions? +

No. They are 20 original scenario questions written from the blueprint for this domain. Reproducing exam content would violate the candidate agreement.

### How should I study applications and integration for CCDV-F? +

Read the domain notes on this page, answer the questions with explanations hidden, then take the timed CCDV-F practice exam and check the per-domain breakdown for this domain.

## Who wrote this

### [Matei Olaru](https://youraidept.com/about/matei-olaru)

CEO, Your AI Department

Former public-company CEO, corporate attorney, and World Bank consultant. Runs the YAID Network and the partner relationship with Anthropic.

### [Michael Greenberg](https://youraidept.com/about/michael-greenberg)

AI Product Lead, Your AI Department

AI at Google, Meta, and Samsung. Six patents. Leads member support and the certification prep guidance.

Your AI Department is a registered Claude Partner Network company. Our members sit these exams under our partner standing. Facts on this page were last checked on October 15, 2026.

## Ready to sit CCDV-F for real?

Registration needs a Claude Partner Network organization. [YAID Network](https://youraidept.com/network) members register under our partner standing. $149 per quarter, exam fee separate.

[Apply to join YAID ↗](https://youraidept.com/network/apply?ref=drill)[How registration works →](https://youraidept.com/network/register-for-claude-certification)