Skip to content

Commit

Permalink
[bot] Updated client based on openapi-75904f0/clientgen (#299)
Browse files Browse the repository at this point in the history
Co-authored-by: API Engineering <[email protected]>
  • Loading branch information
digitalocean-engineering and API Engineering authored Jun 3, 2024
1 parent 3e3ebc9 commit e83aa9d
Show file tree
Hide file tree
Showing 5 changed files with 73 additions and 43 deletions.
2 changes: 1 addition & 1 deletion DO_OPENAPI_COMMIT_SHA.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
b5b24d0
75904f0
13 changes: 6 additions & 7 deletions src/pydo/_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,7 @@ class GeneratedClient: # pylint: disable=client-accepts-api-version-keyword,too
* - PATCH
- Some resources support partial modification. In these cases, the PATCH method is
available. Unlike PUT which generally requires a complete representation of a resource, a PATCH
request is is a set of instructions on how to modify a resource updating only specific
attributes.
request is a set of instructions on how to modify a resource updating only specific attributes.
* - POST
- To create a new object, your request should specify the POST method. The POST request
includes all of the attributes necessary to create a new object. When you wish to create a new
Expand Down Expand Up @@ -200,7 +199,7 @@ class GeneratedClient: # pylint: disable=client-accepts-api-version-keyword,too
Response for a Single Object
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.. code-block::
.. code-block:: json
{
"droplet": {
Expand All @@ -212,7 +211,7 @@ class GeneratedClient: # pylint: disable=client-accepts-api-version-keyword,too
Response for an Object Collection
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.. code-block::
.. code-block:: json
{
"droplets": [
Expand Down Expand Up @@ -244,7 +243,7 @@ class GeneratedClient: # pylint: disable=client-accepts-api-version-keyword,too
Sample Meta Object
^^^^^^^^^^^^^^^^^^
.. code-block::
.. code-block:: json
{
. . .
Expand Down Expand Up @@ -287,7 +286,7 @@ class GeneratedClient: # pylint: disable=client-accepts-api-version-keyword,too
Sample Links Object
^^^^^^^^^^^^^^^^^^^
.. code-block::
.. code-block:: json
{
. . .
Expand Down Expand Up @@ -354,7 +353,7 @@ class GeneratedClient: # pylint: disable=client-accepts-api-version-keyword,too
``ratelimit-remaining`` reaching zero can also indicate that the "burst limit" of 250
requests per minute limit was met, even if the 5,000 requests per hour limit was not.
In this case, the 429 error response will include a retry-after header to indicate how
In this case, the 429 error response will include a ``retry-after`` header to indicate how
long to wait (in seconds) until the request may be retried.
You can see the format of the response in the examples.
Expand Down
13 changes: 6 additions & 7 deletions src/pydo/aio/_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,7 @@ class GeneratedClient: # pylint: disable=client-accepts-api-version-keyword,too
* - PATCH
- Some resources support partial modification. In these cases, the PATCH method is
available. Unlike PUT which generally requires a complete representation of a resource, a PATCH
request is is a set of instructions on how to modify a resource updating only specific
attributes.
request is a set of instructions on how to modify a resource updating only specific attributes.
* - POST
- To create a new object, your request should specify the POST method. The POST request
includes all of the attributes necessary to create a new object. When you wish to create a new
Expand Down Expand Up @@ -200,7 +199,7 @@ class GeneratedClient: # pylint: disable=client-accepts-api-version-keyword,too
Response for a Single Object
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.. code-block::
.. code-block:: json
{
"droplet": {
Expand All @@ -212,7 +211,7 @@ class GeneratedClient: # pylint: disable=client-accepts-api-version-keyword,too
Response for an Object Collection
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.. code-block::
.. code-block:: json
{
"droplets": [
Expand Down Expand Up @@ -244,7 +243,7 @@ class GeneratedClient: # pylint: disable=client-accepts-api-version-keyword,too
Sample Meta Object
^^^^^^^^^^^^^^^^^^
.. code-block::
.. code-block:: json
{
. . .
Expand Down Expand Up @@ -287,7 +286,7 @@ class GeneratedClient: # pylint: disable=client-accepts-api-version-keyword,too
Sample Links Object
^^^^^^^^^^^^^^^^^^^
.. code-block::
.. code-block:: json
{
. . .
Expand Down Expand Up @@ -354,7 +353,7 @@ class GeneratedClient: # pylint: disable=client-accepts-api-version-keyword,too
``ratelimit-remaining`` reaching zero can also indicate that the "burst limit" of 250
requests per minute limit was met, even if the 5,000 requests per hour limit was not.
In this case, the 429 error response will include a retry-after header to indicate how
In this case, the 429 error response will include a ``retry-after`` header to indicate how
long to wait (in seconds) until the request may be retried.
You can see the format of the response in the examples.
Expand Down
44 changes: 30 additions & 14 deletions src/pydo/aio/operations/_operations.py
Original file line number Diff line number Diff line change
Expand Up @@ -85569,6 +85569,8 @@ async def list_options(self, **kwargs: Any) -> JSON:
To list all of the options available for the offered database engines, send a GET request to
``/v2/databases/options``.
The result will be a JSON object with an ``options`` key.
OpenSearch is in closed beta. To request access, `contact support
<https://cloudsupport.digitalocean.com>`_.

:return: JSON object
:rtype: JSON
Expand Down Expand Up @@ -85935,8 +85937,10 @@ async def list_clusters(
"engine": "str", # A slug representing the database engine
used for the cluster. The possible values are: "pg" for PostgreSQL,
"mysql" for MySQL, "redis" for Redis, "mongodb" for MongoDB, "kafka" for
Kafka and "opensearch" for Opensearch. Required. Known values are: "pg",
"mysql", "redis", "mongodb", "kafka", and "opensearch".
Kafka and "opensearch" for OpenSearch. OpenSearch is in closed beta. To
request access, `contact support
<https://cloudsupport.digitalocean.com>`_. Required. Known values are:
"pg", "mysql", "redis", "mongodb", "kafka", and "opensearch".
"name": "str", # A unique, human-readable name referring to
a database cluster. Required.
"num_nodes": 0, # The number of nodes in the database
Expand Down Expand Up @@ -86279,6 +86283,8 @@ async def create_cluster(
timestamp of the backup to be restored. Creating a database from a backup is the same as
forking a database in the control panel.
Note: Backups are not supported for Redis clusters.
OpenSearch is in closed beta. To request access, `contact support
<https://cloudsupport.digitalocean.com>`_.

:param body: Required.
:type body: JSON
Expand All @@ -86297,8 +86303,9 @@ async def create_cluster(
"engine": "str", # A slug representing the database engine used for the
cluster. The possible values are: "pg" for PostgreSQL, "mysql" for MySQL, "redis"
for Redis, "mongodb" for MongoDB, "kafka" for Kafka and "opensearch" for
Opensearch. Required. Known values are: "pg", "mysql", "redis", "mongodb",
"kafka", and "opensearch".
OpenSearch. OpenSearch is in closed beta. To request access, `contact support
<https://cloudsupport.digitalocean.com>`_. Required. Known values are: "pg",
"mysql", "redis", "mongodb", "kafka", and "opensearch".
"name": "str", # A unique, human-readable name referring to a database
cluster. Required.
"num_nodes": 0, # The number of nodes in the database cluster. Required.
Expand Down Expand Up @@ -86516,8 +86523,9 @@ async def create_cluster(
"engine": "str", # A slug representing the database engine used for
the cluster. The possible values are: "pg" for PostgreSQL, "mysql" for MySQL,
"redis" for Redis, "mongodb" for MongoDB, "kafka" for Kafka and "opensearch"
for Opensearch. Required. Known values are: "pg", "mysql", "redis",
"mongodb", "kafka", and "opensearch".
for OpenSearch. OpenSearch is in closed beta. To request access, `contact
support <https://cloudsupport.digitalocean.com>`_. Required. Known values
are: "pg", "mysql", "redis", "mongodb", "kafka", and "opensearch".
"name": "str", # A unique, human-readable name referring to a
database cluster. Required.
"num_nodes": 0, # The number of nodes in the database cluster.
Expand Down Expand Up @@ -86770,6 +86778,8 @@ async def create_cluster(
timestamp of the backup to be restored. Creating a database from a backup is the same as
forking a database in the control panel.
Note: Backups are not supported for Redis clusters.
OpenSearch is in closed beta. To request access, `contact support
<https://cloudsupport.digitalocean.com>`_.

:param body: Required.
:type body: IO[bytes]
Expand All @@ -86789,8 +86799,9 @@ async def create_cluster(
"engine": "str", # A slug representing the database engine used for
the cluster. The possible values are: "pg" for PostgreSQL, "mysql" for MySQL,
"redis" for Redis, "mongodb" for MongoDB, "kafka" for Kafka and "opensearch"
for Opensearch. Required. Known values are: "pg", "mysql", "redis",
"mongodb", "kafka", and "opensearch".
for OpenSearch. OpenSearch is in closed beta. To request access, `contact
support <https://cloudsupport.digitalocean.com>`_. Required. Known values
are: "pg", "mysql", "redis", "mongodb", "kafka", and "opensearch".
"name": "str", # A unique, human-readable name referring to a
database cluster. Required.
"num_nodes": 0, # The number of nodes in the database cluster.
Expand Down Expand Up @@ -87041,6 +87052,8 @@ async def create_cluster(self, body: Union[JSON, IO[bytes]], **kwargs: Any) -> J
timestamp of the backup to be restored. Creating a database from a backup is the same as
forking a database in the control panel.
Note: Backups are not supported for Redis clusters.
OpenSearch is in closed beta. To request access, `contact support
<https://cloudsupport.digitalocean.com>`_.

:param body: Is either a JSON type or a IO[bytes] type. Required.
:type body: JSON or IO[bytes]
Expand All @@ -87056,8 +87069,9 @@ async def create_cluster(self, body: Union[JSON, IO[bytes]], **kwargs: Any) -> J
"engine": "str", # A slug representing the database engine used for the
cluster. The possible values are: "pg" for PostgreSQL, "mysql" for MySQL, "redis"
for Redis, "mongodb" for MongoDB, "kafka" for Kafka and "opensearch" for
Opensearch. Required. Known values are: "pg", "mysql", "redis", "mongodb",
"kafka", and "opensearch".
OpenSearch. OpenSearch is in closed beta. To request access, `contact support
<https://cloudsupport.digitalocean.com>`_. Required. Known values are: "pg",
"mysql", "redis", "mongodb", "kafka", and "opensearch".
"name": "str", # A unique, human-readable name referring to a database
cluster. Required.
"num_nodes": 0, # The number of nodes in the database cluster. Required.
Expand Down Expand Up @@ -87275,8 +87289,9 @@ async def create_cluster(self, body: Union[JSON, IO[bytes]], **kwargs: Any) -> J
"engine": "str", # A slug representing the database engine used for
the cluster. The possible values are: "pg" for PostgreSQL, "mysql" for MySQL,
"redis" for Redis, "mongodb" for MongoDB, "kafka" for Kafka and "opensearch"
for Opensearch. Required. Known values are: "pg", "mysql", "redis",
"mongodb", "kafka", and "opensearch".
for OpenSearch. OpenSearch is in closed beta. To request access, `contact
support <https://cloudsupport.digitalocean.com>`_. Required. Known values
are: "pg", "mysql", "redis", "mongodb", "kafka", and "opensearch".
"name": "str", # A unique, human-readable name referring to a
database cluster. Required.
"num_nodes": 0, # The number of nodes in the database cluster.
Expand Down Expand Up @@ -87628,8 +87643,9 @@ async def get_cluster(self, database_cluster_uuid: str, **kwargs: Any) -> JSON:
"engine": "str", # A slug representing the database engine used for
the cluster. The possible values are: "pg" for PostgreSQL, "mysql" for MySQL,
"redis" for Redis, "mongodb" for MongoDB, "kafka" for Kafka and "opensearch"
for Opensearch. Required. Known values are: "pg", "mysql", "redis",
"mongodb", "kafka", and "opensearch".
for OpenSearch. OpenSearch is in closed beta. To request access, `contact
support <https://cloudsupport.digitalocean.com>`_. Required. Known values
are: "pg", "mysql", "redis", "mongodb", "kafka", and "opensearch".
"name": "str", # A unique, human-readable name referring to a
database cluster. Required.
"num_nodes": 0, # The number of nodes in the database cluster.
Expand Down
Loading

0 comments on commit e83aa9d

Please sign in to comment.