You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This implements the new per resources actions endpoints.
Related to https://docs.hetzner.cloud/changelog#2023-06-29-resource-action-endpoints
```py
# Existing API
client.actions.get_by_id() # /actions/{id}
client.<resource>.get_actions_all() # /<resource>/{resource_id}/actions
client.<resource>.get_actions_list() # /<resource>/{resource_id}/actions
# New API
client.<resource>.actions.get_all() # /<resource>/actions
client.<resource>.actions.get_list() # /<resource>/actions
client.<resource>.actions.get_by_id() # /<resource>/actions/{id}
# Not planned
client.<resource>.get_action_by_id() # /<resource>/{resource_id}/actions/{id}
# Deprecated
client.actions.get_all() # /actions
client.actions.get_list() # /actions
```
One exception is the primary IPs client, it doesn't include calls to `/<resource>/{resource_id}/actions` or `/<resource>/{resource_id}/actions/{id}`: https://docs.hetzner.cloud/#primary-ip-actions
* test: improve existing actions tests
* feat: create ResourceActionsClient
* feat: deprecated /actions endpoint
* test: add tests for ResourceActionsClient
* feat: spread ResourceActionsClient to all clients
* test: add tests for all ResourceActionsClient
* docs: improve reference docs
* docs: add link to deprecation changelog
0 commit comments