Skip to content

Commit 78fe99d

Browse files
release: 7.11.0 (#130)
* codegen metadata * fix(client): preserve hardcoded query params when merging with user params * codegen metadata * feat(api): add content/element/locale methods, remove draft resource, update notifications * feat(api): add list_notifications method to routing_strategies * release: 7.11.0 --------- Co-authored-by: stainless-app[bot] <142633134+stainless-app[bot]@users.noreply.github.com>
1 parent f3d4967 commit 78fe99d

27 files changed

Lines changed: 1452 additions & 360 deletions

.release-please-manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
".": "7.10.0"
2+
".": "7.11.0"
33
}

.stats.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
configured_endpoints: 100
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/courier%2Fcourier-b3dde937486812f8db805a423a30ba5d3f80cc95803e13ab66958589366a5f06.yml
3-
openapi_spec_hash: a249df035d7f5bf57c66084cd94e8841
4-
config_hash: c51fa2bafdf96f2c1e409ccc295b7359
1+
configured_endpoints: 103
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/courier%2Fcourier-d891c800ffe6b7eddce179c225367cedcb49dab758ebc03e352d945240918d96.yml
3+
openapi_spec_hash: 852d55192b8d7ad96c1f85cd9070ef64
4+
config_hash: a730d0e598dc108e89c016802008c9b3

CHANGELOG.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,19 @@
11
# Changelog
22

