MCPcopy Create free account
hub / github.com/anthropics/anthropic-sdk-python / __init__

Method __init__

src/anthropic/_streaming.py:284–300  ·  view source on GitHub ↗
(
        self,
        *,
        event: str | None = None,
        data: str | None = None,
        id: str | None = None,
        retry: int | None = None,
        raw: list[str] | None = None,
    )

Source from the content-addressed store, hash-verified

282
283class ServerSentEvent:
284 def __init__(
285 self,
286 *,
287 event: str | None = None,
288 data: str | None = None,
289 id: str | None = None,
290 retry: int | None = None,
291 raw: list[str] | None = None,
292 ) -> None:
293 if data is None:
294 data = ""
295
296 self._id = id
297 self._data = data
298 self._event = event or None
299 self._retry = retry
300 self._raw = raw if raw is not None else []
301
302 @property
303 def event(self) -> str | None:

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected