waldur-api-client 7.6.5__py3-none-any.whl → 7.6.8__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of waldur-api-client might be problematic. Click here for more details.

Files changed (230) hide show
  1. waldur_api_client/api/access_subnets/access_subnets_list.py +8 -4
  2. waldur_api_client/api/admin_announcements/admin_announcements_list.py +8 -4
  3. waldur_api_client/api/auth_tokens/auth_tokens_list.py +8 -4
  4. waldur_api_client/api/autoprovisioning_rule_plans/autoprovisioning_rule_plans_list.py +8 -4
  5. waldur_api_client/api/autoprovisioning_rules/autoprovisioning_rules_list.py +8 -4
  6. waldur_api_client/api/aws_images/aws_images_list.py +8 -4
  7. waldur_api_client/api/aws_instances/aws_instances_list.py +8 -4
  8. waldur_api_client/api/aws_regions/aws_regions_list.py +8 -4
  9. waldur_api_client/api/aws_sizes/aws_sizes_list.py +8 -4
  10. waldur_api_client/api/aws_volumes/aws_volumes_list.py +8 -4
  11. waldur_api_client/api/azure_images/azure_images_list.py +8 -4
  12. waldur_api_client/api/azure_locations/azure_locations_list.py +8 -4
  13. waldur_api_client/api/azure_public_ips/azure_public_ips_list.py +8 -4
  14. waldur_api_client/api/azure_resource_groups/azure_resource_groups_list.py +8 -4
  15. waldur_api_client/api/azure_sizes/azure_sizes_list.py +8 -4
  16. waldur_api_client/api/azure_sql_databases/azure_sql_databases_list.py +8 -4
  17. waldur_api_client/api/azure_sql_servers/azure_sql_servers_list.py +8 -4
  18. waldur_api_client/api/azure_virtualmachines/azure_virtualmachines_list.py +8 -4
  19. waldur_api_client/api/backend_resource_requests/__init__.py +1 -0
  20. waldur_api_client/api/backend_resource_requests/backend_resource_requests_create.py +150 -0
  21. waldur_api_client/api/backend_resource_requests/backend_resource_requests_list.py +313 -0
  22. waldur_api_client/api/backend_resource_requests/backend_resource_requests_retrieve.py +142 -0
  23. waldur_api_client/api/backend_resource_requests/backend_resource_requests_set_done.py +144 -0
  24. waldur_api_client/api/backend_resource_requests/backend_resource_requests_set_erred.py +166 -0
  25. waldur_api_client/api/backend_resource_requests/backend_resource_requests_start_processing.py +146 -0
  26. waldur_api_client/api/backend_resources/__init__.py +1 -0
  27. waldur_api_client/api/backend_resources/backend_resources_create.py +150 -0
  28. waldur_api_client/api/backend_resources/backend_resources_destroy.py +89 -0
  29. waldur_api_client/api/backend_resources/backend_resources_import_resource.py +162 -0
  30. waldur_api_client/api/backend_resources/backend_resources_list.py +315 -0
  31. waldur_api_client/api/backend_resources/backend_resources_retrieve.py +142 -0
  32. waldur_api_client/api/booking_offerings/booking_offerings_list.py +8 -4
  33. waldur_api_client/api/booking_resources/booking_resources_list.py +8 -4
  34. waldur_api_client/api/broadcast_message_templates/broadcast_message_templates_list.py +8 -4
  35. waldur_api_client/api/broadcast_messages/broadcast_messages_list.py +8 -4
  36. waldur_api_client/api/call_managing_organisations/call_managing_organisations_list.py +8 -4
  37. waldur_api_client/api/call_rounds/call_rounds_list.py +8 -4
  38. waldur_api_client/api/component_user_usage_limits/component_user_usage_limits_list.py +8 -4
  39. waldur_api_client/api/customer_credits/customer_credits_list.py +8 -4
  40. waldur_api_client/api/customer_permissions_reviews/customer_permissions_reviews_list.py +8 -4
  41. waldur_api_client/api/digitalocean_droplets/digitalocean_droplets_list.py +8 -4
  42. waldur_api_client/api/digitalocean_images/digitalocean_images_list.py +8 -4
  43. waldur_api_client/api/digitalocean_regions/digitalocean_regions_list.py +8 -4
  44. waldur_api_client/api/digitalocean_sizes/digitalocean_sizes_list.py +8 -4
  45. waldur_api_client/api/email_logs/email_logs_list.py +8 -4
  46. waldur_api_client/api/event_subscriptions/event_subscriptions_list.py +8 -4
  47. waldur_api_client/api/events/events_list.py +8 -4
  48. waldur_api_client/api/events_stats/events_stats_list.py +8 -4
  49. waldur_api_client/api/financial_reports/financial_reports_list.py +8 -4
  50. waldur_api_client/api/freeipa_profiles/freeipa_profiles_list.py +8 -4
  51. waldur_api_client/api/google_auth/google_auth_list.py +8 -4
  52. waldur_api_client/api/hooks/hooks_list.py +4 -2
  53. waldur_api_client/api/hooks_email/hooks_email_list.py +8 -4
  54. waldur_api_client/api/hooks_web/hooks_web_list.py +8 -4
  55. waldur_api_client/api/identity_providers/identity_providers_list.py +8 -4
  56. waldur_api_client/api/invoice_items/invoice_items_list.py +8 -4
  57. waldur_api_client/api/invoices/invoices_list.py +8 -4
  58. waldur_api_client/api/keycloak_groups/keycloak_groups_list.py +8 -4
  59. waldur_api_client/api/keycloak_user_group_memberships/keycloak_user_group_memberships_list.py +8 -4
  60. waldur_api_client/api/keys/keys_list.py +8 -4
  61. waldur_api_client/api/lexis_links/lexis_links_list.py +8 -4
  62. waldur_api_client/api/marketplace_categories/marketplace_categories_list.py +8 -4
  63. waldur_api_client/api/marketplace_category_columns/marketplace_category_columns_list.py +8 -4
  64. waldur_api_client/api/marketplace_category_component_usages/marketplace_category_component_usages_list.py +8 -4
  65. waldur_api_client/api/marketplace_category_components/marketplace_category_components_list.py +8 -4
  66. waldur_api_client/api/marketplace_category_groups/marketplace_category_groups_list.py +8 -4
  67. waldur_api_client/api/marketplace_category_help_articles/marketplace_category_help_articles_list.py +8 -4
  68. waldur_api_client/api/marketplace_checklists/marketplace_checklists_answers_list.py +8 -4
  69. waldur_api_client/api/marketplace_checklists/marketplace_checklists_list.py +8 -4
  70. waldur_api_client/api/marketplace_checklists/marketplace_checklists_questions_list.py +8 -4
  71. waldur_api_client/api/marketplace_checklists/marketplace_checklists_user_answers_list.py +8 -4
  72. waldur_api_client/api/marketplace_checklists_categories/marketplace_checklists_categories_checklists_list.py +8 -4
  73. waldur_api_client/api/marketplace_checklists_categories/marketplace_checklists_categories_list.py +8 -4
  74. waldur_api_client/api/marketplace_component_usages/marketplace_component_usages_list.py +8 -4
  75. waldur_api_client/api/marketplace_component_user_usages/marketplace_component_user_usages_list.py +8 -4
  76. waldur_api_client/api/marketplace_customer_estimated_cost_policies/marketplace_customer_estimated_cost_policies_list.py +8 -4
  77. waldur_api_client/api/marketplace_customer_service_accounts/marketplace_customer_service_accounts_list.py +8 -4
  78. waldur_api_client/api/marketplace_integration_statuses/marketplace_integration_statuses_list.py +8 -4
  79. waldur_api_client/api/marketplace_offering_estimated_cost_policies/marketplace_offering_estimated_cost_policies_list.py +8 -4
  80. waldur_api_client/api/marketplace_offering_files/marketplace_offering_files_list.py +8 -4
  81. waldur_api_client/api/marketplace_offering_permissions/marketplace_offering_permissions_list.py +18 -17
  82. waldur_api_client/api/marketplace_offering_permissions_log/marketplace_offering_permissions_log_list.py +18 -17
  83. waldur_api_client/api/marketplace_offering_referrals/marketplace_offering_referrals_list.py +8 -4
  84. waldur_api_client/api/marketplace_offering_usage_policies/marketplace_offering_usage_policies_list.py +8 -4
  85. waldur_api_client/api/marketplace_offering_user_roles/marketplace_offering_user_roles_list.py +8 -4
  86. waldur_api_client/api/marketplace_offering_users/marketplace_offering_users_list.py +8 -4
  87. waldur_api_client/api/marketplace_orders/marketplace_orders_list.py +8 -4
  88. waldur_api_client/api/marketplace_plan_components/marketplace_plan_components_list.py +8 -4
  89. waldur_api_client/api/marketplace_plans/marketplace_plans_list.py +8 -4
  90. waldur_api_client/api/marketplace_project_estimated_cost_policies/marketplace_project_estimated_cost_policies_list.py +8 -4
  91. waldur_api_client/api/marketplace_project_service_accounts/marketplace_project_service_accounts_list.py +8 -4
  92. waldur_api_client/api/marketplace_project_update_requests/marketplace_project_update_requests_list.py +8 -4
  93. waldur_api_client/api/marketplace_provider_offerings/marketplace_provider_offerings_component_stats_list.py +10 -13
  94. waldur_api_client/api/marketplace_provider_offerings/marketplace_provider_offerings_costs_list.py +10 -13
  95. waldur_api_client/api/marketplace_provider_offerings/marketplace_provider_offerings_customers_list.py +10 -13
  96. waldur_api_client/api/marketplace_provider_offerings/marketplace_provider_offerings_groups_list.py +10 -13
  97. waldur_api_client/api/marketplace_provider_offerings/marketplace_provider_offerings_list.py +18 -17
  98. waldur_api_client/api/marketplace_provider_offerings/marketplace_provider_offerings_refresh_offering_usernames.py +20 -16
  99. waldur_api_client/api/marketplace_provider_resources/marketplace_provider_resources_list.py +8 -4
  100. waldur_api_client/api/marketplace_provider_resources/marketplace_provider_resources_set_as_erred.py +11 -68
  101. waldur_api_client/api/marketplace_provider_resources/marketplace_provider_resources_set_backend_id.py +20 -16
  102. waldur_api_client/api/marketplace_provider_resources/marketplace_provider_resources_set_backend_metadata.py +12 -12
  103. waldur_api_client/api/marketplace_provider_resources/marketplace_provider_resources_set_limits.py +12 -12
  104. waldur_api_client/api/marketplace_provider_resources/marketplace_provider_resources_submit_report.py +20 -16
  105. waldur_api_client/api/marketplace_public_offerings/marketplace_public_offerings_list.py +18 -17
  106. waldur_api_client/api/marketplace_remote_synchronisations/marketplace_remote_synchronisations_list.py +8 -4
  107. waldur_api_client/api/marketplace_resource_users/marketplace_resource_users_list.py +8 -4
  108. waldur_api_client/api/marketplace_resources/marketplace_resources_list.py +8 -4
  109. waldur_api_client/api/marketplace_resources/marketplace_resources_update_options.py +20 -16
  110. waldur_api_client/api/marketplace_robot_accounts/marketplace_robot_accounts_list.py +8 -4
  111. waldur_api_client/api/marketplace_screenshots/marketplace_screenshots_list.py +8 -4
  112. waldur_api_client/api/marketplace_script_async_dry_run/marketplace_script_async_dry_run_list.py +8 -4
  113. waldur_api_client/api/marketplace_sections/marketplace_sections_list.py +8 -4
  114. waldur_api_client/api/marketplace_service_providers/marketplace_service_providers_customer_projects_list.py +15 -0
  115. waldur_api_client/api/marketplace_service_providers/marketplace_service_providers_list.py +8 -4
  116. waldur_api_client/api/marketplace_service_providers/marketplace_service_providers_offerings_list.py +10 -13
  117. waldur_api_client/api/marketplace_service_providers/marketplace_service_providers_project_permissions_list.py +10 -13
  118. waldur_api_client/api/marketplace_service_providers/marketplace_service_providers_projects_list.py +15 -0
  119. waldur_api_client/api/notification_messages/notification_messages_list.py +8 -4
  120. waldur_api_client/api/notification_messages_templates/notification_messages_templates_list.py +8 -4
  121. waldur_api_client/api/openstack_backups/openstack_backups_list.py +8 -4
  122. waldur_api_client/api/openstack_flavors/openstack_flavors_list.py +26 -4
  123. waldur_api_client/api/openstack_images/openstack_images_list.py +26 -4
  124. waldur_api_client/api/openstack_instance_availability_zones/openstack_instance_availability_zones_list.py +8 -4
  125. waldur_api_client/api/openstack_instances/openstack_instances_list.py +8 -4
  126. waldur_api_client/api/openstack_marketplace_tenants/openstack_marketplace_tenants_list.py +8 -4
  127. waldur_api_client/api/openstack_migrations/openstack_migrations_list.py +8 -4
  128. waldur_api_client/api/openstack_network_rbac_policies/openstack_network_rbac_policies_list.py +8 -4
  129. waldur_api_client/api/openstack_networks/openstack_networks_list.py +8 -4
  130. waldur_api_client/api/openstack_ports/openstack_ports_list.py +8 -4
  131. waldur_api_client/api/openstack_routers/openstack_routers_list.py +8 -4
  132. waldur_api_client/api/openstack_security_groups/openstack_security_groups_list.py +8 -4
  133. waldur_api_client/api/openstack_server_groups/openstack_server_groups_list.py +8 -4
  134. waldur_api_client/api/openstack_snapshots/openstack_snapshots_list.py +8 -4
  135. waldur_api_client/api/openstack_subnets/openstack_subnets_list.py +8 -4
  136. waldur_api_client/api/openstack_tenants/openstack_tenants_list.py +8 -4
  137. waldur_api_client/api/openstack_volume_availability_zones/openstack_volume_availability_zones_list.py +8 -4
  138. waldur_api_client/api/openstack_volume_types/openstack_volume_types_list.py +26 -4
  139. waldur_api_client/api/openstack_volumes/openstack_volumes_list.py +8 -4
  140. waldur_api_client/api/organization_groups/organization_groups_list.py +8 -4
  141. waldur_api_client/api/payment_profiles/payment_profiles_list.py +8 -4
  142. waldur_api_client/api/payments/payments_list.py +8 -4
  143. waldur_api_client/api/project_credits/project_credits_list.py +8 -4
  144. waldur_api_client/api/project_types/project_types_list.py +8 -4
  145. waldur_api_client/api/projects/projects_list.py +23 -4
  146. waldur_api_client/api/promotions_campaigns/promotions_campaigns_list.py +8 -4
  147. waldur_api_client/api/proposal_proposals/proposal_proposals_list.py +8 -4
  148. waldur_api_client/api/proposal_protected_calls/proposal_protected_calls_list.py +8 -4
  149. waldur_api_client/api/proposal_public_calls/proposal_public_calls_list.py +8 -4
  150. waldur_api_client/api/proposal_requested_offerings/proposal_requested_offerings_list.py +8 -4
  151. waldur_api_client/api/proposal_requested_resources/proposal_requested_resources_list.py +8 -4
  152. waldur_api_client/api/proposal_reviews/proposal_reviews_list.py +8 -4
  153. waldur_api_client/api/provider_invoice_items/provider_invoice_items_list.py +8 -4
  154. waldur_api_client/api/rancher_apps/rancher_apps_list.py +8 -4
  155. waldur_api_client/api/rancher_catalogs/rancher_catalogs_list.py +8 -4
  156. waldur_api_client/api/rancher_cluster_security_groups/rancher_cluster_security_groups_list.py +8 -4
  157. waldur_api_client/api/rancher_cluster_templates/rancher_cluster_templates_list.py +8 -4
  158. waldur_api_client/api/rancher_clusters/rancher_clusters_list.py +8 -4
  159. waldur_api_client/api/rancher_hpas/rancher_hpas_list.py +8 -4
  160. waldur_api_client/api/rancher_ingresses/rancher_ingresses_list.py +8 -4
  161. waldur_api_client/api/rancher_namespaces/rancher_namespaces_list.py +8 -4
  162. waldur_api_client/api/rancher_nodes/rancher_nodes_list.py +8 -4
  163. waldur_api_client/api/rancher_projects/rancher_projects_list.py +8 -4
  164. waldur_api_client/api/rancher_role_templates/rancher_role_templates_list.py +8 -4
  165. waldur_api_client/api/rancher_services/rancher_services_list.py +8 -4
  166. waldur_api_client/api/rancher_templates/rancher_templates_list.py +8 -4
  167. waldur_api_client/api/rancher_users/rancher_users_list.py +8 -4
  168. waldur_api_client/api/rancher_workloads/rancher_workloads_list.py +8 -4
  169. waldur_api_client/api/roles/roles_list.py +8 -4
  170. waldur_api_client/api/service_settings/service_settings_list.py +18 -17
  171. waldur_api_client/api/slurm_allocation_user_usage/slurm_allocation_user_usage_list.py +8 -4
  172. waldur_api_client/api/slurm_allocations/slurm_allocations_list.py +8 -4
  173. waldur_api_client/api/slurm_associations/slurm_associations_list.py +8 -4
  174. waldur_api_client/api/slurm_jobs/slurm_jobs_list.py +8 -4
  175. waldur_api_client/api/support_attachments/support_attachments_list.py +8 -4
  176. waldur_api_client/api/support_comments/support_comments_list.py +8 -4
  177. waldur_api_client/api/support_feedbacks/support_feedbacks_list.py +8 -4
  178. waldur_api_client/api/support_issues/support_issues_list.py +8 -4
  179. waldur_api_client/api/support_priorities/support_priorities_list.py +8 -4
  180. waldur_api_client/api/support_templates/support_templates_list.py +8 -4
  181. waldur_api_client/api/support_users/support_users_list.py +8 -4
  182. waldur_api_client/api/user_agreements/user_agreements_list.py +8 -4
  183. waldur_api_client/api/user_group_invitations/user_group_invitations_list.py +8 -4
  184. waldur_api_client/api/user_invitations/user_invitations_list.py +8 -4
  185. waldur_api_client/api/user_permission_requests/user_permission_requests_list.py +8 -4
  186. waldur_api_client/api/user_permissions/user_permissions_list.py +18 -17
  187. waldur_api_client/api/users/users_list.py +8 -4
  188. waldur_api_client/api/vmware_clusters/vmware_clusters_list.py +8 -4
  189. waldur_api_client/api/vmware_datastores/vmware_datastores_list.py +8 -4
  190. waldur_api_client/api/vmware_disks/vmware_disks_list.py +8 -4
  191. waldur_api_client/api/vmware_folders/vmware_folders_list.py +8 -4
  192. waldur_api_client/api/vmware_networks/vmware_networks_list.py +8 -4
  193. waldur_api_client/api/vmware_ports/vmware_ports_list.py +8 -4
  194. waldur_api_client/api/vmware_templates/vmware_templates_list.py +8 -4
  195. waldur_api_client/api/vmware_virtual_machine/vmware_virtual_machine_list.py +8 -4
  196. waldur_api_client/models/__init__.py +28 -16
  197. waldur_api_client/models/backend_resource.py +162 -0
  198. waldur_api_client/models/{resource_backend_id.py → backend_resource_import_request.py} +21 -13
  199. waldur_api_client/models/backend_resource_req.py +162 -0
  200. waldur_api_client/models/{resource_backend_metadata.py → backend_resource_req_request.py} +12 -11
  201. waldur_api_client/models/backend_resource_req_state_enum.py +11 -0
  202. waldur_api_client/models/backend_resource_request.py +96 -0
  203. waldur_api_client/models/{resource_set_state_erred.py → backend_resource_request_set_erred_request.py} +5 -5
  204. waldur_api_client/models/backend_resource_requests_list_o_item.py +9 -0
  205. waldur_api_client/models/backend_resource_requests_list_state_item.py +11 -0
  206. waldur_api_client/models/{order_details_attributes.py → backend_resource_requests_set_done_response_200.py} +6 -6
  207. waldur_api_client/models/{resource_options.py → backend_resource_requests_set_erred_response_200.py} +7 -22
  208. waldur_api_client/models/backend_resource_requests_start_processing_response_200.py +44 -0
  209. waldur_api_client/models/backend_resources_list_o_item.py +9 -0
  210. waldur_api_client/models/constance_settings.py +9 -0
  211. waldur_api_client/models/constance_settings_request.py +9 -0
  212. waldur_api_client/models/customer.py +0 -21
  213. waldur_api_client/models/customers_list_field_item.py +0 -1
  214. waldur_api_client/models/customers_retrieve_field_item.py +0 -1
  215. waldur_api_client/models/event_types_enum.py +5 -0
  216. waldur_api_client/models/merged_plugin_options.py +20 -0
  217. waldur_api_client/models/merged_plugin_options_request.py +20 -0
  218. waldur_api_client/models/nested_requested_offering.py +18 -0
  219. waldur_api_client/models/order_details.py +4 -14
  220. waldur_api_client/models/provider_requested_offering.py +10 -0
  221. waldur_api_client/models/requested_offering.py +10 -0
  222. waldur_api_client/models/{resource_set_limits.py → resource_response_status.py} +11 -11
  223. waldur_api_client/models/user_agreement.py +9 -11
  224. waldur_api_client/models/user_agreement_request.py +9 -11
  225. {waldur_api_client-7.6.5.dist-info → waldur_api_client-7.6.8.dist-info}/METADATA +1 -1
  226. {waldur_api_client-7.6.5.dist-info → waldur_api_client-7.6.8.dist-info}/RECORD +228 -209
  227. waldur_api_client/models/permission_project.py +0 -147
  228. waldur_api_client/models/resource_report.py +0 -73
  229. {waldur_api_client-7.6.5.dist-info → waldur_api_client-7.6.8.dist-info}/LICENSE +0 -0
  230. {waldur_api_client-7.6.5.dist-info → waldur_api_client-7.6.8.dist-info}/WHEEL +0 -0
