Source Intelligence
Sweep 28 Aug 2026 ยท 00:00Z Build v2.1.250 478 read Stable v2.1.236 Latest v2.1.250 Next v2.1.250 Feeds RSS JSON llms.txt

DisclaimerUnofficial, and not affiliated with Anthropic. Nearly all of this is read straight out of what ships: npm bundles, captured prompts, published docs. Anthropic's own notes go in verbatim, marked as theirs. The rest is my reading, and every entry carries the strings behind it. If one looks wrong, vote it down and say why.

One change

Request 2 caches its request content (not the response)

build-with-claude/prompt-caching

first seen The page's own history The capture it came from

Nearest release: v2.1.235, published 10 hours before this site recorded the change. Shown because the two are within 24 hours of each other. Nothing here says the release caused the edit.

build-with-claude/prompt-caching Changed · +0 / -120 lines

from line 3310
       ```python Python
       client.beta.prompt_caching.messages.create(**params)
       ```
-
-      ```typescript TypeScript
-      const client = new Anthropic();
-
-      const response = await client.beta.promptCaching.messages.create({
-        model: "claude-opus-5",
-        max_tokens: 1024,
-        system: [
-          {
-            type: "text",
-            text: "You are an expert on this large document...",
-            cache_control: { type: "ephemeral" }
-          }
-        ],
-        messages: [{ role: "user", content: "Summarize the key points" }]
-      });
-
-      console.log(response);
-      ```
-
-      ```php PHP
-      $client = new Client();
-
-      $message = $client->beta->promptCaching->messages->create(
-          maxTokens: 1024,
-          messages: [
-              ['role' => 'user', 'content' => 'Summarize the key points']
-          ],
-          model: 'claude-opus-5',
-          system: [
-              [
-                  'type' => 'text',
-                  'text' => 'You are an expert on this large document...',
-                  'cache_control' => ['type' => 'ephemeral']
-              ]
-          ],
-      );
-
-      echo json_encode($message, JSON_PRETTY_PRINT), PHP_EOL;
-      ```
-
-      ```ruby Ruby
-      client = Anthropic::Client.new
-
-      message = client.beta.prompt_caching.messages.create(
-        model: "claude-opus-5",
-        max_tokens: 1024,
-        system: [
-          {
-            type: "text",
-            text: "You are an expert on this large document...",
-            cache_control: { type: "ephemeral" }
-          }
-        ],
-        messages: [
-          { role: "user", content: "Summarize the key points" }
-        ]
-      )
-      puts message.content.find { it.type == :text }.text
-      ```
     </CodeGroup>
 
     Use:
from line 3317
     <CodeGroup>
       ```python Python
       client.messages.create(**params)
-      ```
-
-      ```typescript TypeScript
-      const client = new Anthropic();
-
-      const response = await client.messages.create({
-        model: "claude-opus-5",
-        max_tokens: 1024,
-        system: [
-          {
-            type: "text",
-            text: "You are an expert on this large document...",
-            cache_control: { type: "ephemeral" }
-          }
-        ],
-        messages: [{ role: "user", content: "Summarize the key points" }]
-      });
-
-      console.log(response);
-      ```
-
-      ```php PHP
-      $client = new Client();
-
-      $message = $client->messages->create(
-          maxTokens: 1024,
-          messages: [
-              ['role' => 'user', 'content' => 'Summarize the key points']
-          ],
-          model: 'claude-opus-5',
-          system: [
-              [
-                  'type' => 'text',
-                  'text' => 'You are an expert on this large document...',
-                  'cache_control' => ['type' => 'ephemeral']
-              ]
-          ],
-      );
-
-      echo json_encode($message, JSON_PRETTY_PRINT), PHP_EOL;
-      ```
-
-      ```ruby Ruby
-      client = Anthropic::Client.new
-
-      message = client.messages.create(
-        model: "claude-opus-5",
-        max_tokens: 1024,
-        system: [
-          {
-            type: "text",
-            text: "You are an expert on this large document...",
-            cache_control: { type: "ephemeral" }
-          }
-        ],
-        messages: [
-          { role: "user", content: "Summarize the key points" }
-        ]
-      )
-      puts message
       ```
     </CodeGroup>
   </Accordion>