diff --git a/.release-please-manifest.json b/.release-please-manifest.json index e72f113..7ccfe12 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "1.14.0" + ".": "1.15.0" } \ No newline at end of file diff --git a/.stats.yml b/.stats.yml index e0c39b9..ebe253f 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 89 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/knock%2Fknock-fe051300804a0ee8b0212b288cec99c00918e570f4c4b8852f3f4a27afdddd1c.yml -openapi_spec_hash: d2f75f52ceb88b56e4fcf58bf876fe44 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/knock%2Fknock-226200e7cda539eab84341167939339109659a66a48312fd41cb8b15b89ef8e2.yml +openapi_spec_hash: 2097f5fdc617bdbe6a2780daa693a2f8 config_hash: 658c551418df454aa40794f8ac679c18 diff --git a/CHANGELOG.md b/CHANGELOG.md index de8110c..52ca820 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,18 @@ # Changelog +## 1.15.0 (2025-10-13) + +Full Changelog: [v1.14.0...v1.15.0](https://github.com/knocklabs/knock-python/compare/v1.14.0...v1.15.0) + +### Features + +* **api:** api update ([f20d9d2](https://github.com/knocklabs/knock-python/commit/f20d9d2b2a07ca1193140f4409d3701fe7bd00df)) + + +### Chores + +* **internal:** detect missing future annotations with ruff ([1ca76cb](https://github.com/knocklabs/knock-python/commit/1ca76cb3ed72befb82a5474996c2f4d4c928b205)) + ## 1.14.0 (2025-10-07) Full Changelog: [v1.13.0...v1.14.0](https://github.com/knocklabs/knock-python/compare/v1.13.0...v1.14.0) diff --git a/pyproject.toml b/pyproject.toml index f78202a..c562b21 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "knockapi" -version = "1.14.0" +version = "1.15.0" description = "The official Python library for the knock API" dynamic = ["readme"] license = "Apache-2.0" @@ -224,6 +224,8 @@ select = [ "B", # remove unused imports "F401", + # check for missing future annotations + "FA102", # bare except statements "E722", # unused arguments @@ -246,6 +248,8 @@ unfixable = [ "T203", ] +extend-safe-fixes = ["FA102"] + [tool.ruff.lint.flake8-tidy-imports.banned-api] "functools.lru_cache".msg = "This function does not retain type information for the wrapped function's arguments; The `lru_cache` function from `_utils` should be used instead" diff --git a/src/knockapi/_version.py b/src/knockapi/_version.py index 9bb56d9..febe16b 100644 --- a/src/knockapi/_version.py +++ b/src/knockapi/_version.py @@ -1,4 +1,4 @@ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. __title__ = "knockapi" -__version__ = "1.14.0" # x-release-please-version +__version__ = "1.15.0" # x-release-please-version diff --git a/src/knockapi/types/message.py b/src/knockapi/types/message.py index ef0639d..dc8a8bc 100644 --- a/src/knockapi/types/message.py +++ b/src/knockapi/types/message.py @@ -9,7 +9,7 @@ from .._models import BaseModel from .recipient_reference import RecipientReference -__all__ = ["Message", "Source"] +__all__ = ["Message", "Source", "Channel"] class Source(BaseModel): @@ -31,6 +31,29 @@ class Source(BaseModel): """Whether this message was generated from a workflow, broadcast, or guide.""" +class Channel(BaseModel): + id: str + """The unique identifier for the channel.""" + + created_at: datetime + """The timestamp of when the channel was created.""" + + provider: str + """The ID of the provider that this channel uses to deliver messages.""" + + type: Literal["email", "in_app", "in_app_feed", "in_app_guide", "sms", "push", "chat", "http"] + """The type of channel, determining what kind of messages it can send.""" + + updated_at: datetime + """The timestamp of when the channel was last updated.""" + + key: Optional[str] = None + """Unique identifier for the channel within a project (immutable once created).""" + + name: Optional[str] = None + """The human-readable name of the channel.""" + + class Message(BaseModel): id: str """The unique identifier for the message.""" @@ -39,7 +62,7 @@ class Message(BaseModel): """The typename of the schema.""" channel_id: str - """The ID for the channel the message was sent through.""" + """Deprecated, use channel.id instead.""" engagement_statuses: List[Literal["seen", "read", "interacted", "link_clicked", "archived"]] """A list of engagement statuses.""" @@ -72,6 +95,9 @@ class Message(BaseModel): archived_at: Optional[datetime] = None """Timestamp when the message was archived.""" + channel: Optional[Channel] = None + """A configured channel, which is a way to route messages to a provider.""" + clicked_at: Optional[datetime] = None """Timestamp when the message was clicked."""