@@ -0,0 +1,162 @@
1
+ from http import HTTPStatus
2
+ from typing import Any, Union
3
+ from uuid import UUID
4
+
5
+ import httpx
6
+
7
+ from ... import errors
8
+ from ...client import AuthenticatedClient, Client
9
+ from ...models.backend_resource_import_request import BackendResourceImportRequest
10
+ from ...models.resource import Resource
11
+ from ...types import Response
12
+
13
+
14
+ def _get_kwargs(
15
+ uuid: UUID,
16
+ *,
17
+ body: BackendResourceImportRequest,
18
+ ) -> dict[str, Any]:
19
+ headers: dict[str, Any] = {}
20
+
21
+ _kwargs: dict[str, Any] = {
22
+ "method": "post",
23
+ "url": f"/api/backend-resources/{uuid}/import_resource/",
24
+ }
25
+
26
+ _kwargs["json"] = body.to_dict()
27
+
28
+ headers["Content-Type"] = "application/json"
29
+
30
+ _kwargs["headers"] = headers
31
+ return _kwargs
32
+
33
+
34
+ def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Resource:
35
+ if response.status_code == 200:
36
+ response_200 = Resource.from_dict(response.json())
37
+
38
+ return response_200
39
+ raise errors.UnexpectedStatus(response.status_code, response.content)
40
+
41
+
42
+ def _build_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Response[Resource]:
43
+ return Response(
44
+ status_code=HTTPStatus(response.status_code),
45
+ content=response.content,
46
+ headers=response.headers,
47
+ parsed=_parse_response(client=client, response=response),
48
+ )
49
+
50
+
51
+ def sync_detailed(
52
+ uuid: UUID,
53
+ *,
54
+ client: AuthenticatedClient,
55
+ body: BackendResourceImportRequest,
56
+ ) -> Response[Resource]:
57
+ """
58
+ Args:
59
+ uuid (UUID):
60
+ body (BackendResourceImportRequest):
61
+
62
+ Raises:
63
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
64
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
65
+
66
+ Returns:
67
+ Response[Resource]
68
+ """
69
+
70
+ kwargs = _get_kwargs(
71
+ uuid=uuid,
72
+ body=body,
73
+ )
74
+
75
+ response = client.get_httpx_client().request(
76
+ **kwargs,
77
+ )
78
+
79
+ return _build_response(client=client, response=response)
80
+
81
+
82
+ def sync(
83
+ uuid: UUID,
84
+ *,
85
+ client: AuthenticatedClient,
86
+ body: BackendResourceImportRequest,
87
+ ) -> Resource:
88
+ """
89
+ Args:
90
+ uuid (UUID):
91
+ body (BackendResourceImportRequest):
92
+
93
+ Raises:
94
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
95
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
96
+
97
+ Returns:
98
+ Resource
99
+ """
100
+
101
+ return sync_detailed(
102
+ uuid=uuid,
103
+ client=client,
104
+ body=body,
105
+ ).parsed
106
+
107
+
108
+ async def asyncio_detailed(
109
+ uuid: UUID,
110
+ *,
111
+ client: AuthenticatedClient,
112
+ body: BackendResourceImportRequest,
113
+ ) -> Response[Resource]:
114
+ """
115
+ Args:
116
+ uuid (UUID):
117
+ body (BackendResourceImportRequest):
118
+
119
+ Raises:
120
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
121
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
122
+
123
+ Returns:
124
+ Response[Resource]
125
+ """
126
+
127
+ kwargs = _get_kwargs(
128
+ uuid=uuid,
129
+ body=body,
130
+ )
131
+
132
+ response = await client.get_async_httpx_client().request(**kwargs)
133
+
134
+ return _build_response(client=client, response=response)
135
+
136
+
137
+ async def asyncio(
138
+ uuid: UUID,
139
+ *,
140
+ client: AuthenticatedClient,
141
+ body: BackendResourceImportRequest,
142
+ ) -> Resource:
143
+ """
144
+ Args:
145
+ uuid (UUID):
146
+ body (BackendResourceImportRequest):
147
+
148
+ Raises:
149
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
150
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
151
+
152
+ Returns:
153
+ Resource
154
+ """
155
+
156
+ return (
157
+ await asyncio_detailed(
158
+ uuid=uuid,
159
+ client=client,
160
+ body=body,
161
+ )
162
+ ).parsed
@@ -0,0 +1,315 @@
1
+ import datetime
2
+ from http import HTTPStatus
3
+ from typing import Any, Union
4
+ from uuid import UUID
5
+
6
+ import httpx
7
+
8
+ from ... import errors
9
+ from ...client import AuthenticatedClient, Client
10
+ from ...models.backend_resource import BackendResource
11
+ from ...models.backend_resources_list_o_item import BackendResourcesListOItem
12
+ from ...types import UNSET, Response, Unset
13
+
14
+
15
+ def _get_kwargs(
16
+ *,
17
+ backend_id: Union[Unset, str] = UNSET,
18
+ created: Union[Unset, datetime.datetime] = UNSET,
19
+ modified: Union[Unset, datetime.datetime] = UNSET,
20
+ name: Union[Unset, str] = UNSET,
21
+ name_exact: Union[Unset, str] = UNSET,
22
+ o: Union[Unset, list[BackendResourcesListOItem]] = UNSET,
23
+ offering_uuid: Union[Unset, UUID] = UNSET,
24
+ page: Union[Unset, int] = UNSET,
25
+ page_size: Union[Unset, int] = UNSET,
26
+ project_uuid: Union[Unset, UUID] = UNSET,
27
+ ) -> dict[str, Any]:
28
+ params: dict[str, Any] = {}
29
+
30
+ params["backend_id"] = backend_id
31
+
32
+ json_created: Union[Unset, str] = UNSET
33
+ if not isinstance(created, Unset):
34
+ json_created = created.isoformat()
35
+ params["created"] = json_created
36
+
37
+ json_modified: Union[Unset, str] = UNSET
38
+ if not isinstance(modified, Unset):
39
+ json_modified = modified.isoformat()
40
+ params["modified"] = json_modified
41
+
42
+ params["name"] = name
43
+
44
+ params["name_exact"] = name_exact
45
+
46
+ json_o: Union[Unset, list[str]] = UNSET
47
+ if not isinstance(o, Unset):
48
+ json_o = []
49
+ for o_item_data in o:
50
+ o_item = o_item_data.value
51
+ json_o.append(o_item)
52
+
53
+ params["o"] = json_o
54
+
55
+ json_offering_uuid: Union[Unset, str] = UNSET
56
+ if not isinstance(offering_uuid, Unset):
57
+ json_offering_uuid = str(offering_uuid)
58
+ params["offering_uuid"] = json_offering_uuid
59
+
60
+ params["page"] = page
61
+
62
+ params["page_size"] = page_size
63
+
64
+ json_project_uuid: Union[Unset, str] = UNSET
65
+ if not isinstance(project_uuid, Unset):
66
+ json_project_uuid = str(project_uuid)
67
+ params["project_uuid"] = json_project_uuid
68
+
69
+ params = {k: v for k, v in params.items() if v is not UNSET and v is not None}
70
+
71
+ _kwargs: dict[str, Any] = {
72
+ "method": "get",
73
+ "url": "/api/backend-resources/",
74
+ "params": params,
75
+ }
76
+
77
+ return _kwargs
78
+
79
+
80
+ def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> list["BackendResource"]:
81
+ if response.status_code == 200:
82
+ response_200 = []
83
+ _response_200 = response.json()
84
+ for response_200_item_data in _response_200:
85
+ response_200_item = BackendResource.from_dict(response_200_item_data)
86
+
87
+ response_200.append(response_200_item)
88
+
89
+ return response_200
90
+ raise errors.UnexpectedStatus(response.status_code, response.content)
91
+
92
+
93
+ def _build_response(
94
+ *, client: Union[AuthenticatedClient, Client], response: httpx.Response
95
+ ) -> Response[list["BackendResource"]]:
96
+ return Response(
97
+ status_code=HTTPStatus(response.status_code),
98
+ content=response.content,
99
+ headers=response.headers,
100
+ parsed=_parse_response(client=client, response=response),
101
+ )
102
+
103
+
104
+ def sync_detailed(
105
+ *,
106
+ client: AuthenticatedClient,
107
+ backend_id: Union[Unset, str] = UNSET,
108
+ created: Union[Unset, datetime.datetime] = UNSET,
109
+ modified: Union[Unset, datetime.datetime] = UNSET,
110
+ name: Union[Unset, str] = UNSET,
111
+ name_exact: Union[Unset, str] = UNSET,
112
+ o: Union[Unset, list[BackendResourcesListOItem]] = UNSET,
113
+ offering_uuid: Union[Unset, UUID] = UNSET,
114
+ page: Union[Unset, int] = UNSET,
115
+ page_size: Union[Unset, int] = UNSET,
116
+ project_uuid: Union[Unset, UUID] = UNSET,
117
+ ) -> Response[list["BackendResource"]]:
118
+ """Mixin to optimize HEAD requests for DRF views bypassing serializer processing
119
+
120
+ Args:
121
+ backend_id (Union[Unset, str]):
122
+ created (Union[Unset, datetime.datetime]):
123
+ modified (Union[Unset, datetime.datetime]):
124
+ name (Union[Unset, str]):
125
+ name_exact (Union[Unset, str]):
126
+ o (Union[Unset, list[BackendResourcesListOItem]]):
127
+ offering_uuid (Union[Unset, UUID]):
128
+ page (Union[Unset, int]):
129
+ page_size (Union[Unset, int]):
130
+ project_uuid (Union[Unset, UUID]):
131
+
132
+ Raises:
133
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
134
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
135
+
136
+ Returns:
137
+ Response[list['BackendResource']]
138
+ """
139
+
140
+ kwargs = _get_kwargs(
141
+ backend_id=backend_id,
142
+ created=created,
143
+ modified=modified,
144
+ name=name,
145
+ name_exact=name_exact,
146
+ o=o,
147
+ offering_uuid=offering_uuid,
148
+ page=page,
149
+ page_size=page_size,
150
+ project_uuid=project_uuid,
151
+ )
152
+
153
+ response = client.get_httpx_client().request(
154
+ **kwargs,
155
+ )
156
+
157
+ return _build_response(client=client, response=response)
158
+
159
+
160
+ def sync(
161
+ *,
162
+ client: AuthenticatedClient,
163
+ backend_id: Union[Unset, str] = UNSET,
164
+ created: Union[Unset, datetime.datetime] = UNSET,
165
+ modified: Union[Unset, datetime.datetime] = UNSET,
166
+ name: Union[Unset, str] = UNSET,
167
+ name_exact: Union[Unset, str] = UNSET,
168
+ o: Union[Unset, list[BackendResourcesListOItem]] = UNSET,
169
+ offering_uuid: Union[Unset, UUID] = UNSET,
170
+ page: Union[Unset, int] = UNSET,
171
+ page_size: Union[Unset, int] = UNSET,
172
+ project_uuid: Union[Unset, UUID] = UNSET,
173
+ ) -> list["BackendResource"]:
174
+ """Mixin to optimize HEAD requests for DRF views bypassing serializer processing
175
+
176
+ Args:
177
+ backend_id (Union[Unset, str]):
178
+ created (Union[Unset, datetime.datetime]):
179
+ modified (Union[Unset, datetime.datetime]):
180
+ name (Union[Unset, str]):
181
+ name_exact (Union[Unset, str]):
182
+ o (Union[Unset, list[BackendResourcesListOItem]]):
183
+ offering_uuid (Union[Unset, UUID]):
184
+ page (Union[Unset, int]):
185
+ page_size (Union[Unset, int]):
186
+ project_uuid (Union[Unset, UUID]):
187
+
188
+ Raises:
189
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
190
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
191
+
192
+ Returns:
193
+ list['BackendResource']
194
+ """
195
+
196
+ return sync_detailed(
197
+ client=client,
198
+ backend_id=backend_id,
199
+ created=created,
200
+ modified=modified,
201
+ name=name,
202
+ name_exact=name_exact,
203
+ o=o,
204
+ offering_uuid=offering_uuid,
205
+ page=page,
206
+ page_size=page_size,
207
+ project_uuid=project_uuid,
208
+ ).parsed
209
+
210
+
211
+ async def asyncio_detailed(
212
+ *,
213
+ client: AuthenticatedClient,
214
+ backend_id: Union[Unset, str] = UNSET,
215
+ created: Union[Unset, datetime.datetime] = UNSET,
216
+ modified: Union[Unset, datetime.datetime] = UNSET,
217
+ name: Union[Unset, str] = UNSET,
218
+ name_exact: Union[Unset, str] = UNSET,
219
+ o: Union[Unset, list[BackendResourcesListOItem]] = UNSET,
220
+ offering_uuid: Union[Unset, UUID] = UNSET,
221
+ page: Union[Unset, int] = UNSET,
222
+ page_size: Union[Unset, int] = UNSET,
223
+ project_uuid: Union[Unset, UUID] = UNSET,
224
+ ) -> Response[list["BackendResource"]]:
225
+ """Mixin to optimize HEAD requests for DRF views bypassing serializer processing
226
+
227
+ Args:
228
+ backend_id (Union[Unset, str]):
229
+ created (Union[Unset, datetime.datetime]):
230
+ modified (Union[Unset, datetime.datetime]):
231
+ name (Union[Unset, str]):
232
+ name_exact (Union[Unset, str]):
233
+ o (Union[Unset, list[BackendResourcesListOItem]]):
234
+ offering_uuid (Union[Unset, UUID]):
235
+ page (Union[Unset, int]):
236
+ page_size (Union[Unset, int]):
237
+ project_uuid (Union[Unset, UUID]):
238
+
239
+ Raises:
240
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
241
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
242
+
243
+ Returns:
244
+ Response[list['BackendResource']]
245
+ """
246
+
247
+ kwargs = _get_kwargs(
248
+ backend_id=backend_id,
249
+ created=created,
250
+ modified=modified,
251
+ name=name,
252
+ name_exact=name_exact,
253
+ o=o,
254
+ offering_uuid=offering_uuid,
255
+ page=page,
256
+ page_size=page_size,
257
+ project_uuid=project_uuid,
258
+ )
259
+
260
+ response = await client.get_async_httpx_client().request(**kwargs)
261
+
262
+ return _build_response(client=client, response=response)
263
+
264
+
265
+ async def asyncio(
266
+ *,
267
+ client: AuthenticatedClient,
268
+ backend_id: Union[Unset, str] = UNSET,
269
+ created: Union[Unset, datetime.datetime] = UNSET,
270
+ modified: Union[Unset, datetime.datetime] = UNSET,
271
+ name: Union[Unset, str] = UNSET,
272
+ name_exact: Union[Unset, str] = UNSET,
273
+ o: Union[Unset, list[BackendResourcesListOItem]] = UNSET,
274
+ offering_uuid: Union[Unset, UUID] = UNSET,
275
+ page: Union[Unset, int] = UNSET,
276
+ page_size: Union[Unset, int] = UNSET,
277
+ project_uuid: Union[Unset, UUID] = UNSET,
278
+ ) -> list["BackendResource"]:
279
+ """Mixin to optimize HEAD requests for DRF views bypassing serializer processing
280
+
281
+ Args:
282
+ backend_id (Union[Unset, str]):
283
+ created (Union[Unset, datetime.datetime]):
284
+ modified (Union[Unset, datetime.datetime]):
285
+ name (Union[Unset, str]):
286
+ name_exact (Union[Unset, str]):
287
+ o (Union[Unset, list[BackendResourcesListOItem]]):
288
+ offering_uuid (Union[Unset, UUID]):
289
+ page (Union[Unset, int]):
290
+ page_size (Union[Unset, int]):
291
+ project_uuid (Union[Unset, UUID]):
292
+
293
+ Raises:
294
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
295
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
296
+
297
+ Returns:
298
+ list['BackendResource']
299
+ """
300
+
301
+ return (
302
+ await asyncio_detailed(
303
+ client=client,
304
+ backend_id=backend_id,
305
+ created=created,
306
+ modified=modified,
307
+ name=name,
308
+ name_exact=name_exact,
309
+ o=o,
310
+ offering_uuid=offering_uuid,
311
+ page=page,
312
+ page_size=page_size,
313
+ project_uuid=project_uuid,
314
+ )
315
+ ).parsed
@@ -0,0 +1,142 @@
1
+ from http import HTTPStatus
2
+ from typing import Any, Union
3
+ from uuid import UUID
4
+
5
+ import httpx
6
+
7
+ from ... import errors
8
+ from ...client import AuthenticatedClient, Client
9
+ from ...models.backend_resource import BackendResource
10
+ from ...types import Response
11
+
12
+
13
+ def _get_kwargs(
14
+ uuid: UUID,
15
+ ) -> dict[str, Any]:
16
+ _kwargs: dict[str, Any] = {
17
+ "method": "get",
18
+ "url": f"/api/backend-resources/{uuid}/",
19
+ }
20
+
21
+ return _kwargs
22
+
23
+
24
+ def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> BackendResource:
25
+ if response.status_code == 200:
26
+ response_200 = BackendResource.from_dict(response.json())
27
+
28
+ return response_200
29
+ raise errors.UnexpectedStatus(response.status_code, response.content)
30
+
31
+
32
+ def _build_response(
33
+ *, client: Union[AuthenticatedClient, Client], response: httpx.Response
34
+ ) -> Response[BackendResource]:
35
+ return Response(
36
+ status_code=HTTPStatus(response.status_code),
37
+ content=response.content,
38
+ headers=response.headers,
39
+ parsed=_parse_response(client=client, response=response),
40
+ )
41
+
42
+
43
+ def sync_detailed(
44
+ uuid: UUID,
45
+ *,
46
+ client: AuthenticatedClient,
47
+ ) -> Response[BackendResource]:
48
+ """
49
+ Args:
50
+ uuid (UUID):
51
+
52
+ Raises:
53
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
54
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
55
+
56
+ Returns:
57
+ Response[BackendResource]
58
+ """
59
+
60
+ kwargs = _get_kwargs(
61
+ uuid=uuid,
62
+ )
63
+
64
+ response = client.get_httpx_client().request(
65
+ **kwargs,
66
+ )
67
+
68
+ return _build_response(client=client, response=response)
69
+
70
+
71
+ def sync(
72
+ uuid: UUID,
73
+ *,
74
+ client: AuthenticatedClient,
75
+ ) -> BackendResource:
76
+ """
77
+ Args:
78
+ uuid (UUID):
79
+
80
+ Raises:
81
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
82
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
83
+
84
+ Returns:
85
+ BackendResource
86
+ """
87
+
88
+ return sync_detailed(
89
+ uuid=uuid,
90
+ client=client,
91
+ ).parsed
92
+
93
+
94
+ async def asyncio_detailed(
95
+ uuid: UUID,
96
+ *,
97
+ client: AuthenticatedClient,
98
+ ) -> Response[BackendResource]:
99
+ """
100
+ Args:
101
+ uuid (UUID):
102
+
103
+ Raises:
104
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
105
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
106
+
107
+ Returns:
108
+ Response[BackendResource]
109
+ """
110
+
111
+ kwargs = _get_kwargs(
112
+ uuid=uuid,
113
+ )
114
+
115
+ response = await client.get_async_httpx_client().request(**kwargs)
116
+
117
+ return _build_response(client=client, response=response)
118
+
119
+
120
+ async def asyncio(
121
+ uuid: UUID,
122
+ *,
123
+ client: AuthenticatedClient,
124
+ ) -> BackendResource:
125
+ """
126
+ Args:
127
+ uuid (UUID):
128
+
129
+ Raises:
130
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
131
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
132
+
133
+ Returns:
134
+ BackendResource
135
+ """
136
+
137
+ return (
138
+ await asyncio_detailed(
139
+ uuid=uuid,
140
+ client=client,
141
+ )
142
+ ).parsed
@@ -73,7 +73,8 @@ def sync_detailed(
73
73
  page: Union[Unset, int] = UNSET,
74
74
  page_size: Union[Unset, int] = UNSET,
75
75
  ) -> Response[list["Offering"]]:
76
- """
76
+ """Mixin to optimize HEAD requests for DRF views bypassing serializer processing
77
+
77
78
  Args:
78
79
  field (Union[Unset, list[BookingOfferingsListFieldItem]]):
79
80
  page (Union[Unset, int]):
@@ -107,7 +108,8 @@ def sync(
107
108
  page: Union[Unset, int] = UNSET,
108
109
  page_size: Union[Unset, int] = UNSET,
109
110
  ) -> list["Offering"]:
110
- """
111
+ """Mixin to optimize HEAD requests for DRF views bypassing serializer processing
112
+
111
113
  Args:
112
114
  field (Union[Unset, list[BookingOfferingsListFieldItem]]):
113
115
  page (Union[Unset, int]):
@@ -136,7 +138,8 @@ async def asyncio_detailed(
136
138
  page: Union[Unset, int] = UNSET,
137
139
  page_size: Union[Unset, int] = UNSET,
138
140
  ) -> Response[list["Offering"]]:
139
- """
141
+ """Mixin to optimize HEAD requests for DRF views bypassing serializer processing
142
+
140
143
  Args:
141
144
  field (Union[Unset, list[BookingOfferingsListFieldItem]]):
142
145
  page (Union[Unset, int]):
@@ -168,7 +171,8 @@ async def asyncio(
168
171
  page: Union[Unset, int] = UNSET,
169
172
  page_size: Union[Unset, int] = UNSET,
170
173
  ) -> list["Offering"]:
