Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "0.1.0-alpha.13"
".": "0.1.0-alpha.14"
}
6 changes: 3 additions & 3 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 22
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/opencode%2Fopencode-05150c78e0e6e97b0ce97ed685ebcf1cb01dc839beccb99e9d3ead5b783cfd47.yml
openapi_spec_hash: 833a5b6d53d98dc2beac2c4c394b20d5
config_hash: 3695cfc829cfaae14490850b4a1ed282
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/opencode%2Fopencode-7270b9e4859010d6680bcc92afcd6f7c679d80a2645f65d7097d19ce2e8cdc5a.yml
openapi_spec_hash: 5fcbfaedebfea62c17c74437a9728b04
config_hash: 931828b5dd9393834a3c1703e02e02b0
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

## 0.1.0-alpha.14 (2025-07-15)

Full Changelog: [v0.1.0-alpha.13...v0.1.0-alpha.14](https://github.com/sst/opencode-sdk-python/compare/v0.1.0-alpha.13...v0.1.0-alpha.14)

### Features

* **api:** api update ([80d8572](https://github.com/sst/opencode-sdk-python/commit/80d85724c6b17b867ac3d19b0741bb88bb604798))

## 0.1.0-alpha.13 (2025-07-15)

Full Changelog: [v0.1.0-alpha.12...v0.1.0-alpha.13](https://github.com/sst/opencode-sdk-python/compare/v0.1.0-alpha.12...v0.1.0-alpha.13)
Expand Down
1 change: 1 addition & 0 deletions api.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ from opencode_ai.types import (
Message,
Part,
Session,
SnapshotPart,
StepFinishPart,
StepStartPart,
TextPart,
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "opencode-ai"
version = "0.1.0-alpha.13"
version = "0.1.0-alpha.14"
description = "The official Python library for the opencode API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion src/opencode_ai/_version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

__title__ = "opencode_ai"
__version__ = "0.1.0-alpha.13" # x-release-please-version
__version__ = "0.1.0-alpha.14" # x-release-please-version
1 change: 1 addition & 0 deletions src/opencode_ai/types/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
from .tool_part import ToolPart as ToolPart
from .mcp_remote import McpRemote as McpRemote
from .user_message import UserMessage as UserMessage
from .snapshot_part import SnapshotPart as SnapshotPart
from .app_log_params import AppLogParams as AppLogParams
from .file_part_param import FilePartParam as FilePartParam
from .step_start_part import StepStartPart as StepStartPart
Expand Down
26 changes: 7 additions & 19 deletions src/opencode_ai/types/part.py
Original file line number Diff line number Diff line change
@@ -1,30 +1,18 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

from typing import Union
from typing_extensions import Literal, TypeAlias
from typing_extensions import Annotated, TypeAlias

from pydantic import Field as FieldInfo

from .._models import BaseModel
from .._utils import PropertyInfo
from .file_part import FilePart
from .text_part import TextPart
from .tool_part import ToolPart
from .snapshot_part import SnapshotPart
from .step_start_part import StepStartPart
from .step_finish_part import StepFinishPart

__all__ = ["Part", "UnionMember5"]


class UnionMember5(BaseModel):
id: str

message_id: str = FieldInfo(alias="messageID")

session_id: str = FieldInfo(alias="sessionID")

snapshot: str

type: Literal["snapshot"]

__all__ = ["Part"]

Part: TypeAlias = Union[TextPart, FilePart, ToolPart, StepStartPart, StepFinishPart, UnionMember5]
Part: TypeAlias = Annotated[
Union[TextPart, FilePart, ToolPart, StepStartPart, StepFinishPart, SnapshotPart], PropertyInfo(discriminator="type")
]
21 changes: 21 additions & 0 deletions src/opencode_ai/types/snapshot_part.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

from typing_extensions import Literal

from pydantic import Field as FieldInfo

from .._models import BaseModel

__all__ = ["SnapshotPart"]


class SnapshotPart(BaseModel):
id: str

message_id: str = FieldInfo(alias="messageID")

session_id: str = FieldInfo(alias="sessionID")

snapshot: str

type: Literal["snapshot"]
Loading