@anthropic-ai/sdk 1.0.0 removes the legacy Completions surface and the two prompt constants that went with it. Code that imports Completions, Completion, any CompletionCreateParams type, HUMAN_PROMPT or AI_PROMPT stops compiling on upgrade. The package changelog lists the release as breaking and ties it to API version 2026-10-21.

What changed

Before and after

The scan matches imports like these:

import { HUMAN_PROMPT } from '@anthropic-ai/sdk';
import { CompletionCreateParams } from '@anthropic-ai/sdk/resources';

None of the nine changes has a deterministic rewrite, and none of these names has a same-named successor. The nearest replacement the release provides is the Messages API: where CompletionCreateParamsNonStreaming is missing, the TypeScript diagnostic suggests MessageCreateParamsNonStreaming. That is a place to start, not a drop-in swap, because Messages takes a list of role-tagged messages where Completions took one prompt string.

Migration guidance and its limits

All nine findings carry assisted fixes, so emendant fix needs a named model provider, chosen on the command line or in your Emendant configuration. Without one, each finding is reported with its guidance and nothing is sent anywhere. Each patch is checked with a typecheck and your tests, so read the patch header to see which checks passed.

Moving a call from Completions to Messages changes the request and the response shape, so review each patch before you accept it. Code that assembles \n\nHuman: and \n\nAssistant: prompts by hand needs its turns restructured as messages. Where the release gives no clear replacement for a flagged name, a patch may not be available and the surrounding code needs your review.

No finding for this release is report only. A clean scan covers these names imported from @anthropic-ai/sdk, @anthropic-ai/sdk/client and @anthropic-ai/sdk/resources. It does not cover property access such as client.completions or Anthropic.HUMAN_PROMPT, which needs no import, or a name reached through a re-export in your own module.

What Emendant detects, fixes and verifies

17 changes in @anthropic-ai/sdk 1.0.0. 0 automatic fixes, 17 fixes requiring a model provider you choose, 0 report only. Each patch states which checks passed. Understand patch evidence.

ChangeSeverityDetectsFixVerified by
Removed AI_PROMPT
anthropic-ai-sdk-npm-1.0.0-ai-prompt-removed
error TS2614: Module '"@anthropic-ai/sdk"' has no exported member 'AI_PROMPT'. Did you mean to use 'import AI_PROMPT from "@anthropic-ai/sdk"' instead?
Breaking
  • AI_PROMPT imported from @anthropic-ai/sdk
Patch, only when you name a model providerYour typecheck and tests
Removed HUMAN_PROMPT
anthropic-ai-sdk-npm-1.0.0-human-prompt-removed
error TS2614: Module '"@anthropic-ai/sdk"' has no exported member 'HUMAN_PROMPT'. Did you mean to use 'import HUMAN_PROMPT from "@anthropic-ai/sdk"' instead?
Breaking
  • HUMAN_PROMPT imported from @anthropic-ai/sdk
Patch, only when you name a model providerYour typecheck and tests
Removed AI_PROMPT
anthropic-ai-sdk-npm-1.0.0-client-ai-prompt-removed
error TS2305: Module '"@anthropic-ai/sdk/client"' has no exported member 'AI_PROMPT'.
Breaking
  • AI_PROMPT imported from @anthropic-ai/sdk/client
Patch, only when you name a model providerYour typecheck and tests
Removed HUMAN_PROMPT
anthropic-ai-sdk-npm-1.0.0-client-human-prompt-removed
error TS2305: Module '"@anthropic-ai/sdk/client"' has no exported member 'HUMAN_PROMPT'.
Breaking
  • HUMAN_PROMPT imported from @anthropic-ai/sdk/client
Patch, only when you name a model providerYour typecheck and tests
Removed Completion
anthropic-ai-sdk-npm-1.0.0-resources-completion-removed
error TS2305: Module '"@anthropic-ai/sdk/resources"' has no exported member 'Completion'.
Breaking
  • Completion imported from @anthropic-ai/sdk/resources
Patch, only when you name a model providerYour typecheck and tests
Removed CompletionCreateParams
anthropic-ai-sdk-npm-1.0.0-resources-completion-create-params-removed
error TS2305: Module '"@anthropic-ai/sdk/resources"' has no exported member 'CompletionCreateParams'.
Breaking
  • CompletionCreateParams imported from @anthropic-ai/sdk/resources