171
- """
174
+ """Mixin to optimize HEAD requests for DRF views bypassing serializer processing
175
+
172
176
  Args:
173
177
  field (Union[Unset, list[BookingOfferingsListFieldItem]]):
174
178
  page (Union[Unset, int]):
@@ -240,7 +240,8 @@ def sync_detailed(
240
240
  state: Union[Unset, list[BookingResourcesListStateItem]] = UNSET,
241
241
  visible_to_username: Union[Unset, str] = UNSET,
242
242
  ) -> Response[list["BookingResource"]]:
243
- """
243
+ """Mixin to optimize HEAD requests for DRF views bypassing serializer processing
244
+
244
245
  Args:
245
246
  backend_id (Union[Unset, str]):
246
247
  category_uuid (Union[Unset, UUID]):
@@ -361,7 +362,8 @@ def sync(
361
362
  state: Union[Unset, list[BookingResourcesListStateItem]] = UNSET,
362
363
  visible_to_username: Union[Unset, str] = UNSET,
363
364
  ) -> list["BookingResource"]:
364
- """
365
+ """Mixin to optimize HEAD requests for DRF views bypassing serializer processing
366
+
365
367
  Args:
366
368
  backend_id (Union[Unset, str]):
367
369
  category_uuid (Union[Unset, UUID]):
@@ -477,7 +479,8 @@ async def asyncio_detailed(
477
479
  state: Union[Unset, list[BookingResourcesListStateItem]] = UNSET,
478
480
  visible_to_username: Union[Unset, str] = UNSET,
479
481
  ) -> Response[list["BookingResource"]]:
480
- """
482
+ """Mixin to optimize HEAD requests for DRF views bypassing serializer processing
483
+
481
484
  Args:
482
485
  backend_id (Union[Unset, str]):
483
486
  category_uuid (Union[Unset, UUID]):
@@ -596,7 +599,8 @@ async def asyncio(
596
599
  state: Union[Unset, list[BookingResourcesListStateItem]] = UNSET,
597
600
  visible_to_username: Union[Unset, str] = UNSET,
598
601
  ) -> list["BookingResource"]:
599
- """
602
+ """Mixin to optimize HEAD requests for DRF views bypassing serializer processing
603
+
600
604
  Args:
601
605
  backend_id (Union[Unset, str]):
602
606
  category_uuid (Union[Unset, UUID]):