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 @@
{
".": "4.2.0"
".": "4.3.0"
}
6 changes: 3 additions & 3 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 23
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/beeper%2Fbeeper-desktop-api-ee25e67fc85ccc86cedb2ca0865385709877582132103e0afa68d7b43551784a.yml
openapi_spec_hash: d41fd99c9a8645a1fd69c519cd25a637
config_hash: abdcaeff62a619bdf25d727cdeacf3b0
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/beeper%2Fbeeper-desktop-api-4acef56b00be513f305543096fdd407e6947f0a5ad268ab2e627ff30b37a75db.yml
openapi_spec_hash: e876d796b6c25f18577f6be3944bf7d9
config_hash: 659111d4e28efa599b5f800619ed79c2
16 changes: 16 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,21 @@
# Changelog

## 4.3.0 (2026-02-20)

Full Changelog: [v4.2.0...v4.3.0](https://github.com/beeper/desktop-api-python/compare/v4.2.0...v4.3.0)

### Features

* **api:** api update ([4f6c268](https://github.com/beeper/desktop-api-python/commit/4f6c2685f00a7fd4f1db0b34faa6e354a0f7e220))
* **api:** api update ([c77412c](https://github.com/beeper/desktop-api-python/commit/c77412c3d4daa460f8901f715a9f59dc1bfa3970))
* **api:** manual updates ([223108d](https://github.com/beeper/desktop-api-python/commit/223108ddc2f84269df96dd8abf6787d8e45c02e6))


### Chores

* update mock server docs ([70593f0](https://github.com/beeper/desktop-api-python/commit/70593f0416d4ed7251957c9fcdb5805e570b2577))
* update SDK settings ([3741b42](https://github.com/beeper/desktop-api-python/commit/3741b42c7ab0c75897bb5cd753b1ce3b323686d2))

## 4.2.0 (2026-02-20)

Full Changelog: [v4.1.296...v4.2.0](https://github.com/beeper/desktop-api-python/compare/v4.1.296...v4.2.0)
Expand Down
3 changes: 1 addition & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,7 @@ $ pip install ./path-to-wheel-file.whl
Most tests require you to [set up a mock server](https://github.com/stoplightio/prism) against the OpenAPI spec to run the tests.

```sh
# you will need npm installed
$ npx prism mock path/to/your/openapi.yml
$ ./scripts/mock
```

```sh
Expand Down
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -218,10 +218,11 @@ from beeper_desktop_api import BeeperDesktop

client = BeeperDesktop()

client.chats.reminders.create(
chat_id="!NCdzlIaMjZUmvmvyHU:beeper.com",
reminder={"remind_at_ms": 0},
chat = client.chats.create(
account_id="accountID",
user={},
)
print(chat.user)
```

## File uploads
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 = "beeper_desktop_api"
version = "4.2.0"
version = "4.3.0"
description = "The official Python library for the beeperdesktop API"
dynamic = ["readme"]
license = "MIT"
Expand Down
2 changes: 1 addition & 1 deletion src/beeper_desktop_api/_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__ = "beeper_desktop_api"
__version__ = "4.2.0" # x-release-please-version
__version__ = "4.3.0" # x-release-please-version
86 changes: 82 additions & 4 deletions src/beeper_desktop_api/resources/chats/chats.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,14 @@ def with_streaming_response(self) -> ChatsResourceWithStreamingResponse:
def create(
self,
*,
chat: chat_create_params.Chat | Omit = omit,
account_id: str,
allow_invite: bool | Omit = omit,
message_text: str | Omit = omit,
mode: Literal["create", "start"] | Omit = omit,
participant_ids: SequenceNotStr[str] | Omit = omit,
title: str | Omit = omit,
type: Literal["single", "group"] | Omit = omit,
user: chat_create_params.User | Omit = omit,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand All @@ -92,6 +99,26 @@ def create(
user data (mode='start').

Args:
account_id: Account to create or start the chat on.

allow_invite: Whether invite-based DM creation is allowed when required by the platform. Used
for mode='start'.

message_text: Optional first message content if the platform requires it to create the chat.

mode: Operation mode. Defaults to 'create' when omitted.

participant_ids: Required when mode='create'. User IDs to include in the new chat.

title: Optional title for group chats when mode='create'; ignored for single chats on
most platforms.

type: Required when mode='create'. 'single' requires exactly one participantID;
'group' supports multiple participants and optional title.

user: Required when mode='start'. Merged user-like contact payload used to resolve the
best identifier.

extra_headers: Send extra headers

extra_query: Add additional query parameters to the request
Expand All @@ -102,7 +129,19 @@ def create(
"""
return self._post(
"/v1/chats",
body=maybe_transform(chat, chat_create_params.ChatCreateParams),
body=maybe_transform(
{
"account_id": account_id,
"allow_invite": allow_invite,
"message_text": message_text,
"mode": mode,
"participant_ids": participant_ids,
"title": title,
"type": type,
"user": user,
},
chat_create_params.ChatCreateParams,
),
options=make_request_options(
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
),
Expand Down Expand Up @@ -383,7 +422,14 @@ def with_streaming_response(self) -> AsyncChatsResourceWithStreamingResponse:
async def create(
self,
*,
chat: chat_create_params.Chat | Omit = omit,
account_id: str,
allow_invite: bool | Omit = omit,
message_text: str | Omit = omit,
mode: Literal["create", "start"] | Omit = omit,
participant_ids: SequenceNotStr[str] | Omit = omit,
title: str | Omit = omit,
type: Literal["single", "group"] | Omit = omit,
user: chat_create_params.User | Omit = omit,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand All @@ -396,6 +442,26 @@ async def create(
user data (mode='start').

Args:
account_id: Account to create or start the chat on.

allow_invite: Whether invite-based DM creation is allowed when required by the platform. Used
for mode='start'.

message_text: Optional first message content if the platform requires it to create the chat.

mode: Operation mode. Defaults to 'create' when omitted.

participant_ids: Required when mode='create'. User IDs to include in the new chat.

title: Optional title for group chats when mode='create'; ignored for single chats on
most platforms.

type: Required when mode='create'. 'single' requires exactly one participantID;
'group' supports multiple participants and optional title.

user: Required when mode='start'. Merged user-like contact payload used to resolve the
best identifier.

extra_headers: Send extra headers

extra_query: Add additional query parameters to the request
Expand All @@ -406,7 +472,19 @@ async def create(
"""
return await self._post(
"/v1/chats",
body=await async_maybe_transform(chat, chat_create_params.ChatCreateParams),
body=await async_maybe_transform(
{
"account_id": account_id,
"allow_invite": allow_invite,
"message_text": message_text,
"mode": mode,
"participant_ids": participant_ids,
"title": title,
"type": type,
"user": user,
},
chat_create_params.ChatCreateParams,
),
options=make_request_options(
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
),
Expand Down
4 changes: 2 additions & 2 deletions src/beeper_desktop_api/resources/messages.py
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ def search(
limit: int | Omit = omit,
media_types: List[Literal["any", "video", "image", "link", "file"]] | Omit = omit,
query: str | Omit = omit,
sender: Union[Literal["me", "others"], str] | Omit = omit,
sender: str | Omit = omit,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand Down Expand Up @@ -439,7 +439,7 @@ def search(
limit: int | Omit = omit,
media_types: List[Literal["any", "video", "image", "link", "file"]] | Omit = omit,
query: str | Omit = omit,
sender: Union[Literal["me", "others"], str] | Omit = omit,
sender: str | Omit = omit,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand Down
72 changes: 33 additions & 39 deletions src/beeper_desktop_api/types/chat_create_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,44 +2,58 @@

from __future__ import annotations

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

from .._types import SequenceNotStr
from .._utils import PropertyInfo

__all__ = ["ChatCreateParams", "Chat", "ChatUnionMember0", "ChatUnionMember1", "ChatUnionMember1User"]
__all__ = ["ChatCreateParams", "User"]


class ChatCreateParams(TypedDict, total=False):
chat: Chat


class ChatUnionMember0(TypedDict, total=False):
account_id: Required[Annotated[str, PropertyInfo(alias="accountID")]]
"""Account to create the chat on."""
"""Account to create or start the chat on."""

participant_ids: Required[Annotated[SequenceNotStr[str], PropertyInfo(alias="participantIDs")]]
"""User IDs to include in the new chat."""
allow_invite: Annotated[bool, PropertyInfo(alias="allowInvite")]
"""Whether invite-based DM creation is allowed when required by the platform.

type: Required[Literal["single", "group"]]
"""
Chat type to create: 'single' requires exactly one participantID; 'group'
supports multiple participants and optional title.
Used for mode='start'.
"""

message_text: Annotated[str, PropertyInfo(alias="messageText")]
"""Optional first message content if the platform requires it to create the chat."""

mode: Literal["create"]
"""Create mode. Defaults to 'create' when omitted."""
mode: Literal["create", "start"]
"""Operation mode. Defaults to 'create' when omitted."""

participant_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="participantIDs")]
"""Required when mode='create'. User IDs to include in the new chat."""

title: str
"""Optional title for group chats; ignored for single chats on most platforms."""
"""
Optional title for group chats when mode='create'; ignored for single chats on
most platforms.
"""

type: Literal["single", "group"]
"""Required when mode='create'.

class ChatUnionMember1User(TypedDict, total=False):
"""Merged user-like contact payload used to resolve the best identifier."""
'single' requires exactly one participantID; 'group' supports multiple
participants and optional title.
"""

user: User
"""Required when mode='start'.

Merged user-like contact payload used to resolve the best identifier.
"""


class User(TypedDict, total=False):
"""Required when mode='start'.

Merged user-like contact payload used to resolve the best identifier.
"""

id: str
"""Known user ID when available."""
Expand All @@ -55,23 +69,3 @@ class ChatUnionMember1User(TypedDict, total=False):

username: str
"""Username/handle candidate."""


class ChatUnionMember1(TypedDict, total=False):
account_id: Required[Annotated[str, PropertyInfo(alias="accountID")]]
"""Account to start the chat on."""

mode: Required[Literal["start"]]
"""Start mode for resolving/creating a direct chat from merged contact data."""

user: Required[ChatUnionMember1User]
"""Merged user-like contact payload used to resolve the best identifier."""

allow_invite: Annotated[bool, PropertyInfo(alias="allowInvite")]
"""Whether invite-based DM creation is allowed when required by the platform."""

message_text: Annotated[str, PropertyInfo(alias="messageText")]
"""Optional first message content if the platform requires it to create the chat."""


Chat: TypeAlias = Union[ChatUnionMember0, ChatUnionMember1]
2 changes: 1 addition & 1 deletion src/beeper_desktop_api/types/message_search_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ class MessageSearchParams(TypedDict, total=False):
only by other parameters.
"""

sender: Union[Literal["me", "others"], str]
sender: str
"""
Filter by sender: 'me' (messages sent by the authenticated user), 'others'
(messages sent by others), or a specific user ID string (user.id).
Expand Down
10 changes: 5 additions & 5 deletions src/beeper_desktop_api/types/shared/error.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@

from ..._models import BaseModel

__all__ = ["Error", "Details", "DetailsIssues", "DetailsIssuesIssue"]
__all__ = ["Error", "Details", "DetailsValidationDetails", "DetailsValidationDetailsIssue"]


class DetailsIssuesIssue(BaseModel):
class DetailsValidationDetailsIssue(BaseModel):
code: str
"""Validation issue code"""

Expand All @@ -19,14 +19,14 @@ class DetailsIssuesIssue(BaseModel):
"""Path pointing to the invalid field within the payload"""


class DetailsIssues(BaseModel):
class DetailsValidationDetails(BaseModel):
"""Validation error details"""

issues: List[DetailsIssuesIssue]
issues: List[DetailsValidationDetailsIssue]
"""List of validation issues"""


Details: TypeAlias = Union[DetailsIssues, Dict[str, Optional[object]], Optional[object]]
Details: TypeAlias = Union[DetailsValidationDetails, Dict[str, Optional[object]], Optional[object]]


class Error(BaseModel):
Expand Down
Loading