cloudflare / cloudflare/cloudflare-docs
Python API Docs command incorrect - TotalTLS
- Dominant language
- MDX
- Stars
- 5.2k
- Forks
- 16.7k
- Avg merge
- 2d 6h
- Merged PRs (30d)
- 337
Description
### Existing documentation URL(s)
https://developers.cloudflare.com/api/python/resources/acm/subresources/total_tls/methods/update
### What changes are you suggesting?
According to docs enabling TotalTLS with the PythonSDK is done with the following function:
total_tls = client.acm.total_tls.update(
zone_id="023e105f4ecef8ad9ca31a8372d0c353",
enabled=True,
)
The option "update" does not exist as is shown in the following python error message:
Traceback (most recent call last):
File "/home/s73948/dev/cloudflare-zones/./cf-zone-creator.py", line 770, in
main()
File "/home/s73948/dev/cloudflare-zones/./cf-zone-creator.py", line 714, in main
set_ssl_settings(zone_name, zone_id, ssl_settings, features, token)
File "/home/s73948/dev/cloudflare-zones/./cf-zone-creator.py", line 304, in set_ssl_settings
total_tls = client.acm.total_tls.update(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'TotalTLSResource' object has no attribute 'update'
Listing all the attributes and methods of the object shows that no "update" method exists, but "create":
['__annotations__', '__class__', '__delattr__', '__dict__', '__dir__', '__doc__', '__eq__', '__format__', '__ge__', '__getattribute__', '__getstate__', '__gt__', '__hash__', '__init__', '__init_subclass__', '__le__', '__lt__', '__module__', '__ne__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__sizeof__', '__str__', '__subclasshook__', '__weakref__', '_client', '_delete', '_get', '_get_api_list', '_patch', '_post', '_put', '_sleep', 'create', 'get', 'with_raw_response', 'with_streaming_response'
Please correct the documentation to reflect the correct method in the Python SDK
### Additional information
_No response_
Contributor guide
Assessment
This issue has not been assessed yet.