ClaudeCode.Content.CompactionBlock (ClaudeCode v0.36.3)

View Source

Represents a compaction content block within a Claude message.

Compaction blocks contain a summary of previously compacted context. They appear when the API's autocompact context management strategy is triggered. The content may be nil if compaction failed.

Summary

Types

t()

@type t() :: %ClaudeCode.Content.CompactionBlock{
  content: String.t() | nil,
  type: :compaction
}

Functions

new(data)

@spec new(map()) :: {:ok, t()} | {:error, atom()}