3+
## 7.11.0 (2026-04-08)
4+
5+
Full Changelog: [v7.10.0...v7.11.0](https://github.com/trycourier/courier-python/compare/v7.10.0...v7.11.0)
6+
7+
### Features
8+
9+
* **api:** add content/element/locale methods, remove draft resource, update notifications ([ea30dd6](https://github.com/trycourier/courier-python/commit/ea30dd640d10f3a7a64aa1b4d81f3f7c7e2f906b))
10+
* **api:** add list_notifications method to routing_strategies ([63adeb8](https://github.com/trycourier/courier-python/commit/63adeb8eaea8960cc5704eb672ebb1c24f46a946))
11+
12+
13+
### Bug Fixes
14+
15+
* **client:** preserve hardcoded query params when merging with user params ([7e44063](https://github.com/trycourier/courier-python/commit/7e4406306cf5002f4cc5867bf16411a30c4d42fa))
16+
317
## 7.10.0 (2026-04-01)
418

519
Full Changelog: [v7.9.0...v7.10.0](https://github.com/trycourier/courier-python/compare/v7.9.0...v7.10.0)

api.md

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -343,17 +343,25 @@ Types:
343343
from courier.types import (
344344
BaseCheck,
345345
Check,
346+
ElementWithChecksums,
347+
NotificationContentGetResponse,
348+
NotificationContentMutationResponse,
349+
NotificationContentPutRequest,
350+
NotificationElementPutRequest,
346351
NotificationGetContent,
352+
NotificationLocalePutRequest,
347353
NotificationTemplateCreateRequest,
348354
NotificationTemplateGetResponse,
349355
NotificationTemplateMutationResponse,
350356
NotificationTemplatePayload,
351357
NotificationTemplatePublishRequest,
358+
NotificationTemplateState,
352359
NotificationTemplateSummary,
353360
NotificationTemplateUpdateRequest,
354361
NotificationTemplateVersionListResponse,
355362
VersionNode,
356363
NotificationListResponse,
364+
NotificationRetrieveContentResponse,
357365
)
358366
```
359367

@@ -365,14 +373,11 @@ Methods:
365373
- <code title="delete /notifications/{id}">client.notifications.<a href="./src/courier/resources/notifications/notifications.py">archive</a>(id) -> None</code>
366374
- <code title="get /notifications/{id}/versions">client.notifications.<a href="./src/courier/resources/notifications/notifications.py">list_versions</a>(id, \*\*<a href="src/courier/types/notification_list_versions_params.py">params</a>) -> <a href="./src/courier/types/notification_template_version_list_response.py">NotificationTemplateVersionListResponse</a></code>
367375
- <code title="post /notifications/{id}/publish">client.notifications.<a href="./src/courier/resources/notifications/notifications.py">publish</a>(id, \*\*<a href="src/courier/types/notification_publish_params.py">params</a>) -> None</code>
376+
- <code title="put /notifications/{id}/content">client.notifications.<a href="./src/courier/resources/notifications/notifications.py">put_content</a>(id, \*\*<a href="src/courier/types/notification_put_content_params.py">params</a>) -> <a href="./src/courier/types/notification_content_mutation_response.py">NotificationContentMutationResponse</a></code>
377+
- <code title="put /notifications/{id}/elements/{elementId}">client.notifications.<a href="./src/courier/resources/notifications/notifications.py">put_element</a>(element_id, \*, id, \*\*<a href="src/courier/types/notification_put_element_params.py">params</a>) -> <a href="./src/courier/types/notification_content_mutation_response.py">NotificationContentMutationResponse</a></code>
378+
- <code title="put /notifications/{id}/locales/{localeId}">client.notifications.<a href="./src/courier/resources/notifications/notifications.py">put_locale</a>(locale_id, \*, id, \*\*<a href="src/courier/types/notification_put_locale_params.py">params</a>) -> <a href="./src/courier/types/notification_content_mutation_response.py">NotificationContentMutationResponse</a></code>
368379
- <code title="put /notifications/{id}">client.notifications.<a href="./src/courier/resources/notifications/notifications.py">replace</a>(id, \*\*<a href="src/courier/types/notification_replace_params.py">params</a>) -> <a href="./src/courier/types/notification_template_mutation_response.py">NotificationTemplateMutationResponse</a></code>
369-
- <code title="get /notifications/{id}/content">client.notifications.<a href="./src/courier/resources/notifications/notifications.py">retrieve_content</a>(id) -> <a href="./src/courier/types/notification_get_content.py">NotificationGetContent</a></code>
370-
371-
## Draft
372-
373-
Methods:
374-
375-
- <code title="get /notifications/{id}/draft/content">client.notifications.draft.<a href="./src/courier/resources/notifications/draft.py">retrieve_content</a>(id) -> <a href="./src/courier/types/notification_get_content.py">NotificationGetContent</a></code>
380+
- <code title="get /notifications/{id}/content">client.notifications.<a href="./src/courier/resources/notifications/notifications.py">retrieve_content</a>(id, \*\*<a href="src/courier/types/notification_retrieve_content_params.py">params</a>) -> <a href="./src/courier/types/notification_retrieve_content_response.py">NotificationRetrieveContentResponse</a></code>
376381

377382
## Checks
378383

@@ -394,6 +399,7 @@ Types:
394399

395400
```python
396401
from courier.types import (
402+
AssociatedNotificationListResponse,
397403
RoutingStrategyCreateRequest,
398404
RoutingStrategyGetResponse,
399405
RoutingStrategyListResponse,
@@ -409,6 +415,7 @@ Methods:
409415
- <code title="get /routing-strategies/{id}">client.routing_strategies.<a href="./src/courier/resources/routing_strategies.py">retrieve</a>(id) -> <a href="./src/courier/types/routing_strategy_get_response.py">RoutingStrategyGetResponse</a></code>
410416
- <code title="get /routing-strategies">client.routing_strategies.<a href="./src/courier/resources/routing_strategies.py">list</a>(\*\*<a href="src/courier/types/routing_strategy_list_params.py">params</a>) -> <a href="./src/courier/types/routing_strategy_list_response.py">RoutingStrategyListResponse</a></code>
411417
- <code title="delete /routing-strategies/{id}">client.routing_strategies.<a href="./src/courier/resources/routing_strategies.py">archive</a>(id) -> None</code>
418+
- <code title="get /routing-strategies/{id}/notifications">client.routing_strategies.<a href="./src/courier/resources/routing_strategies.py">list_notifications</a>(id, \*\*<a href="src/courier/types/routing_strategy_list_notifications_params.py">params</a>) -> <a href="./src/courier/types/associated_notification_list_response.py">AssociatedNotificationListResponse</a></code>
412419
- <code title="put /routing-strategies/{id}">client.routing_strategies.<a href="./src/courier/resources/routing_strategies.py">replace</a>(id, \*\*<a href="src/courier/types/routing_strategy_replace_params.py">params</a>) -> <a href="./src/courier/types/routing_strategy_mutation_response.py">RoutingStrategyMutationResponse</a></code>
413420

414421
# Profiles

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "trycourier"
3-
version = "7.10.0"
3+
version = "7.11.0"
44
description = "The official Python library for the Courier API"
55
dynamic = ["readme"]
66
license = "Apache-2.0"

src/courier/_base_client.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -540,6 +540,10 @@ def _build_request(
540540
files = cast(HttpxRequestFiles, ForceMultipartDict())
541541

542542
prepared_url = self._prepare_url(options.url)
543+
# preserve hard-coded query params from the url
544+
if params and prepared_url.query:
545+
params = {**dict(prepared_url.params.items()), **params}
546+
prepared_url = prepared_url.copy_with(raw_path=prepared_url.raw_path.split(b"?", 1)[0])
543547
if "_" in prepared_url.host:
544548
# work around https://github.com/encode/httpx/discussions/2880
545549
kwargs["extensions"] = {"sni_hostname": prepared_url.host.replace("_", "-")}

src/courier/_version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
22

33
__title__ = "courier"
4-
__version__ = "7.10.0" # x-release-please-version
4+
__version__ = "7.11.0" # x-release-please-version

src/courier/resources/notifications/__init__.py

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,5 @@
11
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
22

3-
from .draft import (
4-
DraftResource,
5-
AsyncDraftResource,
6-
DraftResourceWithRawResponse,
7-
AsyncDraftResourceWithRawResponse,
8-
DraftResourceWithStreamingResponse,
9-
AsyncDraftResourceWithStreamingResponse,
10-
)
113
from .checks import (
124
ChecksResource,
135
AsyncChecksResource,
@@ -26,12 +18,6 @@
2618
)
2719

2820
__all__ = [
29-
"DraftResource",
30-
"AsyncDraftResource",
31-
"DraftResourceWithRawResponse",
32-
"AsyncDraftResourceWithRawResponse",
33-
"DraftResourceWithStreamingResponse",
34-
"AsyncDraftResourceWithStreamingResponse",
3521
"ChecksResource",
3622
"AsyncChecksResource",
3723
"ChecksResourceWithRawResponse",

src/courier/resources/notifications/draft.py

Lines changed: 0 additions & 160 deletions
This file was deleted.

0 commit comments

Comments
 (0)