Claude Platform Docs

Elenca Dream

$client->beta->dreams->list(?\Datetime createdAtGt, ?\Datetime createdAtLt, ?bool includeArchived, ?int limit, ?string page, ?list<BetaDreamStatus> statuses, ?list<AnthropicBeta> betas, ?string workspaceID): PageCursor<BetaDream>
GET/v1/dreams

Elenca Dream

Parameters
createdAtGt?:optional \Datetime

Return dreams with created_at strictly after this timestamp (exclusive lower bound, RFC 3339). Unset applies no lower bound.

createdAtLt?:optional \Datetime

Return dreams with created_at strictly before this timestamp (exclusive upper bound, RFC 3339). Unset applies no upper bound.

includeArchived?:optional bool

Query parameter for include_archived

limit?:optional int

Query parameter for limit

page?:optional string

Query parameter for page

statuses?:optional list<BetaDreamStatus>

Filter by lifecycle status. Repeat the parameter to match any of multiple statuses. Empty applies no status filter.

betas?:optional list<AnthropicBeta>

Optional header to specify the beta version(s) you want to use.

workspaceID?:optional string
Returns
class BetaDream { $type; $id; $archivedAt; /* 11 more */ }
Elenca Dream
<?php

require_once dirname(__DIR__) . '/vendor/autoload.php';

$client = new Client(apiKey: 'my-anthropic-api-key');

$page = $client->beta->dreams->list(
  createdAtGt: new \DateTimeImmutable('2019-12-27T18:11:19.117Z'),
  createdAtLt: new \DateTimeImmutable('2019-12-27T18:11:19.117Z'),
  includeArchived: true,
  limit: 0,
  page: 'page',
  statuses: [BetaDreamStatus::PENDING],
  betas: [AnthropicBeta::MESSAGE_BATCHES_2024_09_24],
  workspaceID: 'wrkspc_011CZkZaBF1tNoB5wlCeusgy',
);

var_dump($page);
Returns Examples
Response 200
{
  "data": [
    {
      "id": "id",
      "archived_at": "2019-12-27T18:11:19.117Z",
      "created_at": "2019-12-27T18:11:19.117Z",
      "ended_at": "2019-12-27T18:11:19.117Z",
      "error": {
        "message": "message",
        "type": "type"
      },
      "inputs": [
        {
          "memory_store_id": "x",
          "type": "memory_store"
        }
      ],
      "instructions": "instructions",
      "model": {
        "id": "x",
        "speed": "standard"
      },
      "output_behavior": {
        "type": "create_new"
      },
      "outputs": [
        {
          "memory_store_id": "memory_store_id",
          "type": "memory_store"
        }
      ],
      "session_id": "session_id",
      "status": "pending",
      "type": "dream",
      "usage": {
        "cache_creation_input_tokens": 0,
        "cache_read_input_tokens": 0,
        "input_tokens": 0,
        "output_tokens": 0
      }
    }
  ],
  "next_page": "next_page"
}