Skip to content

Commit 22df831

Browse files
committed
change the type of the body in put_access_point_policy and put_bucket_policy.
1 parent f446c22 commit 22df831

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

alibabacloud_oss_v2/models/access_point.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import io
22
from typing import Optional, List, Any
3-
from .. import serde
3+
from .. import serde, BodyType
44

55

66
class AccessPointVpcConfiguration(serde.Model):
@@ -432,20 +432,20 @@ class PutAccessPointPolicyRequest(serde.RequestModel):
432432
_attribute_map = {
433433
'bucket': {'tag': 'input', 'position': 'host', 'rename': 'bucket', 'type': 'str'},
434434
'access_point_name': {'tag': 'input', 'position': 'header', 'rename': 'x-oss-access-point-name', 'type': 'str'},
435-
'body': {'tag': 'input', 'position': 'body', 'rename': 'nop', 'type': 'str'},
435+
'body': {'tag': 'input', 'position': 'body', 'rename': 'nop'},
436436
}
437437

438438
def __init__(
439439
self,
440440
bucket: Optional[str] = None,
441441
access_point_name: Optional[str] = None,
442-
body: Optional[str] = None,
442+
body: Optional[BodyType] = None,
443443
**kwargs: Any
444444
) -> None:
445445
"""
446446
bucket (str, optional): The name of the bucket.
447447
access_point_name (str, optional): The name of the access point.
448-
body (str, optional): The configurations of the access point policy.
448+
body (BodyType, optional): The configurations of the access point policy.
449449
"""
450450
super().__init__(**kwargs)
451451
self.bucket = bucket

alibabacloud_oss_v2/models/bucket_policy.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
from typing import Optional, List, Any, Union
2-
from .. import serde
2+
from .. import serde, BodyType
33

44

55
class PolicyStatus(serde.Model):
@@ -36,18 +36,18 @@ class PutBucketPolicyRequest(serde.RequestModel):
3636

3737
_attribute_map = {
3838
'bucket': {'tag': 'input', 'position': 'host', 'rename': 'bucket', 'type': 'str', 'required': True},
39-
'body': {'tag': 'input', 'position': 'body', 'rename': 'nop', 'type': 'str', 'required': True},
39+
'body': {'tag': 'input', 'position': 'body', 'rename': 'nop', 'required': True},
4040
}
4141

4242
def __init__(
4343
self,
4444
bucket: str = None,
45-
body: Optional[str] = None,
45+
body: Optional[BodyType] = None,
4646
**kwargs: Any
4747
) -> None:
4848
"""
4949
bucket (str, required): The name of the bucket.
50-
body (str, required): The request parameters.
50+
body (BodyType, required): The request parameters.
5151
"""
5252
super().__init__(**kwargs)
5353
self.bucket = bucket

0 commit comments

Comments
 (0)