Skip to content

Commit 7811c6f

Browse files
stainless-app[bot]stainless-bot
authored andcommitted
feat(api): OpenAPI spec update via Stainless API (#1197)
1 parent 0a5eed9 commit 7811c6f

File tree

4 files changed

+20
-25
lines changed

4 files changed

+20
-25
lines changed

.stats.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
configured_endpoints: 1258
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-308cb06dd45e1721541e0692ddb5a613862d196db3ecd11796de06dbf697d4e7.yml
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-631b9d0d61d56c9bcffbbf496ccfa7daa86b8e627fe008bf17ab367f252074ba.yml

src/cloudflare/types/hyperdrive/configuration.py

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

3+
from typing import Optional
34
from typing_extensions import Literal
45

56
from ..._models import BaseModel
@@ -14,11 +15,14 @@ class Configuration(BaseModel):
1415
host: str
1516
"""The host (hostname or IP) of your origin database."""
1617

17-
port: int
18-
"""The port (default: 5432 for Postgres) of your origin database."""
19-
2018
scheme: Literal["postgres", "postgresql", "mysql"]
2119
"""Specifies the URL scheme used to connect to your origin database."""
2220

2321
user: str
2422
"""The user of your origin database."""
23+
24+
access_client_id: Optional[str] = None
25+
"""The Client ID of the Access token to use when connecting to the origin database"""
26+
27+
port: Optional[int] = None
28+
"""The port (default: 5432 for Postgres) of your origin database."""

src/cloudflare/types/hyperdrive/configuration_param.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,14 @@ class ConfigurationParam(TypedDict, total=False):
1414
host: Required[str]
1515
"""The host (hostname or IP) of your origin database."""
1616

17-
port: Required[int]
18-
"""The port (default: 5432 for Postgres) of your origin database."""
19-
2017
scheme: Required[Literal["postgres", "postgresql", "mysql"]]
2118
"""Specifies the URL scheme used to connect to your origin database."""
2219

2320
user: Required[str]
2421
"""The user of your origin database."""
22+
23+
access_client_id: str
24+
"""The Client ID of the Access token to use when connecting to the origin database"""
25+
26+
port: int
27+
"""The port (default: 5432 for Postgres) of your origin database."""

tests/api_resources/hyperdrive/test_configs.py

Lines changed: 6 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ def test_method_create(self, client: Cloudflare) -> None:
3030
origin={
3131
"database": "postgres",
3232
"host": "database.example.com",
33-
"port": 5432,
3433
"scheme": "postgres",
3534
"user": "postgres",
3635
},
@@ -44,6 +43,7 @@ def test_method_create_with_all_params(self, client: Cloudflare) -> None:
4443
account_id="023e105f4ecef8ad9ca31a8372d0c353",
4544
name="example-hyperdrive",
4645
origin={
46+
"access_client_id": "0123456789abcdef0123456789abcdef.access",
4747
"database": "postgres",
4848
"host": "database.example.com",
4949
"port": 5432,
@@ -67,7 +67,6 @@ def test_raw_response_create(self, client: Cloudflare) -> None:
6767
origin={
6868
"database": "postgres",
6969
"host": "database.example.com",
70-
"port": 5432,
7170
"scheme": "postgres",
7271
"user": "postgres",
7372
},
@@ -87,7 +86,6 @@ def test_streaming_response_create(self, client: Cloudflare) -> None:
8786
origin={
8887
"database": "postgres",
8988
"host": "database.example.com",
90-
"port": 5432,
9189
"scheme": "postgres",
9290
"user": "postgres",
9391
},
@@ -110,7 +108,6 @@ def test_path_params_create(self, client: Cloudflare) -> None:
110108
origin={
111109
"database": "postgres",
112110
"host": "database.example.com",
113-
"port": 5432,
114111
"scheme": "postgres",
115112
"user": "postgres",
116113
},
@@ -126,7 +123,6 @@ def test_method_update(self, client: Cloudflare) -> None:
126123
origin={
127124
"database": "postgres",
128125
"host": "database.example.com",
129-
"port": 5432,
130126
"scheme": "postgres",
131127
"user": "postgres",
132128
},
@@ -141,6 +137,7 @@ def test_method_update_with_all_params(self, client: Cloudflare) -> None:
141137
account_id="023e105f4ecef8ad9ca31a8372d0c353",
142138
name="example-hyperdrive",
143139
origin={
140+
"access_client_id": "0123456789abcdef0123456789abcdef.access",
144141
"database": "postgres",
145142
"host": "database.example.com",
146143
"port": 5432,
@@ -165,7 +162,6 @@ def test_raw_response_update(self, client: Cloudflare) -> None:
165162
origin={
166163
"database": "postgres",
167164
"host": "database.example.com",
168-
"port": 5432,
169165
"scheme": "postgres",
170166
"user": "postgres",
171167
},
@@ -186,7 +182,6 @@ def test_streaming_response_update(self, client: Cloudflare) -> None:
186182
origin={
187183
"database": "postgres",
188184
"host": "database.example.com",
189-
"port": 5432,
190185
"scheme": "postgres",
191186
"user": "postgres",
192187
},
@@ -210,7 +205,6 @@ def test_path_params_update(self, client: Cloudflare) -> None:
210205
origin={
211206
"database": "postgres",
212207
"host": "database.example.com",
213-
"port": 5432,
214208
"scheme": "postgres",
215209
"user": "postgres",
216210
},
@@ -224,7 +218,6 @@ def test_path_params_update(self, client: Cloudflare) -> None:
224218
origin={
225219
"database": "postgres",
226220
"host": "database.example.com",
227-
"port": 5432,
228221
"scheme": "postgres",
229222
"user": "postgres",
230223
},
@@ -338,6 +331,7 @@ def test_method_edit_with_all_params(self, client: Cloudflare) -> None:
338331
},
339332
name="example-hyperdrive",
340333
origin={
334+
"access_client_id": "0123456789abcdef0123456789abcdef.access",
341335
"database": "postgres",
342336
"host": "database.example.com",
343337
"port": 5432,
@@ -451,7 +445,6 @@ async def test_method_create(self, async_client: AsyncCloudflare) -> None:
451445
origin={
452446
"database": "postgres",
453447
"host": "database.example.com",
454-
"port": 5432,
455448
"scheme": "postgres",
456449
"user": "postgres",
457450
},
@@ -465,6 +458,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncCloudflare
465458
account_id="023e105f4ecef8ad9ca31a8372d0c353",
466459
name="example-hyperdrive",
467460
origin={
461+
"access_client_id": "0123456789abcdef0123456789abcdef.access",
468462
"database": "postgres",
469463
"host": "database.example.com",
470464
"port": 5432,
@@ -488,7 +482,6 @@ async def test_raw_response_create(self, async_client: AsyncCloudflare) -> None:
488482
origin={
489483
"database": "postgres",
490484
"host": "database.example.com",
491-
"port": 5432,
492485
"scheme": "postgres",
493486
"user": "postgres",
494487
},
@@ -508,7 +501,6 @@ async def test_streaming_response_create(self, async_client: AsyncCloudflare) ->
508501
origin={
509502
"database": "postgres",
510503
"host": "database.example.com",
511-
"port": 5432,
512504
"scheme": "postgres",
513505
"user": "postgres",
514506
},
@@ -531,7 +523,6 @@ async def test_path_params_create(self, async_client: AsyncCloudflare) -> None:
531523
origin={
532524
"database": "postgres",
533525
"host": "database.example.com",
534-
"port": 5432,
535526
"scheme": "postgres",
536527
"user": "postgres",
537528
},
@@ -547,7 +538,6 @@ async def test_method_update(self, async_client: AsyncCloudflare) -> None:
547538
origin={
548539
"database": "postgres",
549540
"host": "database.example.com",
550-
"port": 5432,
551541
"scheme": "postgres",
552542
"user": "postgres",
553543
},
@@ -562,6 +552,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncCloudflare
562552
account_id="023e105f4ecef8ad9ca31a8372d0c353",
563553
name="example-hyperdrive",
564554
origin={
555+
"access_client_id": "0123456789abcdef0123456789abcdef.access",
565556
"database": "postgres",
566557
"host": "database.example.com",
567558
"port": 5432,
@@ -586,7 +577,6 @@ async def test_raw_response_update(self, async_client: AsyncCloudflare) -> None:
586577
origin={
587578
"database": "postgres",
588579
"host": "database.example.com",
589-
"port": 5432,
590580
"scheme": "postgres",
591581
"user": "postgres",
592582
},
@@ -607,7 +597,6 @@ async def test_streaming_response_update(self, async_client: AsyncCloudflare) ->
607597
origin={
608598
"database": "postgres",
609599
"host": "database.example.com",
610-
"port": 5432,
611600
"scheme": "postgres",
612601
"user": "postgres",
613602
},
@@ -631,7 +620,6 @@ async def test_path_params_update(self, async_client: AsyncCloudflare) -> None:
631620
origin={
632621
"database": "postgres",
633622
"host": "database.example.com",
634-
"port": 5432,
635623
"scheme": "postgres",
636624
"user": "postgres",
637625
},
@@ -645,7 +633,6 @@ async def test_path_params_update(self, async_client: AsyncCloudflare) -> None:
645633
origin={
646634
"database": "postgres",
647635
"host": "database.example.com",
648-
"port": 5432,
649636
"scheme": "postgres",
650637
"user": "postgres",
651638
},
@@ -759,6 +746,7 @@ async def test_method_edit_with_all_params(self, async_client: AsyncCloudflare)
759746
},
760747
name="example-hyperdrive",
761748
origin={
749+
"access_client_id": "0123456789abcdef0123456789abcdef.access",
762750
"database": "postgres",
763751
"host": "database.example.com",
764752
"port": 5432,

0 commit comments

Comments
 (0)