File tree Expand file tree Collapse file tree 6 files changed +24
-0
lines changed
scaleway-async/scaleway_async/cockpit/v1beta1
scaleway/scaleway/cockpit/v1beta1 Expand file tree Collapse file tree 6 files changed +24
-0
lines changed Original file line number Diff line number Diff line change @@ -283,13 +283,15 @@ async def create_datasource(
283283 * ,
284284 name : str ,
285285 type_ : DatasourceType ,
286+ is_default : bool ,
286287 project_id : Optional [str ] = None ,
287288 ) -> Datasource :
288289 """
289290 Create a datasource for the specified Project ID and the given type.
290291 :param project_id: ID of the Project the Cockpit belongs to.
291292 :param name: Datasource name.
292293 :param type_: Datasource type.
294+ :param is_default: Specifies that the returned output is the default datasource per type.
293295 :return: :class:`Datasource <Datasource>`
294296
295297 Usage:
@@ -298,6 +300,7 @@ async def create_datasource(
298300 result = await api.create_datasource(
299301 name="example",
300302 type_=unknown_datasource_type,
303+ is_default=True,
301304 )
302305 """
303306
@@ -308,6 +311,7 @@ async def create_datasource(
308311 CreateDatasourceRequest (
309312 name = name ,
310313 type_ = type_ ,
314+ is_default = is_default ,
311315 project_id = project_id ,
312316 ),
313317 self .client ,
Original file line number Diff line number Diff line change @@ -568,6 +568,9 @@ def marshal_CreateDatasourceRequest(
568568) -> Dict [str , Any ]:
569569 output : Dict [str , Any ] = {}
570570
571+ if request .is_default is not None :
572+ output ["is_default" ] = request .is_default
573+
571574 if request .name is not None :
572575 output ["name" ] = request .name
573576
Original file line number Diff line number Diff line change @@ -634,6 +634,11 @@ class CreateDatasourceRequest:
634634 Datasource type.
635635 """
636636
637+ is_default : bool
638+ """
639+ Specifies that the returned output is the default datasource per type.
640+ """
641+
637642
638643@dataclass
639644class ListDatasourcesRequest :
Original file line number Diff line number Diff line change @@ -283,13 +283,15 @@ def create_datasource(
283283 * ,
284284 name : str ,
285285 type_ : DatasourceType ,
286+ is_default : bool ,
286287 project_id : Optional [str ] = None ,
287288 ) -> Datasource :
288289 """
289290 Create a datasource for the specified Project ID and the given type.
290291 :param project_id: ID of the Project the Cockpit belongs to.
291292 :param name: Datasource name.
292293 :param type_: Datasource type.
294+ :param is_default: Specifies that the returned output is the default datasource per type.
293295 :return: :class:`Datasource <Datasource>`
294296
295297 Usage:
@@ -298,6 +300,7 @@ def create_datasource(
298300 result = api.create_datasource(
299301 name="example",
300302 type_=unknown_datasource_type,
303+ is_default=True,
301304 )
302305 """
303306
@@ -308,6 +311,7 @@ def create_datasource(
308311 CreateDatasourceRequest (
309312 name = name ,
310313 type_ = type_ ,
314+ is_default = is_default ,
311315 project_id = project_id ,
312316 ),
313317 self .client ,
Original file line number Diff line number Diff line change @@ -568,6 +568,9 @@ def marshal_CreateDatasourceRequest(
568568) -> Dict [str , Any ]:
569569 output : Dict [str , Any ] = {}
570570
571+ if request .is_default is not None :
572+ output ["is_default" ] = request .is_default
573+
571574 if request .name is not None :
572575 output ["name" ] = request .name
573576
Original file line number Diff line number Diff line change @@ -634,6 +634,11 @@ class CreateDatasourceRequest:
634634 Datasource type.
635635 """
636636
637+ is_default : bool
638+ """
639+ Specifies that the returned output is the default datasource per type.
640+ """
641+
637642
638643@dataclass
639644class ListDatasourcesRequest :
You can’t perform that action at this time.
0 commit comments