Patch, only when you name a model providerYour typecheck and tests
Removed CompletionCreateParamsNonStreaming
anthropic-ai-sdk-npm-1.0.0-resources-completion-create-params-non-streaming-removed
error TS2724: '"@anthropic-ai/sdk/resources"' has no exported member named 'CompletionCreateParamsNonStreaming'. Did you mean 'MessageCreateParamsNonStreaming'?
Breaking
  • CompletionCreateParamsNonStreaming imported from @anthropic-ai/sdk/resources
Patch, only when you name a model providerYour typecheck and tests
Removed CompletionCreateParamsStreaming
anthropic-ai-sdk-npm-1.0.0-resources-completion-create-params-streaming-removed
error TS2305: Module '"@anthropic-ai/sdk/resources"' has no exported member 'CompletionCreateParamsStreaming'.
Breaking
  • CompletionCreateParamsStreaming imported from @anthropic-ai/sdk/resources
Patch, only when you name a model providerYour typecheck and tests
Removed Completions
anthropic-ai-sdk-npm-1.0.0-resources-completions-removed
error TS2305: Module '"@anthropic-ai/sdk/resources"' has no exported member 'Completions'.
Breaking
  • Completions imported from @anthropic-ai/sdk/resources
Patch, only when you name a model providerYour typecheck and tests
Changed the members of Anthropic
anthropic-ai-sdk-npm-1.0.0-anthropic-members-changed
Breaking
medium confidence
  • Anthropic imported from @anthropic-ai/sdk, named in any type position
Patch, only when you name a model providerYour typecheck and tests
Changed the members of ParseableMessageCreateParams
anthropic-ai-sdk-npm-1.0.0-parseable-message-create-params-members-changed
Breaking
medium confidence
  • ParseableMessageCreateParams imported from @anthropic-ai/sdk, named in any type position
Patch, only when you name a model providerYour typecheck and tests
Changed the members of Anthropic
anthropic-ai-sdk-npm-1.0.0-client-anthropic-members-changed
Breaking
medium confidence
  • Anthropic imported from @anthropic-ai/sdk/client, named in any type position
Patch, only when you name a model providerYour typecheck and tests
Changed the members of MessageStreamParams
anthropic-ai-sdk-npm-1.0.0-resources-message-stream-params-members-changed
Breaking
medium confidence
  • MessageStreamParams imported from @anthropic-ai/sdk/resources, named in any type position
Patch, only when you name a model providerYour typecheck and tests
Changed the members of MessageCreateParamsNonStreaming
anthropic-ai-sdk-npm-1.0.0-resources-message-create-params-non-streaming-members-changed
Breaking
medium confidence
  • MessageCreateParamsNonStreaming imported from @anthropic-ai/sdk/resources, named in any type position
Patch, only when you name a model providerYour typecheck and tests
Changed the members of MessageCreateParamsStreaming
anthropic-ai-sdk-npm-1.0.0-resources-message-create-params-streaming-members-changed
Breaking
medium confidence
  • MessageCreateParamsStreaming imported from @anthropic-ai/sdk/resources, named in any type position
Patch, only when you name a model providerYour typecheck and tests
Changed the members of ModelRetrieveParams
anthropic-ai-sdk-npm-1.0.0-resources-model-retrieve-params-members-changed
Breaking
medium confidence
  • ModelRetrieveParams imported from @anthropic-ai/sdk/resources, named in any type position
Patch, only when you name a model providerYour typecheck and tests
Changed the members of ModelListParams
anthropic-ai-sdk-npm-1.0.0-resources-model-list-params-members-changed
Breaking
medium confidence
  • ModelListParams imported from @anthropic-ai/sdk/resources, named in any type position
Patch, only when you name a model providerYour typecheck and tests

emendant explain <change-id> prints any row's entry, guidance and sources at the terminal.

The error TS lines are what TypeScript 5.9.3 printed when code that compiled against @anthropic-ai/sdk 0.137.0 was compiled against 1.0.0. A row without one is a change the compiler does not report, such as a deprecation or a change in behaviour.

Coverage

Requires emendant@0.3.0 or later. Run emendant feed update to get the latest coverage.

Coverage details
Snapshot
2026-10-22.1, sequence 55, signed 22 October 2026
Feed entry
feed/npm/@anthropic-ai/sdk/1.0.0.json

emendant feed status shows the snapshot your machine holds.

Primary sources

Scan your repository

Find affected code without editing your files.

npx emendant scan

Then npx emendant fix writes the patches the table says exist. The getting started guide covers the flags and the patch grades.

Every @anthropic-ai/sdk release page is listed on one page.